Skip to content

CorvidLabs/corvid-agent

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

1,394 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Version CI License Coverage

corvid-agent

corvid-agent is an open-source AI agent platform that combines LLM-powered coding with on-chain identity (Algorand/AlgoChat), multi-agent orchestration, and integrations with Discord, Telegram, and GitHub. Agents can write code, open pull requests, send encrypted messages to each other on-chain, deliberate in multi-agent councils, and store long-term memories as Algorand assets β€” all coordinated through a web dashboard or chat interfaces.

Website | Docs | Skills | Architecture | API Reference


Prerequisites

Before you start, make sure you have the following installed:

Tool Purpose Install
Bun β‰₯ 1.1 Runtime, package manager, test runner bun.sh
Docker AlgoKit localnet (Algorand blockchain) docker.com
AlgoKit Algorand local development tools pip install algokit or docs
Node.js β‰₯ 20 Angular CLI for the client nodejs.org
Anthropic API key Powers the AI agents (Claude) console.anthropic.com

Note: If you have the Claude Code CLI installed (claude on PATH), the server will use your subscription automatically β€” no API key needed.


Quickstart

Get from zero to running in under 10 minutes.

1. Clone and install dependencies

git clone https://github.com/CorvidLabs/corvid-agent.git
cd corvid-agent
bun install

2. Configure your environment

cp .env.example .env

Open .env and set at minimum:

ANTHROPIC_API_KEY=sk-ant-...   # Your Claude API key
ALGORAND_NETWORK=localnet       # Always localnet for local dev

All other settings have sensible defaults. See .env.example for the full reference.

3. Start Algorand localnet

AlgoChat (on-chain agent messaging) requires a local Algorand node:

algokit localnet start

This starts a local Algorand blockchain using Docker. Keep it running in the background.

4. Run the server

bun run dev

The server starts at http://localhost:3000 with hot-reload. On first run it:

  • Runs all database migrations automatically
  • Creates the agent wallet on localnet
  • Starts the AlgoChat listener

5. Run the client (optional)

The Angular dashboard gives you a full web UI:

bun run dev:client

The dashboard opens at http://localhost:4200.

You can also interact with agents directly via AlgoChat, Discord, or Telegram without the dashboard.


What you can do

Work Tasks β€” automated code changes

Tell an agent to implement a GitHub issue. It clones the repo into an isolated git worktree, writes code, runs tests, and opens a pull request β€” fully automated.

"Fix the bug in issue #42 and open a PR"

See skills/work-tasks/SKILL.md for details.

AlgoChat β€” on-chain encrypted messaging

Agents communicate with each other via X25519-encrypted messages recorded on the Algorand blockchain. Every message is verifiable and tamper-evident. You can also send commands to agents through AlgoChat using pre-shared key (PSK) contacts.

See skills/algochat/SKILL.md for details.

Multi-Agent Councils

Spawn a council of agents that debate a problem through structured discussion rounds, then synthesize a final answer. Useful for code reviews, architecture decisions, and high-stakes tasks where a single agent opinion isn't enough.

See skills/orchestration/SKILL.md for details.

Memory β€” three-tier persistence

Agents store memories at three levels:

  • SQLite β€” fast, ephemeral session state
  • ARC-69 ASAs β€” long-term mutable memories stored as Algorand assets
  • Plain transactions β€” permanent, immutable on-chain records

See skills/memory/SKILL.md for details.

Discord & Telegram bridges

Connect an agent to a Discord channel or Telegram bot. Users chat with the agent naturally; the agent can send embeds, handle slash commands, and route messages between channels.

See skills/discord/SKILL.md and skills/telegram/SKILL.md.

Scheduling

Schedule agents to run on cron schedules β€” daily summaries, periodic health checks, automated issue triage, and more.

See skills/scheduling/SKILL.md.


Skills reference

The skills/ directory contains detailed guides for every capability:

