Skip to content

update agent docs #107

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
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
44 changes: 44 additions & 0 deletions agent/README.md
Original file line number Diff line number Diff line change
@@ -1,6 +1,45 @@
# Agent for Commit0
This tool provides a command-line interface for configuring and running AI agents to assist with code development and testing.


## (Update) Running with OpenHands

**Step 1**: Clone (OpenHands)[https://github.com/All-Hands-AI/OpenHands/tree/main] and install (OpenHands)[https://github.com/All-Hands-AI/OpenHands/blob/main/evaluation/README.md#development-environment]

**Step 2**: Create `config.toml` and write

```
[core]
workspace_base="~/OpenHands/evaluation/benchmarks/commit0_bench"

[llm]
model="anthropic/claude-3-5-sonnet-20241022"
api_key="..."
embedding_model=""
temperature = 0.0
caching_prompt = true
```


**Step 3**: Run
```bash
./evaluation/benchmarks/commit0_bench/scripts/run_infer.sh SPLIT MODEL HEAD CodeActAgent 16 STEPS PARALLEL_NUMBER

# Example
./evaluation/benchmarks/commit0_bench/scripts/run_infer.sh lite llm.eval_deepseekv3 HEAD CodeActAgent 16 100 2
```

**Step 3.1**:
You can do the following before running code to parallelize them on remote server from OpenHands

```bash
export RUNTIME=remote
export SANDBOX_REMOTE_RUNTIME_API_URL="https://runtime.eval.all-hands.dev"
export ALLHANDS_API_KEY=...
```


```python
## Quick Start
Configure an agent:
```bash
Expand All @@ -12,6 +51,11 @@ Run an agent on a specific branch:
agent run [OPTIONS] BRANCH
```

### Example
```bash
agent run sonnet --max-parallel-repos 16 --agent-config-file .agent_sonnet.yaml --commit0-config-file .commit0.yaml
```

For more detailed information on available commands and options:
```bash
agent -h
Expand Down