Skip to main content

What's new in Hindsight 0.4.22

· 3 min read
Nicolò Boschi
Hindsight Team

Hindsight 0.4.22 is primarily a bugfix release, with fixes across providers, integrations, and the recall pipeline. It also adds mental model trigger tag filtering and exposes document metadata through the API and Control Plane.

  • Mental Model Tag Filtering: Control how memories are filtered during mental model refresh with tags_match and tag_groups.
  • Document Metadata API: Retained document metadata is now exposed in list/get endpoints and the Control Plane UI.

Mental Model Tag Filtering

When refreshing a mental model with tags, Hindsight previously hardcoded all_strict tag matching, which silently excluded all untagged memories from the refresh. Mental model triggers now support tags_match and tag_groups fields, giving you explicit control over how memories are filtered during refresh.

For example, you can use any matching to include untagged memories alongside tagged ones, or define tag groups for complex filtering logic. The Control Plane UI adds corresponding dropdowns and inputs for these new fields.

Existing mental models without these fields keep the previous all_strict behavior — no migration required.

Document Metadata API

The retain endpoint has always accepted a metadata dict, but that data was never surfaced back through the API. This release properly exposes document_metadata in both the list and get document endpoints, and displays it in the Control Plane documents table and detail panel.

This is useful for any workflow that tags documents at ingest time — for example, by source system, user, or session ID.

Other Updates

Improvements

  • Custom LLM parameters via HINDSIGHT_API_LLM_EXTRA_BODY — pass arbitrary JSON to extra_body on every OpenAI-compatible API call, useful for vLLM and custom model servers. (Contributed by @emirhan-gazi.)
  • Codex integration now retains structured tool calls (function_call, local_shell_call, web_search_call, etc.) as JSON content blocks, enabled by default.
  • API responses now include an X-Ignored-Params header to warn when unknown request parameters were silently ignored.
  • LiteLLM embeddings support optional output dimensions via HINDSIGHT_API_EMBEDDINGS_LITELLM_SDK_OUTPUT_DIMENSIONS. (Contributed by @bullbo.)
  • ZeroEntropy reranker now supports a configurable base URL for self-hosted deployments. (Contributed by @iskhakovt.)
  • Experience fact classification now correctly categorizes first-person agent actions (code changes, debugging, discoveries) as experience facts instead of world facts, improving recall precision for coding agents and agentic workflows.
  • LLM provider initialization refactored to use centralized from_env() pattern with proper config constants.
  • 13 previously undocumented config fields are now documented (Gemini safety settings, retain batch tokens, webhook settings, audit log settings, and more).

Bug Fixes

  • Cohere reranker on Azure AI Foundry endpoints no longer hits 404 errors from double-path URLs — uses httpx directly when a custom base_url is configured. (Contributed by @kagura-agent.)
  • Claude Code LLM provider no longer suffers from MCP tool deferral when too many built-in tools are loaded — built-in tools are now disabled so MCP tools load eagerly. (Contributed by @mkremnev.)
  • Recall endpoint no longer drops metadata from response.
  • Codex integration merges new settings on upgrade instead of overwriting existing configuration.
  • LlamaIndex integration fixes for document_id handling, memory API, and ReAct trace formatting.
  • OpenClaw defers heavy initialization to service.start() to avoid CLI slowdown.
  • Gemini thought_signature is now read from the correct object for 3.1+ tool calls.

Feedback and Community

Hindsight 0.4.22 is a drop-in replacement for 0.4.x with no breaking changes.

Share your feedback:

For detailed changes, see the full changelog.