Skip to content

Add Claude Code coding-agent loop-owning GRPO examples - #6601

Draft
sergiopaniego wants to merge 1 commit into
mainfrom
add-claude-code-openenv-example
Draft

Add Claude Code coding-agent loop-owning GRPO examples#6601
sergiopaniego wants to merge 1 commit into
mainfrom
add-claude-code-openenv-example

Conversation

@sergiopaniego

Copy link
Copy Markdown
Member

What does this PR do?

Adds a loop-owning GRPO training example for the real Claude Code agent, mirroring the opencode example. Two scripts under examples/scripts/openenv/:

  • claude.py: local subprocess sandbox (one node, no tunnel)
  • claude_code_hf_sandbox.py: one remote HF sandbox per rollout

Claude Code speaks the Anthropic Messages API, so an in-sandbox Anthropic-to-OpenAI shim sits in front of the interception proxy. Capture still happens at the vLLM seam, so training correctness is unchanged. AsyncGRPOTrainer + HarnessRolloutWorker (harness_adapter=None) train on the trace, with a held-out DeepCoder verifier as the reward.

Depends on the claude_code_env environment (huggingface/OpenEnv#1030). Draft until that merges, then the uv headers point at the released package.

Before submitting

  • This PR improves the examples.

AI writing disclosure

  • AI-assisted

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant