isar_agent_memory 0.4.0 copy "isar_agent_memory: ^0.4.0" to clipboard
isar_agent_memory: ^0.4.0 copied to clipboard

Universal, local-first cognitive memory package for LLMs and AI agents. Graph-based, explainable, LLM-agnostic. Inspired by Cognee/Graphiti.

Changelog #

0.4.0 - 2025-11-25 #

Major Features #

  • HiRAG Phase 2: Complete implementation of advanced hierarchical RAG capabilities.

    • Added LLMAdapter interface for LLM integration.
    • Implemented autoSummarizeLayer() for automatic layer summarization using LLMs.
    • Implemented multiHopSearch() for hierarchical context-aware retrieval.
    • Support for configurable prompt templates and search depth.
  • Cross-Device Sync Backends: Real-time synchronization infrastructure.

    • Added SyncBackend interface with pluggable backend architecture.
    • Implemented FirebaseSyncBackend for Firebase Realtime Database.
    • Implemented WebSocketSyncBackend for custom WebSocket servers.
    • Added CrossDeviceSyncManager for managing sync lifecycle.
    • Factory pattern for automatic backend selection.
    • Stream-based real-time change propagation.
  • Advanced Re-ranking Strategies: Improve search relevance with multiple algorithms.

    • Added ReRankingStrategy interface for extensible re-ranking.
    • Implemented BM25ReRanker for term frequency-based ranking.
    • Implemented MMRReRanker for Maximal Marginal Relevance (diversity + relevance).
    • Implemented DiversityReRanker for maximizing result variety.
    • Implemented RecencyReRanker for time-based relevance.
    • Integrated re-ranking into semanticSearchWithReRanking() and hybridSearchWithReRanking().

Improvements #

  • API Enhancements:

    • Extended MemoryGraph with semanticSearchWithReRanking() method.
    • Extended MemoryGraph with hybridSearchWithReRanking() method.
    • Added createdAt as optional parameter in MemoryNode constructor.
    • Improved query handling in semanticSearch() for layer filtering.
  • Architecture:

    • All new classes properly exported in isar_agent_memory.dart.
    • Clean separation between interfaces and implementations.
    • Factory patterns for extensibility.
  • Testing:

    • Added hirag_phase2_integration_test.dart for LLM-based summarization.
    • Added multi_hop_retrieval_test.dart for hierarchical search.
    • Added reranking_strategies_test.dart for all re-ranking algorithms.
    • Added advanced_retrieval_test.dart for combined features.
    • Added cross_device_sync_firebase_test.dart for Firebase backend.
    • Added cross_device_sync_websocket_test.dart for WebSocket backend.
    • Added sync_conflict_resolution_test.dart for LWW conflict handling.
    • All core tests passing (13/13 ✅).

Dependencies #

  • Added firebase_core and firebase_database for Firebase backend.
  • Added web_socket_channel for WebSocket backend.
  • Updated mockito to ^5.4.4 for improved testing.

Documentation #

  • Updated README.md with comprehensive documentation for all new features.
  • Added usage examples for HiRAG Phase 2, sync backends, and re-ranking.
  • Updated TASKS.md with completed sprint and new priorities.
  • Documented LLMAdapter interface with implementation examples.

Breaking Changes #

None. All changes are backward compatible with v0.3.0.

Notes #

  • WebSocket tests require mock generation via build_runner.
  • Firebase backend requires valid Firebase configuration.
  • LLM adapter implementations require external API keys (e.g., Gemini).
  • All sync operations use AES-256-GCM encryption from v0.3.0.

0.3.0 - 2024-11-24 #

Major Features #

  • Sync Protocol: Implemented secure synchronization with Last-Write-Wins (LWW) conflict resolution using UUIDs.

    • Added SyncManager class for encrypted export/import of memory graphs.
    • Added EncryptionService using AES-256-GCM for client-side encryption.
    • Extended MemoryNode and MemoryEdge with sync fields: uuid, modifiedAt, version, deviceId, isDeleted.
    • Documentation: Added doc/SYNC_PROTOCOL.md describing architecture and reconciliation strategy.
  • HiRAG (Hierarchical RAG): Foundation for hierarchical knowledge management.

    • Added HierarchicalMemoryGraph extension with createSummaryNode and getNodesByLayer methods.
    • Added layer field to MemoryNode for multi-level knowledge organization.
    • Support for summary and part-of relationships between nodes.

