Tempera MCP server
✓ VerifiedProvides Claude Code with persistent episodic memory to recall past solutions, learn from experience, and transfer knowledge across coding projects.
Also known as anvanster/tempera, @astudioplus/tempera-mcp
- Stars
- 6
- Tools
- 12
- Downloads, 30 days
- 295
- Latest version
- 0.4.29
- Last commit
- May 29, 2026
- License
- Apache-2.0
What is Tempera MCP?
Tempera provides Claude Code with persistent episodic memory to recall past solutions, learn from experience, and transfer knowledge across coding projects. It exposes 12 tools, such as tempera_session_start, tempera_brief, tempera_retrieve.
Summary generated from the project's README
About Tempera MCP server
Tempera provides Claude Code with a persistent episodic memory system designed to prevent the loss of context between coding sessions. By capturing sessions as episodes, the server allows an AI agent to recall past solutions, learn from previous successes or failures, and transfer knowledge across different coding projects. It uses semantic search via a BGE-Small embedding model to retrieve relevant memories when a user starts a new task.
Developers use this MCP server by adding it to Claude Code via the command line. The system operates locally, and upon the first run, it automatically downloads the necessary embedding model to a global cache. It features a sophisticated learning loop where helpful memories gain utility through user feedback and multi-hop Bellman propagation, while unhelpful or stale information eventually fades based on its validity scope. This ensures that language-level facts persist for years while project-specific workarounds expire as they become obsolete.
What you can do with it
- 1Retrieve past bugfix solutionsA developer can ask the AI to find how a similar authentication issue was resolved in a previous session.
- 2Transfer knowledge between projectsThe system can surface language or domain-specific claims learned in one codebase when working in a completely different repository.
- 3Automate session preparationThe agent can use a brief tool to check for pending clarifying questions or reasoning templates before starting a task.
Written from the project's README. Every use case is checked against a quote from it.
How to install Tempera MCP
Formats verified 10 Nov 2026Add to CursorAdd to GooseInstall Tempera MCP in Claude Code
$ claude mcp add tempera -- npx -y @astudioplus/tempera-mcpInstall Tempera MCP in Cursor
~/.cursor/mcp.json
{
"mcpServers": {
"tempera": {
"command": "npx",
"args": [
"-y",
"@astudioplus/tempera-mcp"
]
}
}
}Install Tempera MCP in VS Code
.vscode/mcp.json
{
"servers": {
"tempera": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@astudioplus/tempera-mcp"
]
}
}
}Install Tempera MCP in VS Code CLI
$ code --add-mcp '{"name":"tempera","type":"stdio","command":"npx","args":["-y","@astudioplus/tempera-mcp"]}'Install Tempera MCP in Claude Desktop
claude_desktop_config.json
{
"mcpServers": {
"tempera": {
"command": "npx",
"args": [
"-y",
"@astudioplus/tempera-mcp"
]
}
}
}Install Tempera MCP in Codex
$ codex mcp add tempera -- npx -y @astudioplus/tempera-mcpInstall Tempera MCP in Codex config.toml
~/.codex/config.toml
[mcp_servers.tempera] command = "npx" args = ["-y", "@astudioplus/tempera-mcp"]
Install Tempera MCP in Gemini CLI
$ gemini mcp add -s user tempera npx -- -y @astudioplus/tempera-mcpInstall Tempera MCP in Gemini settings.json
~/.gemini/settings.json
{
"mcpServers": {
"tempera": {
"command": "npx",
"args": [
"-y",
"@astudioplus/tempera-mcp"
]
}
}
}Tempera MCP tools 12
Detected from the READMEtempera_session_starttempera_brieftempera_retrievetempera_templatetempera_log_correctiontempera_log_should_have_askedtempera_capturetempera_feedbacktempera_statustempera_statstempera_propagatetempera_review
| tempera_session_start | — | |
| tempera_brief | — | |
| tempera_retrieve | — | |
| tempera_template | — | |
| tempera_log_correction | — | |
| tempera_log_should_have_asked | — | |
| tempera_capture | — | |
| tempera_feedback | — | |
| tempera_status | — | |
| tempera_stats | — | |
| tempera_propagate | — | |
| tempera_review | — |
Automated checks
Ran Nov 14, 2026Full report →Passed our automated checks. That is not a security audit: read the code and give the server the narrowest access it needs. How checks work
- Source repository linked and reachableanvanster/tempera is public and reachablegithub.com/anvanster/tempera ↗Pass
- Package names this repository as its source@astudioplus/tempera-mcp names anvanster/tempera as sourcenpmjs.com/package/@astudioplus/tempera-mcp ↗Pass
- Build provenance (Sigstore attestation)No build attestation published for this releaseNot checked
- Open source license (OSI)Apache-2.0spdx.org/licenses/Apache-2.0.html ↗Pass
- Commit or release in the last yearLast commit or release 2026-05-30github.com/anvanster/tempera ↗Pass
- OpenSSF ScorecardNot checked
- Package name not close to a popular packageNo popular package one edit away from @astudioplus/tempera-mcpPass
- No critical advisory in the package or its dependencies1 resolved dependencies checked; no critical advisoryosv.dev ↗Pass
- No hidden instructions to the model12 tool descriptions and the README read; no override phrases, credential paths or hidden charactersPass
- Destructive tools are labelledNo tool named like delete, drop or execPass
- Remote endpoint answers the MCP handshakeNot checked
README
View on GitHubTempera - Persistent Memory for Claude Code
Tempera gives Claude Code a persistent memory that learns from experience. Instead of starting fresh each session, Claude can recall past solutions, learn what works, and get smarter over time.
Why Tempera?
The Problem: Claude Code forgets everything between sessions. You solve the same problems repeatedly, and Claude can't learn from past successes or failures.
The Solution: Tempera captures coding sessions as "episodes", indexes them for semantic search, and uses reinforcement learning to surface the most valuable memories when relevant.
Without Tempera: With Tempera:
┌─────────────┐ ┌─────────────┐
│ Session 1 │ ──forgotten──> │ Session 1 │ ──captured──┐
└─────────────┘ └─────────────┘ │
┌─────────────┐ ┌─────────────┐ ▼
│ Session 2 │ ──forgotten──> │ Session 2 │ ◄──recalls──┤
└─────────────┘ └─────────────┘ │
┌─────────────┐ ┌─────────────┐ │
│ Session 3 │ ──forgotten──> │ Session 3 │ ◄──recalls──┘
└─────────────┘ └─────────────┘
│ │
▼ ▼
No learning Continuous improvement
How It Works
The Learning Loop
┌────────────────────────────────────────────────────────────────┐
│ 1. START TASK │
│ User: "Fix the login redirect bug" │
└────────────────────────────────────────────────────────────────┘
│
▼
┌────────────────────────────────────────────────────────────────┐
│ 2. RETRIEVE MEMORIES │
│ Claude searches: "login redirect bug" │
│ Finds: "Fixed similar issue by sanitizing return URLs" │
│ + Session context: related episodes from the same task │
└────────────────────────────────────────────────────────────────┘
│
▼
┌────────────────────────────────────────────────────────────────┐
│ 3. SOLVE FASTER │
│ Claude uses past experience to solve the problem │
└────────────────────────────────────────────────────────────────┘
│
▼
┌────────────────────────────────────────────────────────────────┐
│ 4. CAPTURE SESSION │
│ Claude saves: what was done, what worked, what failed │
│ Auto-links to current session for multi-step tasks │
└────────────────────────────────────────────────────────────────┘
│
▼
┌────────────────────────────────────────────────────────────────┐
│ 5. LEARN FROM FEEDBACK │
│ User: "That memory was helpful!" │
│ → Episode utility increases │
│ → Multi-hop Bellman propagation spreads value │
│ → Session-linked episodes get boosted │
│ → Unhelpful memories fade over time │
└────────────────────────────────────────────────────────────────┘
What Makes It "Learn"
| Mechanism | What It Does |
|---|---|
| Feedback | Helpful episodes gain utility score |
| Multi-hop Bellman Propagation | Value spreads through the similarity graph across multiple hops |
| Session Chaining | Related episodes in multi-step tasks are linked and boost each other |
| Temporal Credit | Episodes before successes get credit (even across session boundaries) |
| Recency Boost | Fresh episodes can be weighted higher in retrieval (opt-in) |
| Scope-aware Decay | Project-bound claims fade in ~70 days; language-level facts last ~3 years; universal truths never decay |
| Verification State | Captures advance from Untested → TestsPass → Merged → StableNoRevert; later states weigh more |
| Calibration | Per-(task, project) verified vs. declared ratio surfaces overconfidence |
| Dream Cycle | Nightly reflection, pattern detection, contradiction probing, and template extraction |
| Self-Improvement Log | Tracks corrections, missed questions, and queues clarifying questions for next session |
| Cross-Project Transfer | Claims marked language / crate / domain / forever-scoped surface across projects |
Over time, frequently helpful knowledge rises to the top, while stale or unhelpful memories fade away — and the system itself accumulates a per-project picture of where it tends to be wrong.
The bigger surfaces (v0.6 onward)
Beyond the basic capture/retrieve loop, Tempera ships several higher-order surfaces. Each is opt-in but all flow through the same MCP tools — Claude can use them without any custom client code.
- Grounded capture (v0.6): Every captured claim carries a
falsifiabilityscore, acategory, and aValidityScope(Forever / Language / Crate / Domain / Workaround / Project). Decay rates are per-scope — universal truths never expire, project-specific conventions fade in months, workarounds expire when the underlying issue closes. - Dream cycle (v0.7): A budgeted nightly pipeline that runs
verify_advance → decay → reflect → patterns → contradict → templates. Reflections turn high-signal days into prose; patterns surface themes that keep recurring; contradict probes pairs of frequently-retrieved episodes for factual disagreements; templates extract reusable step sequences from successful task clusters. - Self-improvement (v0.8): Calibration tracks the ratio of declared vs. verified successes per (task, project). Mistakes log records corrections the agent made. Should-have-asked log records questions it realized it should have asked first. Ask-backs are clarifying questions the system itself drafts via Haiku when a capture ends in failure with vague intent — queued for the next session in that project.
- Brief surface (v0.9): One MCP call joins all of the above against the file set the agent is about to touch.
tempera_brief(files, task_type?, domain?)returns pending ask-backs, the matching reasoning template, top correction categories for those files, should-have-asked triggers, and a calibration warning if the agent's track record on this kind of task is shaky. - Cross-project learning (v0.10):
tempera_retrieveandtempera_briefboth acceptcross_project=true. Transferable claims (anything not project-scoped) surface across projects; Project-scoped knowledge stays bound to its codebase. Legacy captures default to non-transferable until reclassified.
Installation
Build from Source
# Clone and build
git clone https://github.com/anvanster/tempera.git
cd tempera
cargo build --release
# Two binaries are created:
# - target/release/tempera (CLI tool)
# - target/release/tempera-mcp (MCP server for Claude Code)
Install from crates.io
cargo install tempera
First Run - Model Download
On first use, Tempera downloads the BGE-Small embedding model (~128MB) for semantic search. This happens automatically and only once:
# Initialize and trigger model download
tempera init
# Output:
# 🔄 Loading embedding model (this may download the model on first run)...
# ✅ Embedding model loaded
The model is cached globally at ~/.tempera/models/ and shared across all projects.
Setup with Claude Code
1. Add the MCP Server
claude mcp add tempera --scope user -- /path/to/Tempera/target/release/tempera-mcp
The --scope user flag makes it available across all your projects.
2. Restart Claude Code
Exit and restart Claude Code to load the new MCP server.
3. Verify
Run /mcp in Claude Code. You should see tempera with 12 tools.
MCP Tools
Once connected, Claude has access to these 12 tools, grouped by purpose:
Session warmup (call at task start)
| Tool | When to Use |
|---|---|
tempera_session_start |
Call ONCE at the very start. Returns any clarifying question tempera drafted after a previous failed/partial session in this project. |
tempera_brief |
Call once the file set is known. Joins pending ask-back, reasoning template, top correction categories for these files, should-have-asked triggers, and calibration warning into one response. Pass task_type + domain for richer output. Set cross_project=true to supplement with rows from other projects. |
tempera_retrieve |
Search for similar past episodes. Set scope="cross-project" to include transferable claims from other projects. |
tempera_template |
Pull the reasoning template stored for a (task_type, domain) pair. The step sequence past wins followed. |
During task
| Tool | When to Use |
|---|---|
tempera_log_correction |
When the user corrects an assumption / decision / piece of code. Categorized log; the brief surface uses it. |
tempera_log_should_have_asked |
When you realize mid-task you should have asked a question up front. Records the trigger context, the question, and the eventual answer. |
End of task
| Tool | When to Use |
|---|---|
tempera_capture |
Save session as an episode. Auto-detects session links and runs propagation. The intent-extraction LLM call also suggests a ValidityScope for cross-project routing. |
tempera_feedback |
Mark retrieved episodes as helpful or not. Drives the utility-learning loop. |
Diagnostics + maintenance
| Tool | When to Use |
|---|---|
tempera_status |
Per-project memory health snapshot. |
tempera_stats |
Statistics + trend analytics (helpfulness over time, domain growth, learning curve). |
tempera_propagate |
Multi-hop Bellman propagation with convergence tracking. Periodic maintenance. |
tempera_review |
Consolidate similar BKMs, cleanup. Run after related task series. |
Standard warmup pattern
tempera_session_start # is anything queued from last session?
tempera_brief(files, ...) # what does tempera know about this exact change?
tempera_retrieve(query) # then deep-dive into specific episodes
Key Lifecycle Behaviors
Start of session: Call tempera_session_start first to consume any pending ask-back, then tempera_brief once the file set is known.
End of task: Capture successful sessions with tempera_capture — don't wait to be asked. Capture also drafts an ask-back via Haiku if the outcome was Failure/Partial with vague intent, so the next session in this project sees the gap.
Session chaining: Episodes captured within 2 hours of each other in the same project are automatically linked. Multi-step tasks share utility and context.
Cross-project routing: New captures get a ValidityScope suggestion from the intent-extraction LLM (v0.10.3). Project-scoped claims stay bound to one codebase; Language / Crate / Domain / Workaround / Forever claims surface across projects when retrieval opts in.
tempera_retrieve Modes
Search: tempera_retrieve(query: "authentication bug")
List all: tempera_retrieve(all: true)
Show details: tempera_retrieve(query: "abc12345") # episode ID
Cross-project: tempera_retrieve(query: "sqlx ordering", scope: "cross-project")
Example Conversation
User: Fix the login redirect vulnerability
Claude: [Calls tempera_session_start()]
No pending ask-back — proceeding.
[Calls tempera_brief(files: ["src/auth.rs", "src/router.rs"],
task_type: "bugfix", domain: "auth-middleware")]
🔴 PENDING ASK-BACK
Ask the user first: "Should auth run before or after request logging?"
📋 REASONING TEMPLATE (bugfix / auth-middleware)
url-redirect validation
1. Find every redirect target read from request input
2. Validate against allow-list or treat as untrusted
3. Add regression test with adversarial input
⚠️ TOP CORRECTION CATEGORIES for these files
- validation_skipped (3×)
- host_header_trust (2×)
Tempera says I've been wrong here before in specific ways.
Let me ask: should auth run before or after logging?
User: Before — we need an auth'd subject for log lines.
Claude: [Implements with URL allow-list, following the template steps]
Done. [Calls tempera_capture(
summary: "Fixed login redirect by validating return URL against allow-list",
outcome: "success",
validity_scope: "domain:auth-middleware"
)]
✅ Episode saved. (Cross-project — this is an auth-middleware pattern.)
User: That memory was helpful!
Claude: [Calls tempera_feedback(helpful: true, episodes: ["..."])]
Marked helpful — future retrievals for similar tasks will rank this higher.
CLI Commands
The CLI mirrors the MCP tool surface so you can drive everything Claude does from a shell.
Basics
# Initialize Tempera
tempera init
# Capture an episode (from a session transcript or interactively)
tempera capture --session /path/to/transcript.md
# Index episodes for semantic search (or re-index)
tempera index [--reindex]
# Search memories — project-scoped by default
tempera retrieve "database connection issues"
tempera retrieve "sqlx pattern" --cross-project # v0.10.1 — pull from other projects
# Provide feedback
tempera feedback helpful --episodes abc123,def456
The brief surface (v0.9)
# Joint summary of every self-improvement signal for these files
tempera brief --files src/auth.rs,src/router.rs \
--task-type bugfix --domain auth-middleware
# Include rows from other projects (foreign rows are tagged [from <project>])
tempera brief --files src/store.rs --cross-project
Session warmup (v0.8.5)
# Show + clear the pending ask-back for this project (if any)
tempera session-start
# History of system-drafted clarifying questions
tempera ask-backs [--pending] [--project P]
Self-improvement surfaces (v0.8)
# Log a correction the user made
tempera log-correction --category "lifetime annotations" \
--description "I assumed &str when &'a str was needed" \
--correction "use named lifetime to match trait"
# View the correction log
tempera mistakes [--top 5] # top categories
tempera mistakes --project tempera # raw list filtered
# Log a question you should have asked up front
tempera log-should-have-asked --trigger "edit auth middleware" \
--question "Which auth provider is wired up?" \
--answer "No auth — internal-only service."
# View the should-have-asked log
tempera asks --top 5
Reasoning templates (v0.8.3)
# List stored templates
tempera templates list
# Fetch a specific template
tempera templates get --task-type bugfix --domain async-rust
# Manually trigger extraction (otherwise runs in dream cycle)
tempera templates extract --max-usd 0.20
Calibration (v0.8.1)
# Per-(task_type, project) verified vs declared rates
tempera calibration --project tempera --task-type bugfix
Dream cycle (v0.7)
# Run the full cycle with a budget cap (default $0.50)
tempera dream --max-usd 0.50
# Run one phase, or list available phases
tempera dream --phase reflect
tempera dream --list
# Plan only — show what would happen without making LLM calls
tempera dream --dry-run
# Author yesterday's reflection (Haiku triage + Sonnet authorship if score >= 0.5)
tempera reflect [--date 2026-05-26] [--dry-run]
# Surface active factual contradictions found during dream
tempera contradict --list
Verification (v0.6.1)
# Move an episode forward in the verification chain
tempera advance-verification --episode abc123 --to tests_pass --run-id <id>
tempera advance-verification --episode abc123 --to merged --commit <sha>
tempera advance-verification --episode abc123 --to stable_no_revert --days 30
Maintenance + analytics
# Multi-hop Bellman propagation (run weekly)
tempera propagate --temporal
# Prune old / low-value episodes
tempera prune --older-than 90 --min-utility 0.2 --execute
# Stats + trends
tempera stats
tempera trends --project tempera --bucket weekly
# Health check + remediation
tempera doctor [--remediate --yes --target-score 90]
# Eval harness (P@5, R@5, MRR, nDCG@5 against a fixture)
tempera eval run --fixture evals/fixtures/real.jsonl --mode hybrid
# Snapshot / restore the data dir
tempera backup
tempera backup --list
tempera backup --restore 20260524T123456Z
Data Storage
Tempera stores everything locally in ~/.tempera/ (shared across all projects). One memory pool serves every project; the project filter is applied at query time.
~/.tempera/
├── config.toml # Configuration (all RL params configurable)
├── episodes/ # Canonical episode JSON
│ └── 2026-01-25/
│ └── <id>.json
├── jobs.sqlite # SQLite for everything indexable (see below)
├── vectors/ # Vector index (vectrust embeddings)
├── models/ # BGE-Small embedding model (~128MB)
├── reflections/ # Daily reflection markdown (v0.7.3)
├── patterns/ # Cross-day pattern pages (v0.7.4)
└── templates/ # Reasoning templates (v0.8.3)
SQLite tables (in jobs.sqlite)
Everything that needs SQL lives here. Each store opens the DB on first use and runs its migration; migrations are in migrations/ and run in order.
| Migration | Table | Purpose |
|---|---|---|
| 0001 | jobs |
Background job queue with lease semantics |
| 0002 | error_fingerprints |
blake3-hashed normalized error text |
| 0003 | dream_verdicts |
Day-level Haiku triage cache |
| 0004 | reflections |
Daily reflection records |
| 0005 | patterns |
Cross-day theme clusters |
| 0006 | contradictions |
Episode-pair disagreements + Wilson CI |
| 0007 | calibration_buckets |
(task_type, project) declared vs verified counts |
| 0008 | mistakes |
Anchored correction log |
| 0009 | reasoning_templates |
Extracted reasoning step sequences |
| 0010 | should_have_asked |
Questions the agent should have asked up front |
| 0011 | ask_backs |
System-drafted clarifying questions for next session |
All projects share the same pool. Cross-project routing is controlled by each episode's ValidityScope (see below) — not by separate storage.
Configuration
All knobs live in ~/.tempera/config.toml. The defaults are tuned to be useful out of the box; you only need to touch this if you want to change retrieval ranking, dream-cycle behavior, or per-phase budgets.
Retrieval + ranking
[retrieval]
mode = "hybrid" # vector | keyword | hybrid (BM25 + vector fusion)
similarity_weight = 0.3 # Weight for semantic similarity (project mode)
utility_weight = 0.7 # Weight for learned utility (project mode)
hybrid_similarity_weight = 0.85 # RRF-normalized retrieval (hybrid mode)
hybrid_utility_weight = 0.15
recency_weight = 0.0 # Recency (0 = off, opt-in)
recency_halflife_days = 30.0
mmr_lambda = 0.7 # MMR diversity (0=diverse, 1=relevant)
min_similarity = 0.5 # Filter threshold
[bellman]
gamma = 0.9 # Discount factor for Bellman updates
alpha = 0.1 # Learning rate
propagation_threshold = 0.5 # Min similarity for propagation
max_propagation_depth = 2 # Multi-hop depth (hops)
temporal_credit_window_hours = 1
Capture + verification
[capture]
auto_capture = true
extract_intent_llm = true # Use LLM to extract intent + claim + scope
capture_diffs = true
ask_back_on_failure = true # Draft a clarifying question on Failure/Partial captures (v0.8.5)
Dream cycle (v0.7)
[dream]
default_max_usd = 0.50 # Per-cycle budget cap
stable_threshold_days = 30 # Days before Merged → StableNoRevert
triage_model = "claude-haiku-4-5-20251001"
reflect_model = "claude-sonnet-4-6"
# Patterns phase
patterns_lookback_days = 30
patterns_min_evidence = 3
patterns_cluster_threshold = 0.75
# Contradict phase
contradict_top_n = 50
contradict_min_similarity = 0.6
contradict_max_similarity = 0.95
contradict_max_pairs = 30
contradict_min_confidence = 0.7
# Templates phase (v0.8.3)
templates_min_evidence = 3
templates_min_verification_weight = 0.30 # 0.30 = Untested (lenient); 0.60 = Merged
Storage + maintenance
[storage]
max_age_days = 180 # Max episode age for pruning
min_utility_threshold = 0.05 # Min utility to keep
min_retrievals = 2 # Min retrievals before pruning allowed
consolidation_threshold = 0.85 # BKM merge threshold
cluster_threshold = 0.85
stale_age_days = 30
stale_utility_threshold = 0.2
Decay rates are scope-aware (per the ValidityScope on each episode's claim):
| Scope | Decay/day | Half-life |
|---|---|---|
Forever |
0.000 | ∞ |
Language { name } |
0.001 | ~3 years |
Domain { tag } |
0.005 | ~140 days |
Project { name } |
0.010 | ~70 days |
Crate { name, version } |
0.020 | ~35 days |
Workaround { ref, expires } |
0.050 | ~14 days |
| (no scope set, legacy) | 0.010 | ~70 days |
Under the Hood
Multi-hop Bellman Propagation
Value from helpful episodes spreads through the similarity graph in multiple hops:
Hop 0: Source episodes (high helpfulness, ≥2 retrievals)
│
▼ γ¹ discount
Hop 1: Similar episodes updated
│
▼ γ² discount
Hop 2: Episodes similar to hop-1 updated
│
▼ Converges when no updates occur
Session Chaining
Episodes captured within 2 hours of each other in the same project are automatically linked:
Session abc123:
├── Episode 1: "Investigated auth bug" (debug)
├── Episode 2: "Found root cause in token validation" (research)
└── Episode 3: "Fixed token expiry check" (bugfix, success)
↓
Temporal credit flows back to episodes 1 & 2
Session-linked propagation boosts all 3
The Dream Cycle (v0.7)
A budgeted background pipeline that runs nightly (or on demand). Each phase shares a CostBudget; free phases ignore it, paid phases check try_spend() before each LLM call.
verify_advance → decay → reflect → patterns → contradict → templates
(free) (free) (Sonnet) (Sonnet) (Haiku) (Sonnet)
↓ ↓ ↓ ↓
reflections/ patterns/ contradictions templates/
- verify_advance: bumps episodes from
MergedtoStableNoRevertafterstable_threshold_days. - decay: scope-aware utility decay (see table above).
- reflect: Haiku triage gates Sonnet authorship; high-signal days get a reflection page.
- patterns: agglomerative clustering on reflection embeddings → cross-day themes.
- contradict: pairs frequently-retrieved BKM episodes and asks Haiku whether they disagree on a factual claim; surfaces a Wilson 95% CI on the contradiction rate.
- templates: groups successful verified episodes by
(task_type, domain), extracts reusable step sequences via Sonnet.
Worst case per full cycle: roughly $0.50 with default settings.
Tempera MCP questions
How do I add Tempera MCP to Claude Code?
Run claude mcp add tempera -- npx -y @astudioplus/tempera-mcp in your terminal. Add --scope user to make it available in every project.
How do I add Tempera MCP to Cursor?
Open ~/.cursor/mcp.json and add the server under mcpServers, using the Cursor config shown in the install section above.
What tools does Tempera MCP provide?
It exposes 12 tools, including tempera_session_start, tempera_brief, tempera_retrieve, tempera_template, tempera_log_correction.
How does Tempera help Claude Code learn?
It captures coding sessions as 'episodes', indexes them for semantic search, and uses reinforcement learning to surface the most valuable memories when relevant.
Can Tempera share knowledge between different projects?
Yes, claims marked with specific scopes like language, crate, or domain can surface across projects when using cross-project retrieval.
Does Tempera require any manual model setup?
No, on the first use, it automatically downloads the BGE-Small embedding model for semantic search.
What happens to old or unhelpful memories?
The system uses scope-aware decay where project-bound claims fade over time, while unhelpful memories are managed through a utility-learning loop.