The intermediate template
Once the Quickstart works, this template shows what a fuller project looks like.
abt init --template intermediate, run in a fresh folder, writes the same two agents with more frontmatter, plus the files they reference: transformers/, contracts/, tools/, context/, few_shots/ and macros/, and a reviewer_org variable in abt.yaml. Here is what they look like.
agents/analyst.md:
---
description: Extract key facts and a one-paragraph summary from the user's document.
tools: []
output_schema:
title: AnalysisResult
properties:
facts:
type: array
items:
type: string
description: Key factual statements extracted from the document.
summary:
type: string
description: A one-paragraph summary of the document.
confidence:
type: number
description: How confident you are in this analysis, from 0 (low) to 1 (high).
complexity:
type: number
description: How hard the document was to analyze, from 0 (straightforward)
to 1 (highly complex, no clear answer).
few_shots:
- analyst_example.yaml
---
You are the analyst. Read the user message (the document to analyze).
Reply with **JSON only** matching your output_schema (facts, summary, confidence, complexity).
The keys that matter first:
descriptiontellsreviewerwhen to callanalyst.toolslists the tools the agent can call.[]means none.output_schemais the structured output the model must fill. This one is written inline.few_shotsadds example trajectories for repetitive tasks.
The text after the frontmatter is the system prompt.
agents/reviewer.md:
---
description: Reviews content quality. Delegates fact extraction to the analyst, then
emits structured JSON via a Pydantic output contract.
tools:
- word_count
output_schema: review_result.ReviewResult
subagents:
- analyst
transformers:
- validate_json
- redact_pii
- quality_gate
middleware:
- run_timeout:
graceful_timeout_seconds: 120
- model_call_limit:
max_model_calls: 5
---
## Style guide
{{ context.local('review/style_guide') }}
## Delegation
When you need extracted facts before judging, involve the `analyst`.
You are reviewing content on behalf of {{ var('reviewer_org') }}.
You are the reviewer. Output **JSON only** matching your output_schema (score, verdict, issues).
Use the analyst's output and the style guide. If you use the word_count tool, call it at most once.
What the reviewer adds:
output_schema: review_result.ReviewResultis a dotted path to a Pydantic model class,ReviewResult, incontracts/review_result.py.subagents:lists the agents this one may call as tools.transformers:names catalog files intransformers/, applied to the reviewer's text in list order.middleware:caps the run, here with a timeout and a model-call limit.{{ context.local(...) }}inlinescontext/review/style_guide.md, and{{ var('reviewer_org') }}readsvars:fromabt.yaml.--varsoverrides it at run time.
abt init --template intermediate --with-handlers also adds an on_success hook to reviewer and an example handler under handlers/.
Back to the Quickstart, or see Agents for every frontmatter key.