Forked from mberman84/gist:d40d3e5c0e649d26dcd3dd0163e9d8d0
Created
August 15, 2023 14:53
-
-
Save nyimbi/932b65169b27823b840543b1812637a0 to your computer and use it in GitHub Desktop.
Generative Agents Installation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# must have conda installed | |
git clone https://github.com/joonspk-research/generative_agents.git | |
cd generative_agents | |
# open visual studio code, open gen agents folder | |
# within vscode, go to reverie/backend_server | |
# create new file utils.py | |
# copy/paste contents from github (below) | |
### | |
# Copy and paste your OpenAI API Key | |
openai_api_key = "<Your OpenAI API>" | |
# Put your name | |
key_owner = "<Name>" | |
maze_assets_loc = "../../environment/frontend_server/static_dirs/assets" | |
env_matrix = f"{maze_assets_loc}/the_ville/matrix" | |
env_visuals = f"{maze_assets_loc}/the_ville/visuals" | |
fs_storage = "../../environment/frontend_server/storage" | |
fs_temp_storage = "../../environment/frontend_server/temp_storage" | |
collision_block_id = "32125" | |
# Verbose | |
debug = True | |
### | |
# fill out openai api key & name | |
conda create -n gen_agents python=3.11.4 | |
conda activate gen_agents | |
# within requirements.txt file, change pillow version to 9.5.0 | |
python -m pip install -r requirements.txt | |
cd environment/frontend_server | |
python manage.py runserver | |
# goto http://127.0.0.1:8000/ and verify it is working | |
# open new command line, leave previous command line running | |
# navigate to generative_agents folder | |
conda activate gen_agents | |
cd reverie/backend_server | |
# open reverie.py, enter this before line 400: | |
### | |
curr_move_path = f"{sim_folder}/movement" | |
# If the folder doesn't exist, we create it. | |
if not os.path.exists(curr_move_path): | |
os.makedirs(curr_move_path) | |
### | |
python reverie.py | |
# enter name of forked simulation: base_the_ville_isabella_maria_klaus | |
# enter name of new simulation: test-simulation | |
# goto: http://localhost:8000/simulator_home | |
# enter option: “run 3” to run 3 steps | |
# to replay, http://localhost:8000/replay/test-simulation/1/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment