AI-Assisted Development#
AReaL ships with first-class configurations for Codex, OpenCode, and Claude Code. The repository includes shared project instructions, domain expert agents, and reusable implementation skills so the three harnesses stay aligned.
This page treats Codex as the canonical harness for repo-local workflows. OpenCode and Claude Code remain supported compatibility layers.
Codex#
Start a Codex session#
cd /path/to/AReaL
codex
Codex reads project context from AGENTS.md. In this repository, the Codex harness is
organized around:
Project instructions:
AGENTS.mdRepo-local skills:
.agents/skills/<name>/SKILL.mdCustom agents:
.codex/config.tomlplus.codex/agents/<name>.tomland.codex/agents/<name>.md
Custom agents are registered in .codex/config.toml and point at per-agent TOML files:
[agents.fsdp-expert]
description = "FSDP2 expert for configuration, parallel strategy, weight sync, and integration guidance."
config_file = "./agents/fsdp-expert.toml"
Each agent TOML then points at its markdown instructions file:
name = "fsdp-expert"
model_instructions_file = "./fsdp-expert.md"
Directly executable Codex workflows#
In AReaL, the directly executable Codex workflows are repo-local skills under
.agents/skills/. Codex does not use / commands here as its primary workflow surface.
Instead, you ask Codex to use the matching skill and carry out the workflow end to end.
Skill |
Purpose |
|---|---|
|
Add a new dataset loader under |
|
Create a new |
|
Implement a new reward function |
|
Add a new model architecture to the Archon engine |
|
Add or extend unit tests |
|
Troubleshoot hangs, OOMs, NCCL issues, and launcher misconfig |
|
Prepare a Conventional Commit message before committing |
|
Run the read-only PR review workflow with risk analysis |
|
Rebase, squash, prepare metadata, and create or update a GitHub PR |
|
Translate |
|
Update runtime image dependencies and drive the Docker PR flow |
|
Audit and upgrade Megatron-Core compatibility |
|
Audit and upgrade vLLM compatibility |
These skills are the answer to “what is Codex’s directly executable workflow in this repository?”.
Custom Codex agents#
Codex custom agents are specialized consultants registered in .codex/config.toml.
Unlike OpenCode’s automatic expert routing, Codex agents are an explicit tool surface:
ask Codex to consult the relevant agent, or rely on repository instructions that tell it
when to do so.
Agent |
Purpose |
|---|---|
|
Plan multi-file work and architectural changes |
|
Perform quick post-change risk checks |
|
Run targeted formatting, lint, and verification commands |
|
FSDP2 configuration, parallel strategy, and weight sync guidance |
|
Archon and MoE integration guidance |
|
Megatron pipeline parallel training guidance |
|
PPO, GRPO, DAPO, reward shaping, and RL workflow guidance |
|
Local, Ray, Slurm, and inference launcher guidance |
Typical Codex sessions#
> Add a new rollout workflow for multimodal evaluation
Codex: [loads add-workflow, inspects areal/workflow/, implements changes]
> Review this PR
Codex: [loads review-pr, analyzes the diff, consults the matching expert agents]
> Create or update the PR
Codex: [loads create-pr, checks branch state, prepares the PR workflow]
OpenCode Compatibility#
Install OpenCode and oh-my-opencode#
curl -fsSL https://opencode.ai/install | bash
Alternative methods: brew install anomalyco/tap/opencode,
npm install -g opencode-ai, or a release binary from GitHub. See the OpenCode docs for
current install details.
oh-my-opencode remains optional, but useful if you want richer OpenCode orchestration and tool integrations.
Start OpenCode#
cd /path/to/AReaL
opencode
OpenCode reads AGENTS.md and discovers agents, commands, skills, and plugins from
.opencode/. It can also read .claude/skills/ where relevant.
OpenCode workflow surface#
OpenCode keeps its own command and agent system:
Command |
Purpose |
|---|---|
|
Rebase, squash commits, and create PR |
|
Intelligent code review with risk analysis |
|
Translate English documentation to Chinese |
OpenCode-specific assets live in .opencode/agents/, .opencode/command/,
.opencode/skills/, and .opencode/package.json.
Claude Code Compatibility#
Claude Code remains supported through CLAUDE.md plus the .claude/ directory for
agents, commands, hooks, and rules.
Configuration Files#
AReaL/
|-- AGENTS.md # Project context (loaded automatically)
|-- .agents/
| +-- skills/ # Codex repo-local skills
|-- .codex/
| |-- config.toml # Registers custom Codex subagents
| +-- agents/ # Codex agent config files and instruction markdown
|-- .opencode/
| |-- agents/ # OpenCode expert agents
| |-- command/ # OpenCode slash commands
| |-- skills/ # OpenCode skills
| +-- package.json # OpenCode plugin dependencies
+-- .claude/
|-- agents/ # Claude Code agents
|-- commands/ # Claude Code commands
|-- hooks/ # Claude Code hooks
+-- rules/ # Claude Code rules
Harness Comparison#
AReaL supports all three harnesses, but each one exposes reusable workflows differently:
Concept |
Codex |
OpenCode |
Claude Code |
|---|---|---|---|
Project context |
|
|
|
Repo workflows |
|
|
|
Custom subagents |
|
|
|
Primary executable workflow form |
Repo-local skill |
Slash command or skill |
Slash command or skill |
Agent dispatch |
Explicit custom agent invocation |
|
Automatic routing |
Expert names |
|
|
|
Commit helper |
|
|
|
Claude Code also ships with additional general-purpose agents:
Agent |
Purpose |
|---|---|
|
Creates implementation plans before complex multi-file changes |
|
Runs pre-commit hooks and tests after code changes |
|
Performs quick code quality checks before commits |
Claude Code configuration lives in:
AReaL/
|-- CLAUDE.md # Project context and constraints
+-- .claude/
|-- agents/ # 5 domain experts + 3 general-purpose (8 total)
|-- skills/ # Guided workflows (shared with OpenCode)
|-- commands/ # Automated actions (create-pr, gen-commit-msg, review-pr)
|-- hooks/ # Pre/post action hooks
+-- rules/ # Code quality standards
Contributing#
We welcome contributions to both the codebase and AI development configurations:
Code contributions: New features, bug fixes, documentation improvements
AI config contributions: New Codex skills, custom agents, or compatibility-layer improvements
Codex configs: Edit
.codex/,.agents/, andAGENTS.mdOpenCode configs: Edit files in
.opencode/Claude Code configs: Edit files in
.claude/
See CONTRIBUTING.md for guidelines.