Learn LLM — a causal attention mask Learn LLM — a causal attention mask Learn LLM
  • Home
  • Timeline
  • Playground
  • Modules
    • 00 Introduction
    • 01 Tensors
    • 02 Autograd

    • 03 Tokenization
    • 04 Embeddings

    • 05 Attention
    • 06 Transformer

    • 07 Training
    • 08 Generation

    • 09 Efficient Attention
    • 10 Long Context
    • 11 Mixture of Experts

    • 12 Alignment
    • 13 Reasoning & Test-Time Compute

    • 14 Quantization
    • 15 Retrieval-Augmented Generation
    • 16 Speculative Decoding

    • 17 Evaluation
    • 18 Tool Use & Agents

    • 19 State-Space Models (Mamba)
    • 20 Multimodal
    • 21 Interpretability
    • 22 Linear & Recurrent Attention
    • 23 Distributed Training
    • 24 Pretraining Data

    • 25 Parameter-Efficient Fine-Tuning
    • 26 Diffusion Language Models
    • 27 Model Merging
    • 28 Knowledge Distillation

Inference Playground

Source Code
---
title: "Inference Playground"
format:
  html:
    page-layout: full
    toc: false
    css: styles/playground.css
resources:
  - playground/app.js
  - playground/tensor.js
  - playground/tokenizer.js
  - playground/model.js
  - playground/core/*.js
  - playground/ui/*.js
  - playground/panels/*.js
  - playground/viz/*.js
  - playground/tokenizer.json
  - playground/weights.json
---

```{=html}
<div id="llm-debugger" class="pg-app" aria-label="LLM Debugger">
  <noscript>
    <p class="pg-noscript">
      The playground is a live, in-browser debugger for a small GPT model and
      needs JavaScript to run.
    </p>
  </noscript>
</div>
<script type="module" src="playground/app.js"></script>
```