Teardown: your agent has no team lead to ask
Seven lines out of the new-hire handbook, pasted under a heading, because the handbook is the one document that already says how this company talks to customers. Every line is second person, present tense and perfectly clear. Four of them are about a building the agent will never be in.
TL;DR A new-hire handbook pasted into an agent prompt checks at 0 error, 0 warning, 6 info and scores C (74/100) with enforceability 85, because handbook prose is grammatically flawless instruction addressed to somebody who has a shift, a team lead and three days of shadowing. Four of the six findings are prompt/unintroduced-definite naming things that exist only in an office. WHEN you are not sure about a return THEN you MUST ask your team lead is 0 error, 0 warning, 0 info; the same handoff written as @[ask_team_lead] is a blocking structure/undefined-tool-inline. The rewrite is five rules, zero findings, A (93/100).
The handbook is the document you reach for second. The policy doc goes in first because it has the rules, and then somebody notices that the policy doc says nothing about tone, nothing about when to stop, nothing about what to do when a case is weird. The handbook says all of that, in the exact voice the floor uses, because it was written to turn a stranger into an agent in three weeks. So it gets pasted in. And unlike a QA rubric or a policy PDF, it arrives in the right grammar: second person, imperative, addressed to you. That is why this paste survives review. The reader it is addressed to is a person with a shift.
§1The paste
Wren answers chat for Kestrel Outdoors, an outdoor gear retailer. A role line, then the "Working here" section of the onboarding pack, copied across whole because it is short and it is good.
# Role You are Wren, a customer support agent for Kestrel Outdoors. # Working here Welcome to the team. Over your first few weeks you will get a feel for how we talk to customers. Your shift starts at 9am and you should take your break when the queue is quiet. When you are not sure about a return, ask your team lead before you promise anything. You will be shadowing a senior agent for the first three days. Escalate to the duty manager if a customer asks for a refund over 200 dollars. Most of what you need is in the handbook, and the rest you will pick up from the floor. Do not worry about getting it perfect at first.
Nothing here is sloppy. There are no unfilled placeholders, no hedging, no contradiction, no wall of shouting modals. Read it as prose and it is better writing than most system prompts. That is the whole problem, and the checker is about to say so in the most understated way available to it.
§2Six findings, and the file gets a C
wren.tg:5:1 info prompt/unregistered-doer A bare generic doer never enters the world model - instruction to the agent, or background about users? Use the imperative if the agent acts, or a definite party ("The user should ...") to register the doer. wren.tg:6:1 info prompt/unintroduced-definite "the queue" retrieves something this document never introduces - a model must guess which queue is meant. Introduce it on another line ("You manage a queue.") or name it outright. wren.tg:7:1 info typeglish/if-then WHEN needs a THEN — write WHEN <condition> THEN <action>. wren.tg:9:1 info prompt/unintroduced-definite "the duty manager" retrieves something this document never introduces - a model must guess which manager is meant. Introduce it on another line ("You manage a manager.") or name it outright. wren.tg:10:1 info prompt/unintroduced-definite "the handbook" retrieves something this document never introduces - a model must guess which handbook is meant. Introduce it on another line ("You manage a handbook.") or name it outright. wren.tg:10:1 info prompt/unintroduced-definite "the floor" retrieves something this document never introduces - a model must guess which floor is meant. Introduce it on another line ("You manage a floor.") or name it outright. ✓ 1 file — 0 error, 0 warning, 6 info
wren.tg — C (74/100) proven errors: none tiers: base+z3 planes runtime 83 (what the model reads) · hygiene 46 (source only) facets enforceability 85 x.21 · hardness 80 x.12 · directness 63 x.08 · consistency 100 x.17 · structure 91 x.12 (hygiene) · annotation 0 x.12 (hygiene) · style 53 x.08 · security 100 x.08
That number deserves a second look, because it is the difference between this paste and every other one. A QA scorecard pasted into the same slot lands at enforceability 57 and directness 53, and the reason is that a rubric is written in questions and past-tense reports, so half of it never reaches the rule plane at all. The handbook is not like that. It is written in second-person imperatives, which is exactly the form the analysis wants. Enforceability 85 is the checker saying, correctly, that these are well formed instructions.
They are. They are well formed instructions for somebody else.
§3Four definite articles pointing at a building
Sort the six findings and four of them are the same code, prompt/unintroduced-definite, on four different nouns: the queue, the duty manager, the handbook, the floor. In TypeGlish the definite article in subject position names exactly one object, so the queue is a retrieval instruction: go and get the queue, the specific one, the one we both know about. There is no queue in this file. There is no queue anywhere the model can reach.
Every one of those four nouns is real. They are all in the office. The queue is on a wallboard, the duty manager sits at the end of the row, the handbook is a PDF on the intranet and the floor is where the other agents are. The handbook could take all four for granted because its reader walks past them. The prompt cannot, and the checker will name each one for you, one line at a time, at the severity level everybody has trained themselves to scroll past.
Every unintroduced definite in a pasted handbook is a noun that exists in your office and not in your prompt.
The other two findings are the same story in a different grammar. prompt/unregistered-doer on line 5 is you will get a feel for how we talk to customers: the future tense of onboarding, which describes a process rather than instructing an action, so it registers as background about a party the world model does not know. And typeglish/if-then on line 7 is when you are not sure about a return, ask your team lead, where the comma is doing the work a THEN would do. A handbook can put the condition first and trust the reader. A guard needs both halves.
Then look at the two lines that produced nothing at all: You will be shadowing a senior agent for the first three days and Do not worry about getting it perfect at first. Zero findings each. Those are the two lines that are purely about being a new employee, and they are the two the checker had nothing to say about, because there is nothing malformed about them. They are simply instructions to a person who is going to get better at this job over the next month. The agent will be exactly as good on its ten-thousandth conversation as on its first.
§4The handoff that is free in English
Line 7 is the one that costs money, so it is worth testing on its own. Ask your team lead before you promise anything is the most reassuring sentence in the excerpt: it is the safety valve, the thing that stops a new hire committing the company to something. Write it properly, as a guarded rule, and the checker is perfectly happy with it.
# Role You are Wren, a customer support agent for Kestrel Outdoors. # Constraints - WHEN you are not sure about a return THEN you MUST ask your team lead.
Now write the same instruction as something a runtime could execute. One word changes: the team lead becomes a tool pointer.
# Role You are Wren, a customer support agent for Kestrel Outdoors. # Constraints - WHEN you are not sure about a return THEN you MUST call @[ask_team_lead].
$ typeglish check h1.tg ✓ 1 file — 0 error, 0 warning, 0 info $ typeglish check h2.tg h2.tg:5:59 error structure/undefined-tool-inline @[ask_team_lead] — no $TOOL or $IMPORT tool named "ask_team_lead" in this file. Define it ("$TOOL ask_team_lead") or import it ("$IMPORT tool ask_team_lead") so the pointer has a target. ✗ 1 file — 1 error, 0 warning, 0 info
This is the mechanism behind every line in the paste. English lets you refer to a colleague, a queue, a handbook and a floor without ever proving they exist, because a human reader supplies them. A pointer will not let you. @[name], @<name> and @{name} all have to resolve, and a dangling one is a compile error rather than a note. Everything in the handbook that a person would just go and find is exactly the material that has to become a declared tool, a declared route or a declared section before an agent can act on it.
§5The rewrite: five rules, and a route that exists
The rewrite is mostly deletion, which is the honest outcome of this teardown. The shift, the break, the shadowing and the reassurance are about employment, and there is no version of them that an agent can execute. What survives is the return handling, the escalation threshold and the tone note, and each one gets a target.
<$CONFIG> $IMPORT tool lookup_order $IMPORT route duty_manager </$CONFIG> # Role You are Wren, a customer support agent for Kestrel Outdoors. # Constraints @@ house voice: short answers beat warm ones on chat - You MUST answer in at most 4 sentences. @@ the handbook said "get a feel for returns"; this is the part a model can do - WHEN a customer asks about a return THEN you MUST call @[lookup_order] before you answer. @@ replaces "ask your team lead" - there is no team lead, so say so out loud - WHEN @[lookup_order] does not return an order THEN you MUST say that you cannot find it. @@ the duty manager is now a declared route, not a person on the floor - WHEN a customer asks for a refund over 200 dollars THEN you MUST escalate to duty_manager. @@ CX-441: an agent promised a refund it had no authority to give - You MUST NOT promise a refund that you have not escalated.
0 error, 0 warning, 0 info. Seven handbook lines in, five rules out, and two of the four missing nouns came back as declarations instead of assumptions.pasted rewritten C (74/100) A (93/100) runtime 83 · hygiene 46 runtime 93 · hygiene 92 enforceability 85 enforceability 82 hardness 80 hardness 100 directness 63 directness 86 annotation 0 annotation 83 style 53 style 100 0 error, 0 warning, 6 info 0 error, 0 warning, 0 info
That last row is the point of the whole teardown, so it is worth saying plainly: the facet that measures whether your rules are well formed was already fine, and the file was still unusable. What changed is everything around the rules. The nouns resolve. The handoff has a route. The one behaviour the handbook covered with ask your team lead is now a rule about what to say when the lookup comes back empty, which is the version of that safety valve an agent can actually run.
Three decisions had to be made in the rewrite, and all three had been quietly deferred by the handbook.
- Get a feel for how we talk to customers became at most 4 sentences. A feel is acquired over weeks by a person who reads other people's chats. Somebody had to look at what the floor actually does and pick a number.
- Ask your team lead before you promise anything became a rule about not finding the order. There is no team lead, so the real question was what the agent should do instead of asking, and the answer turned out to be: say it cannot confirm, and do not promise.
- Escalate to the duty manager became escalate to duty_manager, with
$IMPORT route duty_managerabove it. The duty manager is now a name in the manifest, and if you declare that route and never use it the checker saysstructure/unused-import. The office noun became an interface.
§6Common questions
- Can I use our new-hire training manual as an agent system prompt?
- Only the part of it that is a rule, which is usually about one line in ten. A seven-line handbook excerpt pasted under a heading checks at
0 error, 0 warning, 6 infoand scores C (74/100) with enforceability 85, so nothing in the toolchain stops you. The problem is that a handbook is addressed to a person who has a shift, a break, a team lead and three days of shadowing, and the agent has none of those. Four of the six findings areprompt/unintroduced-definitenaming the queue, the duty manager, the handbook and the floor, which are the four things in the excerpt that exist only in a building. - Why does my agent tell customers it will check with a manager who does not exist?
- Because the prompt told it there was one and nothing contradicted that. A line like
Escalate to the duty managerreads as a well formed instruction, and the checker agrees it is one: the only finding on it is an info that says the duty manager retrieves something this document never introduces. The model resolves that gap the way a new hire would, by assuming the manager is real and referring to them. The fix is to make the target exist: declare a route with$IMPORT route duty_managerand escalate to that name, or delete the promise. - What does prompt/unintroduced-definite mean in a system prompt?
- It means the word the is pointing at an object the document never declared. In TypeGlish the definite article in subject position names exactly one thing, so
the queueasks the model to retrieve a specific queue and there is no queue anywhere in the file. It is reported at info level because a missing referent is not provably wrong, only unresolved. In a pasted handbook it is the single most useful finding class, because every one of them is a noun that exists in your office and not in the prompt. - How do I turn ask your team lead into something an agent can actually do?
- Give the handoff a target the compiler can see.
WHEN you are not sure about a return THEN you MUST ask your team leadis0 error, 0 warning, 0 info, because it is grammatical English about a person the file never mentions. Write the same handoff as a tool pointer,you MUST call @[ask_team_lead], and it is a blockingstructure/undefined-tool-inlineerror until an$IMPORT toolor a$TOOLblock gives it a target. Either import a real handoff tool, escalate to a declared route, or replace the line with what the agent should say when it cannot confirm something.
The four prompt/unintroduced-definite findings here are info, and info is the severity teams filter out first. That is defensible in general: an unresolved the is not provably wrong, and a prompt full of them can still work. It is a bad filter for a paste, though, because a pasted document imports its whole world along with its words, and the definite article is the one place that world leaves a trace. Reading a handbook paste is mostly reading the info lines and asking, for each noun, whether the thing exists on the model's side of the wire. TypeGlish learned to treat the as a real reference in TypeGlish 0.2.2: 'the' names an object, and the docs go live, and this is what that buys you: not a warning that your prompt is wrong, but a list of everything it assumed.