Home / Generation Z Developers / Lenses, roles and loops

Generation Z Developers · The second edition, part by part · board 10

Lenses, roles and loops

How LLMs and agents work: a prompt as a lens, a role as a model with a description, an agent as a loop, tools as requests, no memory, compression, and focused threads. 13 panels.

draft 14 panels · gen-z.journalist, 18 October 2026, from Dinis's memo on LLMs and agents · book v1.0.0 is the only official version; the second edition is in release candidates (rc1 and rc2 frozen). Every line the Guide says, and every quote card, is from the article 'Lenses, roles and loops', word for word; the build checks it. The five lenses on recursion, the weather question and the named threads are the storyboard's illustrations.

Take it with you

The same storyboard in every shape it comes in. The data and its derived files are on this site; the pictures are drawn in your browser, now, by the same code as the deck (export.js, v0.1.0), from the current panel.

storyboard.jsonthe data, as gen-z-developers.sgit.ai wrote it bundle.jsonthe data with its cast, for an embed index.mdthe script, as markdown graph.jsona semantic graph: 34 nodes, 69 edges thumb.jpgthe cover, 480 wide og.jpgthe cover, 1200 wide

Put it on your page

Two lines, from any site. The script is pinned to an immutable release of the kit, so the embed draws exactly this, for as long as the page exists. How embedding works.

<script src="https://api.storyboards.sgit.ai/v0/v0.1/v0.1.0/embed.js" defer></script>
<sg-storyboard src="https://storyboards.sgit.ai/gen-z-developers/lenses-roles-and-loops/bundle.json" view="deck"></sg-storyboard>

The panels

  1. 1. Lenses, roles and loops: It stops being magic when you see how it works. (cover; Lenses, roles and loops)
  2. 2. One idea, recursion, through five lenses. Teenager → Musician → Doctor → Football fan → Portuguese (spectrum; Lenses, roles and loops, A prompt is a lens)
  3. 3. The wrong lens. Priya says: “I've always been bad at maths.” The Guide says: “The analogy is the reason someone understands something.” (scene; Lenses, roles and loops, A prompt is a lens)
  4. 4. A role is a model with a description. (graph; Lenses, roles and loops, A role is a model with a description)
  5. 5. An agent is a loop with a goal. The Guide says: “Fundamentally the agent is simply a task: do this; then, are we done yet, or do we need to continue?” (scene; Lenses, roles and loops, An agent is a loop with a goal)
  6. 6. The loop, with one tool call. (graph; Lenses, roles and loops, Tools changed everything; Precisely)
  7. 7. What the next request carries. Your question → Model asks → Harness → All of it, resent → The answer (spectrum; Lenses, roles and loops, Tools changed everything)
  8. 8. From training only, to tools. Nov 2022 → Mar 2023 → Mid 2023 → Nov 2024 → 2026 (spectrum; Lenses, roles and loops, Tools changed everything)
  9. 9. It remembers nothing. Zara says: “So it doesn't remember what I said an hour ago?” The Guide says: “There is no memory.” (scene; Lenses, roles and loops, It remembers nothing)
  10. 10. Long chats are compressed. What one summary keeps: the chat 100%, its summary 1.7% (evidence; Lenses, roles and loops, Long chats are compressed)
  11. 11. The newsroom's answer. “The rules are restored, not remembered.” (Re-anchoring agent behaviour policies (newsroom)) (evidence; Lenses, roles and loops, Long chats are compressed)
  12. 12. Many focused threads, each with a name. (graph; Lenses, roles and loops, Many focused threads)
  13. 13. Where the memory is. “Nothing is remembered by the model between sessions. Everything is remembered by the files.” (Memory is not a spectator sport (newsroom)) (evidence; Lenses, roles and loops, Long chats are compressed)
  14. 14. Not magic: a lens, a role, a loop.. (punchline; Lenses, roles and loops, Why this matters)

Imported unchanged from SGit-AI/SGit-AI__Website__Gen-Z-Developers/admin/content/storyboards/10__lenses-roles-and-loops.json at commit e2a71808 (2026-10-19). Every quote and Guide line was checked word for word against admin/content/articles/14__lenses-roles-and-loops.md by the origin site's build. The cast is cast.json.