Expand description
Verb response presentation modes and transformation (ADR-045).
Handlers always return a canonical (verbose) shape. This module transforms that shape into a caller-appropriate form AFTER dispatch, BEFORE wire serialization.
§Transformation rules
| Field type | Verbose form | Agent form |
|---|---|---|
| UUID (36-char) | "a1b2c3d4-e5f6-..." | "a1b2c3d4" (8 chars) |
| ISO-8601 timestamp | "2026-05-23T16:18:15.234Z" | "2026-05-23T16:18" (< 24h: "3m ago") |
Empty string "" | included | dropped |
Empty array [] | included | dropped |
Empty object {} | included | dropped |
null (non-lifecycle) | included | dropped |
null (lifecycle *_at, relationship markers) | included | preserved |
| Score fields | 0.1234567890 | 0.123 (3 sig figs) |
Verbose mode passes through canonically. Human mode is delegated to the
CLI layer and is not transformed here (returned as-is from this crate).
Chain invariant: present_response MUST NOT be called on intermediate
chain results — only on the final response envelope after all $prev
substitutions complete.
Enums§
- Presentation
Mode - How the response envelope is presented to the caller (ADR-045).
Functions§
- present
- Transform a successful verb result value according to the given
PresentationMode.