ai-agents-from-scratch
AI Agents From Scratch is a code-first learning series that teaches how to build AI agents locally and without frameworks, using local LLMs and node-llama-cpp. The stated aim is to understand what happens under the hood before using production frameworks: how LLMs work at a basic level, what an agent really is (an LLM plus tools plus patterns), how different agent architectures function and why frameworks make the choices they do. The README links a long-form interactive version at agentsfromscratch.com for those who prefer diagrams and conceptual explanations.
Phase 1 takes you from LLMs to a ReAct agent through numbered examples, each with runnable code, a code explanation and a concepts page: an introduction to basic LLM interaction, an optional OpenAI example (temperature and token use), translation with system prompts, and further steps up to the ReAct agent. You need Node.js 18+, at least 8 GB of RAM (16 GB recommended) and downloaded model files placed in ./models/, then `npm install` and run the examples with node. A next phase is described as re-implementing core ideas of LangChain and LangGraph in plain JavaScript with local models, and related projects cover AI product development and a Python version. GitHub shows no licence.
Features
Why choose it
Trade-offs
Maintenance check
- Last commit
- 2026-07-24
- Commits, last 90 days
- 0
- Releases, last 90 days
- 0
- Latest release
- —
- Open issues
- 12
- Recent issues with at least one comment
- 10/22
Oldest week on the left; the latest four weeks are orange. Source: GitHub commit activity.
Status rule: archived on GitHub = Archived; last commit within 90 days = Active; 91 to 365 days = Slowing; older = Stale. All figures come from the GitHub API on the date shown.
Most discussed open issues
- #17 Invalid path of the model after download3 comments · 2025-11-01
- #4 New Example: Add validation for structured outputs from LLM3 comments · 2025-10-24
- #5 New Example: Enable tool composition and chaining of function results2 comments · 2025-10-24
- #28 pguso/ai-agents-from-scratch was independently reviewed on Hlido — scored 80/100, right of reply open0 comments · 2026-10-12
- #26 09 ReAct agent ignores prompt -- does all logic at once0 comments · 2026-08-20
Issue titles are quoted from GitHub. Open the link to check whether a problem still applies to the version you use.
Compatibility
Quick start
Use cases
Alternatives
Comments
No comments yet. Be the first!