fleet-memory/hindsight-docs/docs/developer/api
Nicolò Boschi 5d05962db0
feat: add source facts token limits to consolidation and recall (#509)
* feat: add source facts token limits to consolidation and recall

- Add two new configurable (per-bank) parameters:
  - consolidation_source_facts_max_tokens: total token budget for source
    facts across all observations in the consolidation prompt (-1 = unlimited)
  - consolidation_source_facts_max_tokens_per_observation: per-observation
    cap so each observation gets a fair share of source facts (-1 = unlimited,
    default 256)
- Both are also exposed as recall API parameters via SourceFactsIncludeOptions
  (max_tokens and max_tokens_per_observation)
- Consolidation now uses resolve_full_config to respect bank-level overrides
- Improve consolidation prompt: temporal metadata (occurred_start=, | Involving:)
  is now clearly separated from observation text, with a concrete example showing
  the expected synthesis style and explicit rules not to copy raw fact lines
- Add tests for recall source facts capping and consolidation config forwarding
- Expose all three new fields in the control plane bank config UI
- Document new env vars in configuration.md
- Regenerate OpenAPI spec and all SDK clients

* fix: reorder observations UI fields and rename Label Groups to Entity Labels

* fix: revert Entities section title (only rename inner label)

* doc: add consolidation source facts and batch size fields to memory-banks docs
2026-03-06 13:01:33 +01:00
..
documents.mdx feat: add tags filtering and q description fix for list documents API (#468) 2026-03-02 17:03:16 +01:00
main-methods.mdx chore: internal renames (#204) 2026-01-27 09:53:28 +01:00
memory-banks.mdx feat: add source facts token limits to consolidation and recall (#509) 2026-03-06 13:01:33 +01:00
mental-models.mdx feat: filter graph memories with tags (#431) 2026-02-25 10:31:40 +01:00
operations.md chore: internal renames (#204) 2026-01-27 09:53:28 +01:00
quickstart.mdx doc: mental models (#199) 2026-01-26 14:27:08 +01:00
recall.mdx feat: filter graph memories with tags (#431) 2026-02-25 10:31:40 +01:00
reflect.mdx doc: improve api explanation (#415) 2026-02-20 17:02:01 +01:00
retain.mdx feat: support timestamp="unset" to retain content without a date (#465) 2026-03-02 12:03:23 +01:00
webhooks.mdx feat: webhook system with retain.completed event, UI, and docs (#487) 2026-03-04 14:17:01 +01:00