Spaces:
Sleeping
Sleeping
A newer version of the Gradio SDK is available:
6.3.0
metadata
title: Automated AI Video & Social Media Publisher (n8n converted)
emoji: 🚀
colorFrom: purple
colorTo: indigo
sdk: gradio
app_file: app.py
python_version: '3.10'
Automated AI Video & Social Media Publisher
This Hugging Face Space automates the process of creating AI avatar videos and publishing them to social media. It is a direct Python conversion of an n8n workflow.
How it Works
The workflow performs the following steps:
- News Research (Hacker News): Fetches the top 10 AI/LLM-related stories from Hacker News and selects the most viral one.
- Script Generation (OpenAI): Generates a 30-second monologue script for an AI avatar video based on the selected news story and comments.
- Caption Generation (OpenAI): Creates both long and short captions for social media posts.
- AI Video Creation (Heygen): Uses the generated script to create an AI avatar video.
- Media Upload (Blotato): Uploads the generated video to Blotato's media library.
- Social Media Publishing (Blotato): Publishes the video and captions to various social media platforms (currently YouTube is enabled in the Python code, others are disabled as per the n8n workflow).
Setup & Secrets
To run this Space, you must set the following environment variables as Space Secrets in the "Settings" tab of your Hugging Face Space:
OPENAI_API_KEY: Your OpenAI API key.HEYGEN_API_KEY: Your Heygen API key (a paid Heygen plan is required for video generation, as the free plan is insufficient).BLOTATO_API_KEY: Your Blotato API key.
Optional Environment Variables (set if different from defaults or dynamic):
HEYGEN_AVATAR_ID(Default:c67f3f55c5fd49d080e19a2ea9666e77)HEYGEN_VOICE_ID(Default:e515d746526f448fa533afddc97e4933)HEYGEN_BACKGROUND_VIDEO_URL(Default:https://database.blotato.io/storage/v1/object/public/public_media/4ddd33eb-e811-4ab5-93e1-2cd0b7e8fb3f/videogen2-render-e6b398a2-5859-4a77-88ef-2345bcefdc98.mp4)BLOTATO_INSTAGRAM_IDBLOTATO_YOUTUBE_ID(Default:5174)BLOTATO_TIKTOK_IDBLOTATO_FACEBOOK_IDBLOTATO_FACEBOOK_PAGE_IDBLOTATO_THREADS_IDBLOTATO_TWITTER_IDBLOTATO_LINKEDIN_IDBLOTATO_PINTEREST_IDBLOTATO_PINTEREST_BOARD_IDBLOTATO_BLUESKY_ID