- Python 100%
| helper | ||
| prompts | ||
| .gitignore | ||
| LICENSE | ||
| main.py | ||
| README.md | ||
| requirements.txt | ||
ExecAI
🚧 Prototype of a LLM with access to python and system commands. 🚧
The chatbot has full access to python eval and system console
⚠️ Use at your own risk, with caution. this chatbot could completely destroy your system ⚠️
Usage
Clone the repo
git clone https://codeberg.org/timedin/ExecAI.git
cd ExecAI
Create VENV and install librariees
python3 -m venv venv
source venv/bin/activate
pip install -r requirements.txt
Run the script
python main.py
Arguments
-dor--debugEnable debug logging--infoEnable info logging (reduced logs, only shows direct LLM responses)-ior--insecure-funcEnable direct running of insecure functions (python exec and os.exec).
How does it work
This code instructs a LLM to use various functions (like python commands or shell commands) to do various things on your system. Like creating and reading files, accessing website, opening programs and shutting your system down.
First the user request is send to the LLM, this replies in a JSON format and specifies all functions it needs to run. The script runs the functions with the supplied parameters and sends the output back in another request to the LLM to let it respond with a matching confirmation.
Functions
The LLM knows the system the script is running on. It currently can use the following functions:
- getDate, returns the current datetime
- getUrl: Send GET-requests to websites
- eval: Execute Python commands
- os: Run System Console commands
- exit: On user Request the Chatbot can exit the app
