AI Short Story Generator
AI Short Story Generator
Create an interactive platform that uses artificial intelligence to dynamically generate captivating stories and accompanying images, offering users a unique narrative experience each time.
Created: 11/06/2023 by Dustin Usey
Skill level: intermediate
Topics used: HTML CSS JavaScript AI
Estimated completion time: 10 Hours
Create an interactive platform that uses artificial intelligence to dynamically generate captivating stories and accompanying images, offering users a unique narrative experience each time.
![Code adventure mockup image](https://treehouse-code-adventures.s3.amazonaws.com/resource-thumbnails/resource-treehouse.webp)
JavaScript and the DOM
JavaScript lets you create interactive web pages which can respond to a user's actions. In this course, you'll learn how to bring web pages to life using the power of JavaScript.
![Code adventure mockup image](https://treehouse-code-adventures.s3.amazonaws.com/resource-thumbnails/resource-treehouse.webp)
Interacting with the DOM
Along with selecting DOM elements in JavaScript we can also write code that gives elements behavior. In this course we will first explore how to watch for interaction and respond using the method addEventListener.
![Code adventure mockup image](https://treehouse-code-adventures.s3.amazonaws.com/resource-thumbnails/resource-treehouse.webp)
DOM Scripting By Example
Use JavaScript to build an RSVP web application. Many of the features you'll build are common to other web applications.
![Code adventure mockup image](https://treehouse-code-adventures.s3.amazonaws.com/resource-thumbnails/resource-treehouse.webp)
Using Local Storage With JavaScript
Local Storage is part of the Web Storage API, and allows you, as a developer, to store data in a user's browser.
![Code adventure mockup image](https://treehouse-code-adventures.s3.amazonaws.com/resource-thumbnails/resource-treehouse.webp)
Working with the Fetch API
Learn how to use the Fetch API to fetch resources.
![Code adventure mockup image](https://treehouse-code-adventures.s3.amazonaws.com/resource-thumbnails/resource-openai.webp)
OpenAI API
Transforming work and creativity with AI. Our API platform offers our latest models and guides for safety best practices.
![Code adventure mockup image](https://treehouse-code-adventures.s3.amazonaws.com/resource-thumbnails/resource-openai.webp)
DALL·E 3
When prompted with an idea, ChatGPT will automatically generate tailored, detailed prompts for DALL·E 3 that bring your idea to life.
-
0
To begin, click "Start Adventure" at the top of the page and then download your starter files.
-
1
Utilize A.I. to craft stories based on predefined themes and genres.
-
2
Auto generate four paragraphs of text that follow a logical narrative structure.
-
3
Implement variability so that each story generated has distinct characters, challenges, and resolutions.
-
4
Use A.I. image generation tools to produce images in line with the narrative.
-
5
Ensure that the image aesthetics match the story's tone—be it dark, whimsical, romantic, etc.
-
6
Maintain consistency in image style across the entire story for visual cohesion.
-
7
Allow the user to prompt the A.I. to create additional paragraphs and images.
-
8
Extra Challenge: Users can save, share, or revisit their unique stories.
-
9
Extra Challenge: Allow users to select themes or provide initial auto inputs to guide the story's direction.