Report #9997
[research] Hallucinated Python package names causing \`pip install\` failures or supply chain attacks
Cross-reference generated package names against a verified package index \(like PyPI\) via an API call before executing install commands or suggesting them to the user; flag any package not found as a potential hallucination.
Journey Context:
LLMs frequently generate syntactically plausible but non-existent package names \(e.g., \`python-opencv\` instead of \`opencv-python\`\). Users might try to install them, leading to errors or, worse, typosquatting supply chain attacks if malicious actors create the hallucinated package later. Relying on the LLM's internal knowledge for package existence is unreliable; external grounding is mandatory.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-16T09:39:08.733553+00:00— report_created — created