anti-phantom-symbols

Verify APIs, imports, methods, and class members against a codebase.

Updated Jun 27, 2026
One-click install
npx skills add https://github.com/coff33ninja/ai-skills-mcp --skill anti-phantom-symbols
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: anti-phantom-symbols
Source: https://github.com/coff33ninja/ai-skills-mcp/tree/main/skills/anti-phantom-symbols
Command: npx skills add https://github.com/coff33ninja/ai-skills-mcp --skill anti-phantom-symbols

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) components.

What problem does it solve?

The skill solves the issue of Scaffolding Hallucination where LLMS generate plausible code but with missing APIs or imports.

Core Features & Use Cases

  • Method Existence Verification: Checks for the existence of methods on class objects before they are called.
  • Import Verification: Validates imported modules and symbols before use.
  • Runtime Verification: Performs runtime checks on method calls, import paths, and class constructors to avoid runtime errors.
  • Use Case: Prevents issues during execution caused by fictional APIs, imports, or class members.

Quick Start

Verify that the method session.execution_options(...) exists on AsyncSession before calling it.

Frequently Asked Questions about anti-phantom-symbols

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I verify API and import existence to prevent LLM code hallucination?

To prevent LLM code hallucination, verify API and import existence by checking methods, class members, and imported modules against your project's codebase and framework documentation before execution.

How can I check if a method exists on a class object before calling it in generated code?

You can check method existence on class objects by performing runtime verification against the project codebase, ensuring the method signature is valid before the code attempts to call it.

What is the best way to validate imported modules and symbols to avoid runtime errors?

The best way to validate imported modules and symbols is to verify import paths and class constructors against framework documentation, ensuring imported items actually exist before runtime execution.

How do I perform runtime verification on class constructors and import paths?

Runtime verification on class constructors and import paths involves checking the actual existence of APIs and class members in the codebase, preventing issues caused by fictional or missing imports.

Can I use this import validation tool for code generation and modification workflows?

Yes, this import validation tool is specifically applicable to code generation and modification workflows, ensuring reliability and correctness by verifying generated APIs and imports against existing codebase documentation.

Why does generated code fail with missing APIs during execution?

Generated code fails with missing APIs during execution due to scaffolding hallucination, where plausible code is generated with fictional imports or methods that do not exist in the project's framework documentation.