All-Hands-AI / openhands-resolver

A system that tries to resolve all issues on a github repo with OpenHands.
MIT License
85 stars 20 forks source link

Add repo instructions option #319

Closed ryx2 closed 4 days ago

ryx2 commented 4 days ago

This way, users can pass in their own files for additional instructions in the .jinja:

{% if repo_instruction %}

Some basic information about this repository:
{{ repo_instruction }}{% endif %}
neubig commented 4 days ago

Hey @ryx2 , this is already supported through the .openhands_instruction file I think, or is this something different?

ryx2 commented 4 days ago

@neubig I am running this openhands-resolver code on multiple of my repos, so I would appreciate the option to switch instructions and keep those instructions in the repo that's being edited itself, as opposed to needing to make a branch for each repo on my fork of this openhands-resolver repo that contains an edit of the .openhands_instructions file

neubig commented 4 days ago

Hey @ryx2 , yes, you can already do that. Add .openhands_instructions file to the top directory any repo that you're working on and it will automatically be pulled in by the resolver without any code changes.

neubig commented 4 days ago

Here's an example: https://github.com/All-Hands-AI/OpenHands/blob/main/.openhands_instructions

ryx2 commented 4 days ago

ok! is it possible to throw a line into the readme.md so people like me would be able to understand the .openhands_instructions goes into the prompt? I can also add that line in a separate PR if you let me know what section it would be best in

neubig commented 4 days ago

Hey @ryx2 , yes a PR for the readme would be awesome! I think a new section "providing custom instructions" would be good. We could maybe add a few examples like the one from this repo and the one from the openhands repo.

malhotra5 commented 4 days ago

+1 on this; I think maybe the section should be called "advanced settings" or "custom settings"? This would include a guide for setting repo instructions as detailed above + a custom macro to invoke openhands-resolver (introduced in #323)?

ryx2 commented 4 days ago

@malhotra5 I don't know what the custom macro is, but i just made a PR for just the .openhands_instructions, maybe you could add on the macro to that same section after a merge?