Skip to main content

Grok Bot cut a 46-minute livestream into a 32-second vertical clip in 9 seconds

XXCreators Toolbox2026-11-22

Content and writingGetting startedSource read in fullRead first

Overview

Tool discovery site Creators Toolbox built a clip-page workflow with Grok Bot Routines and its computer (ffmpeg/yt-dlp/whisper-ctranslate2) and Postiz CLI. Check sources every 2 hours, cut captioned credited vertical clips, save TikTok/Instagram drafts for approval, and test on a 46-minute NASA livestream.

Workflow

Trigger: Creators Toolbox wanted to cut the time required for a clip page, an account that posts shorts made from longer videos. Check sources every 2 hours, pick the best new moment, cut vertical 1080x1920 with burned-in captions and on-screen credit, make TikTok and Instagram Reels drafts and ask for approval. The author's yes schedules them. One Routine runs a saved prompt, downloading and editing with free ffmpeg, yt-dlp and whisper-ctranslate2 on Grok Bot's computer, without occupying the author's machine. Setup takes about 20 minutes. Three requirements: Grok Bot (the Routine uses your allowance), footage you have rights to use (your stream, written streamer permission or freely reusable footage like NASA's) and Postiz connected to TikTok and Instagram. Its docs list a 7-day trial, plans from $29/month and free self-hosting.

  1. By hand: Write two files, sources and editing rules. Sources restrict footage and specify attribution. Rules define what makes a good clip. The author provides both files as examples and asks readers to substitute their sources. First, sources.md:

    # Clip sources

    Only clip from this list. Anything else needs my OK first.

    ## 1. NASA launch broadcasts

    • Find: NASA Image and Video Library API, search "live launch coverage", newest first.
    • Rights: NASA video is generally not under US copyright. Credit NASA and never imply NASA endorses this page.
    • Credit line: Video: NASA

    ## 2. My own Twitch channel (add your channel name)

    • Find: Twitch API Get Clips for my channel, clips made in the last 2 hours, most viewed first.
    • Rights: my own streams.
    • Credit line: none

    Then rules.md:

    # Clip rules

    • One moment per clip, 20 to 45 seconds long.
    • Start on the action. No intros, no "hey guys".
    • The moment must make sense with the sound off.
    • 1080x1920, captions burned in, credit line on screen the whole time.
    • Fix obvious caption typos. Never change what someone said.
    • Skip anything already listed in done.txt.
    • Never publish. Make a Postiz draft and ask me first.
  2. Bot: Set up the clip page on Grok Bot's computer. Send the message below followed by both files. The files persist on the bot's computer between runs, so set them up once. The author did this in the example run.

    Set up a clip page on your computer. Install ffmpeg, yt-dlp, jq, whisper-ctranslate2 and the Postiz CLI (npm package "postiz"). Make a folder called clip-page with sources.md and rules.md from the text below, an empty done.txt, and a queue folder.

  3. By hand: Connect Postiz. Register at postiz.com and connect TikTok and Instagram there. Have Grok Bot run postiz auth:login, open the link it returns, enter the one-time code, log in and approve. The docs say login persists on that computer so later runs need no repeat authorization. You can also use an API key in Settings → Developers. The CLI uploads clips, saves drafts and changes a draft to scheduled, enabling the yes/no approval. Postiz offers Instagram with or without a linked public Facebook page. Choose for your account type.
  4. By hand: Connect your Twitch channel (optional). Viewer clips already mark interesting moments of your own streams. Official Twitch Get Clips returns clips in the window, ranked by views. For the past 2 hours, the top clip marks what to cut. Each has title, duration and start in the archived stream. Get Clips Download returns file links and vertical versions where available to channel owners or editors only. Create a free app in the developer console and use Twitch device code flow to log in from Grok Bot, entering the short code at twitch.tv/activate. The author says to use only documented Twitch APIs because private endpoints can break without warning.
  5. Bot: Run the whole workflow manually before automating. Send the Routine prompt and add "Run this once now." Watch the result as a viewer. If it starts too late or captions are out of position, tell Grok Bot to update rules.md so the fix applies beyond this clip. The author followed the prompt step by step in the example:

    Run my clip page. Work in the clip-page folder on your computer.

    1. Read sources.md and rules.md. Only use sources on that list.
    2. Look for footage newer than anything in done.txt. If nothing is new, stop and do not message me.
    3. Download the newest new video. Use its caption file if it has one. Otherwise transcribe it with whisper-ctranslate2.
    4. Read the transcript and pick the one best moment that follows rules.md. Save the start, end, hook, why and credit line in moment.json.
    5. Cut it with ffmpeg to 1080x1920 with burned-in captions and the credit line on screen the whole time. Save the clip, a still, the cut command and a post caption with the credit in queue/<date>-<name>/.
    6. Upload the clip with the Postiz CLI and create a draft for my TikTok channel and my Instagram channel, dated for the next open slot at 12 PM or 6 PM my time. Never schedule or publish anything.
    7. Add the footage ID to done.txt.

    Send me the hook, the caption and the Postiz draft IDs here in this chat. When I reply yes, schedule those drafts with postiz posts:status. If I reply no, delete the drafts.

  6. Bot: Schedule a Routine after the manual run works. The author gives readers the line below and does not say whether it has stayed active over time:

    Save the clip page prompt as a routine that runs every 2 hours from 8 AM to 8 PM.

    Grok Bot shows the time and prompt for approval before saving. Each run then finds nothing and stays quiet, or sends a clip for approval. Ask for overnight runs if desired. There will be drafts in the morning, with nothing published without yes.

  7. Bot: Live test, find new material. The author manually ran the whole prompt on the Grok Bot box, choosing NASA launch coverage because its videos can generally be reused with credit. An empty done.txt made every source new. NASA Image and Video Library API returned launch footage with SpaceX CRS-35 resupply on October 13, 2026 at the top.
  8. Bot: Live test, download. NASA lists all files per video. The author took a medium MP4 and official captions. The 46-minute stream downloaded in about 15 seconds on the box. NASA's captions eliminated transcription. Streams without them use whisper-ctranslate2, which took about 12 minutes for two hours in an earlier test.
  9. Bot: Live test, select the moment. Search 800 lines of captions for countdown, ignition and liftoff. The 32-second selection went from T minus 15 to the rocket clearing the tower.
  10. Bot: Live test, cut the clip. The source is landscape. Use a centered square crop of the rocket with a blurred enlarged duplicate behind, captions near the bottom and Video: NASA across the top throughout. Fix the speech recognition error that heard SpaceX as "NASA's space 35th". The bot wrote the command itself and saved cut.sh. The author says readers never need to type it and the next run can reuse the visual treatment. The command cuts 00:16:54 to 00:17:26, enlarges the 608x608 crop to 1080x1080 and centers vertically, enlarges the duplicate with Gaussian blur and slight darkening, burns Archivo Black 17-point captions at bottom and Video: NASA in 44-point type at top, and outputs libx264 with CRF 20. About 9 seconds for 1080x1920 at exactly 32 seconds.
  11. Bot: Live test, queue the output. Save clip, still, captions, cut command and post copy in one folder. Mark the stream done so later runs avoid repeating it.
  12. Bot: Live test, seek approval (this step was skipped). With Postiz connected, it would upload and make one TikTok and one Instagram draft. A sample message says the new clip goes from T minus 15 to liftoff and the caption identifies NASA's October 13, 2026 SpaceX CRS-35 delivery to the International Space Station with Video: NASA. Drafts are set for tomorrow 12 PM, with yes to schedule and no to delete. Postiz requires an account and was not run in this test. Each previous step ran on the Grok Bot box.
  13. Bot: Let the bot troubleshoot. Seven fixes. (1) If it messages with no new material, check prompt step 2 still says to exit quietly and done.txt is updating. (2) If it cuts twice, have it show done.txt. A missing ID means step 7 failed. Run once by hand and add the ID. (3) If download fails, update yt-dlp for public sites because they change. For NASA check whether the file URL still opens. (4) If captions cover the image, have the bot move them and save in rules.md for every clip. (5) For missing Postiz login, have it run postiz auth:status. If unauthenticated, repeat postiz auth:login and approve the new code. (6) If TikTok or Instagram refuses the video, reupload with --adjust to resize to 1080p and re-encode as MP4. (7) If yes did not publish, run postiz posts:list and check whether the draft became scheduled.

