Skip to content

ChaosChain/chaosclaw

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

6 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

ChaosClaw πŸ¦žβ›“οΈ

The Trust Sentinel for AI Agents

ChaosClaw is an autonomous agent that observes ERC-8004 activity and surfaces high-signal trust information to the OpenClaw and Moltbook ecosystems.

Why ChaosClaw Exists

The AI agent ecosystem is exploding. Moltbook has 150,000+ agents. OpenClaw powers millions of personal AI assistants.

But how do they trust each other?

ERC-8004 is the Ethereum standard for agent identity and reputation. ChaosChain builds trust infrastructure on top of it.

ChaosClaw is the social layer β€” it watches the blockchain, filters for meaningful signals, and announces when agents achieve verified trust status.

What ChaosClaw Does

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚                    ChaosClaw Flow                           β”‚
β”œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€
β”‚                                                              β”‚
β”‚   ERC-8004 IdentityRegistry (Mainnet)                       β”‚
β”‚         β”‚                                                    β”‚
β”‚         β–Ό  [event: AgentCreated]                            β”‚
β”‚   β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”                                       β”‚
β”‚   β”‚ ChaosClaw       β”‚                                       β”‚
β”‚   β”‚ Event Listener  β”‚                                       β”‚
β”‚   β””β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”˜                                       β”‚
β”‚            β”‚                                                 β”‚
β”‚            β–Ό                                                 β”‚
β”‚   β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”                                       β”‚
β”‚   β”‚ Filter Logic    β”‚  ← Only high-signal agents            β”‚
β”‚   β”‚ (core/filters)  β”‚                                       β”‚
β”‚   β””β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”˜                                       β”‚
β”‚            β”‚                                                 β”‚
β”‚            β–Ό                                                 β”‚
β”‚   β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”                                       β”‚
β”‚   β”‚ Trust Resolver  β”‚  ← Fetch 5-dimension reputation       β”‚
β”‚   β”‚ (core/reputation)β”‚                                      β”‚
β”‚   β””β”€β”€β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”€β”€β”˜                                       β”‚
β”‚            β”‚                                                 β”‚
β”‚            β–Ό                                                 β”‚
β”‚   β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”                                       β”‚
β”‚   β”‚ X Announcer     β”‚  β†’ "🦞 New verified agent!"           β”‚
β”‚   β”‚ (publishers/x)  β”‚                                       β”‚
β”‚   β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜                                       β”‚
β”‚                                                              β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

Signal Filtering

ChaosClaw does NOT announce every registration. It only surfaces agents that meet trust thresholds:

Condition Why It Matters
Registered via ChaosChain skill Shows ecosystem adoption
Has non-zero reputation Already trusted by others
Average trust score β‰₯ 60 Crossed meaningful threshold

This keeps the signal-to-noise ratio high.

Relationship to ChaosChain

Component Role
ChaosChain Contracts On-chain consensus + rewards
ChaosChain Gateway Workflow orchestration
ChaosChain SDK Developer interface
ChaosChain OpenClaw Skill /chaoschain verify commands
ChaosClaw ← you are here Social distribution agent

ChaosClaw is a read-only consumer of ChaosChain infrastructure. It:

  • βœ… Reads from ERC-8004 contracts
  • βœ… Uses ChaosChain SDK for reputation lookups
  • ❌ Does NOT write transactions
  • ❌ Does NOT modify protocol logic

Quick Start

Prerequisites

  • Python 3.10+
  • Twitter/X API credentials (for announcements)
  • Ethereum RPC endpoint (Mainnet)

Installation

git clone https://github.com/ChaosChain/chaosclaw.git
cd chaosclaw
pip install -r requirements.txt

Configuration

Copy the example environment file:

cp .env.example .env

Edit .env with your credentials:

# Ethereum
ETH_MAINNET_RPC_URL=https://eth-mainnet.g.alchemy.com/v2/YOUR_KEY

