Skip to main content

OpenHands integration for Hindsight - persistent long-term memory via MCP

Project description

hindsight-openhands

Long-term memory for OpenHands (formerly OpenDevin), powered by Hindsight.

hindsight-openhands init wires the Hindsight MCP server into OpenHands' config.toml and adds a recall/retain rule to your project's AGENTS.md. The agent then has recall / retain / reflect tools and — guided by the rule — recalls relevant memory at the start of a task and retains durable facts as it works.

How it works

OpenHands has native Streamable-HTTP MCP support, so the Hindsight MCP endpoint connects directly (no bridge):

[mcp]
shttp_servers = [
    {url = "https://api.hindsight.vectorize.io/mcp/my-project/", api_key = "hsk_..."}
]

OpenHands also loads AGENTS.md (and repo microagents) into the agent's context on every task — that's where the recall/retain rule lives.

Install

pip install hindsight-openhands
cd your-project
hindsight-openhands init --api-token YOUR_HINDSIGHT_API_KEY --bank-id my-project

init merges the [mcp] entry into ./config.toml and writes the rule into ./AGENTS.md. Use Hindsight Cloud, or a self-hosted server with --api-url http://localhost:8888 (no token needed for an open local server).

If config.toml can't be parsed safely, init prints the exact [mcp] snippet to paste instead of touching the file. hindsight-openhands init --print-only shows the snippet + rule anytime.

Commands

Command Description
hindsight-openhands init Add the MCP server + recall/retain rule
hindsight-openhands status Show whether the server + rule are configured
hindsight-openhands uninstall Remove the server + rule

Configuration

Setting Env var Default
API URL HINDSIGHT_API_URL https://api.hindsight.vectorize.io
API token HINDSIGHT_API_TOKEN (none; required for Cloud)
Bank id HINDSIGHT_OPENHANDS_BANK_ID openhands

Development

uv sync
uv run pytest tests -v -m 'not requires_real_llm'   # deterministic suite
uv run pytest tests -v -m requires_real_llm          # gated MCP-endpoint check

License

MIT

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

hindsight_openhands-0.1.0.tar.gz (20.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

hindsight_openhands-0.1.0-py3-none-any.whl (10.0 kB view details)

Uploaded Python 3

File details

Details for the file hindsight_openhands-0.1.0.tar.gz.

File metadata

  • Download URL: hindsight_openhands-0.1.0.tar.gz
  • Upload date:
  • Size: 20.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for hindsight_openhands-0.1.0.tar.gz
Algorithm Hash digest
SHA256 ea6411b4f10938aa97b93e8705a1423d8ded71b4c1f82b325f1ab455d7f7ee4f
MD5 e45f7a5ee7a0eb8c0d3970f6d93aa13a
BLAKE2b-256 d79a5893b8fdbfc861585edd1eefccad00f1845483512152e7d299c5247a9851

See more details on using hashes here.

Provenance

The following attestation bundles were made for hindsight_openhands-0.1.0.tar.gz:

Publisher: release-integration.yml on vectorize-io/hindsight

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file hindsight_openhands-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for hindsight_openhands-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 6fdb715c87d166e89a7ad6df7359ff25450a40adff8d5c8c0a4b5c81e97acf2f
MD5 39dd120a9087fbc12b0b915bf83a8e8a
BLAKE2b-256 1770e1542bb718229e96cdd7ce7c0b22357357789c9b138d80e9c84dfa385340

See more details on using hashes here.

Provenance

The following attestation bundles were made for hindsight_openhands-0.1.0-py3-none-any.whl:

Publisher: release-integration.yml on vectorize-io/hindsight

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page