nicolaygerold/howtobuildacodingagent — explained in plain English
Analysis updated 2026-05-18
Learn how coding agents decide what goes into a model's limited context window.
Study why early context compaction techniques failed and why they work again with newer models.
Compare tool design choices, like a read tool versus shell commands, using working demo plugins.
Run a small, fully readable 400-line coding agent in Go to see the core agent loop end to end.
| nicolaygerold/howtobuildacodingagent | 8thpark/geode | codeweb-dev/spark-ui | |
|---|---|---|---|
| Stars | 25 | 25 | 25 |
| Language | TypeScript | TypeScript | TypeScript |
| Setup difficulty | moderate | moderate | — |
| Complexity | 3/5 | 2/5 | — |
| Audience | developer | vibe coder | developer |
Figures from each repo's GitHub metadata at analysis time.
Requires installing the pi or Amp agent tool separately, then running it from the repo root to auto-load the demo plugins.
This repository is workshop material for learning how AI coding agents are actually built, focused on a single idea: everything an AI language model outputs is a function of what gets fed into its context window, since the model itself cannot be changed by the person using it. The workshop is about the practice of deciding what information goes into that window, and how responsibility for that decision has shifted over time between the person typing the prompt, the surrounding agent tooling, and now increasingly the model itself. Each of the nine topics has a short written explainer with plain ASCII diagrams, plus a runnable demo. The topics move through the history and current state of the field: the basic loop that all agents run on, engineering the tooling layer around a model, why early attempts at compacting long conversations failed and why the technique is coming back now that models are more capable, compacting context by writing it out to files instead, letting the agent plan before acting, handing off work between agent sessions, an experimental recursive approach to extracting relevant context, and practical comparisons between different tool designs, such as a plain read tool versus a shell command, or dedicated edit tools versus a generic patch-apply tool. The demos are built as plugins for two specific coding agent tools, called pi and Amp, and they load automatically the moment either tool is run from inside this repository. One demo is also a small, runnable 400-line agent written in Go, included so learners can see the entire core agent loop laid out plainly rather than buried in a larger codebase. To use it, you install either pi or Amp separately, then simply run the agent from the root of this repository so its project-level extensions and plugins are picked up automatically. The repository is organized into a docs folder with the written explainers, a folder holding the standalone Go agent, and separate folders for the pi and Amp demo plugins.
Workshop material teaching how AI coding agents manage their context window, with written explainers and runnable demo plugins for the pi and Amp agent tools.
Mainly TypeScript. The stack also includes TypeScript, Go, pi.
Setup difficulty is rated moderate, with roughly 30min to a first successful run.
Mainly developer.
This repo across BitVibe Labs
double-check against the repo, no cap.