{"id":20113143,"url":"https://github.com/cloudacademy/openai_storyteller","last_synced_at":"2026-05-31T20:31:08.111Z","repository":{"id":212143653,"uuid":"730806488","full_name":"cloudacademy/openai_storyteller","owner":"cloudacademy","description":"A Python-based web application used to demonstrate the OpenAI Assistants API","archived":false,"fork":false,"pushed_at":"2023-12-17T00:17:01.000Z","size":808,"stargazers_count":3,"open_issues_count":0,"forks_count":0,"subscribers_count":3,"default_branch":"main","last_synced_at":"2025-03-02T18:51:14.724Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":null,"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/cloudacademy.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":"2023-12-12T18:00:34.000Z","updated_at":"2024-09-11T06:04:13.000Z","dependencies_parsed_at":"2023-12-17T01:24:28.489Z","dependency_job_id":null,"html_url":"https://github.com/cloudacademy/openai_storyteller","commit_stats":null,"previous_names":["cloudacademy/openai_storyteller"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/cloudacademy/openai_storyteller","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cloudacademy%2Fopenai_storyteller","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cloudacademy%2Fopenai_storyteller/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cloudacademy%2Fopenai_storyteller/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cloudacademy%2Fopenai_storyteller/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/cloudacademy","download_url":"https://codeload.github.com/cloudacademy/openai_storyteller/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/cloudacademy%2Fopenai_storyteller/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":33748607,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-05-26T15:22:16.424Z","status":"online","status_checked_at":"2026-05-31T02:00:06.040Z","response_time":95,"last_error":null,"robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":true,"can_crawl_api":true,"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":[],"created_at":"2024-11-13T18:23:25.383Z","updated_at":"2026-05-31T20:31:08.090Z","avatar_url":"https://github.com/cloudacademy.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# OpenAI Storyteller\n\nThis application demonstrates how to use the OpenAI Assistants API. The application is an interactive story creation tool. The intended use is as a choose your own adventure story creation tool. However, it's flexible enough to be used in other ways.\n\nThe application tracks the state of the story by capturing the theme, general story guidelines, and entities that appear in the story, such as: characters, items, and locations. The application ties into the OpenAI image and audio generation APIs to provide a more immersive experience. \n\nThe user interface consists of a sidebar and a main view. The sidebar contains functionality for creating, loading, and removing story sessions. It also contains functionality for configuring the assistant and audio/image generation. The main view contains a chat input used to send messages to the assistant. Messages are displayed on the story tab of the main view. \n\n![The Story Tab](./screenshots/story.png)\n\nEntities extracted from the story are displayed on the entities tab. The assistant uses the description of the entities to provide more context for the story, and to generate images.\n\n![Entities Tab](./screenshots/entities.png)\n\n\n### Requirements\n\n- Python 3.11+\n- OpenAI API key\n\n\n### Setup\n\n1. Clone the repository.\n    ```bash\n    git clone \"https://github.com/cloudacademy/openai_storyteller.git\"\n\n2. Change directory to the root of the project.\n    ```bash\n    cd openai_storyteller\n    ```\n    \n3. Create a new virtual environment.\n    ```bash\n    python -m venv .venv\n    ```\n\n4. Activate the virtual environment.\n    ```bash\n    source .venv/bin/activate\n    ```\n\n5. Change directory to the root of the project.\n    ```bash\n    cd stories\n    ```\n\n6. Install the dependencies.\n    ```bash\n    pip install -r requirements.txt\n    ```\n\n7. Create a `.env` file in the root of the project and add the following environment variables.\n    ```bash\n    echo \"OPENAI_API_KEY=\u003cyour-openai-api-key\u003e\" \u003e .env\n    ```\n\n8. Add the current module to the Python path.\n    ```bash\n    export PYTHONPATH=$PYTHONPATH:$(pwd)/src\n    ```\n\n9. Start the UI.\n    ```bash\n    streamlit run src/stories/ui.py\n    ```\n\n10. Open the URL listed in the console.\n\n\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcloudacademy%2Fopenai_storyteller","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fcloudacademy%2Fopenai_storyteller","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fcloudacademy%2Fopenai_storyteller/lists"}