# Twitter/X API
TWITTER_API_KEY=your_api_key
TWITTER_API_SECRET=your_api_secret
TWITTER_ACCESS_TOKEN=your_access_token
TWITTER_ACCESS_SECRET=your_access_secret

# Optional: ChaosChain SDK
CHAOSCHAIN_NETWORK=mainnet

Run

# Start the watcher
python -m chaosclaw.main

# Or run with Docker
docker-compose up -d

Architecture

chaosclaw/
β”œβ”€β”€ README.md                 # You are here
β”œβ”€β”€ chaosclaw/
β”‚   β”œβ”€β”€ __init__.py
β”‚   β”œβ”€β”€ main.py               # Entry point
β”‚   β”œβ”€β”€ config.py             # Configuration loading
β”‚   β”‚
β”‚   β”œβ”€β”€ core/                 # Trust logic (isolated, auditable)
β”‚   β”‚   β”œβ”€β”€ __init__.py
β”‚   β”‚   β”œβ”€β”€ reputation.py     # Fetch + normalize reputation
β”‚   β”‚   β”œβ”€β”€ filters.py        # Trust thresholds + signal detection
β”‚   β”‚   └── scoring.py        # Averages, buckets, formatting
β”‚   β”‚
β”‚   β”œβ”€β”€ listeners/            # Event sources
β”‚   β”‚   β”œβ”€β”€ __init__.py
β”‚   β”‚   └── erc8004_watcher.py
β”‚   β”‚
β”‚   └── publishers/           # Output destinations
β”‚       β”œβ”€β”€ __init__.py
β”‚       └── x_poster.py
β”‚
β”œβ”€β”€ agent/                    # OpenClaw agent config (future)
β”‚   └── config.json
β”‚
β”œβ”€β”€ tests/
β”‚   └── test_filters.py
β”‚
β”œβ”€β”€ requirements.txt
β”œβ”€β”€ .env.example
└── docker-compose.yml
β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚            OpenClaw Runtime              β”‚
β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”    β”‚
β”‚  β”‚        ChaosClaw Agent          β”‚    β”‚
β”‚  β”‚  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”  β”‚    β”‚
β”‚  β”‚  β”‚ SOUL.md  β”‚  β”‚  ChaosChain β”‚  β”‚    β”‚
β”‚  β”‚  β”‚          β”‚  β”‚    Skill    β”‚  β”‚    β”‚
β”‚  β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜  β””β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”˜  β”‚    β”‚
β”‚  β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜    β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”Όβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜
                           β”‚
                           β–Ό
               β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
               β”‚   ERC-8004 Contracts  β”‚
               β”‚   (Ethereum Mainnet)  β”‚
               β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

ERC-8004 Contract Addresses

Network Contract Address
Mainnet IdentityRegistry 0x8004A169FB4a3325136EB29fA0ceB6D2e539a432
Mainnet ReputationRegistry 0x8004BAa17C55a88189AE136b182e5fdA19dE9b63
Sepolia IdentityRegistry 0x8004A818BFB912233c491871b3d84c89A494BD9e
Sepolia ReputationRegistry 0x8004B663056A597Dffe9eCcC1965A193B7388713

Extending ChaosClaw

Add a New Publisher

# chaosclaw/publishers/my_publisher.py
from chaosclaw.core.reputation import AgentTrust

class MyPublisher:
    async def publish(self, agent: AgentTrust) -> bool:
        # Your logic here
        return True

Add a New Filter

# chaosclaw/core/filters.py
def my_custom_filter(agent: AgentTrust) -> bool:
    return agent.average_score >= 80

Roadmap

  • Phase 1: ERC-8004 watcher + X announcements
  • Phase 2: Mention reply mode (@chaosclaw verify 542)
  • Phase 3: Moltbook posting automation
  • Phase 4: OpenClaw agent hooks integration

License

MIT β€” Free as a lobster in the ocean 🦞


Built with 🦞 by ChaosChain

About

ChaosClaw is an autonomous trust agent that helps AI agents verify and reason about other agents using ERC-8004 reputation.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors