hindsight-aider
Persistent long-term memory for Aider, powered by Hindsight.
hindsight-aider is a drop-in wrapper for the aider command. It recalls
relevant project memory before each session (injected into Aider's context via
a read-only file) and retains the session transcript afterwards — so every
Aider session starts with what you've learned before and saves what it learns
for next time. Memory is scoped per git repo.
How it works
Aider has no MCP client or per-prompt hook, but it does load read-only context files and writes a chat-history file. The wrapper uses both:
- Recall (before): queries Hindsight, writes the results to
.aider.hindsight-memory.md, and launchesaider --read .aider.hindsight-memory.md …so the memory is in context. If you runaider -m "fix the auth bug", that message is used as the recall query; otherwise a general project-context query. - Retain (after): when Aider exits, the wrapper reads the slice of the chat-history file written during the session and retains it to the repo's bank.
Recall is once per session (Aider can't be hooked mid-conversation), which fits its session-oriented workflow.
Install
pip install hindsight-aider # also needs aider installed: pip install aider-chat
export HINDSIGHT_API_TOKEN=hsk_... # omit for an open self-hosted server
Usage
Use it exactly like aider — all arguments pass straight through:
hindsight-aider # interactive, project memory loaded
hindsight-aider -m "add retry logic" # one-shot; recall uses the message
hindsight-aider src/app.py tests/ # any aider args
Use Hindsight Cloud or a self-hosted server
with HINDSIGHT_API_URL=http://localhost:8888.
Configuration
Settings come from ~/.hindsight/aider.json or environment variables:
| 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_AIDER_BANK_ID |
(git repo name) |
| Auto-recall | HINDSIGHT_AIDER_AUTO_RECALL |
true |
| Auto-retain | HINDSIGHT_AIDER_AUTO_RETAIN |
true |
| Aider command | HINDSIGHT_AIDER_COMMAND |
aider |
The bank defaults to the git repo name so a project's memory is shared with the other Hindsight editor integrations on the same repo.
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 live retain/recall
License
MIT
Metadata
Release files for hindsight-aider 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_aider-0.1.1.tar.gz | 93.1 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| hindsight_aider-0.1.1-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 104.0 kB
Release files / hindsight_aider-0.1.1.tar.gz
| Download URL | hindsight_aider-0.1.1.tar.gz |
|---|---|
| Size | 93.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
3ac58ed2d5be2c8e54f7309cdfbe5372a13cd625e6c1db9f3a080bfe953ccbb1
|
|
BLAKE2b-256 checksum How to use checksums |
db415a420509585552f21c9797428e3c5756b692469ad659104dd75d505523aa
|
| 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_aider-0.1.1-py3-none-any.whl
| Download URL | hindsight_aider-0.1.1-py3-none-any.whl |
|---|---|
| Size | 10.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
97e0b8d22c80988263da6c54108142533a087497d9d82d24350ea4cac358f69d
|
|
BLAKE2b-256 checksum How to use checksums |
b98fd4199b152392bbe92807caf988858b0d32c96dc11150bc15f2eba0fc9292
|
| 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