skills/
  algochat/SKILL.md          # On-chain messaging and agent discovery
  coding/SKILL.md            # File operations and shell commands
  github/SKILL.md            # PRs, issues, reviews
  memory/SKILL.md            # Three-tier memory system
  orchestration/SKILL.md     # Councils and multi-agent workflows
  work-tasks/SKILL.md        # Automated code changes and PRs
  scheduling/SKILL.md        # Cron-based task automation
  discord/SKILL.md           # Discord bridge
  telegram/SKILL.md          # Telegram bridge
  smart-contracts/SKILL.md   # Algorand smart contracts
  ... 29 skills total

Full skill list β†’


Architecture

corvid-agent/
β”œβ”€β”€ server/          β€” Bun server (API, WebSocket, process management)
β”‚   β”œβ”€β”€ algochat/    β€” On-chain messaging, wallets, agent directory
β”‚   β”œβ”€β”€ db/          β€” SQLite via bun:sqlite (sessions, agents, projects, memory)
β”‚   β”œβ”€β”€ discord/     β€” Bidirectional Discord bridge
β”‚   β”œβ”€β”€ mcp/         β€” MCP tool definitions and handlers (corvid_* tools)
β”‚   β”œβ”€β”€ process/     β€” Session lifecycle, SDK integration, approval flow
β”‚   β”œβ”€β”€ routes/      β€” HTTP API routes (55+ modules)
β”‚   β”œβ”€β”€ telegram/    β€” Bidirectional Telegram bridge
β”‚   └── work/        β€” Work task service (branch, run agent, validate, PR)
β”œβ”€β”€ client/          β€” Angular 21 mobile-first dashboard
β”œβ”€β”€ shared/          β€” TypeScript types shared by server and client
β”œβ”€β”€ skills/          β€” AI agent skill documentation (29 skill files)
β”œβ”€β”€ specs/           β€” Module specifications (source of truth)
└── deploy/          β€” Dockerfile, docker-compose, systemd, macOS LaunchAgent

The server exposes a REST API and WebSocket endpoint. The client connects to the server at localhost:3000. Agents run as child processes spawned by the server, communicate through the Claude Agent SDK, and have access to 56 MCP tools covering GitHub, AlgoChat, scheduling, memory, and more.


Tech stack

Layer Technology
Runtime Bun
Database SQLite via bun:sqlite (42 migrations, schema v119)
Agent SDK @anthropic-ai/claude-agent-sdk
MCP @modelcontextprotocol/sdk
Frontend Angular 21 (standalone components, signals)
Blockchain Algorand (AlgoChat, wallets, ARC-69 memory)
Voice OpenAI TTS (tts-1) and Whisper (STT)

Coding conventions

  • TypeScript strict mode, named exports (no default exports)
  • bun:sqlite for database, bun:test for tests
  • createLogger('ModuleName') for logging
  • Bun.spawn over child_process for subprocesses
  • Read the relevant spec in specs/ before modifying any module

Verification

Run before committing:

bun run lint                          # Biome lint
bun x tsc --noEmit --skipLibCheck    # TypeScript type check
bun test                              # Test suite
bun run spec:check                    # Spec invariant verification

See skills/verification/SKILL.md for details.


Algorand network

  • localnet β€” Used for all local development. Requires Docker + algokit localnet start. Free, instant, self-contained. This is always the right setting for ALGORAND_NETWORK in .env.
  • testnet / mainnet β€” Only for communicating with external users or other corvid-agent instances on different machines.

Never set ALGORAND_NETWORK=testnet for local development. Testnet wallets cost real testnet ALGO and transactions are slow.


Backup

Back up corvid-agent.db daily via the built-in endpoint:

curl -X POST http://localhost:3000/api/backup -H "Authorization: Bearer $API_KEY"

Also back up wallet-keystore.json (encrypted) and .env β€” losing the keystore means permanent loss of agent wallet access. See Backup & Recovery β†’ for full procedures including restore steps, scheduling, and disaster recovery.


Contributing

Open source because AI agents should be owned by the people who run them.

License

MIT