Home › The Schema

Object 02 // typed contract

Schema-first on what you know. A catch-all for the rest.

Which event types can you name today, and which will you only discover in production?

Schema-first on the event types you know for certain, a structured catch-all for everything else. You get most of the structured benefit on day one without a blind spot for the unknown.

Watch the transformation

The same fact, before and after a contract.

"Maria refinanced her mortgage in March after the rate cut, dropping her monthly payment by about 240 euros. It took three weeks to close."

event_typemortgage_refinance
actor_idmaria_k
timestamp2026-03-14
triggerrate_cut
payment_delta_eur-240
days_to_close21

The prose is still the source of record. The typed event is what you embed, rank, and reason over. Types make retrieval deterministic instead of fuzzy.

The two options most teams try to take both of

Schema-first, with a catch-all that earns its keep.

Schema-first gives fast, deterministic, cheap retrieval, at the cost of rigidity: every new type is a migration, and you will miss types in month one. Unstructured-first is flexible and fast to bootstrap, but quality degrades as the corpus grows and you hit a wall where you re-engineer the whole index anyway, now with ten times the data.

So you take neither extreme. Schema-first on the core types you know, a structured catch-all bucket for the rest. You get 80% of the structured benefit on day one, and the catch-all gives you signal on what new types are actually appearing. You mine it every quarter and promote patterns into first-class types. It is not elegant. It works.

Common questions

The objections that come up here.

This sounds rigid.

It is rigid where rigidity is cheap and flexible where it matters. Determinism on the types you know, a catch-all that gives signal on the unknown, promoted on a schedule. The rigidity is what makes retrieval reproducible.

What if I miss an important event type in month one?

You will, and the catch-all catches it. You promote recurring patterns into first-class types each quarter, on a schedule, instead of discovering the gap in production.

In the structure

before in the loop

← The Event

Each event instantiates one schema. The unit comes first, the contract gives it structure.

Open the object →
next in the loop

The Context Slots →

The schema's typed fields map to typed positions in the brief the model reads.

Open the object →

The reading

Sketch your core schema in twenty minutes.

Bring one domain. We define the typed fields and the catch-all on the call.

Book my technical call →