Faithful Elixir port of Hindsight's engine/consolidation/prompts.py
(build_batch_consolidation_prompt): the LLM merge contract that turns raw
facts into consolidated observations via creates/updates/deletes.
The MISSION defines what to track (bank-overridable) and takes priority over the PROCESSING RULES when the two conflict. Rules, decision guide, and output format are always present.
Summary
Functions
Render new facts as bracketed lines: [uuid] content (occurred_start=..., mentioned_at=...).
Mirrors the Hindsight fact rendering the source_fact_ids rules refer to.
Render pooled existing observations as a JSON array string (empty → "[]").
Build the system + user messages for a batch consolidation call.
JSON schema for the creates/updates/deletes response contract.
Functions
Render new facts as bracketed lines: [uuid] content (occurred_start=..., mentioned_at=...).
Mirrors the Hindsight fact rendering the source_fact_ids rules refer to.
Render pooled existing observations as a JSON array string (empty → "[]").
Build the system + user messages for a batch consolidation call.
mission is the bank's observations mission (nil → default). facts_text and
observations_text are the rendered INPUT sections (see format_facts/1 and
format_observations/1). capacity_note is an optional slot-cap constraint.
@spec schema() :: map()
JSON schema for the creates/updates/deletes response contract.