Skip to main content

Documentor

An enterprise-grade AI documentation suite. It ingests a codebase, parses it semantically, generates accurate documentation using LLMs, and serves it via CLI, Web UI, and CI/CD pipelines.

Installation

Recommended Method (pipx)

Because Documentor is a standalone CLI tool, the best way to install it on modern Linux/macOS systems (which enforce PEP 668) is using pipx. This installs Documentor in an isolated environment while exposing the CLI globally.

# If you don't have pipx installed: python3 -m pip install --user pipx
pipx install git+https://github.com/nirajmatere/documentor.git

Alternative Methods

If you are inside an active virtual environment (like .venv/), you can use standard pip:

pip install git+https://github.com/nirajmatere/documentor.git

(Note: If you attempt this globally on newer Linux distributions without pipx, you will get an externally-managed-environment error. You can bypass this by appending --break-system-packages, though pipx is heavily preferred).

BYO-LLM (Bring Your Own LLM)

Documentor uses LiteLLM under the hood, allowing you to use your preferred model (OpenAI, Anthropic, Gemini, DeepSeek, local models via Ollama, etc.).

Run the interactive setup command to configure your API keys:

documentor configure

(Alternatively, you can just export your keys directly in your terminal, e.g. export OPENAI_API_KEY="sk-...")

Usage

1. Command Line Interface (CLI)

To generate documentation for a repository, run:

documentor generate /path/to/your/repo --model gpt-4o-mini

Once the repository is indexed, you can chat with your codebase using RAG:

documentor chat "How does the authentication system work?" --path /path/to/your/repo

2. Web UI (Playground)

Prefer a visual interface? Spin up the beautifully designed, glassmorphic Web UI:

documentor serve --port 8000

Then open http://localhost:8000 in your browser.

3. GitHub Action (CI/CD)

Documentor comes packaged as a lightning-fast Docker Action. You can automate documentation generation on your Pull Requests by creating .github/workflows/documentor.yml in your target repository:

name: Generate AI Docs
on:
  pull_request:
    branches: [ main ]
jobs:
  docs:
    runs-on: ubuntu-latest
    permissions:
      contents: write
    steps:
      - uses: actions/checkout@v4
        with:
          fetch-depth: 0
      - uses: nirajmatere/documentor@main
        with:
          model: 'gpt-4o-mini'
        env:
          OPENAI_API_KEY: ${{ secrets.OPENAI_API_KEY }}
      - run: |
          git config --global user.name 'github-actions[bot]'
          git config --global user.email 'github-actions[bot]@users.noreply.github.com'
          git add docs/ ARCHITECTURE.md QUICKSTART.md
          git commit -m "docs: Auto-update AI documentation" || echo "No changes to commit"
          git push

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

documentor_ai-0.1.0.tar.gz (16.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

documentor_ai-0.1.0-py3-none-any.whl (17.6 kB view details)

Uploaded Python 3

File details

Details for the file documentor_ai-0.1.0.tar.gz.

File metadata

  • Download URL: documentor_ai-0.1.0.tar.gz
  • Upload date:
  • Size: 16.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.12.3

File hashes

Hashes for documentor_ai-0.1.0.tar.gz
Algorithm Hash digest
SHA256 271a82715903c8afe3c29c223825995dbfa94c036057bac5f29015f76ca3efbd
MD5 03883eb69845ebd1cde019c28dd7a0b2
BLAKE2b-256 e4bc3f4b230eedb24fc601a30457550113b20b30129728bef099e23982e1ae2e

See more details on using hashes here.

File details

Details for the file documentor_ai-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: documentor_ai-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 17.6 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.12.3

File hashes

Hashes for documentor_ai-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 c4c622ea26788072802adb1aeb756d853eec127ce6b58949d73a1231068d03d8
MD5 92e7a635bad4fb84190c7b0665313f40
BLAKE2b-256 bc1cce73be6e5d2c760ba8983f97cf7c79053a4e66b07648d6135aa3335e8ebc

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page