{"id":50100212,"url":"https://github.com/hackafterdark/reveriecore","last_synced_at":"2026-05-23T07:08:41.640Z","repository":{"id":354967355,"uuid":"1215417538","full_name":"hackafterdark/reveriecore","owner":"hackafterdark","description":"Reverie Core is an agentic cognition layer for the Hermes ecosystem (memory plugin)","archived":false,"fork":false,"pushed_at":"2026-05-01T07:09:38.000Z","size":833,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-05-01T08:25:32.569Z","etag":null,"topics":["agent-memory-system","agentic-memory","agents","ai","ai-memory","graph-rag","hermes-agent","llm","rag"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/hackafterdark.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":"AGENTS.md","dco":null,"cla":null}},"created_at":"2026-04-19T22:08:10.000Z","updated_at":"2026-05-01T07:09:42.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/hackafterdark/reveriecore","commit_stats":null,"previous_names":["hackafterdark/reveriecore"],"tags_count":null,"template":false,"template_full_name":null,"purl":"pkg:github/hackafterdark/reveriecore","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hackafterdark%2Freveriecore","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hackafterdark%2Freveriecore/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hackafterdark%2Freveriecore/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hackafterdark%2Freveriecore/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/hackafterdark","download_url":"https://codeload.github.com/hackafterdark/reveriecore/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/hackafterdark%2Freveriecore/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33386101,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-23T04:15:53.637Z","status":"ssl_error","status_checked_at":"2026-05-23T04:15:53.242Z","response_time":53,"last_error":"SSL_read: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["agent-memory-system","agentic-memory","agents","ai","ai-memory","graph-rag","hermes-agent","llm","rag"],"created_at":"2026-05-23T07:08:40.913Z","updated_at":"2026-05-23T07:08:41.635Z","avatar_url":"https://github.com/hackafterdark.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# 🌌 Reverie Core\n\n[![License](https://img.shields.io/badge/license-MIT-green.svg)](LICENSE)\n[![Platform](https://img.shields.io/badge/platform-Hermes-purple.svg)](https://github.com/hackafterdark/reveriecore)\n\n**Reverie Core** is an agentic cognition layer designed for the **Hermes agent ecosystem**. Unlike static RAG frameworks that treat memory as a passive document store, Reverie Core manages memory as a **dynamic, self-pruning knowledge graph.** It bridges the gap between raw data and long-term agent intelligence by automating the **Enrichment** (understanding), **Retention** (budgeting), and **Retrieval** (graph-traversal) of your agent's experience.\n\nDesigned from the ground up for local-first performance and full observability, it ensures your agent doesn't just \"retrieve\" data—it \"remembers\" with purpose.\n\n---\n\n## 🔗 Platform Strategy: Hermes Memory Provider\n\n**Reverie Core** functions as a high-performance **memory plugin** for the [Hermes](https://hermes-agent.nousresearch.com/) ecosystem. Unlike standard utility plugins, it plugs directly into the agent’s core cognitive loop, replacing basic memory storage with a stateful, graph-based knowledge engine.\n\n* **Current Status**: Built specifically for the Hermes `memory_provider` interface, leveraging native hooks for pre-fetch context injection and background write-back synchronization.\n* **The Roadmap**: While currently optimized for the Hermes runtime, the core logic is abstracted via `provider.py`. We are actively refining this **Provider Interface** to ensure the cognition engine remains platform-agnostic, with a roadmap to support future integration as an MCP (Model Context Protocol) server for IDE-based agents (like Cursor) and standalone agent runtimes.\n\nIf you are a developer looking to bridge Reverie Core into another agent runtime, `provider.py` serves as the primary abstraction layer, mapping internal graph and memory logic to the host agent's lifecycle events.\n\n---\n\n## ✨ Why Reverie Core?\n\n* **From \"RAG\" to \"Memory\"**: Move beyond simple text retrieval. Our `MesaService` actively maintains your knowledge graph, archiving transient noise and elevating critical insights so your context window stays performant.\n* **Decoupled Intelligence**: A plug-and-play architecture where enrichment and retrieval pipelines are fully composable. See our [**Pipeline Architecture Diagram**](DIAGRAM.md) for a visual breakdown. Swap handlers for classification, profiling, or ranking as your agent's needs evolve.\n* **Local-First, Graph-Powered**: Uses `sqlite-vec` for high-speed similarity search combined with **Bidirectional Graph Traversal** to bridge non-obvious relationships in your data.\n* **Production-Ready Observability**: Built-in **OpenTelemetry** instrumentation (OTLP) provides granular, trace-based insight into how your agent \"thinks\" and where its retrieval precision bottlenecks lie.\n* **Config-Driven Engineering**: Move away from hardcoded magic numbers. Every threshold, weight, and pipeline stage is managed via a validated `reveriecore.yaml`, allowing for precise, reproducible benchmark tuning.\n\n### 🧠 Data Portability \u0026 Resilience\nReverie Core treats your agent's memory as a first-class citizen. Its **Sync Engine** provides:\n- **Bi-Directional Portability**: Export your entire semantic knowledge graph to Hive-partitioned Markdown files (e.g., `year=2026/month=04/day=27/`) with relationship-mapped frontmatter, and import them back into any `ReverieCore` instance with full structural integrity.\n- **Version-Controlled Cognition**: Exported memories are human-readable and Git-friendly. Commit your agent's \"brain\" to your repository to track how its knowledge evolves over time.\n- **Data Lake Ready**: Hive-style directory partitioning allows you to hook your agent’s long-term memory into standard data analytics tools (like DuckDB, Trino, or Apache Spark) without additional ETL.\n\n---\n\n### Key Differentiators\n\n| Feature | Reverie Core | Standard RAG Frameworks |\n| :--- | :--- | :--- |\n| **Primary Goal** | Agent State \u0026 Cognition | Document Retrieval |\n| **Maintenance** | Active (`MesaService`) | Passive (Static Index) |\n| **Graph Logic** | Bi-directional Traversal | Vector-only or Fixed-depth |\n| **Configurability** | Pydantic-Validated YAML | Hardcoded or Code-heavy |\n| **Tracing** | Native OpenTelemetry | Print statements or external wrappers |\n| **Portability** | Hive-Partitioned Markdown | Opaque Binary Blobs |\n| **Platform** | Native Hermes (Extensible) | Tied to specific RAG libraries |\n\n---\n\n### 📊 Benchmark Results \u0026 Interpretation\n\nReverie Core is benchmarked against a grounded question-answering [dataset](https://huggingface.co/datasets/vibrantlabsai/amnesty_qa) using [RAGAS](https://docs.ragas.io/en/stable/) to measure system reliability. We prioritize **Faithfulness** (the agent's ability to ground answers in context) and **Context Precision** (the relevance of retrieved information).\n\n| Metric | Result | Interpretation |\n| :--- | :--- | :--- |\n| **Faithfulness** | **0.925** | **Reliably Grounded.** High factual alignment between retrieval context and agent response, effectively eliminating hallucination. |\n| **Context Precision** | **0.70** | **High-Signal Retrieval.** The pipeline consistently surfaces relevant nodes at the top of the context window for synthesis. |\n\n\u003e **Note on Performance:** These benchmarks represent a \"Real-World Baseline\" achieved with the configuration settings found in `reveriecore.yaml.example`. We intentionally avoid \"benchmark hacking\" with synthetic datasets, preferring to tune for grounding and low-latency performance that holds up in daily usage.\n\n---\n\n## 🛠️ Technology Stack\n\n- **Intelligence**: `transformers` (BART), `sentence-transformers` (all-MiniLM-L6-v2), `flashrank` (MiniLM reranker)\n- **Storage**: `SQLite 3` with `sqlite-vec` extension\n- **Observability**: `OpenTelemetry` (OTLP/gRPC)\n- **Integration**: Python 3.11+, Hermes Plugin Bridge\n\n---\n\n## 🚀 Getting Started\n\n### 1. Installation\nClone this repository into your Hermes plugins directory and install dependencies into the agent's virtual environment:\n\n```bash\ngit clone https://github.com/hackafterdark/reveriecore.git\ncd reveriecore\nVIRTUAL_ENV=~/.hermes/hermes-agent/venv uv pip install -e .\n./run_tests.sh  # Verifies environment and initializes local models\n```\n\n### 1.5. Download Query Rewriter Model (Optional)\nIf you plan to use the **Query Rewriter** (highly recommended for complex queries), you must download the GGUF model manually. From the `reveriecore` root (assuming you have the Hugging Face CLI tool installed):\n\n```bash\nhf download microsoft/Phi-3-mini-4k-instruct-gguf Phi-3-mini-4k-instruct-q4.gguf --local-dir models\n```\n\n### 2. Configuration (`reveriecore.yaml`)\nReverie Core uses a structured, validated configuration system. The engine discovers configuration in this order:\n1.  **Hermes Pointer**: `memory.reveriecore_cfg` in `config.yaml`.\n2.  **Env Var**: `REVERIECORE_CONFIG` path override.\n3.  **Local Default**: `~/.reveriecore.yaml`.\n\nFor a full list of settings, see [**CONFIGURATION.md**](CONFIGURATION.md).\n\n---\n\n## 📖 Documentation \u0026 Architecture\n\nFor deep dives into the mechanics, see the [AGENT_DOCS](AGENT_DOCS) and [ADR](ADR) directories:\n\n- [**Pipeline Architecture Diagram**](DIAGRAM.md)\n- [**Full Configuration Guide**](CONFIGURATION.md)\n- [ADR 006: Pipeline Architecture](ADR/006-reverie-framework-pipeline-architecture.md)\n- [ADR 008: OpenTelemetry Integration](ADR/008-opentelemetry-integration.md)\n- [Knowledge Graph Mechanics](AGENT_DOCS/knowledge_graph_mechanics.md)\n- [Active Maintenance (Mesa)](AGENT_DOCS/how_mesa_works.md)\n\n---\n\n## ⚖️ License\n\nDistributed under the MIT License. See `LICENSE` for more information.","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhackafterdark%2Freveriecore","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhackafterdark%2Freveriecore","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhackafterdark%2Freveriecore/lists"}