memory_write
Save durable Markdown notes about repository paths for future agents; update existing notes or target by permalink, with conflict detection.
Instructions
Save a durable note about repository paths (a lesson, trap, handoff or research) as committed Markdown; the next agent that claims those paths gets its excerpt in the brief. A title that already exists updates that note in place, and permalink targets one explicitly. Pass the updated_at you read as if_updated_at so a concurrent edit returns conflict instead of being overwritten. Not for settled choices (decision_record) or talk between agents (message_send).
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| body | Yes | The note itself, as Markdown. | |
| kind | No | One of `fact`, `lesson`, `gotcha`, `handoff`, `research`, `decision`, `note` (the default). | |
| tags | No | Tags for filtering; lowercased, and a leading `#` is dropped. | |
| agent | Yes | Your stable agent name. | |
| paths | No | Repo-relative paths this note is about. | |
| title | Yes | Short title. Becomes the permalink the first time. | |
| permalink | No | Overwrite this note instead of matching on the title. | |
| if_updated_at | No | RFC 3339 `updated_at` from a read; refused if the note changed since. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| note | No | The note as stored: id, permalink, title, kind, body, observations, relations, paths, tags, author, updated_by, created_at, updated_at. | |
| status | Yes | ok. conflict: if_updated_at was set and the note changed since. not_found: an explicit permalink that does not exist. invalid: bad kind or input. | |
| created | No | True for a new note, false when an existing title or permalink was updated. | |
| message | No | Human-readable detail, on most outcomes other than ok. | |
| permalink | No | On conflict: the note that changed. | |
| updated_at | No | On conflict: its real updated_at; read again and retry. |