Agent OS

🌞 Build autonomous AI agents!

🛠️The Agent OS is an experimental framework and runtime to build sophisticated, long running, and self-coding AI agents.

We believe that the most important super-power of AI agents is to write and execute their own code to interact with the world. But for that to work, they need to run in a suitable environment—a place designed to be inhabited by agents. The Agent OS is designed from the ground up to function as a long-term computing substrate for these kinds of self-evolving agents.

❓If you want to understand the motivation behind the project, read the manifesto.
❓To learn how everything works, start reading the design docs.

In short:

Jetpack Demo Video
Click the the image to watch a short demo on YouTube.

NOTE: WE ARE CURRENTLY WORKING ON A DISTRIBUTED RUNTIME. Everything below this is out of date.

Getting Started

As long as the project is still in alpha, the best way to get started is to clone this repository.

Requires Python >= 3.10 and Poetry. Works on Linux, macOS, and Windows.

Once cloned, cd into the repository and run:

poetry install

The project comes with a CLI that can be used to initiate and run agents. To see the available commands run:

poetry run aos --help

Test Drive an Agent 🤖

To run your first agent, put an .env file in the project root that contains an OpenAI API key. (It also works without an .env file or key if you just want to give the project a quick spin.)

OPENAI_API_KEY=sk-myspecialkey

Agent Dependencies

Some of the dependencies for the demo agents are optional and not part of the core Agent OS source. To install them, run:

poetry install --with agents

Jetpack Agent

The "Jetpack" agent demonstrates what the Agent OS can do and is geared towards end-to-end code generation and execution. It's a conversational agent that can accomplish various tasks for you. To run it, execute the following commands:

poetry run aos -d agents/jetpack/ push
poetry run aos -d agents/jetpack/ run

Jetpack comes with a web interface, and the Agent OS hosts a web server. To access the interface, browse to http://127.0.0.1:5000/ag/jetpack/wit/actors/frontend/query/web

Project Structure

Running the Tests

If you want to hack on the code, it is helpful to run the tests. The project uses pytest and has almost 100 unit tests.

poetry run pytest tests/