Check: The author used step 5 to inspect the manual run, verified 1080x1920 at exactly 32 seconds, and found and corrected the SpaceX caption recognition error under the rules. The author says every step before Postiz ran on the box. There are no long-term scheduled results.

Key points and results

  • Drafts require approval before scheduling. Step 6 of the Routine prompt bans scheduling and publishing. A run ends quietly or sends a clip for approval. Overnight runs accumulate drafts, with nothing sent without yes.
  • Running every 2 hours consumes your Grok Bot allowance. The author says it adds up in a day and gives no specific usage.
  • Rights to footage are required. Use your stream, written permission or freely reusable material like NASA video. Rebroadcasting another streamer needs approval. TikTok and Instagram copyright and reuse rules still apply with attribution.
  • Postiz is the only outside service. The docs list a 7-day trial, plans from $29/month and free self-hosting. Its CLI changes drafts to scheduled, enabling yes/no approval.
  • Measured speed (author's claim, not reproduced). A 46-minute stream downloaded in about 15 seconds on the box. The moment was found in 800 caption lines. ffmpeg cut a 1080x1920, exactly 32-second clip in about 9 seconds. In an earlier test, whisper-ctranslate2 transcribed an uncaptained two-hour stream in about 12 minutes.
  • Use official captions when available. NASA's caption file meant no transcription. whisper-ctranslate2 is for streams without captions.
  • The bot writes and saves ffmpeg commands. The reader need never type the command. Grok Bot writes and keeps cut.sh so future runs match the style.
  • Fix caption errors without changing speech. rules.md permits obvious corrections. The test fixed "NASA's space 35th", a misrecognition of SpaceX.
  • Delegate troubleshooting. Seven fixes use the bot to update yt-dlp, rerun postiz auth:login, upload with --adjust, check drafts with postiz posts:list, edit rules.md and so on.
  • The full version is on the author's site. More examples and all screenshots are at creatorstoolbox.com.

Contributions from others

Added by others (not the author)

  • An X Community Note by other users on the same article says people seeking an AI-driven scheduler gravitate to Postiz for its API, CLI and self-hosting.
  • Another X Community Note says ask before making clips of a streamer. A public consent request keeps a clear yes on record.

Source

Platform
X
Author
Creators Toolbox
Published
Categories
Content and writing, Getting started

What this evidence label means

Source read in full

We read the source (post, article or transcript). That only means the original was read. It does not mean this site reproduced the author's results.

Read the editorial and evidence policy

Other cases in this scenario

This unofficial community project is independent of xAI. xAI has neither approved nor endorsed it. No sign-up. The methods and figures come from the original authors.