Tencent Cloud Portrait Segmentation
Paste the following prompt into your AI chat to install this skill:
Please follow https://skillhub.cn/install/skillhub.md and install @tencent-adm/tencentcloud-yt-segment-portrait.
About this skill
Problem
In image workflows, a common task is to separate a person from a busy background for poster composites, video assets, e-commerce product images, or virtual character work. Manual masking or asking a general model to “look” at the image can produce unstable results and cannot reliably prove that the output is a real segmentation. This skill reduces the task to one synchronous API call: pass in an image, detect the full human outline, and return a portrait segmentation result, avoiding the risk of mistaking a plausible-looking result for the final cutout.
How It Works
The skill is built on Tencent Cloud's SegmentPortraitPic capability and runs through the core script scripts/main.py. It accepts an input image, calls the Tencent Cloud portrait segmentation service, performs human outline detection and cutout processing, and returns the result synchronously. It requires the portrait segmentation service to be enabled, an API key to be configured, environment variables to be set, and a runtime compatible with Python 3.7+ and tencentcloud-sdk-python; the provided notes say the script can install dependencies automatically. The execution contract for an agent is also explicit: when a user supplies an image and intends portrait segmentation, the skill should run the script directly, not merely print the path, not ask for confirmation, and not manually install dependencies; if the call fails, it must return a clear error and must not let the model guess or fabricate segmentation content.
Boundaries
This skill is suited for portrait segmentation on one or a few images, with an input size limit of ≤5MB and a synchronous return model. It is not a general-purpose segmentation tool, and it does not promise support for arbitrary poses, multiple overlapping people, heavy occlusion, or non-person subjects. In production use, check service enablement, key permissions, and network reachability; preserve original error messages for failed calls so the issue can be traced to parameters, quotas, service state, or the input image. It fits into an existing media pipeline as a deterministic step from raw image to portrait asset.
Use Cases
- When an operations lead has an event poster background and needs to cut out a person for scene replacement.
- Before video packaging, a motion designer needs clean portrait cutouts to add captions, effects, and backgrounds.
- E-commerce designers need to extract person outlines from product photos for transparent-background hero images.
- Engineers integrating user image uploads need a stable Tencent Cloud segmentation call for cutout outputs.
Best For
- Operations designers who need quick person cutouts from event posters for background replacement.
- Video packaging specialists who need clean portrait assets for compositing talking-head or event videos.
- E-commerce designers who need person outlines extracted for transparent-background product pages.
- AI application engineers who need a deterministic Tencent Cloud segmentation call in image pipelines.
Related Skills
Generate an interactive HTML product detail page from images and copy, with multi-product carousel, inline text editing, design controls, and PDF/JPG/PSD export support.
Enter a material name to get preview and download links for free, commercially usable video assets, with paid platform options, pricing, and search suggestions when results are limited.
A local CLI for Dreamina image and video generation, including credit checks, async submission, result queries, and task history review.
Generate and validate JianYing drafts from storyboard JSON with narrated commentary, original-sound preservation, timing checks, and draft inspection.