Configuration
The behavior of the Podcast Teaser Generator can be customized through a configuration file. By default, the application uses the settings in config.json, but you can provide your own configuration file with the --config option.
Configuration File Format
The configuration file is in JSON format. Here’s an example with all available options:
{
"teaser_duration": 60,
"segment_min_duration": 3,
"segment_max_duration": 15,
"num_segments": 5,
"crossfade_duration": 500,
"output_format": "mp3",
"normalize_audio": true,
"energy_weight": 0.4,
"spectral_weight": 0.3,
"tempo_weight": 0.2,
"silence_threshold": -40,
"exclude_intro_outro": true,
"intro_duration": 30,
"outro_duration": 30,
"create_summary_teaser": true,
"summary_segments_per_track": 2,
"summary_teaser_duration": 120,
"visualize": false,
"transcription": {
"enable": true,
"method": "whisper",
"keyword_boost": ["interesting", "amazing", "surprising"]
}
}
Configuration Parameters
Analysis Weights
Parameter |
Description |
Default |
|---|---|---|
|
Weight for energy-based detection |
0.4 |
|
Weight for spectral contrast (tonal variation) |
0.3 |
|
Weight for speech tempo variations |
0.2 |
|
dB threshold for silence detection |
-40 |
Intro/Outro Handling
Parameter |
Description |
Default |
|---|---|---|
|
Whether to exclude podcast intro/outro music |
true |
|
Estimated duration of intro in seconds |
30 |
|
Estimated duration of outro in seconds |
30 |
Visualization
Parameter |
Description |
Default |
|---|---|---|
|
Generate visualization of audio analysis |
false |
Transcription Settings
Parameter |
Description |
Default |
|---|---|---|
``transcription.enable``| Whether to use transcription-based analysis |
true |
|
``transcription.method``| Method to use (“whisper” or “sphinx”) |
“whisper” |
|
``transcription.keyword_boost``| Keywords to boost in segment selection |
[] |
|
Optimizing for Different Podcast Types
Interview Podcasts
{
"segment_min_duration": 5,
"segment_max_duration": 15,
"energy_weight": 0.3,
"spectral_weight": 0.5,
"tempo_weight": 0.2
}
Solo Podcasts / Monologue
{
"segment_min_duration": 3,
"segment_max_duration": 10,
"energy_weight": 0.5,
"spectral_weight": 0.2,
"tempo_weight": 0.3
}
Storytelling Podcasts
{
"segment_min_duration": 4,
"segment_max_duration": 12,
"energy_weight": 0.4,
"spectral_weight": 0.3,
"tempo_weight": 0.3
}