Skip to content

A sophisticated system that uses multiple AI agents to research, create, and polish video scripts for social media platforms. The system employs specialized agents for research, script writing, polishing, and evaluation to ensure high-quality, engaging content.

Notifications You must be signed in to change notification settings

kr3t3n/smolagents-video-script-generator

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Multi-Agent Video Content Planner

A sophisticated system that uses multiple AI agents to research, create, and polish video scripts for social media platforms. The system employs specialized agents for research, script writing, polishing, and evaluation to ensure high-quality, engaging content.

Features

  • Multi-Agent Architecture

    • ResearchAgent: Plans and conducts topic research
    • ScriptWriterAgent: Creates initial video scripts
    • PolishingAgent: Enhances scripts for engagement
    • EvaluatorAgent: Assesses quality and provides feedback
  • Advanced Content Research

    • Dynamic search query generation
    • Web content extraction and processing
    • ChromaDB-based vector storage for semantic search
    • URL deduplication and content filtering
  • Intelligent Script Generation

    • Platform-specific formatting (TikTok, YouTube Shorts, Instagram Reels)
    • Automatic timestamp generation
    • Engaging transitions and hooks
    • Visual suggestions and hashtag generation
  • Quality Assurance

    • Automated evaluation of research quality
    • Script engagement scoring
    • Improvement suggestions
    • Multiple retry attempts for low-scoring outputs

Requirements

  • Python 3.8+
  • DeepSeek API key
  • SerpAPI key
  • Required Python packages (see requirements.txt)

Installation

  1. Clone the repository:
git clone https://github.com/kr3t3n/smolagents-video-script-generator.git
cd smolagents-video-script-generator
  1. Create and activate a virtual environment:
python -m venv venv
source venv/bin/activate  # On Windows: venv\Scripts\activate
  1. Install dependencies:
pip install -r requirements.txt
  1. Create a .env file with your API keys:
DEEPSEEK_API_KEY=your_deepseek_api_key
SERPAPI_KEY=your_serpapi_key

Usage

  1. Run the script:
python deepseek_agent.py
  1. Follow the interactive prompts to specify:

    • Video format (TikTok, YouTube Short, Instagram Reel)
    • Video length
    • Number of questions/items
    • Topic
    • Number of URLs per search query
    • Number of search terms
  2. The system will generate:

    • Research data
    • Initial script
    • Polished script
    • Evaluation reports
    • Human-readable output

Output Structure

output/
├── [Topic]_[Timestamp]/
│   ├── debug/
│   │   └── (Debug logs and raw API responses)
│   ├── research/
│   │   └── (Research data and evaluations)
│   ├── script/
│   │   └── (Initial and polished scripts)
│   ├── evaluation/
│   │   └── (Evaluation reports)
│   ├── final_script.json
│   └── final_script.txt

Configuration

  • Adjust scoring thresholds in main()
  • Modify agent prompts in respective agent classes
  • Configure retry attempts and delays in ContentRetrieverTool

Error Handling

  • Comprehensive error handling for API calls
  • Automatic retries for failed searches
  • Fallback mechanisms for incomplete responses
  • Detailed error logging

Contributing

  1. Fork the repository
  2. Create a feature branch
  3. Commit your changes
  4. Push to the branch
  5. Create a Pull Request

📄 License

Free to use and open to everyone.

👨‍💻 Author

Created by Georgi from Mangia Studios Limited.

❤️ Support

If you find this project useful, consider buying me a coffee ☕

Acknowledgments

  • DeepSeek API for language model capabilities
  • SerpAPI for web search functionality
  • ChromaDB for vector storage
  • All other open-source libraries used in this project

About

A sophisticated system that uses multiple AI agents to research, create, and polish video scripts for social media platforms. The system employs specialized agents for research, script writing, polishing, and evaluation to ensure high-quality, engaging content.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages