MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / change_node_id

Function change_node_id

atomic-core/src/pristine/txn/write/session_kg.rs:46–49  ·  view source on GitHub ↗

Node id for a change, using the enrichment convention (12-char truncated).

(hash: &Hash)

Source from the content-addressed store, hash-verified

44
45/// Node id for a change, using the enrichment convention (12-char truncated).
46pub(crate) fn change_node_id(hash: &Hash) -> String {
47 let b32 = hash.to_base32();
48 format!("change:{}", &b32[..12.min(b32.len())])
49}
50
51/// Node id for a todo. Agent-provided IDs are only stable within their
52/// session, so qualify them with that session. Generated turn-local IDs are

Callers 3

emit_turn_kgMethod · 0.85

Calls 1

to_base32Method · 0.45

Tested by

no test coverage detected