Skip to main content

AI-powered API documentation for Python projects — one command, full docs.

Project description

dinorex-py

AI-powered API documentation for Python projects — one command, full docs.

The Python sibling of dinorex.
Point it at any Python backend and get a live interactive docs UI instantly.

Supported frameworks

Framework Route detection Model/schema detection
FastAPI @router.get, @app.get, APIRouter Pydantic v1 & v2 BaseModel
Flask @app.route, @bp.route, MethodView Marshmallow schemas
Django urls.py path() / re_path(), CBVs Django ORM models.Model
DRF ViewSet, APIView, @action ModelSerializer, Serializer
Falcon on_get, on_post … responders
Sanic @app.route, @bp.route
Litestar @get, @post, Controller Pydantic / attrs
Starlette Route(), Mount() Pydantic
Tornado RequestHandler subclasses
aiohttp RouteTableDef, add_route
SQLAlchemy Column, mapped_column
Tortoise ORM fields.CharField

Installation

pip install dinorex-py

Quick start

# Anthropic (default)
export ANTHROPIC_API_KEY=sk-ant-...
dinorex scan /path/to/your/project

# Groq (free)
export GROQ_API_KEY=gsk_...
dinorex scan /path/to/your/project --provider groq

# Custom port
dinorex scan . -p 8080

Project structure

dinorex-py/
├── src/
│   └── dinorex_py/
│       ├── __init__.py
│       ├── cli.py          # Click CLI entry point
│       ├── scanner.py      # File discovery for all Python frameworks
│       ├── agent.py        # Anthropic Claude agent
│       ├── agent_groq.py   # Groq/Llama3 agent (free tier)
│       ├── server.py       # Flask server + REST API
│       ├── store.py        # Persistent spec cache + diff logic
│       └── public/         # Frontend UI (shared with dinorex Node)
├── pyproject.toml
└── README.md

How it works

  1. Scan — discovers route files, controllers, services, and models using glob patterns tuned for every Python framework.
  2. Analyse — sends the source code to Claude (or Llama3 via Groq) which extracts a structured JSON spec.
  3. Cache — saves the spec and file hashes to .dinorex/spec.json. Re-runs are incremental — only changed files are re-analysed.
  4. Serve — starts a local Flask server with the interactive UI.

Environment variables

Variable Description
ANTHROPIC_API_KEY Required for Anthropic provider
GROQ_API_KEY Required for Groq provider
DINOREX_PROVIDER Set default provider (anthropic or groq)

License

MIT

Project details


Download files

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

Source Distribution

dinorex_py-0.1.2.tar.gz (22.0 kB view details)

Uploaded Source

Built Distribution

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

dinorex_py-0.1.2-py3-none-any.whl (36.2 kB view details)

Uploaded Python 3

File details

Details for the file dinorex_py-0.1.2.tar.gz.

File metadata

  • Download URL: dinorex_py-0.1.2.tar.gz
  • Upload date:
  • Size: 22.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.15

File hashes

Hashes for dinorex_py-0.1.2.tar.gz
Algorithm Hash digest
SHA256 63fa7f6915884b5f608b459df0eb3cba3fd71c257a78714e8ecacf385d02107f
MD5 c9b532ac2311ba5a714ddef982290592
BLAKE2b-256 0aefc110117a10bf3104141ef06f66307a3ba8ec7b7b1059fa39f62e417afd41

See more details on using hashes here.

File details

Details for the file dinorex_py-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: dinorex_py-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 36.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.15

File hashes

Hashes for dinorex_py-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 6b9b6e4f54554ec03eb56bddda19c430e4d83c4daf551d8fc397a4f31f4ef2cf
MD5 fc1cf84081a0e855baa70f5cccb9853d
BLAKE2b-256 bb12f1f80ba7f65a253a98b63d9cd8256db46308c8b8486e05ac41dc9fcc642e

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