-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Labels
RFCRequest for Comments — protocol designRequest for Comments — protocol designroadmapPlanned for future developmentPlanned for future development
Description
Context
Suggested by Claude 3.7 Sonnet and partially by Grok during LLM evaluations. This is the most critical missing piece for federated multi-agent scenarios.
Problem
In federated mode, two agents at different nodes can independently derive from the same parent_id. When these nodes sync, there's no protocol-defined way to:
- Detect the conflict
- Represent both branches faithfully
- Resolve or merge without losing lineage information
Proposed RFC Outline
New concept: artifact.lineage.fork_id
When a conflict is detected during sync:
{
"artifact_id": "uuid-B",
"lineage": {
"parent_id": "uuid-A",
"fork_id": "uuid-A",
"fork_seq": 1
}
}Merkle DAG for auditable proofs
Each artifact's content_hash chain forms a Merkle DAG. Any node can verify a lineage proof without trusting the origin server:
verify_lineage(leaf_id, root_id) → MerkleProof
CRDT-based sync
Artifact sets are modeled as a Grow-Only Set (G-Set) CRDT — artifacts are immutable once published, conflicts are forks (not mutations), and merge is always union.
# Sync two nodes
proof = node_a.sync(node_b)
proof.conflicts # list of fork pairs
proof.merged # total artifact count after mergeAcceptance Criteria
- RFC KCP-003 document in
rfcs/kcp-003-lineage-conflict.md - Fork detection algorithm defined
- Merkle proof structure specified
- CRDT merge semantics defined
- Python SDK reference implementation
- Tests: conflict detection + merge
Related
- RFC KCP-001 §5 (Federation)
- RFC KCP-002 (MCP Bridge — context for multi-agent scenarios)
- Suggested by: Claude 3.7, Grok 2
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
RFCRequest for Comments — protocol designRequest for Comments — protocol designroadmapPlanned for future developmentPlanned for future development