story-shot-agent
剧本分镜智能体(PenShot):电影/动漫/短剧/小说→分镜片段→视频提示词。基于 LLM 通过 LangGraph+LlamaIndex实现任意格式剧本的自动解析,生成 Sora/Veo/Runway 等模型可
What is story-shot-agent?
剧本分镜智能体(PenShot):电影/动漫/短剧/小说→分镜片段→视频提示词。基于 LLM 通过 LangGraph+LlamaIndex实现任意格式剧本的自动解析,生成 Sora/Veo/Runway 等模型可用的连贯text-to-video提示词。保持角色/剧情跨片段一致,支持 MCP/REST API/Function Calls/A2A 集成。(LLM-powered text-to-video-prompt agent. Break scripts into Sora/Veo-ready shots with character consistency)
Overview of story-shot-agent
What it is
Story Shot Agent (PenShot) is an LLM-powered text-to-video-prompt agent that breaks scripts (movies, anime, short plays, novels) into shot-level descriptions and generates coherent prompts for AI video models like Sora, Veo, Runway, and Kling. It uses LangGraph + LlamaIndex to automatically parse scripts in any format, ensuring character and scene consistency across fragments. The system supports integration via Python SDK, MCP service, Function Calling, REST API, and A2A protocol.
Key features
- Intelligent script parsing: automatically identifies scenes, dialogues, and actions, supports long-text segmentation - Precise timing planning: splits content at shot granularity with reasonable duration, adapting to AI video model limits - Consistency guardian: multi-level memory (short/medium/long-term) with Chroma vector retrieval, snapshot mechanism, and multi-dimensional recall to maintain cross-fragment consistency - High-quality prompt output: generates detailed bilingual (Chinese/English) visual descriptions, negative prompts, and audio prompts - Multi-model compatibility: supports OpenAI, Qwen, DeepSeek, Ollama, and other mainstream LLM providers - Multi-protocol integration: provides Python SDK, REST API, LangGraph nodes, A2A collaboration protocol, and MCP standard interface - Robustness and traceability: built-in auto-retry, error degradation, and bidirectional traceability from each fragment back to the original script
Use cases
- Converting movie, anime, short drama, or novel scripts into shot-level prompts for AI video generation - Maintaining character appearance, scene, and plot consistency across multiple video clips - Automating the script-to-prompt pipeline for content creators, filmmakers, and AI video enthusiasts - Integrating with upstream script-writing agents and downstream video generation/editing tools via MCP, REST API, or A2A
Getting started
bash pip install penshot docker pull neotems/penshot See the repository README for environment configuration and usage examples.
License and pricing
License: MIT. Open source and free to use.
Based on the project's public README and repository metadata.