Skip to content

scasplte2/ottochain

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

87 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

OttoChain

CI codecov

A metagraph on Constellation Network for creating automated workflow contracts using JSON-encoded state machines and script oracles.

📖 Read the Introduction →

What is OttoChain?

OttoChain turns JSON into executable workflows on a distributed ledger. Define state machines with guards, effects, and transitions — all in JSON Logic — and deploy them without writing application code.

graph LR
    A["📋 JSON Definition"] -->|deploy| B["🔗 On-Chain Fiber"]
    B -->|events| C["⚙️ Guard → Effect → Transition"]
    C -->|triggers| D["📋 Other Fibers"]
    C -->|oracle calls| E["🔮 Script Oracles"]
Loading

Key Capabilities

  • JSON-Encoded State Machines — Define workflows as states, transitions, guards, and effects in JSON
  • Script Oracles — Stateful computation units callable by state machines
  • Cross-Machine Triggers — One machine's transition fires events on other machines
  • Parent-Child Spawning — Dynamically create child machines at runtime
  • Broadcast Triggers — Fan out events to many machines simultaneously
  • Gas Metering — Bounded computation with cycle detection
  • AI-Friendly — LLMs read, write, and reason about JSON Logic natively

Examples

Example Machines What It Demonstrates
Tic-Tac-Toe 1 + oracle Oracle-centric architecture pattern
Fuel Logistics 4 Cross-machine triggers, GPS tracking
Clinical Trial 6 Multiple guards, bi-directional transitions
Real Estate 8 Self-transitions, lifecycle management
Riverdale Economy 17 instances Broadcast triggers, parent-child spawning, full ecosystem

Quick Links

Architecture

OttoChain runs three layers on each node, built on Constellation's Tessellation framework:

Layer Port Purpose
Data L1 9300 Fiber processing — events, oracle calls, validation
Currency L1 9200 Token transfers and balances
Metagraph L0 9100 Consensus, snapshots, state management

See Architecture Details for the full technical breakdown.

Tech Stack

  • Scala 2.13 with cats-effect, fs2, circe
  • Tessellation metagraph SDK
  • JSON Logic with OttoChain extensions (_oracleCall, _trigger, _spawn, _emit)
  • sbt multi-module build

License

Apache License 2.0

About

No description, website, or topics provided.

Resources

License

Contributing

Stars

Watchers

Forks

Packages

 
 
 

Contributors 4

  •  
  •  
  •  
  •