Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions xtuner/v1/rl/agent_loop/sandbox_agent_loop/sandbox.py
Original file line number Diff line number Diff line change
Expand Up @@ -939,6 +939,8 @@ async def _acquire_ready(self, spec: SandboxSpec, *, record: StageRecord | None
record.metadata["sandbox_create_attempts"] = attempt
try:
create_kwargs: dict[str, Any] = {}
if spec.cluster_name:
create_kwargs["cluster_name"] = spec.cluster_name
if spec.key:
create_kwargs["key"] = spec.key
if spec.env_vars:
Expand Down
1 change: 1 addition & 0 deletions xtuner/v1/rl/agent_loop/sandbox_agent_loop/schemas.py
Original file line number Diff line number Diff line change
Expand Up @@ -229,6 +229,7 @@ class SandboxSpec(BaseModel):
env_vars: dict[str, str] = Field(default_factory=dict)
resources: dict[str, Any] = Field(default_factory=dict)
key: str | None = None
cluster_name: str | None = None


class AgentSpec(BaseModel):
Expand Down
Loading