From 'Won't Open' to Ready to Post: A Complete AI Agent Workflow in KwaFlux
Follow one broken phone clip through diagnosis, repair, Quality Repair, and a platform export, all requested from an AI assistant and run by KwaFlux.
Key takeaways
- An AI assistant connected to KwaFlux can take a damaged clip through diagnosis, repair, Quality Repair, and a platform export, one request at a time or all at once.
- Diagnose first. It's quick, it tells you whether the file can be repaired, and it picks the repair mode.
- Each step is a separate KwaFlux task with progress you can watch and a result the assistant can check before it moves on.
- Every file is written next to the original, which stays untouched.
This guide follows one file all the way through: an old phone clip of a birthday that stopped recording when the battery died. It won't open in any player. By the end, there's a repaired copy, a cleaned-up 1080p version, and a YouTube-ready export, each one requested from an AI assistant and run by KwaFlux on your own computer.
In this guide, you'll learn the order of steps that works, what to say at each one, what the assistant gets back, and what to do when a step doesn't go as planned.
Contents
- What is an agent workflow?
- Before you start
- Step 1. Diagnose the file
- Step 2. Repair it
- Step 3. Check that it plays
- Step 4. Improve the picture
- Step 5. Export for the platform
- Doing it in one request
- Troubleshooting
- What repair can't bring back
- FAQ
What is an agent workflow?
An agent workflow is a multi-step job that an AI assistant carries out by calling tools in sequence, checking each result before choosing the next step.
The checking is what separates it from a script. If the diagnosis says the file can't be repaired, the assistant should stop and tell you, not carry on and run an enhancement on nothing.
Before you start
You need:
- KwaFlux open, with your assistant connected over MCP. The quick start covers setup.
- The damaged file on a local drive, not a network share.
- A copy of the original. Repair writes a new file and leaves the original alone, but a second copy somewhere else costs nothing.
- Optionally, a clip that plays, recorded on the same phone with the same settings. Repair can use it as a reference.
Step 1. Diagnose the file
Ask:
Check D:\Phone\birthday.mp4. It won't open. Can it be repaired?
The assistant runs KwaFlux's diagnosis, which needs no sign-in. The diagnosis reads the file's structure and reports whether it can be repaired and which mode it recommends: Quick for a broken index or header, Deep or Smart for heavier damage, or Auto to try the gentler pass first. For what the modes do, see how to fix a video that won't open.
If the diagnosis says the file can't be repaired, stop here. Nothing later in this workflow can recover footage that isn't in the file.
Step 2. Repair it
Repair it with the recommended mode. Use D:\Phone\party-ok.mp4 as the reference clip.
The assistant queues the repair and waits on the task. Your host shows a progress bar while KwaFlux works, and you can stop the wait at any point; the assistant can then cancel the task if you ask. In KwaFlux, the task appears in the task list with a tag showing which assistant submitted it.
When the task succeeds, the assistant gets the repaired file's name. The file is next to birthday.mp4.
Pro tip: The reference clip matters most when the file's header is gone, which is common when a phone loses power mid-recording. A clip from the same phone with the same resolution and frame rate tells the repair how the missing parts should look.
Step 3. Check that it plays
Open the repaired file in a player and scrub to the end. This is the one step worth doing yourself. An assistant can read the task result, but it can't watch the video.
If it plays but the last seconds are missing, that's expected: those frames weren't written before the battery died.
Step 4. Improve the picture
The clip is from an older phone: 720p, noisy indoor light. Ask:
Run Quality Repair on the repaired file and output 1080p.
The assistant picks 1080p from the same list of output sizes the app offers, and KwaFlux builds the job with the same rules as an export you'd click. For which setting does what, see Quality Repair.
If you want to judge the effect before committing to a full export, use the free preview in the app; the assistant runs full jobs only.
Step 5. Export for the platform
Export the enhanced version for YouTube at HD 1080P.
The assistant asks KwaFlux for the YouTube format's tiers, picks HD 1080P, and queues the export. KwaFlux's converter offers 64 formats and 435 quality tiers, including presets for YouTube, TikTok, Instagram, and other platforms.
When it's done, the folder holds the original, the repaired copy, the enhanced 1080p file, and the YouTube export. If a file with the same name already existed, the new one gets a (1) added instead of replacing it.
Doing it in one request
Once you've seen the steps, you can ask for the whole chain:
Diagnose D:\Phone\birthday.mp4. If it can be repaired, repair it with the recommended mode using D:\Phone\party-ok.mp4 as reference. Then run Quality Repair at 1080p and export the result for YouTube at HD 1080P. Stop and tell me if any step fails.
Or, if your host shows MCP prompts, pick KwaFlux's repair a damaged video prompt, which walks the assistant through the diagnosis and repair in the right order. KwaFlux also ships prompts for platform export and AI quality repair.
Because each step is its own task with a structured result, the assistant can tell success from failure without guessing, and the last line, "Stop and tell me if any step fails," gives it permission to stop. For why one wait call per step is enough, see how KwaFlux's tools stay light on context.
Troubleshooting
| Symptom | Cause | Fix |
|---|---|---|
| "Path not allowed" | Network drive or relative path | Copy the file to a local drive and give the full path |
| Diagnosis says it can't be repaired | The file is empty or the data isn't there | Check the file size; if it's 0 KB, there's nothing to repair |
| Repair finishes but the file still won't play | The mode wasn't enough for the damage | Ask for Deep or Smart mode, and add a reference clip |
| Repaired clip has no sound | The audio part of the file was lost | Try again with a reference clip that has sound; see how video file repair works |
| The assistant moved on after a failed step | Your request didn't say to stop | Add "stop and tell me if any step fails" |
| A step fails with a sign-in or plan error | That step writes a file | Sign in to KwaFlux, then ask the assistant to retry |
What repair can't bring back
File repair rebuilds the structure around footage that was recorded. It can't create frames that weren't written, footage that was cut off, or a file that was overwritten. Quality Repair improves what's in the frames; it doesn't recover what isn't there. If the battery died ten seconds before the candles, those ten seconds are gone, and no workflow changes that.
Final thoughts
Diagnose, repair, check that it plays, improve, export. The order is the same whether you click or ask, but with an AI assistant each step is one sentence, each one shows up in KwaFlux as a task you can watch, and the original file stays where it was.
Hand the repair chain to your assistant
KwaFlux's local MCP server lets Codex, Claude, Cursor, and other MCP apps diagnose, repair, enhance, and export your videos on your computer. AI processing runs locally on your GPU — media files are not uploaded for processing. It runs on Windows 10 (64-bit, version 1809 or later), Windows 11, and macOS 12 or newer on Apple Silicon. Importing files and exploring the app need no account. Signing in with an active paid plan is required only to export, convert, repair a file, or download a file from a link.
Try It on Your Own Footage
Download KwaFlux and preview effects on your own footage for free before you pay — no account needed, and your media is processed on your GPU, not uploaded for processing. Video previews run 1, 3, or 5 seconds; stabilization previews run 5, 15, or 30 seconds.
Frequently asked questions
Can AI fix a corrupted video?
Partly. Damage to a file's structure, such as a missing index after a recording was cut off, can often be repaired, and AI enhancement can then clean up the picture. Neither can bring back footage that wasn't written. See how to fix a video that won't open.
Why diagnose a video before repairing it?
Because the diagnosis tells you whether repair is possible and which mode fits the damage. Running a heavy repair on a file that only needs its index rebuilt wastes time, and running any repair on an empty file wastes more.
What is a reference file in video repair?
It's a healthy clip recorded on the same device with the same settings. Repair tools use it to learn the structure the damaged file should have, which helps most when the header is missing.
Should I enhance a video before or after repairing it?
After. Enhancement needs a file that opens and plays. Repair first, check it plays, then improve the picture. For the full sequence, see how video file repair works.
Can an AI agent run several editing steps without me?
Yes, if each step returns a result it can check. Ask it to stop and report when a step fails, and check the final video yourself, because the assistant can read results but can't watch the footage.
Sources
- Model Context Protocol, "Prompts" (2025-11-25; user-selected workflows) (accessed 2026-10-25)
- Model Context Protocol, "Progress" (2025-11-25; progress notifications) (accessed 2026-10-25)


