ShakeScript is a cutting-edge, AI-powered storytelling system designed to generate immersive, multi-episode narratives with rich characters, evolving plots, and long-term memory. By blending the strengths of GPT-4o and Google Gemini, it overcomes traditional limitations in AI storytelling, such as token constraints and narrative inconsistencies.
Traditional AI-generated stories often struggle with:
| Challenge | Description |
|---|---|
| ๐ Narrative Coherence | Maintaining seamless connections between episodes. |
| ๐ง Token Limitations | Handling the restricted context windows of large language models. |
| ๐ค Character Consistency | Preserving character traits, relationships, and emotional states. |
| ๐ Extended Narratives | Structuring long stories into coherent, episodic chunks. |
| ๐พ AI Memory | Retaining relevant story context across multiple episodes. |
ShakeScript enables long-form storytelling with AI memory, human feedback integration, and cultural nuance.
- Accepts brief prompts, including genres, tropes, or plotlines.
- Generates multi-episode stories with detailed world-building and character arcs.
- Maintains narrative continuity using metadata and embeddings.
- Supports Hinglish storytelling.
- Offers both AI-driven and human-in-the-loop episode refinement.
- Utilizes a robust database and Gemini-based semantic embeddings for memory.
- Endpoint:
/stories - Gemini extracts:
- Characters: Names, roles, relationships, and emotions.
- Settings: Detailed location descriptions.
- Structure: Exposition โ Climax โ Denouement.
- Theme & Tone: (e.g., Suspenseful, Romantic).
- Data is stored in Supabase in the
storiesandcharacterstables.
- Uses structured metadata to generate an episode that aligns with the story's outline (e.g., Exposition).
- Retrieves up to three past episodes for context.
- Gemini-generated embeddings fetch relevant story chunks to ensure long-form continuity.
- Ensures character consistency, thematic alignment, and narrative progression.
- Saves episode content, titles, summaries, and emotional states in the
episodestable. - Splits episodes into semantic chunks using
SemanticSplitterNodeParser. - Vectorizes and stores these chunks in the
chunkstable using Gemini Embeddings.
- Tracks the
current_episode,key_events,timeline, and character evolution.
- Uses Google Gemini Embeddings (
models/embedding-001) to vectorize story chunks. - Scores relevance based on the characters involved and episode order, enabling memory-aware story generation.
- Endpoints:
/storiesโ Create a new story./generate-batchโ Generate a batch of episodes./refine-batchโ Handle human feedback and refinement.
- Uses Pydantic models for structured data (
schemas.py).
- A React/Next.js user interface.
- Features:
- Episode display.
- Character profiles.
- Hinglish support.
- Real-time story updates.
- ๐ Multi-Episode Consistency โ Maintains coherent and evolving narratives.
- ๐ก Token Limit Workaround โ Smart retrieval using Gemini Embeddings.
- ๐ค Character Evolution โ Tracks character traits, arcs, and relationships.
- ๐ Human Refinement โ Combines LLM polish with user feedback.
- ๐ Hinglish Support โ Culturally tuned storytelling.
| Feature | Description |
|---|---|
| ๐ง TTS Narration | Add audio playback with Text-to-Speech. |
| ๐ง Custom AI Models | Fine-tune LLMs for specific genres or styles. |
ShakeScript redefines AI-powered storytelling by:
- Solving token limitation challenges.
- Supporting long-form, culturally nuanced narratives.
- Seamlessly blending LLMs, embeddings, and human input.
๐ Let the stories unfold โ with ShakeScript, your narrative has no limits.
Made with โค๏ธ by the ShakeScript AI Team



