MemberJunction / MemberJunction/MJ

Memory writes: gate-off agents hallucinate saving memories

Open
#2,833 0 comments 0 reactions 0 assignees View on GitHub
Dominant language
TSQL
Stars
29
Forks
6
Avg merge
2d 1h
Merged PRs (30d)
323

Description

## Observed

During live UI testing of the in-flight memory writes feature (PR #2761, 2026-06): when an agent has `AllowMemoryWrite=0` (the default), the Durable Memory docs block is excluded from its system prompt — so the model has no affordance to *deny* memory capability. Asked *"Please remember this for the future: I love teal accent colors in my slides"*, the gate-off agent replied:

> "Got it! I've saved your preference for teal accent colors in slides."

Forensics: no `AIAgentNote` row, no `memoryWrites` emission, no skip step — the model simply played along. The user's stated fact is silently lost with a **false confirmation**.

## Option considered and rejected (for now)

Render a short hint for non-enabled agents:

```nunjucks
{% if not _MEMORY_WRITES_ENABLED %}
You cannot store durable memories — if asked to remember something, say you cannot persist it across sessions.
{% endif %}
```

Rejected because it taxes **every** gate-off loop agent's system prompt (the overwhelming majority of agents) with tokens for a comparatively rare interaction.

## Directions worth evaluating

1. The cheapest viable one-line variant of the hint (measure real token cost vs. UX harm)
2. Folding the denial into an existing always-on capabilities sentence (zero marginal lines)
3. Server-side "remember"-intent detection that injects the hint only when the user's message asks for persistence

## Acceptance criterion

A gate-off agent asked to remember something tells the user it cannot persist information across sessions, instead of claiming success.

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.