Files
agency/.pnpm-store/v3/files/75/0c92aaf2e4573f34bed846b3768d96aaa600e024cdc28d736cf9e4b76d5ef6c2535af2a46bad9d6bc4304e91e472556fbfb873f641e7f91ab001f54956b0f2
hanzo-agent 5af6960b87 run project
Run: sess_f37640604ae254cb4d11dc6217f7b721
2026-09-30 00:04:56 +00:00

45 lines
2.0 KiB
Plaintext

/**
* What each event MEANS and what it CARRIES.
*
* `names.ts` says which events exist. This says what they are — one entry per
* name, a sentence a human can read and a property list a machine can check.
*
* Two rules keep this honest, and both matter more than completeness:
*
* 1. A property is listed only where there is EVIDENCE for it — a docstring in
* the vocabulary, or a live `capture()` call in a Hanzo surface. An invented
* property is worse than an absent one: it teaches a wrong shape to whoever
* reads this next, and to anything trained on the corpus.
*
* 2. Every event is OPEN. The wire accepts free-form properties and always has,
* so `props` is what we know an event carries, never the exhaustive set. A
* property absent here is undocumented, not forbidden — which is why the
* server records an unknown one rather than refusing it.
*
* The dimensions of an event are properties, never part of its name:
* `deploy_succeeded` with `{framework:'static'}`, never `deploy_static_succeeded`.
* That is what makes a funnel line up across surfaces, and it is why this file
* can exist at all.
*/
/** A property's type, as it travels on the wire. */
export type PropType = 'string' | 'number' | 'boolean';
export interface PropSpec {
type: PropType;
/** What it means. Written for someone reading a chart, not a type signature. */
doc: string;
/** The values seen in practice. Advisory — the wire accepts others. */
values?: readonly string[];
}
export interface EventSpec {
/** One sentence: the user-visible moment this records. */
summary: string;
/** Properties we have evidence for. Never exhaustive — see rule 2 above. */
props: Readonly<Record<string, PropSpec>>;
}
/**
* The catalog, keyed by the wire name (the value in EVENTS, not the constant).
* Keying by the wire name is deliberate: it is what arrives at the door, what
* lands in the warehouse, and therefore what anything reading this has in hand.
*/
export declare const SCHEMA: Readonly<Record<string, EventSpec>>;