Expand description
The awkward agent: a backend that produces the shapes real providers do.
This is not the application. It is the fixture the application is aimed at,
and it lives here because a client dogfood is only worth as much as the
streams it is pointed at. task-board’s agent is well-behaved — bracketed
messages, whole tool arguments, one call at a time — so it proves the happy
path and nothing else. Real streams are worse:
- text arrives as
TEXT_MESSAGE_CHUNKwith the id only on the first one; - tool arguments are split at arbitrary byte offsets, including between a backslash and the character it escapes;
- a model calls two tools at once and their events interleave;
- a producer in another language sends something the protocol forbids.
Every scenario is chosen by the first word of the user’s message, so a transcript names what it exercised. Nothing here is timed and nothing is random: the same message produces the same bytes every run.
§Why so much of it is raw emit
ag-ui-server’s typestate handles bracket what they open, which is exactly
what a chunk event is defined not to do — there is no ctx.text_chunk(),
and two overlapping ToolCallHandles are a
borrow-check error by design. Producing provider-shaped output therefore
means dropping to RunContext::emit, which is the documented escape
hatch. See the report: this is a finding, not a complaint about the design.
Structs§
- Awkward
- An agent that answers in the shapes a provider adapter produces.
Constants§
- BUDGET
- The interrupt ids the
approvescenario pauses on. - DATE
- The second of them. Two, because answering one per request never terminates.
- RAW_
ROUTE - Where the hand-framed, deliberately illegal streams are mounted.
- ROUTE
- Where the awkward agent is mounted.
Functions§
- raw_
script - The scripted illegal streams, by name.
- router
- The whole fake backend: the agent, the raw endpoint, and a health check.