autodoctools
v1.0.4
Published
AI-powered README generator CLI
Readme
AutoDocTools CLI (autodoctools)
AutoDocTools helps you generate and maintain a README.md from your project files using AI-assisted analysis.
This README is for npm users of the CLI package.
Install / run
Use it directly with npx:
npx autodoctools --helpAfter install, the executable name is:
autodoc-aiSo these are equivalent patterns:
npx autodoctools generate .
autodoc-ai generate .Commands you will use
Initialize config in your project:
autodoc-ai init .Generate README once:
autodoc-ai generate .Keep README updated while you code:
autodoc-ai watch .AI setup
AutoDocTools supports:
- Groq (cloud API)
- Ollama (local runtime)
Option A: Groq
- Create an API key at https://console.groq.com.
- Export it in your shell:
export GROQ_API_KEY="gsk_your_key_here"- Run generation:
autodoc-ai generate .Option B: Ollama
- Start Ollama locally.
- Pull a model:
ollama pull codellama:7b- (Optional) set host if not default:
export OLLAMA_BASE_URL="http://localhost:11434"- Set provider to
ollamain.autodoc.json(example below), then generate.
Where to put AI requirements
API keys / endpoints
- Put secrets in environment variables:
GROQ_API_KEYOLLAMA_BASE_URL(optional)
- Do not commit keys into
.autodoc.json.
AI behavior config
Run:
autodoc-ai init .This creates .autodoc.json in your project root.
Example AI config:
{
"version": "1",
"output": "./README.md",
"ai": {
"provider": "groq",
"model": "llama3-70b-8192",
"fallback": "ollama",
"ollamaModel": "codellama:7b"
}
}How AI analysis works
You do not paste your code manually.
When you run generate or watch, AutoDocTools:
- scans the target directory,
- applies ignore rules,
- builds a compact project snapshot,
- sends that snapshot to the configured provider,
- uses returned insights to build README sections.
So the "input" for AI is simply your project files in the directory you pass:
autodoc-ai generate /path/to/projectUseful options
Generate to custom output:
autodoc-ai generate . --output ./README.mdDisable AI:
autodoc-ai generate . --no-aiPreview without writing:
autodoc-ai generate . --dry-runSet watch debounce:
autodoc-ai watch . --debounce 2000Quick start (copy/paste)
# from your repository root
npx autodoctools init .
export GROQ_API_KEY="gsk_your_key_here"
npx autodoctools generate .
npx autodoctools watch .License
MIT
