open-interpreter
open-interpreter copied to clipboard
How can I get interpreter to output all scripts to files neatly?
Is your feature request related to a problem? Please describe.
The problem is interpreter will write a lot of code and try to execute it. But it doesn't output the programs to files neatly.
Describe the solution you'd like
I want interpreter to automatically output its programs to files like file1.sh, file2.sh, file3.sh or file1.py, file2.py, file3.py and so on.
Describe alternatives you've considered
No response
Additional context
No response
Have you asked it to? Maybe add your requirements from above as part of your prompt or system message?
You can use a simple file writing operation. The sample code is as follows. shell_script_content = """ #!/bin/bash echo "Hello, World from the generated shell script!" """ with open("file1.sh", "w") as f: f.write(shell_script_content)