samholt / L2MAC

🚀 The LLM Automatic Computer Framework: L2MAC
https://samholt.github.io/L2MAC/
MIT License
31 stars 10 forks source link

How to update generated code #5

Open grant-d opened 2 weeks ago

grant-d commented 2 weeks ago

Wonderful paper and implementation. Thank you.

Do you have guidance as to how you'd update (eg) the snake code, vs generate it from scratch? For example, how would you change the code so that this would work: L2MAC --foo "update the grid to be 50 x 50"

samholt commented 3 days ago

Thank you!

Yes, that is quite easy, and the original implementation before relating it publically supported this. This is on the feature roadmap to implement this in a good way, so I welcome any contributions to do this.

It's somewhat straightforward. All you need is a function to load an existing codebase / repository of folders and files, into a nested dictionary, change the prompts to then have knowledge of this codebase, and use the existing codebase, and it should work. This was done in the original implementation in the paper, and you can see examples of this working in the appendix.

Thank you. If you want I can also try to provide an implementation in the next 2-4 months.

Best, Sam