Improvements #

  • Model Updates: Regenerated Isar and ObjectBox models to support new sync and HiRAG fields.
  • Testing: Added integration test for sync functionality (isar_agent_memory_tests/test/sync_integration_test.dart).
  • Testing: Added unit tests for EncryptionService and SyncManager.

Dependencies #

  • Added cryptography: ^2.9.0 for encryption support.
  • Added json_annotation: ^4.9.0 for JSON serialization.

Documentation #

  • Updated TASKS.md to mark release 0.2.3 as completed.
  • Added comprehensive sync protocol documentation.

0.2.3 - 2024-11-24 #

  • Fix: Critical bug in OnDeviceEmbeddingsAdapter - corrected outputs.values.first to outputs.first.
  • Fix: Corrected invalid Mermaid diagram syntax in README (ASCII art → valid Mermaid).
  • Fix: Moved http from dev_dependencies to dependencies for tool scripts.
  • Improvement: Replaced forEach with for loops in resource cleanup (better Dart practice).
  • CI/CD: Disabled automatic benchmark workflow trigger (manual only) and added Linux desktop support.
  • Chore: Added test_resources/ and tool/ to .pubignore to reduce package size.

0.2.2 - 2025-08-18 #

  • New Feature: Added OnDeviceEmbeddingsAdapter using onnxruntime for privacy-first, local embedding generation.
  • New Feature: Implemented a basic WordPieceTokenizer for BERT-based models.
  • Improvement: Enhanced MemoryGraph robustness with a fallback mechanism (linear scan) when vector index operations fail (e.g., dimension mismatch).
  • Improvement: Added explicit dimension validation in ObjectBoxVectorIndex to prevent native crashes.
  • Documentation: Translated README.md and TASKS.md to 100% English. Added instructions for On-Device Embeddings.
  • Dependencies: Updated langchain to ^0.8.0, objectbox to ^5.0.0, langchain_google to ^0.7.0, and added onnxruntime ^1.4.1.
  • Refactor: Removed deprecated vector_index_dvdb.dart.

0.2.1 - 2025-08-17 #

  • CI/CD: Added publish-to-pub-dev.yml workflow for automated publishing on release creation or manual dispatch.
  • Credentials: Documented usage of PUB_CREDENTIALS_JSON secret.
  • Maintenance: Minor release preparation and local validation.

0.2.0 - 2025-08-17 #

  • Major Cleanup: Removed DVDB as a vector backend.
    • Deleted dvdb dependency and public export.
    • Retained vector_index_dvdb.dart as a deprecated stub (now removed in 0.2.2).
    • Established ObjectBox as the sole supported on-device ANN (HNSW) backend.
  • Testing:
    • Introduced InMemoryVectorIndex for plugin-free unit testing.
    • Removed isar_flutter_libs from the test subproject.
    • Fixed similarity metric consistency (cosine/L2/dot) in memory index.
  • Documentation:
    • Cleaned up references to DVDB in docs.
    • Clarified ObjectBox default usage.
    • Fixed linting issues.

0.1.2 - 2025-07-10 #

  • Fix: Resolved JavaScript error in Isar generated files by integrating build_runner.

0.1.1 - 2025-07-10 #

  • Documentation: Added comprehensive dartdoc comments to public APIs.
  • Linting: Fixed various linting and formatting issues.
  • Publishing: Corrected pub.flutter-io.cn topics for successful publication.

0.1.0 - 2025-07-09 #

  • Initial release: Isar agent memory graph with ANN search, explainability, robust tests, and modern CI/CD automation (Coderabbit, Renovate, Dependabot, Jules).
4
likes
140
points
318
downloads

Publisher

unverified uploader

Weekly Downloads

Universal, local-first cognitive memory package for LLMs and AI agents. Graph-based, explainable, LLM-agnostic. Inspired by Cognee/Graphiti.

Repository (GitHub)
View/report issues
Contributing

Topics

#agent #graph #isar #llm #memory

Documentation

API reference

License

MIT (license)

Dependencies

collection, cryptography, firebase_core, firebase_database, flat_buffers, google_generative_ai, graphs, http, isar, json_annotation, langchain, langchain_google, meta, objectbox, onnxruntime, uuid, web_socket_channel

More

Packages that depend on isar_agent_memory