Raftos
Asynchronous replication framework for distributed Python projects
Install / Use
/learn @zhebrak/RaftosREADME
raftos
Asynchronous replication framework based on Raft Algorithm for fault-tolerant distributed systems.

Install
pip install raftos
Register nodes on every server
import raftos
loop.create_task(
raftos.register(
# node running on this machine
'127.0.0.1:8000',
# other servers
cluster=[
'127.0.0.1:8001',
'127.0.0.1:8002'
]
)
)
loop.run_forever()
Data replication
counter = raftos.Replicated(name='counter')
data = raftos.ReplicatedDict(name='data')
# value on a leader gets replicated to all followers
await counter.set(42)
await data.update({
'id': 337,
'data': {
'amount': 20000,
'created_at': '7/11/16 18:45'
}
})
In case you only need consensus algorithm with leader election
await raftos.wait_until_leader(current_node)
or
if raftos.get_leader() == current_node:
# make request or respond to a client
or
raftos.configure({
'on_leader': start,
'on_follower': stop
})
Whenever the leader falls, someone takes its place.
Related Skills
node-connect
351.2kDiagnose OpenClaw node connection and pairing failures for Android, iOS, and macOS companion apps
claude-opus-4-5-migration
110.6kMigrate prompts and code from Claude Sonnet 4.0, Sonnet 4.5, or Opus 4.1 to Opus 4.5
frontend-design
110.6kCreate distinctive, production-grade frontend interfaces with high design quality. Use this skill when the user asks to build web components, pages, or applications. Generates creative, polished code that avoids generic AI aesthetics.
model-usage
351.2kUse CodexBar CLI local cost usage to summarize per-model usage for Codex or Claude, including the current (most recent) model or a full model breakdown. Trigger when asked for model-level usage/cost data from codexbar, or when you need a scriptable per-model summary from codexbar cost JSON.
