Tutorials¶
Interactive Jupyter notebooks covering Director-AI from first principles to production deployment. Every notebook runs in Google Colab with zero local setup.
Learning Path¶
graph TD
subgraph "Foundations (30 min)"
A["00 Quickstart<br/>5 min"] --> B["01 Coherence Engine<br/>15 min"]
end
subgraph "Core Tracks"
B --> C["09 Production Guardrails<br/>guard() + SDK wrapping"]
B --> D["02 Streaming Oversight<br/>token-level halt"]
B --> V["16 Verification Gems<br/>8 standalone modules"]
end
subgraph "Deep Dives"
C --> E["10 Vector RAG Pipeline<br/>ChromaDB + reranking"]
C --> F["12 Domain Presets & Config<br/>8 profiles"]
D --> G["11 Streaming Halt Deep Dive<br/>hard/soft/trend"]
E --> H["06 Medical RAG Chatbot<br/>domain-specific"]
end
subgraph "Production (enterprise)"
F --> I["13 Batch Processing<br/>evaluation pipelines"]
I --> J["14 Enterprise Multi-Tenant<br/>Docker + K8s"]
J --> K["15 Custom Fine-Tuning<br/>domain NLI + ONNX export"]
end
style A fill:#7c4dff,color:#fff
style B fill:#7c4dff,color:#fff
style C fill:#2e7d32,color:#fff
style D fill:#1565c0,color:#fff
style V fill:#ff8f00,color:#fff
style K fill:#c62828,color:#fff
Getting Started¶
Start here. These two notebooks teach the core concepts in under 30 minutes.
| # | Notebook | What You Learn | Time | Colab |
|---|---|---|---|---|
| 00 | Quickstart | Install, score, guard, stream, presets | 5 min | |
| 01 | Coherence Engine | CoherenceScorer, SafetyKernel, CoherenceAgent, dual-entropy formula | 15 min |
Core Features¶
Deep dives into the four pillars of Director-AI.
| # | Notebook | What You Learn | Time | Colab |
|---|---|---|---|---|
| 09 | Production Guardrails | guard() for OpenAI / Anthropic / Bedrock / Gemini / Cohere, failure modes, streaming guards |
20 min | |
| 10 | Vector RAG Pipeline | Semantic retrieval, ChromaDB, pluggable backends, reranking, multi-tenant KB | 25 min | |
| 11 | Streaming Halt Deep Dive | Hard limit, sliding window, trend detection, async, per-token visualization | 20 min | |
| 12 | Domain Presets & Config | 8 profiles, env vars, YAML, backends, strict mode, multi-GPU, LLM-as-judge | 15 min |
Domain Applications¶
Real-world integrations and domain-specific patterns.
| # | Notebook | What You Learn | Time | Colab |
|---|---|---|---|---|
| 02 | Streaming Oversight | StreamingKernel basics, token-by-token monitoring | 10 min | |
| 03 | Vector Store | VectorGroundTruthStore, InMemoryBackend, fact ingestion | 10 min | |
| 05 | SSGF Geometry | Self-similar geometry foundation concepts | 10 min | |
| 06 | Medical RAG Chatbot | Healthcare-specific guardrails, high thresholds, evidence citations | 20 min | |
| 07 | LangChain Integration | CoherenceCallbackHandler, chain integration, output parsing | 15 min | |
| 08 | Provider Adapters | OpenAI, Anthropic, Bedrock, Gemini, Cohere adapter patterns | 10 min |
Verification & Analysis¶
Standalone analysis modules — no NLI model required. All stdlib-only.
| # | Resource | What You Learn | Time | Colab |
|---|---|---|---|---|
| 16 | Verification Gems | All 8 gems: numeric, reasoning, temporal, consensus, conformal, feedback loops, agentic, REST API | 15 min | |
| — | Guide: Verification Gems | Full parameter reference for all 8 gems | 15 min | — |
| — | Example: verification_gems_demo.py | Runnable demo of all 7 standalone verification modules | 5 min | — |
CLI quick start:
director-ai verify-numeric "Revenue grew 50% from \$100 to \$120"
director-ai verify-reasoning "Step 1: A is true. Step 2: Therefore B."
director-ai temporal-freshness "The CEO of Apple is Tim Cook"
director-ai check-step "Find revenue data" "search" "revenue Q3"
REST quick start (with server running):
curl -X POST http://localhost:8080/v1/verify/numeric \
-H "Content-Type: application/json" \
-d '{"text": "Revenue grew 50% from $100 to $120."}'
Enterprise & Production¶
Scale, evaluate, fine-tune, and deploy.
| # | Notebook | What You Learn | Time | Colab |
|---|---|---|---|---|
| 04 | End-to-End Benchmark | Full benchmark suite, latency profiling, accuracy metrics | 15 min | |
| 13 | Batch Processing & Evaluation | BatchProcessor, evaluation pipelines, claim attribution, regression gates | 20 min | |
| 14 | Enterprise Multi-Tenant | Tenant isolation, REST/gRPC servers, Docker, Kubernetes, monitoring | 25 min | |
| 15 | Custom Fine-Tuning | JSONL data prep, validation, training, anti-forgetting, ONNX export, REST API | 30 min |
Prerequisites¶
All notebooks run on Python 3.11+ with pip install director-ai.
Notebooks requiring optional extras note this in their first cell:
| Extra | Install | Notebooks |
|---|---|---|
| NLI scoring | pip install director-ai[nli] |
01, 04, 06, 09–15 |
| Vector store | pip install director-ai[vector] |
10, 14 |
| Fine-tuning | pip install director-ai[finetune] |
15 |
| Server | pip install director-ai[server] |
14 |
| gRPC | pip install director-ai[grpc] |
14 |