Open-interpreter: OpenAI's Code Interpreter in your terminal, running locally
github.com
github.com
I had a great experience with Open-Interpreter. Watching it work with GPT-4 as LLM vendor is nothing short of magical. In fact it was the closest thing I've ever seen to pure science fiction in my lifetime, esp since I hooked it up to a microphone and I was controlling it with voice. "Computer, bring up Hacker News. Summarize. Make it so.".
And it WORKS. Good times! That is a trivial exercise for GPT-4!
No, it's not going to brick your computer. You should know by now that GPT-4 is so well aligned at this point that it's yawn inducingly boring.
Before Autogen, before LlamaIndex, before LangChain, etc, Open Interpreter was the first thing to convince me that LLMs had a use beyond mere novelty -- that they could be the engine for useful agentic software robotics. Up until that point it was all theory, I had never seen it.
In fact, the paranoia that it could brick your system or extract information from your machine requires you to concede that it could generate and run code. Which it can -- except it in fact tries to be helpful. If you tell it to brick your computer, I doubt it would even comply.
My criticism comes not from Open-Interpreter but from the fact that there are many products like this that only work with GPT-4, and that's a shame.
But it was extremely inspiring to, rather than sit around and complain about it, get to work building some models and systems that can actually be used to do useful stuff and deliver on the automation promised, and it has become a sustainable small business model for me. So, thank you killianlucas, for inspiring me and making me a lot of money.
So put that in your pipe and downvote it.
Am I missing an interesting use case here?
Code interpreter takes you out of that loop - GPT can find and fix its own mistakes.
The idea of Code Interpreter is that ChatGPT, instead of inventing/hallucinating the answer to your complex question, can write code to solve it.
ChatGPT is better at writing code that matches the logic of the problem, than it is at coming up with a straight-up reply.
So it comes up with the code, it runs it with Code Interpreter, and then reads the answer out loud to you.
The API is governed by a different policy than ChatGPT and won’t be used for training data.
> An open-source, locally running implementation of OpenAI's Code Interpreter.
> […]
> Open Interpreter lets LLMs run code (Python, Javascript, Shell, and more) locally. You can chat with Open Interpreter through a ChatGPT-like interface in your terminal by running $ interpreter after installing.
> […]
> Comparison to ChatGPT's Code Interpreter
> OpenAI's release of Code Interpreter with GPT-4 presents a fantastic opportunity to accomplish real-world tasks with ChatGPT.
> However, OpenAI's service is hosted, closed-source, and heavily restricted:
> - No internet access.
> - Limited set of pre-installed packages.
> - 100 MB maximum upload, 120.0 second runtime limit.
> - State is cleared (along with any generated files or links) when the environment dies.
> Open Interpreter overcomes these limitations by running in your local environment. It has full access to the internet, isn't restricted by time or file size, and can utilize any package or library.
> This combines the power of GPT-4's Code Interpreter with the flexibility of your local development environment.
> […]
> Change your Language Model
> Open Interpreter uses LiteLLM to connect to hosted language models.
> You can change the model by setting the model parameter
> […]
> Running Open Interpreter locally
> Open Interpreter uses LM Studio to connect to local language models (experimental).
> Simply run interpreter in local mode from the command line
So AFAICT your prompt is still "leaked" to OpenAI, but not your data.
But that's not the biggest issue in most cases.
Prompt: "I have a file of 315 customers with their IP, behavior, religious affiliation and previous purchases plus medical history. I want to figure out if I have any customers whose religious affiliation pre-dates a post-surgery stay in hospital."
Data: a huge CSV file which, as you can tell, contains incredibly sensitive/legally impactful information.
With this system, you send the prompt to GPT-4 or Claude, and it doesn't see your data at all. It just writes a python program that can do the analysis.
You run the program locally on C:/Users/passwordoops/SuperSensitiveData/Confidential.csv
You get the result.
OpenAI has never seen your data.
It's a win for confidentiality.
(of course, that's if the LLM didn't give you a program that would exfiltrate your prompt, and if the CSV contains no prompt injection to exfiltrate the data, etc. This system is a security nightmare.)
Cool idea on paper and there was no way people wouldn't do it.
Security-wise though, this seems like a pretty epically catastrophe-prone concept.
Open Interpreter will ask for user confirmation before executing code.It will protect you against an "honest mistake" like if you asked for code to delete all files with an "x" in the name and the command is deleting all files with a star "*" and you catch that. Great.
It will not protect you against actual malicious code. LLM inputs should be treated with the same caution and suspicion as unregistered-user inputs submitted over Tor.
Also, it is very likely that a further GPT model might behave, with non-malicious prompt, like a malicious actor, simply because such an fairly-unlikely event is almost guaranteed at the kinds of scales we are talking (100MM weekly active users is a lot of rolls of the dice).
But people make mistakes, too. The code that people write themselves or copy from Stack Overflow will have lots of bugs at scale.
For the individual programmer who knows what they're doing and uses it responsibly, it's unclear that the risks are any higher than writing code on your own.
And the linux build must be requested from discord: https://lmstudio.ai/
It's perfect to run fast bash commands that I forgot but are simple enough that the first Google search result would solve it anyways.
[1] https://www.npmjs.com/package/@githubnext/github-copilot-cli
It currently has 882 stars and I think a few people at least are enjoying using it.
One easier option which would likely work: run Python code entirely inside a WebAssembly sandbox directly in the browser using Pyodide. https://pyodide.org/
Anyone seen an attempt at that yet?
No, I don’t think I will.
For anything remotely complex, even gpt-4 hallucinates libraries and commands.
The two most dangerous types of programmers are experts and novices.
I think you're forgetting the latter. It's the reason there's so many "how to exit vim" jokes and why every linux noob (that actually gets into linux and not just "oh, I installed ubuntu and only use the GUI) deletes shit they needed and learn the importance of backup the hard way. Hell, even being on systems like this for over a decade and knowing them really well I sometimes make mistakes. I have a bunch of aliases and routines literally to prevent accidents.
... and running exec() on the resulting code?
for those of us too unimaginative to draw the rest of the owl
https://marketplace.visualstudio.com/items?itemName=skybrian...
The code is then retrieved to your computer and run locally.
This way you can run the code on local files or give it access to the internet. Basically, this is Code Interpreter with none of the security features.