fix docker cp image build on ci - #10
Merged
Merged
Conversation
DK09876
added a commit
that referenced
this pull request
Mar 19, 2026
- Fix #2: Add per-bank asyncio.Lock to _ensure_bank for concurrency safety - Fix #3: Clamp search score to max(0.0, ...) to prevent negative values - Fix #4: Implement suffix matching in _handle_list_namespaces - Fix #5: Truncate namespaces to max_depth instead of filtering (per BaseStore contract) - Fix #6: Remove list_namespaces/alist_namespaces overrides — let base class handle prefix=/suffix= kwargs - Fix #7: Document ephemeral namespace tracking and get() limitations in class docstring - Fix #8: Add stable ID to recall node SystemMessage, document ordering behavior - Fix #9: Change budget/max_tokens/recall_tags_match defaults to None so global config fallback works - Fix #10: Conditionally populate __all__ so import * works without langgraph installed - Fix #11: Bump langgraph lower bound from >=0.3.0 to >=0.5.0 - Fix #12: Extract _resolve_client to shared _client.py module Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
nicoloboschi
pushed a commit
that referenced
this pull request
Mar 20, 2026
* feat: add LangGraph integration with tools, nodes, and store patterns Add hindsight-langgraph SDK providing three integration patterns: - Tools: retain/recall/reflect as LangChain tools for ReAct agents - Nodes: automatic memory injection and storage as graph steps - Store: LangGraph BaseStore implementation for checkpoint-based memory Fix: remove `from __future__ import annotations` in nodes.py which prevented LangGraph from passing RunnableConfig to node functions (runtime type inspection saw string annotations instead of actual types). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * chore: register langgraph with independent versioning system - Set version to 0.1.0 (integrations are versioned independently) - Add langgraph to VALID_INTEGRATIONS in release-integration.sh - Add changelog page for langgraph integration Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * chore: remove manual cookbook recipe page The sync-cookbook script will auto-generate this from the notebook in hindsight-cookbook once PR #17 is merged. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * fix: comprehensive improvements to langgraph integration Code fixes: - Retain node only stores latest messages instead of all history (prevents duplicates) - Handle multimodal msg.content (list type) in nodes - Fix store docstring separator "/" → "." - Apply search filters before pagination in store - Add ttl parameter to store.aput for LangGraph BaseStore compat - Fix _ensure_bank to not cache failed bank creations - Fix falsy value bugs (or → is not None) in tools - Remove from __future__ import annotations from all files - Consistent default budget="mid" across tools/nodes/store - Bump langgraph floor to >=0.3.0, remove duplicate dev deps Docs fixes: - Fix broken Cloud client example (base_url is required) - Complete API reference tables with all parameters - Add Limitations and Notes section (async-only store, etc.) - Add Requirements section - Fix broken cookbook link and Cloud claim in blog post All 61 unit tests pass. E2E tested against Hindsight Cloud: tools, nodes, store, configure(), multimodal content. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * chore: remove blog post (lives in hindsight-marketing-content) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * chore: remove Hindsight Cloud section from langgraph docs Keep OSS docs self-hosted-first, consistent with other integration docs (crewai, pydantic-ai, agno). Cloud setup details live in the cookbook notebooks. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * docs: explicitly mention LangChain compatibility in langgraph integration The tools pattern (create_hindsight_tools) only depends on langchain-core and works with plain LangChain via bind_tools() — no LangGraph required. Update docs to make this clear with both LangGraph and LangChain quick start examples. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * fix: address PR review findings 1. Guard manual test files with if __name__ == "__main__" so pytest doesn't collect and execute them during test runs 2. Remove semantic fallback in HindsightStore.aget() — only return exact document_id matches, not unrelated semantic search hits 3. Make langgraph an optional dependency — tools pattern only needs langchain-core. Install with pip install hindsight-langgraph[langgraph] for nodes and store patterns. Lazy imports with clear error messages. 4. Clean up README to be self-hosted-first, consistent with other integration docs 5. Update docs requirements section to reflect optional langgraph dep Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * fix: address PR review feedback for langgraph integration - Fix #2: Add per-bank asyncio.Lock to _ensure_bank for concurrency safety - Fix #3: Clamp search score to max(0.0, ...) to prevent negative values - Fix #4: Implement suffix matching in _handle_list_namespaces - Fix #5: Truncate namespaces to max_depth instead of filtering (per BaseStore contract) - Fix #6: Remove list_namespaces/alist_namespaces overrides — let base class handle prefix=/suffix= kwargs - Fix #7: Document ephemeral namespace tracking and get() limitations in class docstring - Fix #8: Add stable ID to recall node SystemMessage, document ordering behavior - Fix #9: Change budget/max_tokens/recall_tags_match defaults to None so global config fallback works - Fix #10: Conditionally populate __all__ so import * works without langgraph installed - Fix #11: Bump langgraph lower bound from >=0.3.0 to >=0.5.0 - Fix #12: Extract _resolve_client to shared _client.py module Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * fix: address remaining review gaps for langgraph integration - Add output_key parameter to create_recall_node for prompt ordering control - Add prefix/suffix/combined filter tests for list_namespaces - Add output_key unit tests (memory text, none on empty, none on error) - Remove unused imports and backward-compat alias in tools.py - Update docs with output_key usage example and API reference Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * fix: relax langgraph version constraint to >=0.3.0 Research confirmed all required APIs (BaseStore, SearchItem, Result, GetOp, PutOp, SearchOp, ListNamespacesOp) are available since langgraph-checkpoint 2.0.7, which maps to langgraph >=0.2.63. Using >=0.3.0 as a clean semver boundary — >=0.5.0 was unnecessarily conservative and excluded many compatible versions. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> --------- Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
nicoloboschi
added a commit
that referenced
this pull request
May 26, 2026
The previous derivation kept only the first 10 units per entity before pairing, so any unit beyond #10 for a hot entity had zero entity edges in /graph — even though it shared the entity with many visible units. Switch to a sliding window: each unit links to its next N neighbors in the per-entity list. Every unit that shares an entity with another visible unit gets edges (its successors directly, predecessors via their pairs), and total edges stay bounded at ~N * cap per entity instead of N². Adds a regression test that retains 15 facts mentioning the same person and asserts every retained unit appears in at least one entity edge in /graph.
nicoloboschi
added a commit
that referenced
this pull request
May 26, 2026
The previous derivation kept only the first 10 units per entity before pairing, so any unit beyond #10 for a hot entity had zero entity edges in /graph — even though it shared the entity with many visible units. Switch to a sliding window: each unit links to its next N neighbors in the per-entity list. Every unit that shares an entity with another visible unit gets edges (its successors directly, predecessors via their pairs), and total edges stay bounded at ~N * cap per entity instead of N². Adds a regression test that retains 15 facts mentioning the same person and asserts every retained unit appears in at least one entity edge in /graph.
nicoloboschi
added a commit
that referenced
this pull request
May 26, 2026
…izing them (#1766) * chore: regenerate docs skill (sync Tigris S3 config notes) Drift picked up by the generate-docs-skill pre-commit hook — keeps skills/hindsight-docs/ in sync with the upstream hindsight-docs/ sources. * perf(api): derive entity edges from unit_entities instead of materializing them Stop writing link_type='entity' rows to memory_links and derive entity edges on demand in the /graph endpoint (from the unit_entities self-join recall already uses) and in /stats (by replicating the historical writer cap). Why: on the recall-perf-medium bench bank (10k units), entity rows were 53% of all memory_links — 345k rows, ~190 MB of table+index — and recall never read them (entity expansion in link_expansion_retrieval.py uses unit_entities, not memory_links). Retain was running a synchronous pairwise loop per shared entity to write rows nothing read; per-unit entity degree was uncapped (max 326 outgoing on a single unit), and overall per-unit total degree averaged 130 with a p99 of 462. Changes: - Drop Phase 3 entity-link build/insert from retain orchestrator. Keep entity_resolver.flush_pending_stats() so entity_cooccurrences (which feeds /entities/graph) still updates. - Delete build_entity_links_from_resolved, insert_entity_links_batch, MAX_LINKS_PER_ENTITY, EntityLink, Phase3Context, and the now-dead fetch_entity_unit_fanout op (PG + Oracle). - /graph: filter memory_links query to link_type <> 'entity'; broaden the existing observation-inferred entity-pair loop to cover all visible units; cap at 10 units per entity to bound hot entities. - /stats: split link_breakdown into a memory_links query (non-entity) and a unit_entities-based derivation for entity, sized to the historical writer cap so link_counts.entity stays in the same magnitude. - Migration e9b2c7d1f3a4: drop idx_memory_links_entity_covering and chunk-delete existing entity rows (PG + Oracle paths). - Tests: rewrite test_entity_links_creation and test_all_link_types_together to assert via /graph + /stats; assert no entity rows in memory_links. API response shapes (graph edges, stats link_counts/links_breakdown) are unchanged at the boundary, so SDKs and the control plane do not need to be regenerated. * fix(graph): cap entity edges per unit, not per entity list The previous derivation kept only the first 10 units per entity before pairing, so any unit beyond #10 for a hot entity had zero entity edges in /graph — even though it shared the entity with many visible units. Switch to a sliding window: each unit links to its next N neighbors in the per-entity list. Every unit that shares an entity with another visible unit gets edges (its successors directly, predecessors via their pairs), and total edges stay bounded at ~N * cap per entity instead of N². Adds a regression test that retains 15 facts mentioning the same person and asserts every retained unit appears in at least one entity edge in /graph. * fix(migration): re-parent entity-link drop after e1b2c3d4f5a6 landed on main #1762 landed e1b2c3d4f5a6_drop_unused_indexes between this PR opening and CI run, which also drops idx_memory_links_entity_covering. Our migration's down_revision still pointed at the prior head, leaving Alembic with two heads and tripping test_alembic_dag.test_single_head. Re-parent to e1b2c3d4f5a6 to unify the head. The DROP INDEX IF EXISTS line becomes a defensive no-op (since #1762 already dropped it), but is retained in case this migration runs against a snapshot taken before #1762.
cdbartholomew
added a commit
that referenced
this pull request
Jun 9, 2026
…ever (#2092) * blog: Hindsight is the fastest-growing open-source AI memory project ever Equal-age GitHub star analysis (per-star timestamps) plus third-party validation from OSSCAR (#10 fastest-growing OSS org, ahead of Mem0) and dope.security (#1 MCP server in enterprise traffic). Adds cdbartholomew to blog authors. * blog: add truncate marker, featured image, fix Slack invite link - Add <!-- truncate --> after the lead (fixes the build warning addressed repo-wide in #2065) - Add featured/social image and hero image - Replace workspace login URL with the canonical join.slack.com invite * blog: clean up featured image (remove curve overlapping the headline) * blog: add captured star-history chart (Hindsight steepest slope); align featured image to brand palette - Embed a static capture of the overlaid star-history graph in the 'still accelerating' section; Hindsight shows the steepest slope of any project. Replaces the unreliable live-URL embed (rate-limited). - Recolor the featured/OG card to the Hindsight brand palette (#0074d9 -> #009296 gradient, #09090b background) instead of off-palette mint. * blog: add star-history chart to featured image (text left, chart right)
nepenth
pushed a commit
to nepenth/hindsight
that referenced
this pull request
Aug 7, 2026
- Fix vectorize-io#2: Add per-bank asyncio.Lock to _ensure_bank for concurrency safety - Fix vectorize-io#3: Clamp search score to max(0.0, ...) to prevent negative values - Fix vectorize-io#4: Implement suffix matching in _handle_list_namespaces - Fix vectorize-io#5: Truncate namespaces to max_depth instead of filtering (per BaseStore contract) - Fix vectorize-io#6: Remove list_namespaces/alist_namespaces overrides — let base class handle prefix=/suffix= kwargs - Fix #7: Document ephemeral namespace tracking and get() limitations in class docstring - Fix vectorize-io#8: Add stable ID to recall node SystemMessage, document ordering behavior - Fix vectorize-io#9: Change budget/max_tokens/recall_tags_match defaults to None so global config fallback works - Fix vectorize-io#10: Conditionally populate __all__ so import * works without langgraph installed - Fix vectorize-io#11: Bump langgraph lower bound from >=0.3.0 to >=0.5.0 - Fix vectorize-io#12: Extract _resolve_client to shared _client.py module Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
nepenth
pushed a commit
to nepenth/hindsight
that referenced
this pull request
Aug 7, 2026
- Fix vectorize-io#2: Add per-bank asyncio.Lock to _ensure_bank for concurrency safety - Fix vectorize-io#3: Clamp search score to max(0.0, ...) to prevent negative values - Fix vectorize-io#4: Implement suffix matching in _handle_list_namespaces - Fix vectorize-io#5: Truncate namespaces to max_depth instead of filtering (per BaseStore contract) - Fix vectorize-io#6: Remove list_namespaces/alist_namespaces overrides — let base class handle prefix=/suffix= kwargs - Fix #7: Document ephemeral namespace tracking and get() limitations in class docstring - Fix vectorize-io#8: Add stable ID to recall node SystemMessage, document ordering behavior - Fix vectorize-io#9: Change budget/max_tokens/recall_tags_match defaults to None so global config fallback works - Fix vectorize-io#10: Conditionally populate __all__ so import * works without langgraph installed - Fix vectorize-io#11: Bump langgraph lower bound from >=0.3.0 to >=0.5.0 - Fix vectorize-io#12: Extract _resolve_client to shared _client.py module Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
No description provided.