podcast_llm.utils.text

Utilities for text processing and formatting in podcast generation.

This module provides utilities for working with text content in podcast scripts and outlines. It handles formatting and conversion of podcast content into different text representations.

Key components: - generate_markdown_script: Converts podcast outline and script into markdown format

for easy viewing and sharing

The module helps with: - Converting internal podcast data structures to human-readable formats - Generating documentation and review materials from podcast content - Maintaining consistent text formatting across the application

podcast_llm.utils.text.generate_markdown_script(topic: str, outline: PodcastOutline, script: list) None[source]

Generate a markdown formatted version of the podcast script.

Parameters:
  • topic (str) – The main topic of the podcast

  • outline (PodcastOutline) – The podcast outline containing sections and key points

  • script (list) –

    List of dictionaries containing script lines with structure: {

    ’speaker’: str, # Speaker identifier (‘Interviewer’ or ‘Interviewee’) ‘text’: str # Line content

    }

Returns:

Markdown formatted script including topic, outline and conversation

Return type:

str