Capabilities and preparation
Fixed use of video-remove-auto to complete video watermark cleaning; the server automatically identifies the content to be removed and repairs the corresponding frames. When the material and target are clear, execute directly according to existing authorization and keep the original video for comparison; for requirements such as specifying elements to keep or region control, verify the invocation method according to the platform documentation.
Invoke the server-side processing capability through the parameters supported by the current CLI; for specific parameters, query help or contracts; follow this Skill's automatic removal command binding. Depends on meitu-kaipai-cli, verified target version 0.1.8, compatible with >=0.1.8 <0.2.0。
On first execution, readPlatform access, parse the CLI entry point and check the version and tool video-remove-auto --help. When JSON fields or media restrictions are unclear, query according to the platform documentation the entry for the current tool in kaipai contracts ; when encountering output parsing, server-side inquiries, or execution exceptions, readRunning and recovery。
Collect input
- Obtain one real video file or URL from the current request and attachments; do not repeatedly ask when the information is clear. When there are multiple candidates and the target is unclear, ask; do not automatically choose on the user's behalf; when the user has explicitly authorized processing them one by one, invoke separately and record the tasks.
- For local materials, use a real readable path; for remote materials, first followPlatform accessto download the original resource, then upload it as a local file. When there is only a media ID, first query the Task or history of the session it belongs to to obtain the real URL, then download; if that fails, ask the user to download it themselves and provide the local original file.
- When continuing an existing task, add
-r '<session_id>'; for a new task, omit the session. Apply defaults, prepare login, and handle missing input according to the platform documentation; query the current help for optional parameters, and omit them when unspecified. - Keep the original source, real local path, and session as recovery input. After the user supplements with a downloaded file, continue with the original target; do not treat failed results as source material.
Upload and submit
Using the parsed CLI entry point, pass the prepared local file as an independent parameter:
kaipai tool video-remove-auto --video-file '<本地视频路径>'
After the CLI validates the file, obtain an owned CDN URL through the built-in Meitu upload pipeline, then submit the task and by default wait for this execution to end. Do not first call create-room / add-media, and do not construct media placeholder text. Parameter files and independent prechecks are used only as needed; for safe parameter passing and cleanup rules, see the platform documentation.
Follow-up and delivery
- Save the original input,
session_id / room_urland all real Task IDs; continuously read the stdout and stderr of the original command separately, and do not open another poll at the same time. TASK_STATE_COMPLETEDand only deliver the processing result after obtaining the usable artifact URL for this execution. HTTP 200, stream end, exit code 0, orend.reason=resultalone do not prove completion; an unknown task status cannot be regarded as success.- Use the host's available native preview/attachment or a complete clickable URL, preserve query parameters, and deliver all available Parts one by one; for partial success, deliver the successful parts first. When there is an actual
room_url, attach the session entry for starting the shoot; do not construct links from IDs. - When there is a disconnection, timeout, or unknown acceptance, first query the original session and task; do not automatically resubmit. Only initiate a new attempt after the failure cause has been fixed and the user has authorized a retry; if downloading the output artifact fails, only resume the download. For specific inquiry, recovery, and local save steps, see the running instructions.