Skip to content
Layers Deep

Understand how it works.Build it yourself.

Layers Deep teaches coding, AI, large language models, retrieval-augmented generation, and system design one mechanism at a time. Predict what happens, watch it run, change the inputs, then prove it with exercises checked by real tests.

The first lesson needs no account. Progress saves in this browser.

Loops, step by step

Step 4 of the lesson: see it work

Open the full lesson
const prices = [4, 8, 15, 16, 23];let total = 0;for (let i = 0; i < prices.length; i++) {  total = total + prices[i];}console.log(total);
priceslength 5
  1. 40
  2. 81
  3. 152
  4. 163
  5. 234
i
–
total
–
Condition
–
Console
–

1/20Create an array named prices with 5 values. Indexes run from 0 to 4.

One character. Watch what the last pass reads, and what the total becomes.

Every lesson follows the same nine steps.

Most lessons take 5 to 12 minutes. You predict before you see, so the explanation lands on a question you already care about. Jargon is defined where it first appears, with optional deeper notes.

Completion is not mastery

Reading a lesson completes it. Only answering on your own, without revealing the solution, counts as evidence that you understand it. Your skill map shows the difference.

  1. 01

    Outcome

    What you'll be able to do when you finish.

  2. 02

    Why it matters

    A concrete problem the idea solves.

  3. 03

    Predict

    Commit to a guess before you see it run.

  4. 04

    See it work

    The mechanism, animated one step at a time.

  5. 05

    Experiment

    Change the inputs and inspect what happens.

  6. 06

    Practice

    Write or fix code, checked by real tests.

  7. 07

    Check understanding

    Questions that explain the misconception you hit.

  8. 08

    Transfer

    Apply the idea to a different problem.

  9. 09

    Recap

    Takeaways, plus a review scheduled from how you did.

Five connected tracks, taught in order.

Tracks build on each other: the loops you write in Coding foundations reappear when you chunk documents for retrieval, and caching returns when you make an AI assistant fast. Three lessons are ready today; the rest are marked as coming soon.

Coding foundations

Read, write, and debug real programs.

1 lesson available, 10 coming soon

  1. 1First steps: values and decisions(coming soon)
  2. 2Iteration and functions(has an available lesson)
  3. 3Debugging, testing, and Git(coming soon)
  4. 4APIs, data, and async(coming soon)

AI foundations

What machine learning actually does.

No lessons yet, 7 coming soon

  1. 1What models learn(coming soon)
  2. 2Measuring models(coming soon)
  3. 3Representations and responsibility(coming soon)

LLM engineering

Build dependable features on large language models.

No lessons yet, 9 coming soon

  1. 1How LLMs read and write(coming soon)
  2. 2Prompting, structure, and tools(coming soon)
  3. 3LLMs in production(coming soon)

RAG engineering

Answer questions from your own documents, with evidence.

1 lesson available, 8 coming soon

  1. 1Retrieval-augmented generation(has an available lesson)
  2. 2Better retrieval(coming soon)
  3. 3Grounded answers and evaluation(coming soon)

System design

Reason about systems that serve real traffic.

1 lesson available, 11 coming soon

  1. 1Requirements and estimates(coming soon)
  2. 2Performance and scale(has an available lesson)
  3. 3Data at scale(coming soon)
  4. 4Operating in production(coming soon)

Recommended starting path

AI Engineering Foundations

Go from loops to a retrieval pipeline that answers with evidence, then make it fast and affordable with caching.

7 modules, 3 lessons ready now, 16 in production.

Projects that prove the skill.

Each project has requirements, milestones, test criteria, a rubric, and reflection questions. The briefs are ready; guided, automatically checked builds are being added project by project.

  • A small tested API

    Build a notes API with validation, persistence, and an automated test suite.

    • HTTP
    • Validation
    • Testing
    • Persistence
    Read the brief
    clientPOST/notesdbtests
  • Document search app

    Ingest a folder of documents, chunk them, and answer searches with ranked, linked passages.

    • Ingestion
    • Chunking
    • Keyword search
    • Vector search
    Read the brief
    docschunksindexquerytop results
  • Evaluated RAG assistant

    Build an assistant that answers from your documents with citations, abstains when unsure, and is measured on an evaluation set.

    • Grounded generation
    • Citations
    • Evaluation
    • Failure analysis
    Read the brief
    questionretrieveLLM[1][2]eval set: recall, faithful
  • System design case study: a link shortener

    Design a link shortener from requirements to caching and failure handling, with every assumption written down.

    • Requirements
    • Estimation
    • Caching
    • Tradeoffs
    Read the brief
    usersLBappappcachedb

A daily habit sized to your day.

  • Pick 10, 20, or 30 minutes, or your own number. Minutes come from finished activities, never from time spent on a page.
  • Reviews come back on a schedule based on how each concept went: sooner when you struggled, later when you didn't.
  • Streaks are optional and forgiving. Meet your weekly goal and you earn a shield that covers a missed day.
  • Badges mean something. You earn them for fixing a failing program, tuning a retrieval pipeline, or explaining a tradeoff, never for clicking.
10 mingoal met
20 min12 of 20
30 min6 of 30

Start with ten minutes and one loop.

Four quick questions set your goal and recommend where to begin. You can skip them.