local-ai·lab
local-ai-lab - a neural network flowing into ascending learning steps

Build local AI,
one lesson at a time.

A hands-on course where you build small, fully working programs from scratch - and understand every line. Everything runs on your own machine, with no API key required.

The curriculum

Lesson 1

RAG from scratch

Extract → chunk → retrieve (BM25 + embeddings) → grounded answer with citations. A drag-and-drop document Q&A app.
✓ Available
Lesson 2

MCP servers

Expose your document search as a Model Context Protocol tool that Claude Code can call natively.
✓ Available
Lesson 3

Hybrid retrieval & reranking

Combine BM25 keyword search with a semantic arm and fuse them with Reciprocal Rank Fusion - offline, in Python, Node.js and C#.
✓ Available
Lesson 4

RAG safety & prompt injection

Treat retrieved documents as untrusted input - defend against prompt injection and poisoned content, in Python, Node.js and C#.
✓ Available
Lesson 5

RAG evaluation & regression testing

Golden questions, groundedness scoring, and regression tests - turn "seems good" into a tracked number, in Python, Node.js and C#.
✓ Available
Lesson 6

Repo-aware AI assistant

Ground an assistant in your codebase so it answers with cited, repo-specific context - and refuses when the answer isn't there - in Python, Node.js and C#.
✓ Available
Lesson 7

Rebuild RAG with LangChain

Rebuild the pipeline on LangChain, watch where it grounds differently, and price the swap - components replaced, lines you still write, packages you did not read.
✓ Available
Lesson 8

LangGraph

Turn the pipeline into a stateful agent graph with retries, tool routing, and memory.
Planned
Lesson 9

Ollama + Function Calling

Give a local model real tools it can call (function calling) - 100% offline.
Planned
Lesson 10

Microsoft Semantic Kernel

Rebuild the agent in C# / .NET with SK plugins and auto function calling - runs locally.
Planned
Lesson 11

AWS Bedrock Agents

Knowledge bases + action groups on a managed cloud agent, built and driven from your machine.
Planned
Lesson 12

Google AI Development Kit

Build and run a Gemini agent locally with Google's open-source ADK.
Planned
Lesson 13

AI-assisted testing

Generate, run, review, and let failures guide the fix - better coverage without blindly trusting generated tests.
Planned
Lesson 14

AI code review & issue detection

Use AI to catch the serious issues in review - real bugs, security, and risky changes.
Planned
Lesson 15

Documentation from sprint changes

Generate release notes and docs straight from a sprint's commits and pull requests.
Planned

Why "from scratch"?

Most tutorials teach you to glue frameworks together. This course does the opposite: you write the chunker, the retriever, the grounding prompt, and the provider abstraction yourself - a few dozen lines each. Once you understand the primitives, every framework (LangChain, LlamaIndex, LangGraph) becomes obvious, because you already know what it automates.

How each lesson works

Every lesson is an interactive step-by-step slider. Each step explains what you're building and why, gives you the exact command to type, and shows the code. Use the / arrow keys, the dots, or the buttons to move between steps. Any step is deep-linkable, so you can share a link straight to a specific point.

Setup, PDFs & languages

Runs with the language toolchains directly - no Docker. One-time setup and per-lesson dependencies for Linux, macOS, and Windows are in the install guide. The course is polyglot: Python is the reference today, with Node.js and C# opt-in per lesson (./run -l 1 --lang node).

Every lesson with a written guide also has a printable PDF - open a menu to grab one:

Begin Lesson 1 → Install guide (PDF)

Who's teaching this

Built and taught by Nik Reljin - a former college educator who likes nothing more than teaching new technologies, and who now helps engineers build with modern AI through team trainings, one-on-one mentoring, talks and workshops, and hands-on courses like this one. More about the author and related work →