Skip to content

GH05TCREW/playstory

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PlayStory

A proof-of-concept web app for creating branching video stories with Sora. Generate a clip, choose from 3 AI-suggested actions, then generate the next clip using the last frame as visual reference. Repeat to build your story.

playstory.mp4

Prerequisites

  • Python 3.11+
  • Node 18+
  • ffmpeg (on PATH)
  • OpenAI API key with Sora access

Setup

Backend:

cd backend
Copy-Item .env.example .env
# Edit .env and set OPENAI_API_KEY
python -m venv .venv
. .venv\Scripts\Activate.ps1
pip install -r requirements.txt
uvicorn app:app --reload --port 8000

Frontend:

cd frontend
npm install
npm run dev

Open http://localhost:5173

How it works

  • FastAPI backend with endpoints for starting jobs, polling status, and branching stories
  • Media stored in media/videos and media/frames
  • Last frame extracted and used as input_reference for the next clip to maintain visual continuity
  • Optional story context mode includes recent events in prompts for narrative continuity

Tips

  • Use one consistent video size for your project (e.g., 1280x720)
  • Sora 2 supports 4, 8, or 12 second clips
  • Keep prompts focused on a single scene or beat

License

MIT

About

Branching video story builder using Sora - generate clips, choose actions, build interactive narratives.

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors