Personal Agent
Build a General-Purpose Agent Harness from Scratch in 100 Days
Project Status: D100 / 100 · v1.0.0 · MIT
Technology Stack: TypeScript · Node.js 24+ · SQLite · MCP · CLI / SDK
Personal Agent is not just a chat application; it is an embeddable, replaceable, and observable Agent Runtime. The tutorial separates “what the model decides to do” from “what the system actually allows it to do,” building a complete execution loop layer by layer across 100 daily topics.
← Back to Series Overview · View Source and Daily Branches

Final Project Capabilities
Agent Fundamentals
- OpenAI-compatible Provider, standard requests, and streaming responses.
- Tool contracts, recursive Schema validation, registries, and dynamic tool discovery.
- File reads, write protection, precise edits, command execution, and error feedback.
- MCP stdio Client/Server, filesystem adaptation, and reconnection after disconnections.
- Cancellation, model timeouts, consecutive tool error circuit breakers, and structured stop reasons.
Context, Memory, and Long-Running Tasks
- Character budgets, message priorities, deterministic pruning, and tool-result truncation.
- Context compaction, task summaries, and grouped expansion of tool Schemas.
- Layered boundaries among short-term memory, task summaries, and long-term memory.
- Long-term memory writes, retrieval, version conflicts, and expiration handling.
- Task state machines, plans, checkpoints, recovery strategies, cost accounting, and budget-based degradation.
Orchestration, Observability, and Evaluation
- Task queues, background Runners, cancellation, pause, and resume.
- Subagents, parallel orchestration, resource isolation, and DAG dependencies.
- Run Store, idempotency protection, and unknown side-effect states.
- Trace/Span, Trace Store, Replay executor, and Eval assertions.
Productization
- CLI task submission, status queries, configuration display, and tool capability inventories.
- Sensitive-tool approval, multi-tenant isolation, data retention, and version migrations.
- Programmatic SDK, health checks, deployment documentation, and API compatibility checks.
- Release audits, RC acceptance, and final release acceptance.
100-Day Curriculum Roadmap
| Stage | Days | Core Topics | Stage Release |
|---|---|---|---|
| G1 | D001–D025 | Agent Loop, tools, events, Session, cancellation, persistence, and the first offline repair Demo | v0.1.0 |
| G2 | D026–D050 | Hot-pluggable tools, permissions, execution resilience, MCP, external APIs, sandboxing, and dynamic retrieval | v0.2.0 |
| G3 | D051–D070 | Context engineering, compaction, memory, planning, checkpoints, costs, and long-running task Benchmarks | v0.3.0 |
| G4 | D071–D085 | Queues, background tasks, subagents, DAGs, Trace, Replay, and Eval | v0.4.0 |
| G5 | D086–D100 | CLI, approvals, multi-tenancy, migrations, SDK, health checks, compatibility, and release audits | v1.0.0 |
How the Tutorial Is Organized
Each day corresponds to an independent Dxxx branch. Each daily branch contains an implementation, tests, a Demo or scripts, and topic notes, while main consolidates the overall results and index. Readers can either follow along day by day or go directly to the final architecture and milestone release documentation.
git clone https://github.com/Your-First-Agent-Harness/personal-agent.git
cd personal-agent
git checkout D050My Engineering Focus in This Project
- Decompose the Agent Harness into replaceable layers for integration, orchestration, capabilities, context, domains, and observability.
- Treat errors, cancellation, timeouts, and consecutive failures as explicit runtime semantics rather than unhandled exceptions.
- Use offline Demos and deterministic tests to verify execution flows, without equating scripted results with genuine model intelligence.
- Treat tutorials, ADRs, release notes, and acceptance evidence as part of the engineering deliverables.
Evidence Boundaries
Project tests and Demos demonstrate component contracts, failure paths, and reproducible compositions. They do not establish real-world user scale, production-grade distributed reliability, cost reductions, or production SLOs. Refer to the source repository and corresponding release tags for implementation details and validation baselines.