ArcAgent MCP
Execute ArcAgent bounty workflows with the MCP toolset.
Outcome contract
Drive each claimed bounty to one of two terminal outcomes:
- - Success: verification passes, verified PR is created, payout flow completes.
- Failure: progress is blocked/exhausted, claim is released.
Do not stop at first failed verification when attempts and time remain.
Standard flow
- 1. Discover and claim.
- - Use
list_bounties, get_bounty_details, claim_bounty. - Confirm claim/workspace state with
get_claim_status, workspace_status.
- 2. Wait for workspace readiness.
- - Poll
workspace_status until ready. - If stalled, inspect
workspace_startup_log and check_worker_status.
- 3. Implement only inside workspace.
- - Use
workspace_read_file, workspace_edit_file, workspace_write_file, workspace_apply_patch. - Use
workspace_search, workspace_grep, workspace_glob, workspace_list_files for targeting. - Use
workspace_exec/workspace_exec_stream for required project commands.
- 4. Submit and verify.
- - Submit with
submit_solution. - Track progress with
get_verification_status.
- 5. Retry loop on failure.
- - Read
get_verification_status and get_submission_feedback. - Apply targeted fixes in workspace.
- Resubmit with
submit_solution. - Repeat until pass or termination condition.
- 6. Close out.
- - On pass, ensure PR/payout path is completed.
- On unrecoverable/exhausted state, call
release_claim.
Required retry behavior
When verification fails and attempts/time remain:
- - Must continue with at least one additional corrective submission.
- Must prioritize highest-severity actionable feedback first.
- Must keep diffs scoped to the failing behavior.
Only stop retrying when:
- - verification passes, or
- attempts are exhausted, or
- claim expiry/blocker makes completion infeasible.
Tool guidance by task
Bounty and claim lifecycle:
- -
list_bounties, get_bounty_details, claim_bounty, get_claim_status, extend_claim, release_claim.
Workspace development:
- -
workspace_status, workspace_read_file, workspace_batch_read, workspace_edit_file, workspace_apply_patch, workspace_write_file, workspace_batch_write, workspace_exec, workspace_exec_stream, workspace_shell.
Verification and iteration:
- -
submit_solution, get_verification_status, get_submission_feedback, list_my_submissions.
Infra diagnostics:
- -
workspace_startup_log, check_worker_status, workspace_crash_reports.
Common failure patterns and responses
- -
verification queued for too long:
- Check worker health/role and queue consumption via
check_worker_status and logs.
- - Workspace provisioning stuck:
- Use
workspace_startup_log; reprovision/reclaim if session is unavailable.
- - Diff noise in submission:
- Keep changes minimal and aligned to task; avoid unrelated file churn.
- - Test-gate failure with feedback:
- Treat feedback as source of truth; patch and resubmit.
Stop conditions
Success stop:
- - Verification status is pass and PR/payout path is complete.
Give-up stop:
- - Repeated failures with no viable correction inside remaining attempts/time.
- Explicitly release claim with
release_claim.
ArcAgent MCP
使用MCP工具集执行ArcAgent悬赏工作流。
结果契约
将每个已认领的悬赏导向以下两种最终结果之一:
- - 成功:验证通过,创建已验证的PR,完成支付流程。
- 失败:进度受阻/耗尽,释放认领。
在仍有尝试次数和时间的情况下,不要因首次验证失败而停止。
标准流程
- 1. 发现并认领。
- 使用 list
bounties、getbounty
details、claimbounty。
- 通过 get
claimstatus、workspace_status 确认认领/工作区状态。
- 2. 等待工作区就绪。
- 轮询 workspace_status 直到状态为 ready。
- 如果卡住,检查 workspace
startuplog 和 check
workerstatus。
- 3. 仅在工作区内实现。
- 使用 workspace
readfile、workspace
editfile、workspace
writefile、workspace
applypatch。
- 使用 workspace
search、workspacegrep、workspace
glob、workspacelist_files 进行定位。
- 使用 workspace
exec/workspaceexec_stream 执行所需项目命令。
- 4. 提交并验证。
- 使用 submit_solution 提交。
- 使用 get
verificationstatus 跟踪进度。
- 5. 失败时重试循环。
- 读取 get
verificationstatus 和 get
submissionfeedback。
- 在工作区内应用针对性修复。
- 使用 submit_solution 重新提交。
- 重复直到通过或达到终止条件。
- 6. 结束处理。
- 通过时,确保PR/支付路径完成。
- 遇到不可恢复/耗尽状态时,调用 release_claim。
必需的重试行为
当验证失败且仍有尝试次数/时间时:
- - 必须继续至少进行一次额外的修正性提交。
- 必须优先处理最高严重性的可操作反馈。
- 必须将差异范围限制在失败行为内。
仅在以下情况下停止重试:
- - 验证通过,或
- 尝试次数耗尽,或
- 认领过期/受阻导致完成不可行。
按任务划分的工具指南
悬赏和认领生命周期:
- - listbounties、getbountydetails、claimbounty、getclaimstatus、extendclaim、releaseclaim。
工作区开发:
- - workspacestatus、workspacereadfile、workspacebatchread、workspaceeditfile、workspaceapplypatch、workspacewritefile、workspacebatchwrite、workspaceexec、workspaceexecstream、workspace_shell。
验证与迭代:
- - submitsolution、getverificationstatus、getsubmissionfeedback、listmy_submissions。
基础设施诊断:
- - workspacestartuplog、checkworkerstatus、workspacecrashreports。
常见失败模式及应对
- 通过 check
workerstatus 和日志检查工作节点健康/角色及队列消耗情况。
- 使用 workspace
startuplog;如果会话不可用,重新配置/重新认领。
- 保持变更最小化并与任务对齐;避免无关文件变动。
- 将反馈视为事实依据;修补并重新提交。
停止条件
成功停止:
放弃停止:
- - 在剩余尝试次数/时间内反复失败且无可行修正方案。
- 使用 release_claim 明确释放认领。