Skip to main content
POST
Restore a learning version

Authorizations

X-API-Key
string
header
required

Path Parameters

version_id
string<uuid>
required

Query Parameters

dry_run
boolean
default:false

Report what would happen, and change nothing.

Response

Successful Response

One learning: a one-line rule the agent follows on every output.

batch_id
string<uuid> | null
required

The release that wrote it, for a learning split from a long prompt (simplified) or carried over from old feedback (carried): undoing that event (POST /agent-learnings/thumbs-downs/{event_id}/revert/ with this id) is Put back the original prompt. Null for a learning a thumbs down taught.

created_at
string<date-time>
required
created_by_user_id
string | null
required

Who taught it, or null for a release.

id
string<uuid>
required
last_event_id
string<uuid> | null
required

The latest thumbs down that wrote it, for Undo (POST /agent-learnings/thumbs-downs/{event_id}/revert/); null when none did or the learning was only read.

source
enum<string>
required

Where it was taught: the surface whose thumbs down added it, simplified when a long prompt was split into a goal and learnings, carried when old feedback was carried over.

Available options:
table_cells,
agent_preview,
task,
writing_preview,
reply_draft,
sent_message,
hand_edit,
simplified,
carried,
template,
hand
text
string
required

The rule, one line.

updated_at
string<date-time>
required
all_sequences
boolean
default:false

Whether every sequence's writer follows it, rather than one agent.

note
string | null

What the person said in the thumbs down that last wrote it (last_event_id), every note of a refined one joined, one per line; null when no thumbs down did, and once its feedback session closed: a saved, discarded or undone session keeps none of the person's notes.

note_surface
enum<string> | null

Where the thumbs down that last wrote it (last_event_id) was given, which note and source_text come from; it can differ from source once a later thumbs down on another surface changed it. Null when no thumbs down did.

Available options:
table_cells,
agent_preview,
task,
writing_preview,
reply_draft,
sent_message,
hand_edit,
simplified,
carried,
template,
hand
noted_at
string<date-time> | null

When that thumbs down was given; null when no thumbs down wrote it.

notes
string[]

The same notes one by one, oldest first, each whole: the thumbs down's own, then each further note in its session. Empty when no thumbs down wrote it, and once its feedback session closed.

repeats
integer
default:0

How often a later Needs work asked for it again, as it stood, once saved; 0 when none did.

source_text
string | null

The message that thumbs down was given on, as it read then; null when none was kept (a table agent's, or a learning a release wrote).

step_key
string | null

The one step of the sequence it holds for, by the step's agent prompt slot; null when it holds for every message the agent writes.

step_label
string | null

That step as the sequence names it now, e.g. "Step 2 · Follow up"; null when it holds for every message, or the step is gone.