podcast_llm.gui

Graphical user interface module for podcast generation.

This module provides a web-based GUI using Gradio for generating podcasts. It allows users to interactively specify podcast generation parameters including:

  • Topic selection

  • Operation mode (research or context-based)

  • Source materials (files and URLs) for context mode

  • Number of Q&A rounds

  • Checkpointing preferences

  • Custom configuration

  • Output paths for text and audio

The GUI provides a user-friendly way to access the podcast generation functionality without needing to use the command line interface.

The module handles form submission, input validation, logging setup, and coordinates with the core generation functionality. It uses temporary files for logging and provides real-time feedback during the generation process.

podcast_llm.gui.main()[source]

Main entry point for the Gradio web interface.

Creates and launches a Gradio interface that provides a user-friendly way to interact with the podcast generation system. The interface includes: - Topic input and conversation settings - Mode selection (research vs context) - Source file and URL inputs for context mode - Behavior options like checkpointing - Output configuration options

The interface is organized into logical sections with clear labels and tooltips. All inputs are validated and passed to the generate() function.

Returns:

None

podcast_llm.gui.submit_handler(topic: str, mode_of_operation: str, source_files: list[str], source_urls: str, qa_rounds: int, use_checkpoints: bool, custom_config_file: str | None, text_output: str, audio_output: str) None[source]

Handle form submission for podcast generation.

Processes user inputs from the GUI form and calls the generate function with appropriate parameters. Handles input validation, logging, and file path processing.

Parameters:
  • topic – The podcast topic

  • mode_of_operation – Either ‘research’ or ‘context’ mode

  • source_files – List of source file paths to use as context

  • source_urls – Newline-separated string of URLs to use as context

  • qa_rounds – Number of Q&A rounds per section

  • use_checkpoints – Whether to enable checkpointing

  • custom_config_file – Optional path to custom config file

  • text_output – Path to save text output (optional)

  • audio_output – Path to save audio output (optional)

Returns:

None