A starter structure for an application-, as well as research-like AI / ML / Data-Science projects. Simply run the script and enjoy meticulously thought of project file,- folder architecture that encompasses most of the daily stuff you need.
For AI applications, 2 patterns are supported:
- a single-service layout for one focused product : bootstrap_single covered here
- and a multi-service monorepo for projects that may grow into several backend services behind a unified frontend : bootstrap_multi, covered here)
For ML Research project, 1 pattern is available:
- Longer version, suitable for a long research : bootstrap_research, covered here
- Shorter version, usual Data Science code Project structure : bootstrap_research_ml, covered here
Claude code project Structure, that lets you fast on your feet with the most basic and needed skills, agents and rules
- bootstrap_claude, described here
This repo is a GitHub template. If you do not want to download or pull the repo, you can then click "Use this template" to create a new repo from it, then run one of the bootstrap scripts.
Of course, not everything is presented withing the scripts, many things are missing and some stuff uses packages not common for some developers. Feel freee to add, change, rename and further develop the repo.
-
Click "Use this template" → "Create a new repository" at the top of this page.
-
Clone your new repo locally.
-
Go into the Project. Pick a pattern and run the matching bootstrap script:
cd AI-Project-Template # Single-service: one focused product, one Python package. chmod +x bootstrap_single.sh bash bootstrap_single.sh # Multi-service: monorepo of independent backend services. chmod +x bootstrap_multi.sh bash bootstrap_multi.sh # ML-research: focus on data-driven research and problem solving. chmod +x bootstrap_multi.sh bash bootstrap_multi.sh
Each script is idempotent — it lays down folders, stub files,
.gitignore,.env.example, and a runnable Flask + gunicorn skeleton. -
Rename the placeholder (
your_pkgfor single-service,service_afor multi-service) to your real package or service name. Use a valid Python identifier — lowercase, no hyphens. -
Set up the venv and verify it runs (for service architectures):
cd backend python -m venv venv source venv/bin/activate pip install -r requirements.txt # Dev server (single-service): flask --app your_pkg.api.main run --host 0.0.0.0 --port 8000 # OR more production-ready gunicorn --bind 127.0.0.1:8000 your_pkg.api.main:app # Dev server (multi-service): flask --app service_a.api.main run --host 0.0.0.0 --port 8000 # OR more production-ready gunicorn --bind 127.0.0.1:8000 service_a.api.main:app
Then in an other terminal verify response:
# Multi architecture curl http://localhost:8000/service_a/health # Single architecture curl http://localhost:8000/your_pkg/health
You should get
{"status": "ok"}. -
Replace this README with one for your actual project.
The full layout, conventions, and rationale (why services are siblings, why models/ is split from ml_models/, where databases fit, etc.) are documented in docs/:
docs/single-service-project-structure.mddocs/multi-service-project-structure.mddocs/research-project-structure.mddocs/research-project-structure-short.mddocs/claude-code-project-structure.md
Defaults baked into the bootstraps: Flask + gunicorn, requirements.txt, etc.
MIT — see LICENSE.