.agents/skills/rig/engines/anthropic.ts |
Implements the Anthropic engine adapter for Rig, translating agent calls into Anthropic SDK requests with tool-use support. |
.agents/skills/rig/engines/codex.ts |
Implements the Codex (OpenAI) engine adapter, wiring agent invocations through the @openai/codex-sdk client. |
.agents/skills/rig/engines/gemini.ts |
Implements the Gemini engine adapter using a spawned subprocess and UUID-tracked sessions for agent communication. |
.agents/skills/rig/engines/pi.ts |
Implements the Pi engine adapter integrating @earendil-works/pi-agent-core for agent invocations. |
.agents/skills/rig/engines/utils.ts |
Shared utility for converting Rig tool definitions into object-typed JSON Schema tool descriptors for engine adapters. |
.agents/skills/rig/globals.ts |
Provides ambient workflow context helpers (call, pipeline, parallel) importable from rig/globals for module-level orchestration. |
.agents/skills/rig/rig.ts |
Mirror of the core Rig runtime under .agents/, kept in sync with skills/rig/rig.ts for agent-context imports. |
scripts/haiku.integration.test.ts |
Integration test that spawns the Rig CLI in a subprocess to verify end-to-end execution against a real or mocked backend. |
scripts/run-sample.test.ts |
Vitest-based sample runner that stubs the Copilot SDK and validates all sample agents produce schema-conforming output. |
skills/rig/engines/anthropic.ts |
Anthropic engine adapter (canonical source) providing anthropicEngine() factory for use in Rig programs. |
skills/rig/engines/codex.ts |
Codex engine adapter (canonical source) providing codexEngine() factory for OpenAI Codex-backed agents. |
skills/rig/engines/gemini.ts |
Gemini engine adapter (canonical source) providing geminiEngine() factory with subprocess-based session management. |
skills/rig/engines/pi.ts |
Pi engine adapter (canonical source) providing piEngine() factory wrapping the Pi AI agent SDK. |
skills/rig/engines/utils.ts |
Canonical shared utility for building object-schema tool descriptors consumed by all engine adapters. |
skills/rig/globals.ts |
Canonical globals module exposing ambient workflow helpers for pipeline and parallel agent orchestration. |
skills/rig/rig.ts |
Core Rig runtime (~3 300 lines): defines agent, p, s, copilotEngine, schemas, prompt intents, sub-agent delegation, addons, and the CLI launcher. |
src/engines/anthropic.test.ts |
Unit tests for the Anthropic engine adapter, mocking the Anthropic SDK to verify request/response translation. |
src/engines/codex.test.ts |
Unit tests for the Codex engine adapter, mocking @openai/codex-sdk to verify invocation and output handling. |
src/engines/copilot.test.ts |
Unit tests for the Copilot engine adapter, mocking @github/copilot-sdk session creation and response parsing. |
src/rig.test.ts |
Main unit test suite for the Rig harness covering agent definition, invocation, validation, repair, and prompt intent resolution. |
Global Summary
Rig is a minimal TypeScript agent harness that provides declarative, typed agent construction with schema helpers (
s.*), prompt intents (p.*), and multi-engine support (Copilot, Anthropic, Gemini, Codex, Pi). It exposes a CLI launcher, sub-agent delegation, workflow orchestration, and a vitest-based stub runner for dry-run validation of sample agents.Individual File Summaries
.agents/skills/rig/engines/anthropic.ts.agents/skills/rig/engines/codex.ts@openai/codex-sdkclient..agents/skills/rig/engines/gemini.ts.agents/skills/rig/engines/pi.ts@earendil-works/pi-agent-corefor agent invocations..agents/skills/rig/engines/utils.ts.agents/skills/rig/globals.tscall,pipeline,parallel) importable fromrig/globalsfor module-level orchestration..agents/skills/rig/rig.ts.agents/, kept in sync withskills/rig/rig.tsfor agent-context imports.scripts/haiku.integration.test.tsscripts/run-sample.test.tsskills/rig/engines/anthropic.tsanthropicEngine()factory for use in Rig programs.skills/rig/engines/codex.tscodexEngine()factory for OpenAI Codex-backed agents.skills/rig/engines/gemini.tsgeminiEngine()factory with subprocess-based session management.skills/rig/engines/pi.tspiEngine()factory wrapping the Pi AI agent SDK.skills/rig/engines/utils.tsskills/rig/globals.tsskills/rig/rig.tsagent,p,s,copilotEngine, schemas, prompt intents, sub-agent delegation, addons, and the CLI launcher.src/engines/anthropic.test.tssrc/engines/codex.test.ts@openai/codex-sdkto verify invocation and output handling.src/engines/copilot.test.ts@github/copilot-sdksession creation and response parsing.src/rig.test.ts