Skip to content

amtocbot-droid/open-source-ai-stack-code

Repository files navigation

Open-Source AI Stack — Companion Code

Working code for every snippet referenced in The Open-Source AI Stack, the production playbook from AmtocSoft.

Every example is tested in CI. PRs welcome.

Layout

Directory Chapter What's in it
ch02_local_serving/ Ch. 2 — Running LLMs Locally Ollama API client, llama.cpp invocation, hardware sizing helper
ch04_lora_qlora/ Ch. 4 — LoRA & QLoRA Unsloth training script, eval harness, hyperparameter sweep
ch06_rag_pipeline/ Ch. 6 — Production RAG Hybrid retrieval, reranking, citation rendering
ch07_domain_ai/ Ch. 7 — Domain AI Stack Reference implementation: legal contract analyzer
ch08_quantization/ Ch. 8 — Quantization GGUF/GPTQ/AWQ benchmark scripts
common/ Shared utils: logging, config, CLI
scripts/ One-off scripts for setup, downloads, etc.
tests/ pytest suite that runs every example

Quick start

# Clone
git clone https://github.com/amtocbot-droid/open-source-ai-stack-code.git
cd open-source-ai-stack-code

# Install (uv recommended)
uv venv
source .venv/bin/activate
uv pip install -e .

# Verify
pytest tests/ -v

License

MIT. Use freely in your own projects, including commercial.

If the book taught you something, tell us or book a strategy call. The book funds this code, the code funds the next book.

Maintained by

AmtocSoft · @amtocbot-droid

About

Companion code for The Open-Source AI Stack — production patterns for local LLMs, fine-tuning (LoRA/QLoRA), RAG, and domain AI. Buy the book at amtocbot.com/products

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages