{
 "schema_version": 1,
 "generated": "2026-10-26",
 "id": "smol-env-smol--learn-agent-loop-in-an-afternoon",
 "repo": "smol-env/smol",
 "repo_url": "https://github.com/smol-env/smol",
 "repo_slug": "smol-env-smol",
 "title": "Understand a full agent loop in one afternoon",
 "page_title": "How to understand a full agent loop in one afternoon with Smol",
 "summary": "Run Smol, a deliberately tiny Python agent with one shell tool, against any Responses API endpoint, then read its code with the README's questions.",
 "who": "A developer or student who uses coding agents and wants to understand what actually happens inside one.",
 "problem": "Production agents are huge, so it is hard to see the core loop, why context matters and where failures come from.",
 "outcome": "A working agent you have read line by line, including retries, context compaction and shell output truncation, and answers to why each choice was made.",
 "steps": [
  "Clone the repo and read Smol.py",
  "Run a small local proxy that holds your API key or session and exposes a Responses API endpoint",
  "Run `python3 smol.py http://127.0.0.1:8787/v1/responses`",
  "Type a prompt at the > prompt; empty input exits",
  "Paste the README prompt into your favourite agent: Read the code of Smol.py and answer all questions from the README",
  "Work through the questions on compaction, truncation and why there is no system prompt"
 ],
 "agent_prompt": "Read the code of smol.py from smol-env/smol and answer all questions from the README: what it does, why it has one tool, how compaction keeps a stable prefix and what that does to caching and cost, and its failure modes. Then explain it line by line.",
 "agents": [
  "any"
 ],
 "difficulty": "Beginner",
 "time": "2 hours",
 "basis": "readme",
 "caveat": "Model requested commands run directly through sh, so use a disposable environment.",
 "category": "Software and DevOps",
 "tags": [
  "Software and DevOps"
 ],
 "lang": "python",
 "requirements": [
  "Python 3 or Go",
  "An OpenAI Responses API compatible endpoint, such as a local proxy that adds your key"
 ],
 "risk": "none",
 "seen_in_the_wild": false,
 "mentioned_publicly": false,
 "risks": [
  {
   "tag": "credentials",
   "notice": "Smol adds no credentials; whatever proxy you put in front holds your key or session."
  }
 ],
 "best": true,
 "score": 1.0,
 "evidence": [],
 "url": "https://dedupedai.com/use-cases/smol-env-smol/learn-agent-loop-in-an-afternoon/",
 "md": "https://dedupedai.com/use-cases/smol-env-smol/learn-agent-loop-in-an-afternoon/index.md",
 "disclaimer": "Deduped lists open-source repositories that belong to other people. We do not own, maintain, audit, or vouch for any of them, and a repo appearing here is not an endorsement or a safety check. The use cases, steps, and prompts are written by AI and may be incomplete, outdated, or just wrong. Where a use case is marked \"Seen in the wild\", we link to public posts where someone described something similar, but we have not verified those posts and the use case itself is still our AI's own write-up. Use all of this at your own risk. Only run code, commands, or agents on systems and accounts you are authorized to use, and read the code and every command before you run it, especially anything that touches credentials, files, or the network. Nothing here is professional, security, legal, or financial advice. All trademarks and project names belong to their respective owners, and their use here does not imply affiliation. Content is provided as is, without warranties of any kind. Found a mistake, a safety problem, or something you want removed? Email hello@dedupedai.com and we will look at it promptly.",
 "api": "https://dedupedai.com/api/v1/usecases/smol-env-smol--learn-agent-loop-in-an-afternoon.json",
 "api_version": "v1"
}
