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.tomlcan't be parsed safely,initprints the exact[mcp]snippet to paste instead of touching the file.hindsight-openhands init --print-onlyshows the snippet + rule anytime.
Running the OpenHands Docker app?
The containerized OpenHands app loads MCP servers from its UI settings, not
from a project config.toml. So add the server in Settings → MCP as a
Streamable HTTP server (not SSE — Hindsight's endpoint is streamable HTTP):
- URL:
http://host.docker.internal:8888/mcp/<bank>/(usehost.docker.internal, notlocalhost, so the container can reach a Hindsight server on your host; launch the app with--add-host host.docker.internal:host-gateway) - API key: your
hsk_...for Cloud, or none for an open local server
The MCP tools load when a conversation starts. The AGENTS.md rule still applies
when you open the project as a repository.
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
Metadata
Release files for hindsight-openhands 0.1.1
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| hindsight_openhands-0.1.1.tar.gz | 21.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| hindsight_openhands-0.1.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 31.7 kB
Release files / hindsight_openhands-0.1.1.tar.gz
| Download URL | hindsight_openhands-0.1.1.tar.gz |
|---|---|
| Size | 21.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
682436c6f985f82849b6d40cd16985b08ea375155b99410831657d385e48dfc3
|
|
BLAKE2b-256 checksum How to use checksums |
7a8af23cddd019c2ac3bcd78c249785ae45e4bc6bdecd13b5bd3e35702d3bb36
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jun 30, 2026.
Transparency logRelease files / hindsight_openhands-0.1.1-py3-none-any.whl
| Download URL | hindsight_openhands-0.1.1-py3-none-any.whl |
|---|---|
| Size | 10.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
3185e2a31f18145810933934afe809cb9f9d844bf40ebd2a69b5024d1fdf3e26
|
|
BLAKE2b-256 checksum How to use checksums |
c0fbcaf262c6473d6096402f7176682edf5e5c15370ec79df4e8803591689a4a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/6.1.0 CPython/3.13.12
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Jun 30, 2026.
Transparency log