Project Structure
Understanding the codebase organization is key to customization:Configuration System
All user-facing configuration lives inconfig.json. The src/config.py module provides getter functions:
Adding New Config Options
1. Add toconfig.example.json:
src/config.py:
Configuration Best Practices
- Use descriptive names (
whisper_model, notwm) - Provide sensible defaults with
.get(key, default) - Support environment variables for sensitive data:
- Document options in
config.example.json
Extending Provider Classes
YouTube Class Extension
TheYouTube class (src/classes/YouTube.py:35) handles video generation and upload. Here’s how to extend it:
Example: Add Custom Video Effects
Twitter Class Extension
TheTwitter class (src/classes/Twitter.py:24) handles social media automation.
Example: Custom Post Formatting
Adding New Providers
To add support for a new platform (e.g., TikTok, Instagram): 1. Create a new class file:src/classes/TikTok.py
config.json:
src/config.py:
src/cron.py or CLI:
Custom LLM Providers
Thesrc/llm_provider.py module abstracts LLM calls. To add a new provider:
Example: Add Anthropic Claude
config.json:
Modifying Prompts
Prompts are scattered throughout provider classes. To systematically customize them: Centralize prompts insrc/prompts.py:
Testing Your Extensions
When developing custom features: 1. Use verbose mode:status.py module provides logging:
Contributing Extensions
If you build something useful:- Document your changes in
docs/ - Update
config.example.jsonwith new options - Add examples and usage instructions
- Submit a pull request to the main repository
- See CONTRIBUTING.md for guidelines