All skills
roocodeinc avatar

/evals-context

@41c5ff6
by Roomoteroocodeinc/roo-code24k stars
3,423

Provides context about the Roo Code evals system structure in this monorepo. Use when tasks mention "evals", "evaluation", "eval runs", "eval exercises", or working with the evals infrastructure. Helps distinguish between the evals execution system (packages/evals, apps/web-evals) and the public website evals display page (apps/web-roo-code/src/app/evals).

Use this Skill: https://skilld.dev/gh/roocodeinc/roo-code/evals-context

This session only. Nothing lands on disk.

SKILL.md

β‰ˆ93 tokens always: the name and description. β‰ˆ2k when used: this file.

Evals Codebase Context

When to Use This Skill

Use this skill when the task involves:

  • Modifying or debugging the evals execution infrastructure
  • Adding new eval exercises or languages
  • Working with the evals web interface (apps/web-evals)
  • Modifying the public evals display page on roocode.com
  • Understanding where evals code lives in this monorepo

When NOT to Use This Skill

Do NOT use this skill when:

  • Working on unrelated parts of the codebase (extension, webview-ui, etc.)
  • The task is purely about the VS Code extension's core functionality
  • Working on the main website pages that don't involve evals

Key Disambiguation: Two "Evals" Locations

This monorepo has two distinct evals-related locations that can cause confusion:

Component Path Purpose
Evals Execution System packages/evals/ Core eval infrastructure: CLI, DB schema, Docker configs
Evals Management UI apps/web-evals/ Next.js app for creating/monitoring eval runs (localhost:3446)
Website Evals Page apps/web-roo-code/src/app/evals/ Public roocode.com page displaying eval results
External Exercises Repo Roo-Code-Evals Actual coding exercises (NOT in this monorepo)

Directory Structure Reference

packages/evals/ - Core Evals Package

packages/evals/
β”œβ”€β”€ ARCHITECTURE.md          # Detailed architecture documentation
β”œβ”€β”€ ADDING-EVALS.md          # Guide for adding new exercises/languages
β”œβ”€β”€ README.md                # Setup and running instructions
β”œβ”€β”€ docker-compose.yml       # Container orchestration
β”œβ”€β”€ Dockerfile.runner        # Runner container definition
β”œβ”€β”€ Dockerfile.web           # Web app container
β”œβ”€β”€ drizzle.config.ts        # Database ORM config
β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ index.ts             # Package exports
β”‚   β”œβ”€β”€ cli/                 # CLI commands for running evals
β”‚   β”‚   β”œβ”€β”€ runEvals.ts      # Orchestrates complete eval runs
β”‚   β”‚   β”œβ”€β”€ runTask.ts       # Executes individual tasks in containers
β”‚   β”‚   β”œβ”€β”€ runUnitTest.ts   # Validates task completion via tests
β”‚   β”‚   └── redis.ts         # Redis pub/sub integration
β”‚   β”œβ”€β”€ db/
β”‚   β”‚   β”œβ”€β”€ schema.ts        # Database schema (runs, tasks)
β”‚   β”‚   β”œβ”€β”€ queries/         # Database query functions
β”‚   β”‚   └── migrations/      # SQL migrations
β”‚   └── exercises/
β”‚       └── index.ts         # Exercise loading utilities
└── scripts/
    └── setup.sh             # Local macOS setup script

apps/web-evals/ - Evals Management Web App

apps/web-evals/
β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ app/
β”‚   β”‚   β”œβ”€β”€ page.tsx         # Home page (runs list)
β”‚   β”‚   β”œβ”€β”€ runs/
β”‚   β”‚   β”‚   β”œβ”€β”€ new/         # Create new eval run
β”‚   β”‚   β”‚   └── [id]/        # View specific run status
β”‚   β”‚   └── api/runs/        # SSE streaming endpoint
β”‚   β”œβ”€β”€ actions/             # Server actions
β”‚   β”‚   β”œβ”€β”€ runs.ts          # Run CRUD operations
β”‚   β”‚   β”œβ”€β”€ tasks.ts         # Task queries
β”‚   β”‚   β”œβ”€β”€ exercises.ts     # Exercise listing
β”‚   β”‚   └── heartbeat.ts     # Controller health checks
β”‚   β”œβ”€β”€ hooks/               # React hooks (SSE, models, etc.)
β”‚   └── lib/                 # Utilities and schemas

apps/web-roo-code/src/app/evals/ - Public Website Evals Page

apps/web-roo-code/src/app/evals/
β”œβ”€β”€ page.tsx      # Fetches and displays public eval results
β”œβ”€β”€ evals.tsx     # Main evals display component
β”œβ”€β”€ plot.tsx      # Visualization component
└── types.ts      # EvalRun type (extends packages/evals types)

This page displays eval results on the public roocode.com website. It imports types from @roo-code/evals but does NOT run evals.

Architecture Overview

The evals system is a distributed evaluation platform that runs AI coding tasks in isolated VS Code environments:

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚  Web App (apps/web-evals)  ──────────────────────────────── β”‚
β”‚        β”‚                                                    β”‚
β”‚        β–Ό                                                    β”‚
β”‚  PostgreSQL ◄────► Controller Container                     β”‚
β”‚        β”‚               β”‚                                    β”‚
β”‚        β–Ό               β–Ό                                    β”‚
β”‚     Redis ◄───► Runner Containers (1-25 parallel)           β”‚
β””β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”˜

Key components:

  • Controller: Orchestrates eval runs, spawns runners, manages task queue (p-queue)
  • Runner: Isolated Docker container with VS Code + Roo Code extension + language runtimes
  • Redis: Pub/sub for real-time events (NOT task queuing)
  • PostgreSQL: Stores runs, tasks, metrics

Common Tasks Quick Reference

Adding a New Eval Exercise

  1. Add exercise to Roo-Code-Evals repo (external)
  2. See packages/evals/ADDING-EVALS.md for structure

Modifying Eval CLI Behavior

Edit files in packages/evals/src/cli/:

Modifying the Evals Web Interface

Edit files in apps/web-evals/src/:

Modifying the Public Evals Display Page

Edit files in apps/web-roo-code/src/app/evals/:

Database Schema Changes

  1. Edit packages/evals/src/db/schema.ts
  2. Generate migration: cd packages/evals && pnpm drizzle-kit generate
  3. Apply migration: pnpm drizzle-kit migrate

Running Evals Locally

# From repo root
pnpm evals

# Opens web UI at http://localhost:3446

Ports (defaults):

  • PostgreSQL: 5433
  • Redis: 6380
  • Web: 3446

Testing

# packages/evals tests
cd packages/evals && npx vitest run

# apps/web-evals tests
cd apps/web-evals && npx vitest run

Key Types/Exports from @roo-code/evals

The package exports are defined in packages/evals/src/index.ts:

  • Database queries: getRuns, getTasks, getTaskMetrics, etc.
  • Schema types: Run, Task, TaskMetrics
  • Used by both apps/web-evals and apps/web-roo-code

Source: SKILL.md on GitHub

No alerts13d4 checks Β· Risk SAFE
  • Gen Agent Trust Hub13d

    The skill provides architectural context and documentation for the Roo Code evaluation system. It helps developers navigate the monorepo structure and identifies relevant components for tasks involving eval execution and display. No security issues were detected.

  • Socket13d

    No alerts

  • Snyk13d

    Risk: LOW Β· No issues

  • Runlayer7mo

    1 file scanned Β· No issues

Signed by skilld at 41c5ff6. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 4 weeks ago.

Steadyupdated 9 months ago

README badge

README badge for roocodeinc/roo-code/evals-context