OpenHands icon indicating copy to clipboard operation
OpenHands copied to clipboard

Revamp agent delegation

Open li-boxuan opened this issue 1 year ago • 4 comments

This PR fixes #1897. In addition, this PR fixes typo_fixer_agent which still uses legacy think action.

For the first time, I am able to use ManagerAgent to complete test_write_simple_script and test_edits tasks in integration tests, so this PR also adds ManagerAgent as part of integration tests. test_write_simple_script involves delegation to CoderAgent while test_edits involves delegation to TypoFixerAgent.

This PR adds two new checks to make the CI check list even lengthier... but it would be better after #1888, with which the number of agents won't affect the number of CI checks.

This PR is a blocker for #1735.

li-boxuan avatar May 20 '24 03:05 li-boxuan

@rbren This might have some overlap/conflict with #1660, but I believe we anyways need to fix the current broken AgentDelegateAction. Your review is greatly appreciated!

li-boxuan avatar May 20 '24 04:05 li-boxuan

@li-boxuan for some reason I can't open a PR into your branch, but here's my repro:

https://github.com/OpenDevin/OpenDevin/tree/rb/delegate-repro

See the edits in DummyAgent--it builds a stack of delegates, which just finish immediately

This consistently trips over the error:

poetry run python opendevin/core/main.py -c DummyAgent -t "write a todo list app in react"

rbren avatar May 23 '24 19:05 rbren

for some reason I can't open a PR into your branch

this is on my fork, but you should have access to push to my branch directly. You just need to first do git remote add li-boxuan https://github.com/li-boxuan/OpenDevin.git

li-boxuan avatar May 24 '24 04:05 li-boxuan

I'll come back and work on this this weekend. Hope I could make some progress Friday evening (PT time).

li-boxuan avatar May 24 '24 06:05 li-boxuan

@rbren I believe there are still a few debatable designs such as history management, but I am going to merge this PR as it is, since agent delegation is broken at the moment, and this PR doesn't introduce regression. We could discuss & improve later.

li-boxuan avatar May 29 '24 01:05 li-boxuan