Framework for creating AI agents to manage and interact with your media library.
View Demo »
Report Bug
·
Request Feature
·
New Agent Request
Director provides a advance AI first framework for developing intelligent agents that can interact with your audio/video collection in natural language. Whether you're dealing with social content, lectures, movies, youtube videos, TV shows, talks, music, or other digital content, Director offers variety of tools to build powerful AI-powered assistants.
It uses the VideoDB’s scalable "video as data" infrastructure to create agentic workflows. For example, in natural language you can give commands like “upload this video and send the bullet point summary on my slack”
and the agent will handle the rest.
📺 Watch: Intro video
director_demo_medium.mp4
-
🤖 AI Agent Framework: Build custom agents to perform tasks like summarization, search, indexing, clipping and library organization.
-
🎨 Innovative User Experience: Complete framework for interacting with your media library with chat based UI, Video player and next-gen interactions that can help you create the experience you need.
-
🔍 Media Analysis: Your video infra is taken care by VideoDB. Connect with popular LLMs, Databases, and GenAI APIs seamlessly.
-
🧩 Extensible Architecture: Easily add new capabilities through tools and modules. Run locally or deploy on your own cloud.
- Python 3.9 or higher
- Node.js 22.8.0 or higher
- npm
1. Clone the repository:
git clone https://github.com/video-db/Director.git
cd Director
2. Run the setup script:
./setup.sh
This script will:
- Install nvm (Node Version Manager) if not already installed
- Install Node.js 22.8.0 using nvm
- Install Python and pip
- Set up virtual environments and install dependencies for frontend and backend
Supported platforms:
- Mac
- Linux
- Windows (WSL)
3. Configure the environment variables:
Edit the .env
files to add your API keys and other configuration options.
To start both the backend and frontend servers:
make run
This will start the backend server on http://127.0.0.1:8000
and the frontend server on http://127.0.0.1:8080
.
To run only the backend server: make run-be
To just run the frontend development server: make run-fe
The project documentation is built using MkDocs. To serve the documentation locally on port 9000:
Activate the environment and install dependencies for development:
source backend/venv/bin/activate
make install-be
mkdocs serve -a localhost:9000
To build the documentation:
mkdocs build
To create a new agent in Director, follow these steps:
-
Copy the template: Duplicate
sample_agent.py
inDirector/backend/director/agents/
and rename it to your agent's name. -
Update class details:
- Rename the class (e.g., from
SampleAgent
toYourAgentName
) - Update
agent_name
anddescription
- Rename the class (e.g., from
-
Modify the
run
method:- Update parameters and docstring
- Implement your agent's logic
-
Handle output and status updates:
- Use appropriate content types (TextContent, VideoContent, ImageContent, SearchResultContent)
- Update
self.output_message.actions
for progress indicators - Use
push_update()
to emit progress events - Set content status (progress, success, error) and messages
-
Implement error handling:
- Set error status and messages if issues occur
-
Finalize the response:
- Call
self.output_message.publish()
to emit final state and persist session - Return an
AgentResponse
with result, message, and data
- Call
-
Register the agent:
- Import your new agent class in
Director/backend/director/handler.py
- Add it to the
self.agents
list inChatHandler
- Import your new agent class in
Remember to consider creating reusable tools if your agent's functionality could be shared across multiple agents.
Contributions are what make the open source community such an amazing place to be learn, inspire, and create. Any contributions you make are greatly appreciated.
- Fork the Project
- Create your Feature Branch (
git checkout -b feature/AmazingFeature
) - Commit your Changes (
git commit -m 'Add some AmazingFeature'
) - Push to the Branch (
git push origin feature/AmazingFeature
) - Open a Pull Request