LLM-based text adventure game / tech demo.
You'll need Python 3.11 and Poetry for development.
To install dependencies, run:
poetry install
poetry config virtualenvs.in-project true # For editor support
Then, create .env
file from .env.sample
that is committed to Git.
Fill your API keys to the .env file. NEVER commit the API keys to Git!
Then, to use the created venv from shell, run:
poetry shell
Run the scripts from root directory of this repository. Although Python imports don't care about your working directory, other files are also accessed using relative paths.
$ pwd
/home/you/TextAdventure
$ python src/main.py
Since the application can't be run wihtout an active OpenAI key, we'll provide some image examples of the application. \ The title screen: A scenario description: Choosing a faction to interact with: Text generated while adventuring: A combat encounter: An enemy: A protagonist: Protagonist's inventory: