Engineering-grade UX with code-aware intake, API/schema panels, test results, diffs, and implementation outputs.
Domain: Developer / API Β· Suite: Developer Productivity Suite Β· Accent: #60a5fa
π Quick Start Β· β¨ Features Β· ποΈ Customization Β· π§ LLM Providers Β· π§ͺ Testing Β· π§― Troubleshooting
Api Doc Generator is a standalone, browser-based AI workflow app for Developer / API. It turns structured inputs, uploaded files, and project-specific settings into reviewable outputs using a deterministic local engine plus optional local/cloud LLM enhancement.
Core job: Code/OpenAPI/schema β publishable developer documentation.
Designed for: Domain operator, business owner, analyst, or team member who needs this workflow executed reliably.
Why use it:
- π§© Standalone project folder: run this project by itself without depending on a central dashboard.
- π₯οΈ Elegant GUI: includes project-specific panels, structured forms, upload handling, output preview, and exports.
- π§ Model-flexible: choose local models for privacy or cloud models for stronger reasoning.
- π§Ύ Auditable: every run is stored in SQLite with inputs, settings, result, and export history.
- π« No fake live data: external systems are only used when real API keys/connectors are configured.
- π‘οΈ Human review gates: sensitive legal, medical, hiring, finance, or security outputs are flagged for review.
- OpenAPI import
- endpoint grouping
- auth examples
- SDK snippets
- changelog
- error catalog
- try-it console
- version diff
- Postman/Insomnia export
- β‘ FastAPI backend with documented JSON endpoints.
- π¨ Responsive web UI with dark, polished SaaS-style layout.
- π File upload and text extraction for common document/code formats.
- ποΈ Job history saved locally in
data/*.sqlite3. - π Encrypted provider settings for API keys and local endpoints.
- π€ Exports to Markdown, JSON, DOCX, and PDF when dependencies are available.
- π Provider routing for local and cloud LLMs.
- π§ͺ Local test file to verify the project runs.
UX profile: Developer Workbench
Workflow layout: Code/schema/log intake β analysis β diff/tests/docs β implementation checklist
Empty state: Paste code, schema, logs, or upload source files. Real repository actions require Git/CI connectors.
- Endpoint explorer
- OpenAPI preview
- SDK snippet tabs
- Auth/error catalog
- Docs publish checklist
- Inspect
- Analyze
- Patch
- Test
- Ship
- Coverage readiness
- Risk/bug count
- Implementation clarity
- Docs completeness
- Parse endpoints
- Generate OpenAPI outline
- Build SDK examples
- Create changelog notes
These are the main fields exposed by the GUI and /api/run. Required fields are enforced before execution.
| Field | Type | Required | Default | Purpose |
|---|---|---|---|---|
codeCode |
text | Yes | β | Affects input: Code. |
openapiOpenAPI |
text | Yes | β | Affects input: OpenAPI. |
schemaschema |
select | Yes | β | Affects input: schema. |
work_briefWork brief / source text / URL / instructions |
textarea | Yes | β | Paste the material, URL, description, or instruction needed for this project. |
This project is not a generic prompt box. The customization controls are connected to workflow behavior, validation, output shape, and export format.
| Field | Type | Required | Default | Purpose |
|---|---|---|---|---|
execution_modeExecution mode |
select | No | Production | Controls strictness, depth, and output format for this project workflow. |
audience_levelaudience level |
select | No | general | Affects customization: audience level. |
frameworkframework |
select | No | auto detect | Affects customization: framework. |
language_exampleslanguage examples |
select | No | English | Affects customization: language examples. |
auth_schemeauth scheme |
text | No | β | Affects customization: auth scheme. |
version_styleversion style |
select | No | β | Affects customization: version style. |
public_private_endpointspublic/private endpoints |
textarea | No | β | Affects customization: public/private endpoints. |
code_stylecode style |
select | No | β | Affects customization: code style. |
output_formatoutput format |
select | No | Markdown | Affects customization: output format. |
languagelanguage |
select | No | English | Affects customization: language. |
privacy_modeprivacy mode |
select | No | cloud allowed | Affects customization: privacy mode. |
confidence_thresholdConfidence threshold |
slider | No | 75 | Items below this confidence are escalated to the human review queue. |
- Execution mode: Draft, Production, Audit / strict review, JSON/API output
- audience level: general, executive, technical, legal, medical, student, customer
- framework: auto detect, React, Next.js, Laravel, NestJS, .NET, Django, FastAPI, Custom
- language examples: English, Arabic, Egyptian Arabic, French, German, Spanish
- output format: Markdown, JSON, CSV, PDF, DOCX, XLSX
- language: English, Arabic, Egyptian Arabic, French, German, Spanish
- privacy mode: cloud allowed, local only, redact sensitive data
You can run the project with the local deterministic engine, or enhance the output with a configured LLM provider.
| Provider Type | Examples | Best For |
|---|---|---|
| Local OpenAI-compatible | Ollama, LM Studio, vLLM | Private files, offline/local workflows, cost control |
| Cloud OpenAI-compatible | OpenAI, OpenRouter, custom gateway | General high-quality generation and structured output |
| Anthropic | Claude models | Long-context reasoning and document-heavy workflows |
| Google Gemini | Gemini models | Multimodal or Google ecosystem workflows |
| Mistral | Mistral API | Fast European cloud models |
| Azure OpenAI | Azure deployments | Enterprise-controlled cloud deployment |
| AWS Bedrock | Bedrock-hosted models | AWS enterprise environments |
| Use Case | Recommendation |
|---|---|
| Drafting | fast cloud or local instruct model |
| Reasoning | strong reasoning model |
| Private documents | local model via Ollama/LM Studio/vLLM |
| Vision/PDF pages | vision-capable model when image pages are used |
cd api-doc-generatorchmod +x run_gui.sh
./run_gui.shSet-ExecutionPolicy -Scope Process -ExecutionPolicy Bypass
.\run_gui_windows.ps1http://127.0.0.1:9102
Use this when you want full control instead of the run scripts.
cd api-doc-generator
python -m venv .venv
source .venv/bin/activate # Windows: .venv\Scripts\activate
python -m pip install --upgrade pip
pip install -r requirements.txt
cp .env.example .env # Windows: copy .env.example .env
uvicorn app.main:app --host 127.0.0.1 --port 9102The project can be configured through the GUI settings screen or .env/environment variables.
| Variable | Purpose |
|---|---|
AI_SUITE_HOST |
Host to bind the local app, usually 127.0.0.1. |
AI_SUITE_PORT |
Port for this project GUI, default 9102. |
AI_SUITE_DB |
SQLite database path for job history. |
AI_SUITE_SECRET_KEY |
Secret used for local encryption/signing. Set this in production. |
OPENAI_API_KEY |
Enables OpenAI-compatible cloud calls. |
ANTHROPIC_API_KEY |
Enables Anthropic/Claude calls. |
GEMINI_API_KEY |
Enables Google Gemini calls. |
OPENROUTER_API_KEY |
Enables OpenRouter model routing. |
MISTRAL_API_KEY |
Enables Mistral cloud models. |
AZURE_OPENAI_ENDPOINT |
Azure OpenAI endpoint URL. |
AZURE_OPENAI_API_KEY |
Azure OpenAI key. |
AZURE_OPENAI_DEPLOYMENT |
Azure deployment name. |
OLLAMA_BASE_URL |
Local Ollama OpenAI-compatible base URL. |
LMSTUDIO_BASE_URL |
Local LM Studio OpenAI-compatible base URL. |
VLLM_BASE_URL |
Local vLLM OpenAI-compatible base URL. |
- Open the local URL.
- Review the project purpose and workflow lanes.
- Fill the required input fields.
- Adjust only the project-related customization controls.
- Upload source files when needed.
- Choose
Rule Enginefor local deterministic output or select a configured LLM provider. - Run the workflow.
- Review warnings, scorecards, and output sections.
- Export the result as Markdown, JSON, DOCX, or PDF.
- Code/OpenAPI/schema
- publishable developer documentation
- api_doc
- code_inventory
- developer_review
- Endpoint inventory
- Auth notes
- Examples
- OpenAPI gaps
- Correctness
- Security risk
- Maintainability
- Test coverage
- Deployment readiness
- Markdown/HTML docs
- OpenAPI patches
- Postman collection
- SDK examples
The export system is designed for reviewable deliverables. For regulated or business-critical work, export drafts should be reviewed before sending to clients, customers, patients, employees, authorities, or production systems.
Configured integrations in this standalone folder:
- File upload
- REST API
- Export download
- Job history
- repository or source files
- CI/CD or observability connector for live system data
- human approval before modifying production systems
Important: this project does not simulate live data. If a workflow needs live Shopify, ATS, ERP, tax, customs, medical, security, market, map, analytics, or repository data, it must be connected with valid credentials and real API access. Missing connectors should produce clear setup errors rather than invented results.
- Show uncertainty and confidence
- Cite evidence from input when possible
- Human review required for legal, medical, financial, hiring, or security decisions
- Do not invent facts absent from input
Recommended operating rules:
- β Use local models for private or sensitive files.
- β Keep API keys out of Git.
- β Review low-confidence or high-impact outputs manually.
- β
Keep source files and exported deliverables organized under
data/. - β Do not treat AI output as legal, medical, tax, hiring, trading, or security authority without expert review.
Run the local smoke test:
python tests/test_single_project.pyRun a health check after starting the server:
curl http://127.0.0.1:9102/api/healthExpected result: the API returns ok: true and identifies this project.
| Method | Endpoint | Use |
|---|---|---|
GET |
/ |
Opens the browser GUI. |
GET |
/api/health |
Health check for deployment and uptime monitoring. |
GET |
/api/projects |
Returns the local project configuration. |
GET |
/api/projects/{slug} |
Returns the project plugin metadata. |
GET |
/api/providers |
Lists configured providers and local/cloud options. |
POST |
/api/providers |
Saves provider settings/API keys. |
POST |
/api/upload |
Uploads source files for extraction or context. |
POST |
/api/run |
Runs the project workflow. |
GET |
/api/jobs |
Lists previous runs and job history. |
GET |
/api/jobs/{job_id} |
Reads one completed job. |
GET |
/api/jobs/{job_id}/export/{fmt} |
Exports a job as md, json, docx, or pdf. |
GET |
/api/project-local-status |
Verifies local project registration and implementation status. |
curl -X POST http://127.0.0.1:9102/api/run \
-H "Content-Type: application/json" \
-d '{
"inputs": {
"work_brief": "Paste the source material or task details here"
},
"customization": {
"execution_mode": "Production"
},
"provider": "rule_engine"
}'api-doc-generator/
ββ app/ # FastAPI backend, schemas, DB, providers, exports
ββ static/ # Browser GUI assets
ββ plugins/ # Project plugin JSON metadata
ββ data/ # SQLite DB, uploads, exports
ββ tests/ # Smoke tests
ββ project_config.json # Project-specific inputs, controls, UX, workflow
ββ PROJECT_IMPLEMENTATION.md # Implementation details and domain notes
ββ requirements.txt # Python dependencies
ββ run_gui.sh # macOS/Linux/WSL launcher
ββ run_gui_windows.ps1 # Windows PowerShell launcher
ββ README.md # This file
For local/private deployment, run with uvicorn behind a reverse proxy if needed. For production:
- Set
AI_SUITE_SECRET_KEY. - Use HTTPS.
- Store provider keys in environment variables or a proper secret manager.
- Restrict upload sizes and allowed file types.
- Back up the SQLite database or move job storage to a managed database.
- Add authentication before exposing beyond localhost.
- Enable logging and monitoring.
Example production-style command:
AI_SUITE_HOST=0.0.0.0 AI_SUITE_PORT=9102 uvicorn app.main:app --host 0.0.0.0 --port 9102| Problem | Fix |
|---|---|
python not found |
Install Python 3.10+ and ensure it is on PATH. |
| PowerShell blocks the script | Run Set-ExecutionPolicy -Scope Process -ExecutionPolicy Bypass. |
| Port already in use | Set another port: AI_SUITE_PORT=9200 ./run_gui.sh. |
| Provider fails | Verify API key, base URL, selected model, and account quota. |
| Local model fails | Start Ollama/LM Studio/vLLM before running the workflow. |
| PDF/DOCX export fails | Reinstall requirements and confirm optional export dependencies installed. |
| Upload extraction is incomplete | Use cleaner source files or paste the important text into work_brief. |
You can extend this project by editing:
project_config.jsonfor inputs, settings, output sections, UX metadata, and workflow labels.plugins/api-doc-generator.jsonfor plugin metadata.app/domain_engine.pyfor deterministic business logic.app/llm_gateway.pyfor provider integrations.static/app.jsandstatic/styles.cssfor GUI behavior and component design.tests/test_single_project.pyfor stronger project-specific tests.
| Area | Status |
|---|---|
| Standalone folder GUI | β Implemented |
| FastAPI backend | β Implemented |
| Project-specific config | β Implemented |
| Local deterministic workflow | β Implemented |
| Local/cloud LLM routing | β Implemented |
| Uploads and exports | β Implemented |
| Job history | β Implemented |
| Real external connectors | |
| Fake/simulated live data | β Not allowed |
Use the license included in this folder. If no explicit license is present, treat the code as private until you choose one.