Running Commands And Code
Let AI execute commands and scripts in a secure sandbox.
TaskLift provides powerful tools for running arbitrary commands and code within machines securely hosted by the platform.
Available Tools
The Command Line tool allows AI to run arbitrary commands in a Bash shell and grab their results and exit code. Debian-based machine with root privileges is provided in order to allow installing new packages or changing the configuration to let AI fulfill amy given goals.
The Code Interpreter tool allows AI to run scripts in various programming languages such as Python and grab all the outputs. Under the hood we're using the Jupyter kernel standard which means that:
- AI can easily understand the environment because of the widely adopted Jupyter standard
- Jupyter's additional magic syntax is available (IPython in case of the default Python kernel)
- any programming language may be used simply by installing an appropriate kernel
- console output, display data, return values and errors are all provided in uniform way
Both tools may be used directly by simply picking them for a chat or assistant, or they may be combined and equipped with arbitrary hardware by attaching them to Computer tools. Check out the Combining Tools And Data On Computers page for more information.
Output Preview
All tool calls may be inspected by clicking them in the chat. In case of Command Line and Code Interpreter tools, TaskLift provides additional rich preview of their outputs directly in the inspector. For Command Line calls, this includes the command, its output and exit code. For Code Interpreter calls, outputs with images and interactive Plotly charts are rendered, allowing for immediate visualization of results.
Machine Lifecycle
Just like with any private tools, subsequent command line or code interpreter calls will be executed on the same machine as long as they happen in a quick succession (without a few minutes of inactivity, after which the machine will be stopped in order to conserve credits and started fresh upon further calls). Drive tools may be used to store files persistently across non-successive runs. Check out the Storing Data On Persistent Drives page for more information.
In case of any questions, issues or concerns related to TaskLift, don't hesistate to contact us.