{"id":35094105,"url":"https://github.com/TrySita/AutoDocs","last_synced_at":"2026-01-01T23:01:08.994Z","repository":{"id":313684449,"uuid":"1052238243","full_name":"TrySita/AutoDocs","owner":"TrySita","description":"We handle what AI editors won't: generating and maintaining documentation for your codebase, while also providing search with dependency-aware context that helps your tools understand your codebase and its conventions.","archived":false,"fork":false,"pushed_at":"2025-09-26T04:43:47.000Z","size":33818,"stargazers_count":156,"open_issues_count":2,"forks_count":10,"subscribers_count":2,"default_branch":"main","last_synced_at":"2025-09-26T06:22:42.002Z","etag":null,"topics":["agents","ai","ast","docker","llm","mcp","openai","opensource","scip","sdk","sita","tree-sitter"],"latest_commit_sha":null,"homepage":"https://trysita.com/","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/TrySita.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":"CODE_OF_CONDUCT.md","threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-09-07T17:26:21.000Z","updated_at":"2025-09-26T04:43:51.000Z","dependencies_parsed_at":"2025-09-26T06:23:06.823Z","dependency_job_id":null,"html_url":"https://github.com/TrySita/AutoDocs","commit_stats":null,"previous_names":["trysita/autodocs"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/TrySita/AutoDocs","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TrySita%2FAutoDocs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TrySita%2FAutoDocs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TrySita%2FAutoDocs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TrySita%2FAutoDocs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/TrySita","download_url":"https://codeload.github.com/TrySita/AutoDocs/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/TrySita%2FAutoDocs/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":28165027,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","status":"online","status_checked_at":"2026-01-01T02:00:06.694Z","response_time":59,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["agents","ai","ast","docker","llm","mcp","openai","opensource","scip","sdk","sita","tree-sitter"],"created_at":"2025-12-27T15:04:24.311Z","updated_at":"2026-01-01T23:01:08.988Z","avatar_url":"https://github.com/TrySita.png","language":"Python","funding_links":[],"categories":["📚 Projects (1974 total)"],"sub_categories":["MCP Servers"],"readme":"![Sita Github Banner](https://raw.githubusercontent.com/TrySita/AutoDocs/refs/heads/main/assets/sita-og.png)\n\n## Follow Us\n- **Sohan** - [@SohanSarabu](https://x.com/SohanSarabu)\n- **Adi** - [@adiperswal](https://x.com/adiperswal)\n\n\u003cdiv align=\"center\"\u003e\n   \u003cdiv\u003e\n      \u003ca href=\"https://docs.trysita.com\"\u003e\u003cstrong\u003eDocs\u003c/strong\u003e\u003c/a\u003e ·\n      \u003ca href=\"https://github.com/TrySita/AutoDocs/issues\"\u003e\u003cstrong\u003eReport Bug\u003c/strong\u003e\u003c/a\u003e ·\n      \u003ca href=\"https://langfuse.com/ideas\"\u003e\u003cstrong\u003eFeature Request\u003c/strong\u003e\u003c/a\u003e ·\n   \u003c/div\u003e\n   \u003cbr/\u003e\n   \u003cspan\u003eSita uses \u003ca href=\"https://github.com/orgs/TrySita/discussions\"\u003e\u003cstrong\u003eGitHub Discussions\u003c/strong\u003e\u003c/a\u003e  for Support and Feature Requests.\u003c/span\u003e\n   \u003cbr/\u003e\n   \u003cbr/\u003e\n   \u003cbr/\u003e\n   \u003cdiv\u003e\n   \u003c/div\u003e\n\u003c/div\u003e\n\n\u003cp align=\"center\"\u003e\n   \u003ca href=\"./LICENSE\"\u003e\n   \u003cimg src=\"https://img.shields.io/badge/License-Apache%202.0-E11311.svg\" alt=\"Apache 2.0 License\"\u003e\n   \u003c/a\u003e\n\u003c/p\u003e\n\n\u003cp align=\"center\"\u003e\n  \u003ca href=\"./readmes/README.zh-CN.md\"\u003e\u003cimg alt=\"Español\" src=\"https://img.shields.io/badge/Español-d9d9d9\"\u003e\u003c/a\u003e\n  \u003ca href=\"./readmes/README.zh-CN.md\"\u003e\u003cimg alt=\"हिन्दी\" src=\"https://img.shields.io/badge/Hindi-d9d9d9\"\u003e\u003c/a\u003e\n    \u003ca href=\"./readmes/README.zh-CN.md\"\u003e\u003cimg alt=\"简体中文\" src=\"https://img.shields.io/badge/简体中文-d9d9d9\"\u003e\u003c/a\u003e\n\u003c/p\u003e\n\n\u003cvideo width=\"640\" controls\u003e\n \u003csource src=\"https://github.com/TrySita/AutoDocs/raw/refs/heads/main/assets/sita%20demo.mp4\" type=\"video/mp4\"\u003e\n Your browser does not support the video tag.\n\u003c/video\u003e\n\n# AutoDocs, by [Sita](https://trysita.com)\n\nAutomate documentation for any repo: we traverse your codebase, parse the AST, build a dependency graph, and walk that graph to generate accurate, high-signal docs. A built-in MCP server lets coding agents deep-search your code via HTTP.\n\n(Interested in our hosted or enterprise offerings? Join the waitlist at https://trysita.com)\n\n## What This Repo Does\n\n- Parses your repository using [tree-sitter](https://github.com/tree-sitter/tree-sitter) (AST parsing) and SCIP (symbol resolution).\n- Constructs a code dependency graph (files, definitions, calls, imports) and topologically sorts it.\n- Traverses that graph to create repository-wide, dependency-aware documentation and summaries.\n- Exposes a FastAPI backend for ingestion/search and a Next.js web UI for chat and exploration.\n- Provides an MCP server so agentic tools can query your repo with deep search.\n\n---\n\n## Prerequisites\n\nInstall these once on your machine:\n\n- pnpm 10+ (Node 20+ recommended; Corepack is fine). [Docs](https://pnpm.io/installation)\n- uv (fast Python package manager). [Docs](https://docs.astral.sh/uv/)\n- Docker + Docker Compose (to run everything locally). [Docs](https://docs.docker.com/engine/install/)\n\nReference docs\n\n- pnpm install: https://pnpm.io/installation\n- uv install: https://docs.astral.sh/uv/\n\n## GitHub Personal Access Token (optional)\n\nSome features or scripts may call the GitHub API (e.g., fetching repo metadata). If you hit rate limits or need to access private repos, create a Personal Access Token (PAT) and set it in your environment.\n\n- How-to (official docs): https://docs.github.com/en/authentication/keeping-your-account-and-data-secure/creating-a-personal-access-token\n- Create fine-grained PAT (recommended): https://github.com/settings/personal-access-tokens/new\n- Create classic PAT (legacy): https://github.com/settings/tokens/new\n\nSuggested scopes\n\n- Public repos only: use a fine-grained token with selected repositories (read-only) or a classic token with `public_repo`.\n- Private repos: fine-grained token with read-only repo access to the needed repositories, or a classic token with `repo`.\n\nAdd to your `.env` (or shell env):\n\n```bash\nGITHUB_TOKEN=ghp_your_token_here\n```\n\nNotes\n\n- Keep this token secret; do not commit `.env`.\n- Fine-grained tokens are preferred for tighter, per-repo permissions.\n\n## Quickstart (copy/paste)\n\n1. Environment\n\n```bash\ncp .env.example .env\n```\n\n### Configuration\n\n#### Preconfigured\n\n- Database: `DATABASE_URL` (local postgres DB). In Compose, DB is available at `postgresql://postgres:postgres@db:5432/app`.\n- Ingestion API: `INGESTION_API_URL` for the web app to call the FastAPI service.\n- Analysis storage: `ANALYSIS_DB_DIR` controls where generated per-repo SQLite files live.\n\n---\n\n#### To-be configured\n\n- Summaries: `SUMMARIES_API_KEY`, `SUMMARIES_MODEL`, `SUMMARIES_BASE_URL` (OpenAI-compatible, default [OpenRouter](https://openrouter.ai/))\n- Embeddings: `EMBEDDINGS_API_KEY`, `EMBEDDINGS_MODEL`, `EMBEDDINGS_BASE_URL` (OpenAI-compatible, default [OpenAI](https://openai.com/api/))\n- Rate limiting: `MAX_REQUESTS_PER_SECOND` for LLM summary batching (default 15)\n\n---\n\n2. Run locally with Docker Compose\n\n```bash\ndocker compose up -d\n\n# If you want to see logs\ndocker compose up\n```\n\nYou should now have:\n\n- Web UI at http://localhost:3000\n- API at http://localhost:8000 (OpenAPI schema at `/schema`)\n\n## Updating Docs\n\nTo refresh a repository’s docs after code changes, remove the repo and re-ingest it (temporary workflow):\n\n- UI: delete the repo in your Workspace, then add it again (ingestion starts automatically).\n\nWe’re actively adding a one-click \"Resync\" button in the UI, followed by automatic periodic ingestion (coming soon)\n\n## Using the MCP Server\n\nThe MCP server is available at `http://localhost:3000/api/mcp` and is designed for coding agents and MCP-compatible clients. It exposes a `codebase-qna` tool that answers repository-scoped questions by querying the analysis databases that AutoDocs produces.\n\nTips\n\n- Point your MCP client at `http://localhost:3000/api/mcp`.\n- Include an `x-repo-id` header with the repo ID (you can find it in the UI).\n- For setup guides with popular tools (Claude, Cursor, Continue), see https://docs.trysita.com\n\n## Development Workflow (for contributing)\n\nFor a local dev loop without Docker Compose you can run the API and web dev servers directly:\n\n```bash\n# concurrent dev (API + Web + DB)\n./tools/dev.sh --sync\n```\n\nDatabase migration (run if modifying the postgres schema)\n\n```bash\ncd packages/shared\nDATABASE_URL=postgresql://postgres:postgres@localhost:5432/app pnpm drizzle-kit push --config drizzle.main.config.ts\n```\n\n## Project Layout\n\n- `ingestion/` — Python FastAPI service, AST parser, graph builder, embeddings, and search.\n- `webview/` — Next.js app (Turborepo workspace) and shared TS packages.\n- `docker-compose.yml` — local Postgres, API, and Web services.\n- `tools/` — helper scripts (`build_all.sh`, `dev.sh`, `uv_export_requirements.sh`).\n\n## Troubleshooting\n\n- Web can’t reach the API: ensure `INGESTION_API_URL=http://api:8000` is set in `.env`.\n- Missing `uv`/`pnpm`: install them (see links above)\n\n## Known Issues\n\n- In your repositories, code must live at the repository root, not in a nested folder.\n- Language support: currently supports TS, JS, and Python; currently working on expansion to Go, Kotlin, Java, and Rust.\n- Polyglot repos (multiple languages in one repo): not supported yet, but we’re actively working on it.\n\n## License\n\nLicensed under the Apache 2.0 License. See [LICENSE](./LICENSE).\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FTrySita%2FAutoDocs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2FTrySita%2FAutoDocs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2FTrySita%2FAutoDocs/lists"}