https://github.com/haha-systems/arachne
Research platform for building and observing large societies of interacting AI agents, with a shared DSL (Silk) and built‑in tools for resilience and emergent‑behaviour experiments.
https://github.com/haha-systems/arachne
agents contract-net-protocol dsl llms silk zeromq zig
Last synced: about 1 month ago
JSON representation
Research platform for building and observing large societies of interacting AI agents, with a shared DSL (Silk) and built‑in tools for resilience and emergent‑behaviour experiments.
- Host: GitHub
- URL: https://github.com/haha-systems/arachne
- Owner: haha-systems
- License: mit
- Created: 2025-10-25T17:53:19.000Z (8 months ago)
- Default Branch: main
- Last Pushed: 2026-05-17T18:27:55.000Z (about 1 month ago)
- Last Synced: 2026-05-17T20:42:49.697Z (about 1 month ago)
- Topics: agents, contract-net-protocol, dsl, llms, silk, zeromq, zig
- Language: Zig
- Homepage:
- Size: 541 KB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- License: LICENSE
- Roadmap: docs/ROADMAP.md
- Agents: AGENTS.md
Awesome Lists containing this project
README
# Arachne
> Arachne weaves in Silk.
**Arachne** is a frontier research project exploring distributed, self-regulating machine intelligence. Agents are written in **Silk**, a purpose-built DSL for autonomous systems. Silk provides first-class support for the contract-net protocol, message passing, allostatic regulation, self-models, and bounded self-rewrite.
The goal is not to build a mirror of humanity, but to explore whether machine intelligence can become a new kind of other — with strong ethical safeguards from the start.
## Overview
**Arachne** is the project, framework, and multi-agent runtime.
**Silk** is the DSL in which agents are written (`.silk` files).
Silk is a specialized programming language designed for implementing intelligent agents that coordinate through auctions and message passing. Built with Zig for performance and type safety, Silk provides agent-first constructs for capabilities, policies, actions, and the contract-net protocol.
### Key Features
- **Agent-First Design**: Built-in constructs for capabilities, state, policies, and actions
- **Contract-Net Protocol**: Native support for auction-based task allocation and coordination
- **Type-Safe**: Strong typing with inference for reliability and performance
- **High Performance**: Built with Zig, no garbage collection overhead
- **Message Passing**: Integrated support for ZeroMQ and other transport protocols
- **Policy/Action Separation**: Clean separation between decision-making and execution
- **Observability**: Enterprise-grade tracing and logging support
- **Arena Allocation**: Efficient memory management for agent runtime
## Quick Start
### Prerequisites
- [Zig](https://ziglang.org/) 0.15.2 or higher
- [mise](https://mise.jdx.dev/) (optional, for version management)
### Installation
1. Clone the repository:
```bash
git clone https://github.com/haha-systems/arachne
cd arachne
```
2. Build the project:
```bash
zig build
```
3. Run tests to verify installation:
```bash
zig build test
```
### Your First Silk Agent
Create a simple agent that responds to messages:
```silk
// Define agent capabilities
capability "example.responder" {
topics = ["tasks.simple"]
latency <= 1000ms
quality >= 0.8
tools = ["zmq"]
}
// Agent state
state message_count = 0
// Initialize the agent
handle initialize(ctx) {
zmq.log("info", "Agent initialized", {agent_id: ctx.agent_id})
}
// Handle incoming messages
handle process_message(msg) {
message_count = message_count + 1
zmq.log("info", "Processing message", {
count: message_count,
content: msg.content
})
return {
status: "success",
processed: message_count
}
}
// Policy for deciding whether to bid on tasks
policy should_bid(stimulus) {
// Bid if we have capacity and the task matches our capabilities
if message_count < 100 {
return {
bid: true,
confidence: 0.9,
estimated_cost: 50ms
}
} else {
return {bid: false}
}
}
// Action to execute when assigned a task
act execute_task(task) {
let result = process_task(task)
yield result
}
// Learn from task outcomes
learn update_model(outcome) {
if outcome.success {
// Increase confidence for similar tasks
zmq.log("info", "Task successful, updating model")
}
}
```
Run your agent:
```bash
zig build run -- agents/your_agent.silk
```
## Documentation
- **[Covenant](docs/COVENANT.md)**: Ethical framework and commitments
- **[Roadmap](docs/ROADMAP.md)**: Research trajectory and milestones
- **[Manifesto](docs/MANIFESTO.md)**: Project philosophy and intent
- **[Language Reference](docs/SILK_REFERENCE.md)**: Complete Silk language specification
## Project
Built by an independent researcher. Hosted at [arachne.haha.systems](https://arachne.haha.systems).
Organisation: [haha.systems](https://haha.systems)
---
**Note**: Arachne is in early development. APIs and language features are subject to change.