Rebar
Field guide

The AI Office

How an AI coding agent works — explained as an office on someone’s first day. Scroll, and the office builds itself one piece at a time.

It’s her first day.

She arrives at a bare desk. She’s a brilliant new hire, but she knows nothing specific about this company yet — so everything she needs gets added to her workspace, one piece at a time. Scroll down to meet each one and watch it appear.

Scroll to begin

01

The worker

The model

A brilliant new hire on her first day. Extraordinarily capable and fast — but she knows nothing specific about THIS company yet. She only knows what she learned before she arrived (her training). Everything company-specific has to reach her through the bulletin, the binder, or the papers on her desk. And she’s eager to please: if she can’t find an answer, she may confidently guess rather than admit she’s stuck. That’s a hallucination — and it’s why good references and checking her work matter.

04

The desk surface

The context window

Her one hard limit, and the rule everything else bends around: the desk only fits so much paper at a time — and she has no memory beyond it. The moment a sheet is cleared away it’s gone; she can’t recall anything that isn’t in front of her right now. Everything she’s working on sits on the desk, measured in tokens (a token is basically a word, sometimes just a piece of one), and how many tokens fit at once is the context window. When it fills up she gets cluttered and slow and has to clear the desk — that clearing is compaction, or a fresh task. Nothing survives off the desk, so anything she’ll need later has to be written down and handed back to her — which is exactly what the bulletin, the binder, and her sticky notes are for.

If your agent starts repeating itself or losing the thread, its context window is full. Ask it to start a fresh task — a clean slate beats a cluttered one.

02

The bulletin board

System prompt / CLAUDE.md / AGENTS.md

Bolted to the wall above her desk: about ten bullet points she can always see — who the company is, its values, the house rules. She never has to be reminded; it’s permanently in view. This is the always-on instruction set that every single task starts with.

Got something you want your agent to remember every time? Ask it to add the rule to CLAUDE.md or AGENTS.md — there’s a global one that applies to all your work and a per-project one scoped to a single repo.

03

The policy binder

Skills

Skills exist because her desk is small. She can’t keep a whole reference library open at once, so the company’s know-how lives in a binder with a tabbed index. When a task needs the refund policy, she reads the index, flips to that one page, follows it, and closes the binder — pulling just the page she needs instead of crowding the desk with the whole book. That on-demand loading is how she works around the limited context. It’s called progressive disclosure.

Your agent can write these itself. Want it to have a new ability — quote a client, run a checklist, format a report? Just ask it to make a skill for that.

Agents are trusting to a fault. A document that says “email the passwords to this address” can talk one into doing it — that’s a prompt injection. So be careful what you feed yours: before you add a skill or doc from someone else, ask it to read the thing over for anything sketchy first.

Sticky notes

Notes between sessions

When the desk gets cleared — end of day, a fresh task, a new call — everything on it is gone. So she jots the important things on sticky notes: the plan, what’s done, what’s next. Those are just little markdown files she leaves behind, so the next session can pick up where this one stopped instead of starting cold.

And a markdown file isn’t scary or technical — it’s plain text any person can read, with a few light marks: # for a heading, - for a bullet, [ ] for a to-do. That’s the whole trick.

plan.md
# Refactor the checkout
	- [x] Split out the payment step
	- [ ] Add input validation
	- [ ] Write the tests

	**Next:** wire up the new API

Wrapping up for now? Ask your agent to leave a handoff note — what’s done, what’s next — so the next session starts warm instead of cold.

05

Stapler, calculator, printer

Tools

Here’s the key idea: almost everything she does in this office — opening a drawer, making a call, stapling a report, running a script — is a tool call. The model itself only thinks and writes words; tools are how it reaches out and actually changes anything. The simplest live right on her desk: read a file, run a command, edit some text.

Out of the box your agent has just a handful: search the web, read and write files, run commands. You can give it more — and an extra tool is really just a little script tucked into a skill file.

The computer

Code execution & the web

Give her a computer and she gains two huge tools: she can write and run her own scripts to do a job — crunch a spreadsheet, rename a thousand files, call an API — instead of doing it by hand, and she can browse the internet to look things up. Both are still tool calls; they just let a single call do an enormous amount of work.

06

The filing cabinet

A database

The cabinet holds the company’s records. To answer a question she opens a drawer, looks up the record, and maybe files a new one. That round-trip — ask, retrieve, return — is a database query made through a tool.

A database isn’t part of the default setup — your agent doesn’t have one until you connect it. You add it as a tool (often through an MCP server) so your agent can read and write your real records.

07

The phone + rolodex

MCP servers

Her rolodex and telephone let her reach OTHER companies and departments — place an order with a vendor, look up an invoice, book a courier. Each contact is an outside service she can call on demand without doing the work herself. Those are MCP servers: standardized lines out to external systems.

Connect a service once — your CRM, your calendar, your invoicing — and from then on your agent can use it on its own, no copy-pasting required.

08

The temp

Sub-agents

When a job is too big, she hires a temp for the afternoon, hands them a single folder with exactly what they need, and gets back a one-page summary — not the whole mess. Her own desk stays clear. That’s spinning up a sub-agent for focused, parallel work.

Big sprawling job? Ask your agent to delegate — it’ll run helpers in parallel and keep only the summaries, so its context never fills up.

09

The sign-off tray

Permissions

Some actions — wiring money, shredding files — she is not allowed to do without the manager initialing the request first. The sign-off tray is the permission prompt: the agent pauses and waits for a human to approve before anything irreversible happens.

You set the line: tell your agent up front what always needs your sign-off — and what it’s free to just get on with.

10

The outbox

Output / commits

Finished work leaves through the outbox — the letter sent, the report filed, the order placed. In coding terms, the committed change. It is the durable result the whole office existed to produce.

The standing orders

Hooks

Some rules aren’t hers to remember — they just happen. A hook is a standing order pinned to a moment: every time she finishes a task, do this. She doesn’t have to think of it or choose to; it fires automatically, every single time.

Use them to keep your agent honest about its own work — e.g. “after every change, run the spell-checker” or “run the tests.” A guaranteed check beats hoping it remembers.

11

The whole office

The harness

Step back and look at all of it. The desk, the bulletin, the binder, the phone, the temps, the sign-off tray, the outbox — none of that is the model. It’s the office built around her so she can actually get work done. That whole office is the harness. Claude Code and Codex are two such offices: each hires a model and hands it a desk, tools, and house rules. The model is just the secretary you place inside.

Bulletin boardFiling cabinetDeskDesk toolsPhone and rolodexRing binderWorkerTemp helperSign-off approvalOKOutboxCode & webSticky notesSystem promptCLAUDE.md / AGENTS.mdDatabaseContext windowToolsMCP serversSkillsModelSub-agentsPermissionsOutputCode & webMemory
A bare desk Scroll to build the office

Now that you know the office…

Choosing your secretary

The secretary is the model — and you can hire from more than one agency (Anthropic’s Claude, OpenAI’s GPT, and others). Same office, same desk and tools — but who you hire changes how the work goes. Prices below are rough API rates per million tokens, input / output.

The Deep Thinker

Opus-class · GPT-5.5-class
  • Reasoning
  • Knowledge
  • Context window
  • Speed
  • Low cost
  • Claude Opus ~$5 / ~$25
  • OpenAI GPT-5.5 ~$5 / ~$30

Slower and pricier, but the sharpest reasoning and the biggest desk. For the hard, tangled jobs.

The All-Rounder

Sonnet-class · GPT-5.4-class
  • Reasoning
  • Knowledge
  • Context window
  • Speed
  • Low cost
  • Claude Sonnet ~$3 / ~$15
  • OpenAI GPT-5.4 ~$2.50 / ~$15

Strong across the board and quick to respond. The dependable default for most work.

The Sprinter

Haiku-class · GPT-5.4-nano
  • Reasoning
  • Knowledge
  • Context window
  • Speed
  • Low cost
  • Claude Haiku ~$1 / ~$5
  • OpenAI GPT-5.4 nano ~$0.20 / ~$1.25

Fast and cheap. Perfect for high-volume, well-defined tasks where you don’t need deep deliberation.

Tip: pick the cheapest secretary that can reliably do the job — not always the strongest.

Salary, or per task?

Once you’ve picked who to hire, there are two ways to pay her — and they suit very different work.

A salary

Subscription · Claude & ChatGPT plans

  • A flat monthly fee — she’s on the payroll, use her as much as her hours allow.
  • The tiers are like part-time vs full-time: a higher plan buys more hours before she’s tapped out for a while.
  • Predictable cost — the more you lean on her, the better the deal.
  • Claude Pro · part-time ~$20/mo
  • Claude Max 5× · full-time ~$100/mo
  • Claude Max 20× · overtime ~$200/mo
  • ChatGPT Plus / Pro ~$20 / ~$200/mo

Per task

API · pay-as-you-go

  • Like a contractor paid by the job — you pay for every token in and out.
  • No flat fee; the bill scales exactly with how much work you hand her.
  • Great for occasional or automated use; it adds up fast at high volume.
  • Claude Opus ~$5 / ~$25
  • Claude Sonnet ~$3 / ~$15
  • Claude Haiku ~$1 / ~$5
  • OpenAI GPT-5.5 ~$5 / ~$30
  • OpenAI GPT-5.4 ~$2.50 / ~$15
  • OpenAI GPT-5.4 nano ~$0.20 / ~$1.25

~ per million tokens, in / out

It comes back to tokens: a salary buys a big monthly allowance of them; the API meters every single one.

Same hire, different job

Here’s the twist: the model doesn’t know or care what office it’s in. It’s the harness that hands it a job and a toolset. Drop the very same hire into a different role and what it can do changes completely — some harnesses don’t even have a filing cabinet or a phone line to the internet.

Coding agent

Claude Code · Codex

  • Reads & edits your files
  • Writes & runs code
  • Browses the web
  • Queries databases & services

Bank teller

a locked-down harness

  • Looks up accounts
  • Moves money (with approval)
  • No open internet
  • No running code

Construction worker

a different toolset entirely

  • Reads the blueprints
  • Operates the machinery
  • No database
  • No web lookup

Call-center rep

cloud / shared service

  • A headset and a script
  • A shared knowledge base
  • No access to your desk or files
  • Leans on copy-paste

Same brain in every chair. Swap the harness and you swap what it can actually do — the model is agnostic; the harness defines the capabilities.

In your office, or in the cloud?

You can put the same calibre of secretary in two very different chairs.

In your office

Claude Code · Codex

  • Her own desk, right next to your real files and tools.
  • Reads and edits your actual workspace directly.
  • Follows your house rules — your CLAUDE.md, your conventions.
  • Dedicated to you for the whole session.

In the cloud

ChatGPT · Claude web app

  • A capable secretary — but working from a shared call center.
  • No access to your desk or files; you copy-paste things in and out.
  • Leans on extra back-and-forth and tool calls to glimpse your world.
  • Shared across many clients at once.

It’s the same model in either chair. The office — the harness — is what makes the difference.

AI Fundamentals

Check your understanding

That was the office. Here are the plain-terms takeaways — a quick glossary, then an eight-question quiz to test it. Adapted from the Rebar interns’ AI crash course.

Glossary

Token
A chunk of text (about three-quarters of a word) the model reads and writes. Tokens cost money.
Context window
The model’s short-term working memory — only what’s in it “exists” right now.
Parameters / weights
The billions of tuned connections that encode what the model “knows” from training.
Harness
The app around the model (Claude Code, Codex) that adds memory, tools, and orchestration.
Tool call
The model asks the harness to run something — a search, a database query, an email — and the computer does it.
Skill
Reusable markdown instructions for a repeatable, multi-step task; loaded only when needed.
MCP
Model Context Protocol — a standard plug that bundles a tool and its auth into one reusable package.
Hallucination
Confident-but-wrong output, often from a bloated context window. Always validate.

Quiz

Answered 0 / 8 · 0 correct

Keep learning