---
title: memhtml correct
description: "Supersede a memory: write the new file and archive the target in ONE commit."
---

## 1. Synopsis

Supersede a memory: write the new file and archive the target in ONE commit.

```sh
memhtml correct <target> --title <string> [options]
```

## 2. Arguments

| Argument | Required | Description |
| --- | --- | --- |
| `target` | yes | The memory being corrected. |

## 3. Flags

| Flag | Type | Default | Values | Description |
| --- | --- | --- | --- | --- |
| `--title` | string | *no default* | *no fixed set* | The new memory's title. **Required.** |
| `--claim` | string | *no default* | *no fixed set* | The corrected claim. Exactly one of `--claim` or `--article-html`. |
| `--body` | string, repeatable | *no default* | *no fixed set* | A prose paragraph. Repeatable. |
| `--article-html` | string | *no default* | *no fixed set* | Raw \<article> markup for the superseding memory, used verbatim in place of `--claim`/`--body`. Must contain exactly one \<mark> in the first \<p> or \<li>; the first \<time datetime> becomes the memory's event time. The store refuses format violations before any commit. Exactly one of `--claim` or `--article-html`. |
| `--type` | string | *no default* | `episodic`, `semantic`, `procedural`, `agent_insight`, `user_preference`, `error_pattern`, `verdict`, `precedent`, `arc`, `task` | The new memory's type. Defaults to the target's, so correcting an arc keeps it one. |
| `--reason` | string | *no default* | *no fixed set* | Why the correction was made. |
| `--session-id` | string | *no default* | *no fixed set* | Records a `corrected` session link. |
| `--prompt-id` | string | *no default* | *no fixed set* | The prompt within that session. |
| `--turn-uuid` | string | *no default* | *no fixed set* | The turn within that session. |

Every command also accepts the [global flags](/reference/global-flags/).

## 4. Response

On success the command writes one JSON envelope to stdout, and its `type` is `memory.corrected`.

On failure it writes the failure envelope, whose `code` comes from [error codes](/reference/error-codes/).

[The JSON envelope](/reference/envelope/) gives the fields both shapes carry. [Response types](/reference/response-types/) lists every value `type` takes across the binary.

## 5. Further reading

The guide blocks that name this command:

* [`conflicts`](/reference/guide/conflicts/)
* [`recall-discipline`](/reference/guide/recall-discipline/)

## 6. Provenance

A loader generates this page from `apps/cli/src/commands.ts` while the site builds, so no file in the repository holds it: the `COMMANDS` array there is the one source of argument parsing, of `memhtml manifest`, and of `AGENTS.md`. Change the registry and this page changes with it.