How chiyuliu67/gitdiagram works
Project type and purpose
• The frontend is built with Next.js (TypeScript + Tailwind + ShadCN), and the backend is a Python FastAPI service. A PostgreSQL database (via Drizzle ORM) stores any needed state or caches. The system also integrates with external services (OpenAI o4-mini, GitHub API, PostHog analytics).
File structure
• Top-level directories:
• backend/ – Dockerfile, FastAPI app modules (core, routers, services, utils), Nginx config, deploy scripts
• src/ – Next.js app, React components, hooks, lib, server/db, styles
• public/ – static assets
• config files: docker-compose.yml, drizzle.config.ts, next.config.js, tsconfig.json, .env.example, GitHub Actions under .github/workflows
• backend/app/routers contains two main API endpoints: /generate and /modify
• backend/app/services contains connectors to Claude/OpenAI, GitHub, and rate-limiter logic
• src/app holds Next.js page routes (dynamic [username]/[repo]) and Server Actions
• src/server/db/schema.ts defines your PostgreSQL tables with Drizzle ORM
Inspect the README for architectural insights
• Confirms stack: Next.js frontend on Vercel, Python FastAPI backend on EC2 (Docker + Nginx), PostgreSQL local or containerized, CI/CD via GitHub Actions, analytics via PostHog and Api-Analytics.
• Highlights that most “processing” is done via prompt engineering in backend/app/prompts.py.