Automated News to Podcast Script Generation (Bilingual)
detail.loadingPreview
Scrapes BBC News, filters suitable articles, generates a podcast script using LLMs, and converts it to speech, with support for English and Chinese.
About This Workflow
This workflow automates the process of news aggregation, content suitability assessment, script generation, and text-to-speech conversion. It targets news articles from BBC News, evaluates their potential for storytelling using an LLM classifier, fetches detailed content, and then leverages another LLM to craft an engaging podcast script. Finally, it converts the generated script into audio using a Hugging Face text-to-speech model.
The workflow is designed to handle multiple news items and structure them into a coherent podcast format. It also includes a conditional step to check for the existence of a script before proceeding to the text-to-speech conversion. The ultimate goal is to create structured metadata in both English and Chinese, suitable for various downstream applications.
Key Features
- Web Scraping: Extracts news article titles and links from the BBC News homepage.
- Content Filtering: Utilizes a Gemini LLM to classify news articles based on their suitability for storytelling, filtering out unsuitable or negative content.
- Detail Extraction: Fetches the full content of articles deemed suitable for podcasting.
- Podcast Script Generation: Employs a Gemini LLM to transform news articles into engaging podcast scripts, formatted for direct use with text-to-speech services.
- Bilingual Output Support: The LLM prompt is designed to create content that can be adapted for both English and Chinese. While the current workflow primarily focuses on generating English scripts, the prompt structure can be extended for Chinese language generation.
- Conditional Processing: Includes an 'If' node to ensure script generation is conditional on the presence of extracted content.
- Text-to-Speech Conversion: Integrates with Hugging Face's text-to-speech API to convert the generated script into audio.
How To Use
- Trigger: Start the workflow by clicking 'Test workflow'.
- Fetch BBC News: The
Fetch BBC News Pagenode retrieves the HTML content of the BBC News homepage. - Extract News Blocks: The
Extract News Blocknode uses CSS selectors to extract news titles and links. - Split Titles: The
Split Outnode separates the extractednewsTitlefield. - Extract News Content: The
Extract News Contentnode further extracts thetitle,link, anddescriptionfor each news item. - News Classifier: The
News Classifiernode (using Gemini) evaluates each news item's title and description to determine if it's suitable for storytelling. - Fetch BBC News Detail: For articles classified as 'Suitable', the
Fetch BBC News Detailnode retrieves the full article content using the extracted link. - Extract Detail: The
Extract Detailnode scrapes the main content of the news article. - Filter Empty Detail: The
Filter Empty Detailnode removes any articles where the main content could not be extracted. - Aggregate: The
Aggregatenode collects all the processed news details. - Basic Podcast LLM Chain: This node (using Gemini) takes the aggregated news details and generates a podcast script according to the detailed prompt, aiming for an engaging narrative. It outputs a JSON with a
podcast_scriptkey. - Output Parser: The
Output Parsernode ensures the LLM output adheres to the expected JSON schema. - If script exists: This node checks if a
podcast_scriptwas successfully generated. - Hugging Face Text-to-Speech: If a script exists, this node sends the
podcast_scriptto the Hugging Face API to generate audio. The output is an audio file.
Credentials Required:
- Google Gemini (PaLM) Api account: For the
GeminiandNews Classifiernodes. - HuggingFaceApi account: For the
Hugging Face Text-to-Speech.node.
Apps Used
Workflow JSON
{
"id": "f2020ade-d623-45d9-8fd8-334dbe28a037",
"name": "Automated News to Podcast Script Generation (Bilingual)",
"nodes": 22,
"category": "Content Generation",
"status": "active",
"version": "1.0.0"
}Note: This is a sample preview. The full workflow JSON contains node configurations, credentials placeholders, and execution logic.
Get This Workflow
ID: f2020ade-d623...
About the Author
N8N_Community_Pick
Curator
Hand-picked high quality workflows from the global community.
Statistics
Related Workflows
Discover more workflows you might like
Automated News to Podcast Script Generation (EN/ZH)
Generates podcast scripts from BBC news articles, with potential for multilingual output and TTS integration.
Perplexity Research to HTML Web Page Generator
This workflow takes a research topic, generates structured content using AI, and converts it into a responsive HTML web page styled with Tailwind CSS.
Automated News-to-Blog Post Generation with Multilingual Metadata
This workflow automates the creation of SEO-optimized blog posts from news articles, including title, slug, and meta descriptions, with potential for multilingual content generation.