/memfleet-skills:memfleet-record-episodefrom memfleet-skills
Records structural edit episodes after code changes, classifying conflicts (A/B/C) and updating NodeState rollups for multi-agent fleet coordination.
Ships in memfleet-skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
None: SKILL.md is the whole skill.
Report a finished edit to the broker. The broker:
get_node_state reads are O(1).Every agent that subsequently reads any of those nodes gets the rollup picture immediately. You never re-emit — one episode per semantic edit.
| Tool | Purpose |
|---|---|
record_episode | Report a finished edit; get back a class A/B/C |
publish_intent | (Pre-call) the intent whose intent_id you reference here |
get_node_state | (Optional, post-call) verify the rollup updated as expected |
Parameter types: MCP parameters are strictly typed.
diff_summaryMUST be a JSON object naming the IntentKind variant (same shape aspublish_intent'sintent_kind).reference_timeMUST be RFC3339 — it is the LWW arbitration field for Class B.
Make all your code changes through your normal harness loop. Do not call record_episode mid-edit; wait until the diff is final.
touched_nodes is the set of NodeIdentities your diff actually changed — not the planned set, not the propagation_set from publish_intent. The broker uses this to update the right rollups.
If your edit changed:
record_episodemcp__memfleet__record_episode({
intent_id: "01H…", // from publish_intent
diff_summary: {"Refactor": {"pattern": "RenameSymbol"}},
touched_nodes: ["UserRole", "UserRoleRepo.find"],
reference_time: "2026-04-18T09:30:00Z"
})
Parameters:
intent_id — string (ULID), required. The intent you published before editing.diff_summary — JSON object, required. The structural shape of the change as an IntentKind-compatible enum, NOT prose.touched_nodes — string array, required. The NodeIdentities your diff actually changed.reference_time — RFC3339 string, required. Used for LWW arbitration on Class B collisions.agent_id — string, optional. Useful for query_episodes filtering downstream.Success criteria: the broker returns episode_id, conflict_class, and (for B/C) won / replan_hint / conflict_report.
conflict_class | Meaning | Action |
|---|---|---|
| A | Additive — new symbols, no signature changes, no removals | Done. Auto-accepted. |
| B | Modification collides with another in-flight edit on the same symbol | Read won. If false, follow replan_hint. See memfleet-conflict-resolution. |
| C | Breaking — removes live symbol or changes a signature with active callers | Blocked. Read conflict_report.cause. Branch to memfleet-conflict-resolution. |
| Situation | Action |
|---|---|
| You are part of a leader/follower wave | Use the wave's correlation tag in diff_summary's surface so the leader can match your episode |
| The edit was a no-op (you decided not to change anything) | Skip record_episode — there is nothing structural to report. Optionally release the intent. |
| Your diff also touched test files | Decide: was the test for the same symbol (include in touched_nodes) or a parallel TestAdd (publish a separate intent)? |
Class B won: true | Done; the loser will replan. |
Class B won: false | Re-edit on replan_hint's target; record a fresh episode under a new intent. |
| Class C | Do NOT retry. Coordinate first. |
| Mistake | Reality |
|---|---|
Writing a prose diff_summary ("Renamed UserRole to UserRoleV2 because…") | Prose is what we are replacing. The enum variant IS the coordination signal. |
| Recording multiple episodes for one semantic edit | One episode = one structural change. Multiples inflate conflict counts and confuse the rollup. |
| Delaying the call until end-of-session | Every other agent reads stale rollups until you record. Call immediately after the edit. |
Putting the planned set in touched_nodes instead of what actually changed | The broker can't trust your propagation if the touched set is wrong. Be precise. |
Reusing intent_id from a prior session | The intent has TTL'd out. Publish a fresh intent for the current edit. |
Quoting reference_time as Unix epoch ("1735689600") | RFC3339 only. Wrong format silently breaks LWW arbitration. |
Skipping record_episode after an Exploratory intent | Even probes should record (often as DocsOnly or another Exploratory) so the rollup shows the symbol was scouted. |
This is the last MCP call in the safe-edit loop. Pair with:
memfleet-publish-intentmemfleet-safe-editmemfleet-conflict-resolutionmemfleet-node-stateWhat SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub syncable-dev/memfleet-public --plugin memfleet-skills10 skills in this plugin
/memfleet-conflict-resolutionAlways use when publish_intent returned a non-empty active_conflicts list, or when record_episode classified the result as Class B (you may have lost LWW) or Class C (blocked). Triggered by: 'publish_intent returned conflicts', 'I got a Class B and lost', 'Class C blocker_agent', 'who is blocking my edit', deciding whether to retry, replan, or escalate. Do not retry blindly on Class B without reading replan_hint, do not edit through a Class C — it will break active callers — and do not invent a prose 'rationale'; structural conflicts get structural resolutions./memfleet-firstAlways use FIRST in any multi-agent session before reading code, planning a refactor, or making an edit on a repo with a registered MemFleet broker. Triggered by: 'I'm about to edit X', 'rename Y across the fleet', 'plan this refactor', joining a running fleet session, coordinating with other agents, prose hand-offs between agents. Do not write a prose rationale for an edit, do not grep for 'who else might be touching this', and do not skip publish_intent because 'it's just a small change'. Empty fleet_status is not permission to skip the protocol — it just means you're the first agent in this window. Skip ONLY for solo-agent sessions with no broker registered or for pure docs-only edits where coordination has zero value.Other plugins' skills for the same job