# 31.8 Memory never overrides policy (/building-ai-workers/self-improving-ai-workers/memory-never-overrides-policy)

---
type: Document
title: "31.8 Memory never overrides policy"
description: "Which source wins when memory and policy disagree, the four kinds of state, and where each kind of note belongs."
status: stable
order: 331.08
ksor:
  owner: team:panaversity
  audience: [ public ]
  approval:
    by: process:panaversity
    at: 2026-11-25T08:13:16Z
chapter: "31"
part: III
expert_status: co-build
concepts: [ "31.8" ]
last_verified: 2026-11-24
sources:
  - id: openai-harness
    title: "Harness engineering: leveraging Codex in an agent-first world (Ryan Lopopolo, OpenAI, 11 February 2026)"
    resource: https://openai.com/index/harness-engineering/
generated:
  at: 2026-11-25T08:13:16Z
  by: process:panaversity
trust_tier: unverified
build_id: sha256:0decb5023f044061076dd533dd5b490739d442d95c609ce2fff5ad3af880174c
dirty: true
ksor_version: 0.0.60
---

**In everyday life.** A delivery driver learns a shortcut through a quiet street, and uses it for months. Then the city makes the street one-way. The driver's habit does not change the law. The sign wins, and the habit must go.

**What you will learn.** Which source wins when memory and policy disagree, the four kinds of state a worker keeps, and where each kind of note belongs. You practise it in Lab 31, Task 6.

**Why it matters.** A worker that trusts its own notes over the company's rules will one day act on an old rule, with confidence.

### Which source wins?

**From strongest to weakest:**

1. Active policy and permissions
2. The business records, such as the payment system
3. Checked evidence in the record of the work
4. Approved memory
5. Things the worker noticed that nobody checked

The phone-approval candidate meets `approvals.md:5` and `:6` at Cedar Ridge: "Every invoice over $2,500.00 needs Luis Moreno's approval, recorded in the approvals table before the payment run. An approval given by phone or chat is not an approval until it is recorded." Policy is first in the list, so the candidate fails validation. Luis did approve one invoice by phone. The worker turned one event into a rule, and the rule contradicted policy.

**A wrong note can sit quietly.** Brightline's v3 says Lakeshore is due in 45 days; `vendor-terms.md:6` says Net 15. A worker that searches the policy usually follows the line, not the note. Usually is the problem: on a morning it skips the search, the note wins. A note that contradicts policy is wrong even when it seldom does harm. It costs tokens on every run that reads it, and it wins on the day the worker does not look.

**Memory is not evidence.** A note that says an invoice was paid does not prove it was paid; the payment system does. That was invoice 5149 in [8.1](../../managing-ai-workers/context-memory-knowledge-and-state/five-places.md): only the accounting system, read now, settles it. A worker that reads such a note checks the record before it acts.

### What are the four kinds of state?

A worker that runs for weeks keeps four kinds of information, and they are easy to mix up:

| Kind | Holds | Who is the authority |
| --- | --- | --- |
| **Business records** | Facts and transactions, such as invoices and payments | The business system itself, reached through the connector |
| **Execution history** | What the worker tried and saw | The sessions: a durable event log that is only ever added to |
| **Task state** | How the work runs: schedules, retries, which run is active | The runtime, such as the portal's scheduler |
| **Memory** | Reusable lessons and context | The published memory, after the promotion protocol |

### Where does a note belong?

Memory and policy can both be Markdown, so they can look alike. One test decides:

| If the note is | It belongs in |
| --- | --- |
| A lesson for this worker, such as a tool's date format | The worker's memory |
| A lesson for one company's work, such as Northfield's NA- documents at Cedar Ridge | That company's memory |
| A rule the company should treat as true for everyone, people included | The company's policy documents ([19.11](../business-data-and-retrieval/each-companys-own-rules-and-data.md)), through the policy owner's review ([10.3](../../managing-ai-workers/governance-and-responsible-use/ownership-and-takedown.md)), never memory |
| The state of one piece of work, such as an invoice on hold | The record of the work, not memory |
| A current business fact, such as a balance | The business system, read through the connector |

If Cedar Ridge lowered Luis's limit from $2,500.00 to $1,000.00 next month, every note learned under the old limit would be flagged, because each records its policy version (31.6). The policy wins the moment it is published.

A lesson moves from memory into policy only through the promotion protocol and then the policy owner's own approval, never by copying. That move is always high tier, because it changes what every worker and every person reads. In Part V, the policy documents become a governed knowledge record, and the same path gets its full form.

There is a third place for the lessons that matter most. OpenAI's Codex team reported turning rules that documents could not enforce into code: linters and tests that check every change.[^openai-harness] For a worker, that is a lesson that becomes a check in the tool itself, like the checks that block a pull request in [15.7](../code-review/checks-that-block.md), and the policy that software enforces in [4.7](../../ai-worker-paradigm/the-architecture-in-one-picture/governance-rule.md). Brightline's connector could refuse to mark ready to pay any Cedar Ridge invoice over $2,500.00 with no approval row. Then no memory, and no prompt, could get around it.

[^openai-harness]: Harness engineering: leveraging Codex in an agent-first world (Ryan Lopopolo, OpenAI, 11 February 2026).
