decodingai-magazine/second-brain-ai-assistant-course

Learn to build your Second Brain AI assistant with LLMs, agents, RAG, fine-tuning, LLMOps and AI systems techniques.

What Is This?

An open-source, self-paced course that teaches you how to build a production-ready AI assistant that chats with your personal knowledge base — your "Second Brain." The course is created by Decoding AI in collaboration with MongoDB, Comet, Opik, Unsloth, and ZenML.

The "Second Brain" concept (by Tiago Forte) means your personal collection of notes, ideas, and resources. The AI assistant you'll build can answer questions, summarize documents, and give insights based on that collection — without you manually searching through your notes.

What You'll Build

The course walks you through building two Python applications:

  • second-brain-offline — the "behind the scenes" pipelines: data processing, RAG (Retrieval-Augmented Generation) setup, and model fine-tuning.
  • second-brain-online — the actual AI assistant that serves answers to your questions.

Course Structure (6 Modules)

Module What You'll Learn Code?
0 Overview of the whole course No
1 Architecting an AI assistant for your Second Brain No
2 Data pipelines: process Notion data, crawl documents, score content quality, store in a database Yes
3 Turn noisy documents into a high-quality fine-tuning dataset (via distillation) Yes
4 Fine-tune an open-source LLM (Llama 3.1 8B) to summarize documents, then deploy it as an API Yes
5 Build RAG pipelines using advanced techniques (context retrieval, parent retrieval, vector search) Yes
6 Build the agentic RAG inference pipeline plus monitoring/evaluation (LLMOps) Yes

Key Skills You'll Gain

  • LLM system architecture and MLOps best practices
  • Pipeline orchestration with ZenML
  • LLMOps and RAG evaluation with Opik
  • Web crawling and content normalization
  • Quality scoring using LLMs and heuristics
  • Dataset generation through distillation
  • Fine-tuning Llama models with Unsloth and Comet
  • Serverless model deployment to Hugging Face
  • Advanced RAG and agent building (using smolagents)
  • Modern Python tooling (uv, ruff)

Data Used

The course uses a curated list of ~100 pages and 500+ links of AI/ML resources (GenAI, LLMs, RAG, MLOps, etc.) originally kept in Notion. A free snapshot is available in a public S3 bucket — no Notion account needed. However, the pipeline is flexible enough to load any Notion database if you want to use your own.

Cost

The course itself is free and open-source. Running the code costs roughly $1–$5:

  • OpenAI API: ~$3
  • Hugging Face dedicated endpoints (optional): ~$2

You can complete the whole course for ~$1 by choosing cost-efficient options. Reading-only is completely free.

Who Is It For?

  • ML/AI Engineers — build production-ready agentic RAG & LLM systems (beyond notebook tutorials)
  • Data/Software Engineers — architect end-to-end agentic RAG and LLM applications
  • Data Scientists — implement production AI systems with LLMOps and software engineering best practices

Prerequisites

  • Skills: Intermediate Python; beginner-level Machine Learning, LLMs, and RAG
  • Hardware: A modern laptop/PC (GPU optional — cloud alternatives provided)
  • Level: Intermediate (but the README notes "with a little sweat and patience, anyone can do it")

Getting Started

  1. Clone the repository
  2. Read the accompanying articles (linked in the README)
  3. Set up and run the code to replicate results
  4. Dive deeper into the implementation

Detailed setup instructions live in each app's own documentation folder.

Support & Contributing

  • Questions/issues: Open a GitHub issue
  • Contributing: Fork the repo, fix a bug, submit a pull request (see CONTRIBUTING.md)

License

MIT License.

Core Contributors

  • Paul Iusztin — AI/ML Engineer
  • Ernesto Larios — AI Engineer
  • Anca Ioana Muscalagiu — SWE/ML Engineer

Bottom Line

If you want to learn how to build a real, production-grade AI assistant that retrieves and summarizes information from your own knowledge base — using modern LLMOps and software engineering practices — this free, hands-on course gives you the full codebase, step-by-step lessons, and a working template to adapt for your own projects.

Related

  • Project
  • Project
  • Project
  • Project