Pular para o conteúdo
TakoAPI
Voltar às skills

doc-accurate-codegen

por tobisamaa

Calendar & Scheduling
343Downloads informados pelo clawskills.sh
0Visualizações
0 curtidaEntre para curtir esta skill
—Ainda sem avaliações
Sua avaliação

Resumo

Generate code that references actual documentation, preventing hallucination bugs.

Descrição

O que esta skill faz

Enforces documentation-first code generation to prevent LLM hallucination bugs. Before writing any code, it loads relevant docs, extracts actual API signatures, and validates the output against them. Works for API usage, configuration files, and feature implementation.

Code generators that rely on training data alone will hallucinate method names and parameters; this skill forces every generation step to reference live documentation instead.

Quando usá-la

  • Generating code for an unfamiliar third-party API
  • Writing configuration files for a new tool or framework
  • Updating code after a library releases breaking changes
  • Implementing a feature with an SDK you haven't used before
  • Verifying that a method signature hasn't been renamed or removed

Exemplo de fluxo de trabalho

ENTRADA

User asks: Write a Python script that uses the requests library to fetch paginated API results

AGENTE
  1. 1

    Fetches the official requests library documentation via web_fetch

  2. 2

    Extracts method signatures for Session, get, and response handling

  3. 3

    Generates Python code using exact parameter names and return types from docs

  4. 4

    Validates generated code against the extracted signatures

  5. 5

    Returns code with documentation source references and validation status

SAÍDA

Validated Python script with inline doc source references and confirmed API signatures

Requisitos

  • BRAVE_API_KEY environment variable

Instalação

clawhub install tobisamaa/doc-accurate-codegen

Execute o comando da CLI ou cole o prompt no Claude Code, Cursor, Codex ou no agente de código que você usa.

Links