fleet-memory/hindsight-docs/docs/developer
Nicolò Boschi 99220d0527
feat: per-request file parser selection with fallback chains (#514)
* feat: allow per-request file parser selection with fallback chains

Clients can now specify which parser(s) to use when calling the file
retain endpoint, instead of being locked to the server-side default.

Changes:
- `parser` field added to `FileRetainRequest` (request-level default)
  and `FileRetainMetadata` (per-file override); accepts a single name
  or an ordered fallback chain (list)
- Resolution priority: per-file > request-level > server default
- `HINDSIGHT_API_FILE_PARSER` now accepts a comma-separated fallback
  chain (e.g. `iris,markitdown`); fully backward-compatible
- New `HINDSIGHT_API_FILE_PARSER_ALLOWLIST` env var restricts which
  parsers clients may request (defaults to all registered parsers)
- Invalid/disallowed parser names are rejected with HTTP 400
- `FileParserRegistry.convert_with_fallback()` tries each parser in
  order, falling back on UnsupportedFileTypeError, empty content, or
  any other error
- Worker updated to use the fallback chain stored per-task
- OpenAPI spec and all generated clients regenerated

* fix: handle on_file_convert_complete hook and rebase onto main

- Return ConvertResult dataclass from convert_with_fallback() instead
  of a plain str, carrying both the content and the winning parser name
- Use winning_parser_name in the on_file_convert_complete hook so
  parser_name reflects the parser that actually succeeded, not the chain
- Update all test calls to submit_async_file_retain() to use the new
  per-item parser field instead of the removed top-level parser= kwarg

* docs: document HINDSIGHT_API_FILE_PARSER fallback chain and ALLOWLIST
2026-03-06 16:15:43 +01:00
..
api feat: add source facts token limits to consolidation and recall (#509) 2026-03-06 13:01:33 +01:00
admin-cli.md chore: internal renames (#204) 2026-01-27 09:53:28 +01:00
configuration.md feat: per-request file parser selection with fallback chains (#514) 2026-03-06 16:15:43 +01:00
development.md rename to hindsight (#2) 2025-11-25 19:28:26 +01:00
extensions.md feat: add extension hooks for root routing and error headers (#470) 2026-03-03 10:50:03 +01:00
index.md fix: misc fixes for observations and mental models (#209) 2026-01-27 15:37:57 +01:00
installation.md doc: fix build 2026-02-25 16:58:06 +01:00
mcp-server.md feat: expand MCP tool surface area with 18 new tools and enhanced parameters (#435) 2026-02-25 10:26:46 +01:00
models.md doc: add ZeroEntropy reranker to models.md (#489) 2026-03-04 13:28:25 +01:00
monitoring.md feat: add otel traceability (#330) 2026-02-10 12:20:48 +01:00
multilingual.md chore: internal renames (#204) 2026-01-27 09:53:28 +01:00
observations.mdx feat: observation_scopes field to drive observations granularity (#447) 2026-02-28 10:46:21 +01:00
performance.md doc: changelog for 0.4.12 (#397) 2026-02-18 14:55:19 +01:00
rag-vs-hindsight.md doc: mental models (#199) 2026-01-26 14:27:08 +01:00
reflect.mdx feat: increase customization for reflect, retain and consolidation (#419) 2026-02-23 20:35:32 +01:00
retain.md docs: entities vs tags vs metadata (#466) 2026-03-02 14:47:40 +01:00
retrieval.md chore: internal renames (#204) 2026-01-27 09:53:28 +01:00
services.md doc: mental models (#199) 2026-01-26 14:27:08 +01:00
storage.md bump pg0 0.11.x and improve documentation (#33) 2025-12-16 13:33:01 +01:00