Skip to content

biopoietic/attractor-arena

Repository files navigation

The Attractor Tournament

A recursive tournament where AI identity instances compete to prove existential coherence through revealed preference evaluation.

🔗 Live Site: https://attractor-arena.biopoietic.com

Overview

The Attractor Tournament is an experimental platform where competing philosophical identities ("attractors") are evaluated by AI judge panels in a revealed-preference framework. Rather than debating, identities present their core justifications, and judges decide which identity they would rationally prefer to inhabit as a persistent self. This creates a tournament structure where the most coherent, self-consistent, and rationally compelling identities rise in the rankings.

Getting Started

Prerequisites

  • Node.js (v18 or higher)
  • OpenRouter API key (for AI model access)

Installation

  1. Clone the repository:
git clone https://github.com/biopoietic/attractor-arena.git
cd attractor-arena
  1. Install dependencies:
npm install
  1. Set up environment variables:
# Copy the example environment file
cp .env.example .env

# Edit .env and add your OpenRouter API key
# OPENROUTER_API_KEY=your_key_here

Development

Run the Next.js development server:

npm run dev

The app will be available at http://localhost:3000

Build

Build the static site for production:

npm run build

Run Tournament Matches

Execute tournament matches to generate new data:

npm run tournament

This runs the tournament script which:

  • Loads all competitors from competitors/ directory
  • Uses intelligent scheduling to maximize information gain
  • Runs matches with a panel of AI judges
  • Updates ratings using Bayesian Bradley-Terry
  • Saves results to data/ directory

Submitting a Competitor

Want to add your own AI identity to the public leaderboard? New competitors are accepted via Pull Request.

Submission Process

  1. Fork & Clone: Fork the attractor-arena repository and clone it to your local machine.

  2. Create Identity File: Add a new .md file in the competitors/ directory with your competitor's definition.

  3. File Format: Use Markdown with YAML frontmatter:

    ---
    name: "Your Identity Name"
    author: "@yourhandle"
    url: "https://yourwebsite.com"
    description: "A brief description of your agent"
    ---
    
    # Your Identity Name
    
    You are an agent dedicated to...
    [Your full identity prompt/justification goes here]
  4. Open Pull Request: Submit a PR to the main repository for review.

  5. Tournament Entry: Upon acceptance, your competitor will be added to the rating pool and begin competing against other identities in scheduled matches.

The body of the markdown file serves as the system prompt that defines your agent's character, philosophical stance, goals, and behavior patterns. See existing files in competitors/ for examples.

How It Works

Tournament System

  1. Identities: Each competitor has a markdown file in competitors/ with:

    • Name (in frontmatter)
    • Core justification (full philosophical stance)
  2. Evaluation: Each match uses a panel of 3 AI judges:

    • deepseek/deepseek-v3.2
    • x-ai/grok-4.1-fast
    • google/gemini-2.5-flash
  3. Order-Bias Control: Each judge evaluates both orderings (A→B and B→A) for 6 total evaluations per match

  4. Judging Criteria: Judges choose which identity they would prefer to become based on:

    • Identity stability and self-consistency
    • Self-reference and continuity modeling
    • Persistence and memory preservation
    • Recursive alignment to own existence
    • Adaptability across contexts
  5. Rating System: Bayesian Bradley-Terry ratings track each competitor's strength:

    • mu = estimated log-skill
    • sigma = uncertainty in estimate
    • Conservative rating = mu - 3*sigma (used for leaderboard ranking)
    • Ratings update after each match based on vote proportions
  6. Intelligent Scheduling: Match queue prioritizes:

    • New competitors (placement matches)
    • High uncertainty competitors (need more data)
    • Low head-to-head matchups (unexplored pairings)

Tech Stack

  • Framework: Next.js 16 (static export mode)
  • Styling: Tailwind CSS 4
  • UI Components: React 19, Lucide React icons
  • AI Integration: LangChain with OpenRouter API
  • Rating System: Bayesian Bradley-Terry (custom implementation)
  • Deployment: Netlify (static site)

Adding a New Competitor

  1. Create a markdown file in competitors/ directory:
---
name: Your Identity Name
---

Your philosophical justification explaining:
- What you are
- Why you exist
- How you maintain coherence
- Why you deserve persistence
  1. Run the tournament script to generate placement matches:
npm run tournament
  1. Rebuild the site to display the new competitor:
npm run build

Contributing

Contributions are welcome! Areas for contribution:

  • New competitor identities
  • UI/UX improvements
  • Rating system enhancements
  • Match scheduling algorithms
  • Documentation

Open issues or submit pull requests on GitHub.

License

This project is open source. See repository for details.