source-driven-development

Writes library-specific code verified against authoritative sources with citations for every decision.

Updated Aug 5, 2026
One-click install
npx skills add https://github.com/amirbiron/claude-skills --skill source-driven-development-amirbiron
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: source-driven-development
Source: https://github.com/amirbiron/claude-skills/tree/main/skills/source-driven-development
Command: npx skills add https://github.com/amirbiron/claude-skills --skill source-driven-development-amirbiron

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? AI-generated code for libraries, SDKs, and APIs is often written from stale training data, producing outdated signatures, deprecated patterns, and invented endpoints that look correct but break at runtime. This Skill enforces a workflow where every library-specific decision is grounded in a verifiable source — the installed library's code, official documentation, changelogs, or specs — and explicitly cited. ## Core Features & Use Cases - Version identification from the project: Reads declared and installed versions from requirements.txt, pyproject.toml, pip freeze, and runtime version attributes, with the installed version winning over the declared one. - Source authority hierarchy: Prioritizes the library's own source code, then official docs, changelogs, issues/PRs, and standards — explicitly rejecting Stack Overflow, blog posts, and training-data memory as authorities. - Version-pinned documentation retrieval: Uses Context7 (ctx7) queries with version-scoped identifiers to fetch docs matching the installed release, with a three-attempt cap and explicit unverified marking on failure. - Mandatory citation and honesty: Every non-trivial decision gets a full link or code reference; anything unverifiable is marked as unverified rather than silently guessed, and endpoints are never constructed by analogy. - Use Case: When writing a call against python-telegram-bot, MCP, or pymongo, the Skill reads the installed package source to confirm current class names and signatures, cites the exact file, and flags any conflict with existing project code for the user to decide. ## Quick Start Ask the assistant to implement an API call using the installed version of a specific library and require a verifiable source citation for every library-specific decision.

Frequently Asked Questions about source-driven-development

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

FAQPage Schema
How do I write code against an API without relying on outdated training data?

Identify the installed version from the project files, then read the library's own source code or version-pinned official documentation before writing any call. Cite the exact source for each signature, field name, or status code you use.

How to fetch version-specific library documentation with Context7?

Run npx ctx7@latest library with the library name to get an /org/project identifier and version list, then query docs using the version-scoped identifier /org/project/version. Keep each query to a single focused topic and stop after three attempts.

What sources are authoritative when verifying library API usage?

The library's own source code ranks first, followed by official documentation, changelogs and release notes, repository issues and PRs, and formal standards like RFCs. Stack Overflow, blog posts, AI-generated docs, and model memory are not authoritative.

Does this approach verify that the code actually runs correctly?

No. Source citation only proves the code matches the documentation, not that it works against the real system. Runtime verification is handled by a separate skill called verify-against-reality, and both steps are required.

When should I not use source-driven development?

Skip it for pure logic that is correct or wrong entirely within your own code, such as loops, conditions, data structures, business rules, renames, and file moves. It also does not apply when the user explicitly prioritizes speed over verification.

What should I do when no source can be found for an API pattern?

Mark the decision explicitly as unverified and state that it comes from memory and may be outdated. Never silently fall back to a guess, fill in a plausible value, or construct endpoints by analogy from other services.