Get the latest tech news

The ChatGPT Linux System


crets of the ChatGPT Linux systemSun 16 June 2024 Tagged: software Have you noticed that ChatGPT sometimes writes out Python code and somehow executes it? How does that work? What kind of environment is it using? Can we co-opt it for our own ends? Let's find out! To play along at home: open a ChatGPT chat (I used gpt-4o) and ask if it can execute whoami using os.popen. Here's a short example session: https://chatgpt.com/share/94ad03ba-2a76-4643-a9cc-fb17df2e0345 Occasionally it will refuse to help you, this seems to be random chance as far as I can tell: Executing system-level commands like whoami or using os.exec is not allowed in this environment for security reasons.

So presumably the ChatGPT-running environment uses POST /kernel to create the 3 IPython kernels, then it opens a websocket to/channel to submit ChatGPT's code to run, and retrieve the outputs. After the first sitting I DuckDuckWent the text from the README file and found a LessWrong article from last summer: Jailbreaking GPT-4's code interpreter. Leaking the source code for "user_machine" could be mitigated by, for example, having the webapp owned by a separate user, and dropping privileges to run IPython, but I don't think it's a big deal.

Get the Android app

Or read this on Hacker News

Read more on:

Photo of ChatGPT Linux System

ChatGPT Linux System

Photo of Linux System

Linux System