Yufan Song 256a04b307 fix(sandbox): add get pid code and kill the process (#274) 1 year ago
..
action ea10809a96 fix file write observations (#225) 1 year ago
controller 93656f3bb3 add error handling for action running (#212) 1 year ago
llm 4304aceff3 remove openai key assertion, enable alternate embedding models (#231) 1 year ago
mock 9ab15b3287 add mock server (#214) 1 year ago
sandbox 256a04b307 fix(sandbox): add get pid code and kill the process (#274) 1 year ago
server 73ea0e5803 Fix Docker container creation and error handling (#280) 1 year ago
README.md a9102382f6 Update image registry in README.md (#265) 1 year ago
agent.py eb4a261880 Create generic LLM client using LiteLLM (#114) 1 year ago
main.py 16bf9d3cd2 Check for env var in parser argument default value or use hardcoded default (#276) 1 year ago
observation.py ea10809a96 fix file write observations (#225) 1 year ago
state.py 82f934d4cd New Agent, Action, Observation Abstraction with updated Controller (#105) 1 year ago

README.md

OpenDevin Shared Abstraction and Components

This is a Python package that contains all the shared abstraction (e.g., Agent) and components (e.g., sandbox, web browser, search API, selenium).

Sandbox component

Run the docker-based sandbox interactive:

mkdir workspace
python3 opendevin/sandbox/sandbox.py -d workspace

It will map ./workspace into the docker container with the folder permission correctly adjusted for current user.

Example screenshot:

image

How to run

  1. Build the sandbox image local. If you want to use specific image tags, please also fix the variable in code, in code default image tag is latest.

    docker build -f opendevin/sandbox/Dockerfile -t opendevin/sandbox:v0.1 .
    

Or you can pull the latest image here:

docker pull ghcr.io/opendevin/sandbox:v0.1
  1. Set the OPENAI_API_KEY, please find more details here. Also, choose the model you want. Default is gpt-4-0125-preview

    export OPENAI_API_KEY=xxxxxxx
    
  2. Install the requirement package.

    pip install -r requirements.txt                                                                 
    

    If you still meet problem like ModuleNotFoundError: No module named 'agenthub', try to add the opendevin root path into PATH env.

  3. Run following cmd to start.

    PYTHONPATH=`pwd` python ./opendevin/main.py -d ./workspace -t "write a bash script that prints hello world"