{"id":22854790,"url":"https://github.com/kernelshreyak/ai-rpg-text","last_synced_at":"2026-05-09T16:52:10.037Z","repository":{"id":251033591,"uuid":"836145872","full_name":"kernelshreyak/ai-rpg-text","owner":"kernelshreyak","description":"AI Generated text adventure RPG with fully configurable mechanics","archived":false,"fork":false,"pushed_at":"2024-08-17T11:38:11.000Z","size":117,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-02-06T11:57:02.762Z","etag":null,"topics":["dungeons-and-dragons","langchain","langchain-python","rpg","rpg-game","text-adventure-game"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/kernelshreyak.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-07-31T08:43:24.000Z","updated_at":"2024-08-17T11:38:14.000Z","dependencies_parsed_at":"2024-08-17T12:44:13.898Z","dependency_job_id":"c6f93b7b-96ff-427e-b2b7-10051e8ac04b","html_url":"https://github.com/kernelshreyak/ai-rpg-text","commit_stats":null,"previous_names":["kernelshreyak/ai-rpg-text"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kernelshreyak%2Fai-rpg-text","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kernelshreyak%2Fai-rpg-text/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kernelshreyak%2Fai-rpg-text/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/kernelshreyak%2Fai-rpg-text/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/kernelshreyak","download_url":"https://codeload.github.com/kernelshreyak/ai-rpg-text/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":246429756,"owners_count":20775889,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["dungeons-and-dragons","langchain","langchain-python","rpg","rpg-game","text-adventure-game"],"created_at":"2024-12-13T07:08:41.737Z","updated_at":"2025-10-03T20:07:00.441Z","avatar_url":"https://github.com/kernelshreyak.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# AI RPG Text Adventure\n\nThis project is a text-based RPG adventure game driven by an AI Dungeon Master (DM). The DM generates a solo RPG adventure inspired from Dungeons \u0026 Dragons (DnD) rules, but with simplified mechanics. The player interacts with the game by typing commands, and the AI responds by advancing the story.\n\n## Features\n\n- AI-driven Dungeon Master to generate and control the game world. Uses the latest gpt-4o-mini for fast response\n- Conversational Memory support to maintain conversation context throughout the game session.\n- Simplified DnD mechanics for ease of play.\n- Easy to use Web UI created using Streamlit\n- Modify initial inventory, starting scenarios etc using prompts\n- Configureable prompt templates to modify pre-defined game mechanics using text\n- Save to and load game session using JSON\n\n## Planned features\n - Better object-oriented control of game mechanics\n - Support for other LLMs\n\n## Installation\n\n1. **Clone the repository:**\n   ```bash\n   git clone https://github.com/yourusername/ai-rpg-text-adventure.git\n   cd ai-rpg-text-adventure\n\n2. **Create a virtual environment:**\n    ```bash\n    python -m venv .venv\n    source .venv/bin/activate\n    ```\n3. **Install the dependencies:**\n    ```bash\n    pip install -r requirements.txt\n    ```\n4. **Set up environment variables (for OpenAI or Google Gemini models):**\n    ```bash\n    export OPENAI_API_KEY=\"\u003cyour-openai-key\u003e\"\n    export GOOGLE_API_KEY=\"\u003cyour-google-genai-key\u003e\"\n    ```\n## Usage\nRun the game by executing the main script via streamlit:\n\n```bash\nstreamlit run ai-rpg-text.py\n```\n\n![screenshot](./screenshot.png)","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkernelshreyak%2Fai-rpg-text","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fkernelshreyak%2Fai-rpg-text","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fkernelshreyak%2Fai-rpg-text/lists"}