Took apart Claude Code, then turned it into a free course on harness engineering

  • Posted 2 hours ago by pauliusztin
  • 3 points
The fastest way to learn harness engineering? Build Claude Code from scratch.

Why harness engineering? LangChain kept the same model and changed only the harness. Their coding agent went from 53% to 67% on Terminal-Bench, a top coding-agent benchmark. From outside the top 30 to the top 5. Same model. Better harness.

Over the past few months, I've taken apart Claude Code, OpenCode, and Pi to see how they work under the hood.

And you don't need to ship a coding agent for this to pay off. The same foundations power any agent, in e-commerce, finance, or sales.

On top of that, people are increasingly realizing they need to build their own harness instead of relying on Claude Code or Codex. Ramp scaling its operations with a custom harness is a perfect example.

So I turned what I learned into an in-depth course on harness engineering by building Claude Code from scratch. It's free and open source: 8 articles, 6 videos, and one codebase. It's perfect for people who learn by building. Everything in Python.

For full transparency, Modal, Opik, and Kitaru sponsor the course, which lets me keep it 100% free as an independent AI engineer.

Here are the 8 steps that I think are core to building and maintaining any harness:

1. Design the harness 2. Build the bare-bones agent loop 3. Sandbox it, locally and remotely 4. Apply 4 essential context engineering techniques 5. Add subagents as a context engineering technique 6. Deploy it headless to the cloud: CLI, webhooks, cron 7. Build benchmarks to measure it 8. Replay failed runs to debug agents

Everything is on GitHub: https://github.com/decodingai-magazine/building-a-coding-agent-from-scratch-course

Curious what others here think. Which of these steps has been the hardest to get right in your own agents?

0 comments