Write memory notes in OPVS form
Who this is for: agent builders who keep long-term notes for an agent (decisions, lessons, preferences) and want them short.
What this does: turns a note into two lines that any OPVS parser can read: a routing line that says what kind of note it is and what it is about, and one line with the point.
Before you begin
A place where the agent keeps its notes, such as a
MEMORY.mdfile.An idea of the topics the agent's notes are about.
Steps
Address the note to the agent itself. Use a short name for the person or system the note is about, and send it to itself:
@M>Mfor a note about Martin,@sys>sysfor a system note. Names follow the address rules: ASCII letters, digits,_and-.Say what kind of note it is with a tag. Use one of a small set and keep to it:
Tag
Kind of note
#deca decision
#lrna lesson learned
#pata pattern
#prfa preference
#fcta fact
#suma summary
Add topics, and what the note is not about. More tags for topics (
#api,#deploy), and/#tagto rule something out.Link it.
<-refnames the cause (an incident, an earlier note).!= refsays this note replaces an older one. See Relationship marks.Add values on the routing line. Inline values keep the note on two lines. For example
$f:0.95for how sure the agent is, and$t:2026-01for when.Write the point on line 2. One line, plain words, the part that matters: the reason for a decision, the fix for a lesson.
@M>M . #dec #api $f:0.95 $t:2026-01 REST over GraphQL for the partner API: agents read YAML, no extra translation layer.@sys>sys . #lrn #deploy +fix <-incident-215 $f:0.95 $t:2026-02 Deploy the code before running the migration, or old code crashes on new columns.@M>M . #prf #reports != m_4f1 $t:2026-03 Weekly reports go out on Monday morning, not Friday.
Verify it worked
Parse a note with either library (see Parser libraries). You get the kind tag and topics in tags, the values in context, the cause in caused_by, the replaced note in contradicts, and the point in body. If from_agent is empty, the address line is wrong.
Troubleshoot
The parser returns no sender? Check the first token:
@name>namewith no spaces, and names that start with a letter or digit.A value came back as a number when I wanted text?
2026becomes a number;2026-01stays text. Write dates with a-, and keep ids with leading zeros as they are (007stays text).The note lost detail? Two lines are short on purpose. Shortening a note can leave out something that mattered later, such as how long an outage lasted. Keep that detail in line 2, or in a longer note.
Related
The paper: how much shorter OPVS notes are, measured