-
Notifications
You must be signed in to change notification settings - Fork 5k
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
[Bug]: Agent not recognizing working directory #6612
Comments
Brad, I read the entire log, and I don't think this is a bug. It's doing this: the LLM gets the working directory automatically, and corrects itself. That's what an agent should do, in the measure of possible, because an LLM will always make mistakes. Please look at this:
That's not a bug, you know how they say, it's a feature. 😅 Note: the OBSERVATION is part of the context, it's sent to the LLM. (slightly simplified below to make it more easily readable) 04:35:14 - ACTION 04:35:14 - OBSERVATION ============== 04:35:33 - ACTION ============== 04:35:38 - ACTION 04:35:39 - OBSERVATION --BEGIN AGENT OBSERVATION-- ============== 04:35:58 - ACTION ============== 04:36:06 - ACTION 04:36:07 - OBSERVATION --BEGIN AGENT OBSERVATION-- [Current working directory: /workspace] ============== 04:36:12 - ACTION |
Please note that your logs also include logs from In general, it would be helpful to isolate the logs you find problematic, from In this case, I don't think it's a bug, and it's unclear to me what differences in the prompt could help. Give it all the time all contents of the directory, not only the working directory? Maybe, but that's not obviously better, in general. In the general case, it wouldn't be a file inside the first subdirectory, it could be anywhere, at any depth. On large repos a |
What happens after is a bit strange, on how it gets stuck: the LLM sends a MessageAction, over and over again. That's weird because it's unwarranted. I need to look into it a bit. A thought: you were using DelegatorAgent. That should work in simple tasks, but really the setup with micro-agents is experimental, it doesn't perform well, and I can only really recommend the same task with CodeAct. Or use the existing Delegator as example and develop some smarter agents. ;) |
@enyst I think I started OpenHands after Kevin broke, just to see how well it can handle the stuff in the new version, some of the problem is my fault ngl
This kinda suffers the "Romba hits a wall" type problem that I can't quite put a finger on, where it keeps bumping on the same issue without "turning left", or in this case kept
The thing is that it kept sucking into this over and over and can't really break out of it in this case, would love to replicate again just to send the screenshots cus it is the same head-scratching behavior.
Yeah that is the problem there, I would need some agent that can handle large steps, and Delegator is generally recommended, and I think @SmartManoj found a way to hack CodeAct to think in stepwise multi-task juggling, but that might as well be magic. Definitely would try with CodeAct and pass the results I think at the very least we need |
Just to clarify, Delegator is not recommended. It's an experimental agent, pretty simple, which hasn't even been evaluated on benchmarks because we are sure it won't make it. (so it doesn't make much sense at this stage) |
I modified the label from a bug based on the comments. Please close the issue if the issue is resolved. |
Is there an existing issue for the same bug?
Describe the bug and reproduction steps
Logs here (DeepSeek v3 which should be very capable in code/reasoning) https://pastebin.com/9XThHQHh
Conversation led to possible need for repomap #2185 (comment)
OpenHands Installation
Docker command in README
OpenHands Version
0.23
Operating System
WSL on Windows
Logs, Errors, Screenshots, and Additional Context
See above for the full log
The text was updated successfully, but these errors were encountered: