Crate herolib_sid

Crate herolib_sid 

Source
Expand description

SmartID (SID) - Distributed, Human-Readable Identifiers

SmartID provides short, human-readable identifiers for distributed systems. This module is used internally by the Context module for ID generation.

§Design Targets

  • Human-friendly (chat, voice, memory)
  • Deterministic & auditable
  • Collision-free
  • Offline-capable
  • Scalable (up to 999 contributors)

§Alphabet

Base-36: 0123456789abcdefghijklmnopqrstuvwxyz

§Formula

global_id = local_counter * num_contributors + contributor_id + 1

Modules§

base36
Base-36 encoding and decoding for SmartID

Structs§

SmartId
A SmartID - a short, human-readable, collision-free identifier.

Enums§

SidError
Errors that can occur during SmartID operations

Constants§

MAX_CONTRIBUTORS
Maximum number of contributors per space

Type Aliases§

Result