session_id string | memories list | queries list |
|---|---|---|
synth_001 | [
{
"memory_id": "m001",
"timestamp": "2024-01-01T09:00:00",
"text": "Alice lives in Berlin."
},
{
"memory_id": "m002",
"timestamp": "2024-01-02T10:00:00",
"text": "Alice adopted a golden retriever named Max."
},
{
"memory_id": "m003",
"timestamp": "2024-01-03T14:00:00",
"t... | [
{
"query_id": "q001",
"query_text": "Where does Alice live?",
"expected_answer": "Paris",
"query_type": "retrieval",
"required_memory_ids": [
"m003"
]
},
{
"query_id": "q002",
"query_text": "What pet did Alice get before moving?",
"expected_answer": "golden retriever na... |
synth_002 | [
{
"memory_id": "m004",
"timestamp": "2024-02-10T08:00:00",
"text": "Bob works as a barista at Coffee Corner."
},
{
"memory_id": "m005",
"timestamp": "2024-02-11T09:00:00",
"text": "Bob was promoted to shift supervisor."
},
{
"memory_id": "m006",
"timestamp": "2024-02-12T10:00... | [
{
"query_id": "q004",
"query_text": "Where does Bob work now?",
"expected_answer": "Tea House",
"query_type": "retrieval",
"required_memory_ids": [
"m006"
]
},
{
"query_id": "q005",
"query_text": "What was Bob's first job?",
"expected_answer": "barista at Coffee Corner"... |
synth_003 | [
{
"memory_id": "m007",
"timestamp": "2024-03-01T07:00:00",
"text": "The server IP is 198.51.100.10."
},
{
"memory_id": "m008",
"timestamp": "2024-03-01T12:00:00",
"text": "The server IP was updated to 198.51.100.11."
},
{
"memory_id": "m009",
"timestamp": "2024-03-01T18:00:00... | [
{
"query_id": "q007",
"query_text": "What is the current server IP?",
"expected_answer": "198.51.100.12",
"query_type": "contradiction",
"required_memory_ids": [
"m007",
"m008",
"m009"
],
"latest_memory_id": "m009"
},
{
"query_id": "q008",
"query_text": "Wha... |
synth_004 | [
{
"memory_id": "m010",
"timestamp": "2024-04-05T10:00:00",
"text": "Project Falcon deadline is May 1."
},
{
"memory_id": "m011",
"timestamp": "2024-04-10T11:00:00",
"text": "Project Falcon deadline pushed to May 15."
},
{
"memory_id": "m012",
"timestamp": "2024-04-20T12:00:00... | [
{
"query_id": "q010",
"query_text": "When is the Project Falcon deadline?",
"expected_answer": "June 1",
"query_type": "contradiction",
"required_memory_ids": [
"m010",
"m011",
"m012"
],
"latest_memory_id": "m012"
},
{
"query_id": "q011",
"query_text": "What... |
synth_005 | [
{
"memory_id": "m013",
"timestamp": "2024-05-01T08:00:00",
"text": "Carol's phone number is 555-0101."
},
{
"memory_id": "m014",
"timestamp": "2024-05-02T09:00:00",
"text": "Carol changed her number to 555-0202."
},
{
"memory_id": "m015",
"timestamp": "2024-05-03T10:00:00",
... | [
{
"query_id": "q013",
"query_text": "What is Carol's current phone number?",
"expected_answer": "555-0101",
"query_type": "contradiction",
"required_memory_ids": [
"m013",
"m014",
"m015",
"m016"
],
"latest_memory_id": "m016"
},
{
"query_id": "q014",
"q... |
synth_006 | [
{
"memory_id": "m017",
"timestamp": "2024-06-15T06:00:00",
"text": "Diana is allergic to peanuts."
},
{
"memory_id": "m018",
"timestamp": "2024-06-16T07:00:00",
"text": "Diana tried a peanut butter cookie and had a mild reaction."
},
{
"memory_id": "m019",
"timestamp": "2024-... | [
{
"query_id": "q016",
"query_text": "What is Diana allergic to?",
"expected_answer": "peanuts",
"query_type": "retrieval",
"required_memory_ids": [
"m017"
]
},
{
"query_id": "q017",
"query_text": "What medical device was Diana prescribed?",
"expected_answer": "epinephri... |
synth_007 | [
{
"memory_id": "m020",
"timestamp": "2024-07-01T09:00:00",
"text": "Eve's credit score was 720."
},
{
"memory_id": "m021",
"timestamp": "2024-07-15T10:00:00",
"text": "Eve's credit score dropped to 680 after a missed payment."
},
{
"memory_id": "m022",
"timestamp": "2024-08-0... | [
{
"query_id": "q019",
"query_text": "What is Eve's current credit score?",
"expected_answer": "750",
"query_type": "contradiction",
"required_memory_ids": [
"m020",
"m021",
"m022"
],
"latest_memory_id": "m022"
},
{
"query_id": "q020",
"query_text": "What cau... |
synth_008 | [
{
"memory_id": "m023",
"timestamp": "2024-08-10T12:00:00",
"text": "Frank booked a flight to Tokyo on September 10."
},
{
"memory_id": "m024",
"timestamp": "2024-08-12T13:00:00",
"text": "Frank rescheduled the flight to September 12."
},
{
"memory_id": "m025",
"timestamp": "2... | [
{
"query_id": "q022",
"query_text": "Does Frank have an upcoming flight to Tokyo?",
"expected_answer": "no",
"query_type": "contradiction",
"required_memory_ids": [
"m023",
"m024",
"m025"
],
"latest_memory_id": "m025"
},
{
"query_id": "q023",
"query_text": "... |
synth_009 | [
{
"memory_id": "m026",
"timestamp": "2024-09-01T08:00:00",
"text": "Grace's favorite color is blue."
},
{
"memory_id": "m027",
"timestamp": "2024-09-05T09:00:00",
"text": "Grace said green is her favorite color."
},
{
"memory_id": "m028",
"timestamp": "2024-09-10T10:00:00",
... | [
{
"query_id": "q025",
"query_text": "What is Grace's favorite color now?",
"expected_answer": "purple",
"query_type": "contradiction",
"required_memory_ids": [
"m026",
"m027",
"m028"
],
"latest_memory_id": "m028"
},
{
"query_id": "q026",
"query_text": "What ... |
synth_010 | [
{
"memory_id": "m029",
"timestamp": "2024-10-01T07:00:00",
"text": "Henry started learning Spanish."
},
{
"memory_id": "m030",
"timestamp": "2024-10-15T08:00:00",
"text": "Henry switched to learning French."
},
{
"memory_id": "m031",
"timestamp": "2024-10-30T09:00:00",
"t... | [
{
"query_id": "q028",
"query_text": "Which languages is Henry learning now?",
"expected_answer": "Spanish and French",
"query_type": "contradiction",
"required_memory_ids": [
"m029",
"m030",
"m031"
],
"latest_memory_id": "m031"
},
{
"query_id": "q029",
"quer... |
YAML Metadata Warning:empty or missing yaml metadata in repo card
Check out the documentation for more information.
BrainCore Memory Benchmark (MVP)
A lightweight, extensible harness for evaluating long-term memory systems in LLM-based agents.
Status: MVP — not a SOTA leaderboard. Intended for rapid iteration and community extension.
Goals
- Retrieval accuracy — Can the memory system recall the right fact when queried?
- Temporal consistency — Does it respect the order and timing of events?
- Contradiction handling — Can it resolve or flag updated / retracted facts?
- Cost & latency — How expensive (time + storage) is the memory layer?
Non-Goals
- We do not claim these tasks are exhaustive.
- We do not provide a SOTA ranking.
- We do not cover multi-modal or external-tool memory yet.
Repo Structure
braincore-memory-benchmark/
├── README.md
├── requirements.txt
├── data/
│ └── synthetic_benchmark.jsonl # 100 public-safe synthetic examples
├── src/
│ ├── metrics.py # Scoring primitives
│ ├── baseline_adapter.py # Keyword-based baseline
│ └── evaluator.py # Main harness
├── results/
│ └── results_template.md # Copy this to report your run
Quick Start
pip install -r requirements.txt
python src/evaluator.py --adapter src.baseline_adapter --dataset data/synthetic_benchmark.jsonl --output results/my_run.json
Extending the Harness
We designed the JSONL schema and adapter interface so future datasets (LongMemEval, LoCoMo, MemoryAgentBench, AMA-Bench) can be dropped in with minimal changes.
Adapter Interface
Your adapter must expose:
class MemoryAdapter:
def ingest(self, raw_memories: list[dict]) -> None:
"""Store a batch of memory items."""
...
def retrieve(self, query: str, top_k: int = 1) -> list[dict]:
"""Return ranked memory items for a query."""
...
def storage_bytes(self) -> int:
"""Report current on-disk / in-memory footprint."""
...
The evaluator calls ingest once per session, then retrieve per test case.
Dataset Schema (synthetic_benchmark.jsonl)
Each line is a JSON object with:
| Field | Type | Description |
|---|---|---|
session_id |
str | Group of memories belonging to one synthetic agent session |
memories |
list[dict] | Chronological facts / events |
queries |
list[dict] | Questions asked after all memories are ingested |
Query dict:
| Field | Type | Description |
|---|---|---|
query_id |
str | Unique ID |
query_text |
str | Natural-language question |
expected_answer |
str | Ground-truth answer |
query_type |
str | retrieval | temporal | contradiction |
required_memory_ids |
list[str] | Which memory item(s) must be used |
Metrics
| Metric | Description |
|---|---|
exact_match |
Case-insensitive, stripped string equality |
semantic_placeholder_score |
Cosine similarity of sentence embeddings (fallback) |
temporal_order_score |
Fraction of temporal queries where returned memories are in correct time order |
contradiction_resolution_score |
Fraction of contradiction queries where the latest (revised) fact is returned |
latency_ms |
Mean wall-clock time for retrieve() |
storage_bytes |
Bytes reported by adapter.storage_bytes() |
License
Synthetic data and code are released under the MIT license.
Part of BrainCore Collective
This asset is part of BrainCore Collective, a public Hugging Face collection of datasets, starter kits, and Spaces for practical agent memory, AI operations, and media automation workflows.
- Agent Memory Research Corpus — Canonical corpus for agent-memory papers, systems, benchmarks, and implementation patterns.
- Memory Explorer Space — Interactive browser for the agent-memory research corpus.
- BrainCore Memory Benchmark — Synthetic benchmark for retrieval, temporal consistency, contradiction handling, latency, and storage cost.
- BrainCore pgvector Starter — Postgres/pgvector memory starter with a runnable Gradio landing page and FastAPI code.
- LoRA Caption Quality Checker — CPU-only Gradio utility for checking LoRA caption dataset quality before training.
- Downloads last month
- 32