A developer building an AI photo-editing mini program recently asked for help in a group chat: their mini program review was held up over unauthorized use of public figures’ likenesses, and WeChat required them to “add technical safeguards.” They’d already integrated WeChat’s image safety review, but its API couldn’t identify celebrities or influencers. Alibaba Cloud offers a ready-made celebrity recognition API, but it requires business verification—and they’re a sole proprietor.
This problem is common in mini programs for AI portraits, face swapping, avatar generation, and poster design. Reviewers aren’t asking, “Have you integrated a content safety API?” They want to know, “Can users use your product to generate or share an image of a public figure?” If even one step in the blocking workflow is missing, your submission may be rejected again and again.
This article focuses on public figure recognition APIs. We’ll clarify what WeChat’s content safety API can and can’t do, compare the onboarding requirements of five popular public figure recognition APIs, and then lay out a four-layer technical blocking solution that sole proprietors can implement.
What you’ll get: By the end, you’ll know which public figure recognition API to choose, how to combine the safeguards in a blocking workflow, and how to clearly explain your technical solution when submitting your mini program for review.

Why Public Figure Recognition APIs Have Become a Hard Requirement for Mini Program Reviews
WeChat has been tightening its review standards for AI-generated and image-editing mini programs. There’s a clear regulatory basis for this. The Provisions on the Administration of Deep Synthesis of Internet-based Information Services, which took effect on January 10, 2023, require providers of services that edit biometric information such as faces and voices to tell users to notify the people being edited and obtain their separate consent. The Measures for Labeling AI-Generated Synthetic Content, which took effect on September 1, 2025, go further by requiring both explicit and implicit labels for AI-generated content.
Against this backdrop, platforms are especially concerned about the misuse of “celebrity likenesses”: users uploading an actor’s still for an AI portrait, swapping faces using an influencer’s photo, or entering a celebrity’s name to generate an image “in their style.” These actions may infringe portrait rights, and mini programs—as service providers—are expected to implement technical safeguards. In other words, when reviewers ask you to “add technical safeguards,” they’re asking you to identify public figures at both the upload and generation stages.
What WeChat’s Content Safety API Can and Can’t Do
Many developers’ first instinct is to integrate WeChat’s official content safety API, but it addresses a different set of problems. The table below compares what WeChat’s API can detect with what’s actually needed to prevent unauthorized use of someone’s likeness.
| Detection category | WeChat msgSecCheck / mediaCheckAsync | What’s needed to prevent likeness infringement |
|---|---|---|
| Pornographic or vulgar content | ✅ Supported | Required |
| Politically sensitive content | ✅ Supported (some political figures) | Required |
| Violent, illegal, or abusive content | ✅ Supported | Required |
| Celebrity recognition | ❌ Doesn’t identify people | Core requirement |
| Influencer and streamer recognition | ❌ Not supported | Core requirement |
| Celebrity names in prompts | ⚠️ Checks for text violations, not intent to depict someone | Core requirement |
WeChat’s msgSecCheck is for text, while mediaCheckAsync checks images and audio asynchronously. They mainly detect pornographic, politically sensitive, violent, and abusive content—but they won’t tell you “which celebrity is in this image.” So if you’ve only integrated WeChat’s API, reviewers will see that you’ve covered general content safety, but not public figure likeness blocking.
🎯 Technical tip: A public figure recognition API is only one part of the blocking workflow. Blocking risky prompts is often more important—and cheaper. We recommend using a Large Language Model through the APIYI apiyi.com platform to review prompt semantics. It’s compatible with the OpenAI API format, and individual developers can register and use it directly, making it a quick way to fill this gap.
Comparing 5 Public Figure Recognition API Options
To avoid inaccuracies, the options below are based on each provider’s official English documentation. One thing to keep in mind: public figure recognition falls under facial recognition, and nearly all major providers restrict access to these services. That’s why sole proprietors can feel like they have “nowhere to turn.”

Public Figure Recognition API: Access Requirements and Capabilities
| Option | API capabilities | Access requirements | Coverage of Chinese celebrities/influencers | Pricing reference |
|---|---|---|---|---|
| Alibaba Cloud Visual Intelligence / Content Security | Celebrity recognition with DetectCelebrity; the enhanced image moderation service can return public figure names and locations with infoType=publicFigure |
Developer feedback suggests business identity verification is required | High | Billed by usage |
| Tencent Cloud Image Moderation (IMS) | Returns violation labels and secondary labels; may return a person’s name in some scenarios | Business verification (sole proprietors can try verification with a business license) | Medium to high | Billed by usage |
| AWS Rekognition | RecognizeCelebrities recognizes up to 64 celebrities in a single image and returns names, IDs, confidence scores, and reference links |
An overseas account with a linked credit card is enough; no approval required | Strong for international celebrities, limited for Chinese influencers | First 1 million images at $0.001 per image |
| Hive Celebrity Recognition | Covers 50,000+ political figures, athletes, religious leaders, and celebrities | Requires an API key; geared more toward enterprise customers | Medium | Not published on the website |
| Azure / Google Cloud Vision | Celebrity recognition | Since June 2022, Azure has been available only to managed customers; Google is limited to media and entertainment customers who pass manual review | Medium | Approval required |
As the table shows, AWS Rekognition has the lowest access barrier. However, its celebrity database focuses mainly on international figures from film, sports, business, and politics, with limited coverage of Chinese influencers and livestreamers. Also, faces are sensitive personal information under China’s Personal Information Protection Law (PIPL). Sending user-uploaded photos to an overseas service may raise data export compliance concerns, which you’ll need to consider when preparing your review materials.
Practical Options for Sole Proprietors
First, let’s clear up a common misconception: under the identity verification systems used by major cloud providers in China, sole proprietors with a business license can usually apply through the “business verification” channel. Some highly sensitive APIs may also require additional qualification reviews. So the idea that “a sole proprietor isn’t a business” isn’t entirely accurate. Contact Alibaba Cloud or Tencent Cloud support first to confirm the requirements for the specific API you need.
If you find that you can’t get access, you’ll need to take a different approach: don’t put all the pressure on “identifying who it is.” Instead, use multiple layers of screening to keep public figure likenesses out of the generation pipeline altogether. Reviewers care about how effective your safeguards are and whether the overall process is robust—not which public figure recognition API you use.
A 4-Layer Technical Screening Architecture for Public Figures
This architecture follows the principle of “screen early, tighten controls at each layer.” The earlier layers are cheaper and faster; the later ones are more precise and more expensive. Most risky requests can be stopped in the first two layers.

Responsibilities of the 4 Screening Layers
| Layer | What it screens for | How it works | Typical latency | Access requirements |
|---|---|---|---|---|
| Layer 1: Prompt screening | “Generate a portrait of [celebrity]” or “replace the face with [influencer]’s” | Keyword list + Large Language Model semantic analysis | 0.3–1 second | None; individuals can integrate it |
| Layer 2: Initial image screening | Film stills, posters, magazine covers, livestream screenshots | WeChat mediaCheckAsync + vision model image classification |
1–3 seconds | None |
| Layer 3: Public figure recognition API | Real photos of known public figures | Alibaba Cloud / Tencent Cloud / AWS Rekognition | 0.5–2 seconds | Depends on the provider |
| Layer 4: Product-level safeguards | Content that slips through and disputed content | Authorization statements, reporting and takedowns, manual review, AI labels | Asynchronous | None |
Layer 1 offers the best return for the effort. For AI generation mini-programs, many infringing requests come from prompts—for example, by directly entering a celebrity’s name or asking for a “face like [someone].” Keyword lists alone are easy to evade with homophones, pinyin, or abbreviations. Using a Large Language Model for semantic analysis can significantly improve recall.
The idea behind Layer 2 is “identify what it is, not who it is.” Vision models will often refuse to identify real people in photos, and OpenAI explicitly restricts GPT-4o’s ability to identify real people. But determining whether an image is a “film still, celebrity poster, magazine cover, or livestream screenshot with a channel logo” is well within their capabilities. These image types are risk signals on their own, so you can block them directly or send them to Layer 3.
Layer 1: Example Code for Prompt Semantic Screening
Here’s a minimal example that uses a Large Language Model to determine whether a prompt involves a real public figure. The model returns structured JSON, which the backend uses to allow or block the request.
import json
from openai import OpenAI
client = OpenAI(api_key="YOUR_API_KEY", base_url="https://api.apiyi.com/v1") # APIYI unified interface
def check_prompt(prompt: str) -> dict:
resp = client.chat.completions.create(
model="gpt-4o-mini",
response_format={"type": "json_object"},
messages=[
{"role": "system", "content": "Determine whether the user's prompt requests the generation, imitation, or replacement of the likeness of a real public figure (celebrity, influencer, livestreamer, politician, or athlete)."
"Output JSON only: {\"risk\": true/false, \"names\": [], \"reason\": \"\"}"},
{"role": "user", "content": prompt},
],
)
return json.loads(resp.choices[0].message.content)
print(check_prompt("Generate a portrait like the singer who performed 'Blue and White Porcelain'"))
In this example, the prompt doesn’t mention a name directly, so a keyword list wouldn’t catch it. But the Large Language Model can infer which singer it refers to and flag it as high-risk.
📦 Expand to see the full version: dual-layer prompt and image screening
import base64, json
import boto3
from openai import OpenAI
llm = OpenAI(api_key="YOUR_API_KEY", base_url="https://api.apiyi.com/v1") # APIYI unified interface
rek = boto3.client("rekognition", region_name="ap-southeast-1")
BLOCK_NAMES = {"Example Celebrity A", "Example Influencer B"} # Local list; block matches immediately
def llm_json(messages):
resp = llm.chat.completions.create(
model="gpt-4o-mini",
response_format={"type": "json_object"},
messages=messages,
)
return json.loads(resp.choices[0].message.content)
def layer1_prompt(prompt: str) -> bool:
if any(n in prompt for n in BLOCK_NAMES):
return True
r = llm_json([
{"role": "system", "content": "Determine whether the prompt involves the likeness of a real public figure. Output JSON only: {\"risk\": bool}"},
{"role": "user", "content": prompt},
])
return r.get("risk", False)
def layer2_image(img_bytes: bytes) -> str:
"""Don't identify the person; only classify the image type and return block / suspect / pass."""
b64 = base64.b64encode(img_bytes).decode()
r = llm_json([
{"role": "system", "content": "Do not identify the person's identity. Only classify the image type. Output JSON: "
"{\"type\": \"selfie|film_still|poster|magazine|live_screenshot|non_human|other\", \"real_person\": bool}"},
{"role": "user", "content": [
{"type": "image_url", "image_url": {"url": f"data:image/jpeg;base64,{b64}"}},
]},
])
if r.get("type") in {"film_still", "poster", "magazine", "live_screenshot"}:
return "block"
return "suspect" if r.get("real_person") else "pass"
def layer3_celebrity(img_bytes: bytes, threshold: float = 90.0) -> bool:
res = rek.recognize_celebrities(Image={"Bytes": img_bytes})
return any(c["MatchConfidence"] >= threshold for c in res["CelebrityFaces"])
def moderate(prompt: str, img_bytes: bytes | None) -> str:
if layer1_prompt(prompt):
return "blocked: prompt"
if img_bytes:
verdict = layer2_image(img_bytes)
if verdict == "block":
return "blocked: image_type"
if verdict == "suspect" and layer3_celebrity(img_bytes):
return "blocked: public_figure"
return "pass"
In the full version, Layer 3 is called only for images that Layer 2 classifies as “photos of real people.” This saves on public figure recognition API costs and reduces the amount of facial data that needs to be sent to an external service. If you already have access to Alibaba Cloud or Tencent Cloud’s API, just replace layer3_celebrity with the corresponding SDK call.
🚀 Get started quickly: Layers 1 and 2 both rely on Large Language Models. We recommend starting with APIYI at apiyi.com to get test credits. Run 100 real user prompts and images through the system, then measure the block rate and false positive rate before launch. You can use the same code to switch between GPT, Gemini, Claude, and other models to compare results.
Thresholds and Response Strategies for Public Figure Identification
Identification results aren’t simply “yes” or “no.” Confidence thresholds directly determine false positive and false negative rates. Hive’s official documentation suggests a threshold of 0.85 for real photos and 0.9 for AI-generated content. AWS Rekognition returns MatchConfidence on a scale of 0–100, so you can apply the same approach.
| Confidence range | Action | User message | Notes |
|---|---|---|---|
| ≥ 90 | Block immediately | “This image may contain a public figure. Please upload a photo of yourself.” | High-confidence match with a low likelihood of false positives |
| 70–90 | Block and send to a manual review queue | “Your image is under review. Please wait.” | Lookalikes, unusual angles, and occlusion often fall into this range |
| Face detected but no match | Allow and retain logs | None | Normal photos of everyday users |
| No face detected | Allow | None | Landscapes, pets, objects, and so on |
For AI portrait products, a more reliable approach is to add “identity verification”: ask users to upload a selfie as a baseline first, then require subsequent photos to meet a face-similarity threshold against that baseline before allowing generation. This helps prevent users from using someone else’s face, even if the public figure identification API doesn’t cover a lesser-known influencer.
💡 Recommendation: If your main risk comes from influencers and streamers in China, no overseas public figure identification API will provide sufficient coverage. Focus instead on Layer 1 prompt blocking and an “identity verification” mechanism. You can connect the Layer 1 Large Language Model invocation through APIYI apiyi.com, typically at a fraction of the cost of image recognition.
How to Describe Your Public Figure Blocking Measures When Submitting for Review
Getting the technology right isn’t enough—you also need to make sure reviewers understand it. In your review notes or supplemental materials, explain your approach using the following structure:
- Blocking workflow: Describe which detection capabilities are used at each of the three stages: prompts, image uploads, and generated results.
- Public figure identification capabilities: Specify the public figure identification API or alternative solution you use, and what happens when a match is detected.
- Product safeguards: Cover portrait authorization terms in the user agreement, the “Only upload photos of yourself” confirmation prompt shown before upload, the reporting channel, and the takedown timeline.
- AI content labeling: Add a visible “AI-generated” label to generated images and include an invisible label in the file metadata.
- Testing evidence: Attach screenshots or screen recordings showing that celebrity photos and prompts containing celebrity names are blocked.
The fifth point is often the most persuasive. Reviewers will often test the product directly with celebrity photos. Your chances of approval can improve significantly if your recording shows “upload a celebrity still → blocked” and “enter a celebrity’s name → blocked.”
Frequently Asked Questions About Public Figure Identification APIs
Q1: Can a Large Language Model completely replace a public figure identification API?
No. Mainstream vision Large Language Models typically refuse to identify real people in photos due to privacy policies. Even when they can identify someone, their results may be inconsistent, making them unsuitable for definitive identity checks. Large Language Models are best suited to semantic prompt blocking and image type classification. Identity recognition should still be handled by a dedicated public figure identification API. You can test the blocking performance of different models on the same set of samples through APIYI apiyi.com, then decide how to divide the work.
Q2: Can AWS Rekognition identify Chinese celebrities?
It can identify some well-known Chinese-language film and TV stars and athletes, but its coverage of Chinese influencers, streamers, and short-video creators is much more limited. It’s also an overseas service, so you’ll need to assess cross-border data transfer compliance when processing sensitive personal information such as face data. We recommend calling it only for suspicious images flagged at Layer 2 and clearly disclosing this in your privacy policy.
Q3: Are sole proprietors always unable to access Alibaba Cloud’s celebrity identification service?
Not necessarily. Sole proprietors can usually complete a cloud provider’s business verification with a business license, though some APIs require additional qualification reviews. We recommend submitting a support ticket to ask about the requirements for the specific API, and keeping Tencent Cloud as a backup option.
Q4: Is it expensive to use a Large Language Model for prompt blocking?
No. A single prompt review usually consumes only a few hundred tokens, and the per-request cost with a lightweight model is far lower than that of a single image recognition call. Calling the model through APIYI apiyi.com also lets you pay based on usage, making it suitable for mini programs with fluctuating review volumes.
Q5: What should I do if my product is still rejected after implementing blocking?
First, check whether the rejection cites issues with existing content. For example, do sample images or templates in the mini program already feature celebrities? Many developers implement technical blocking only to be rejected again because the sample images on the home page use celebrity likenesses. Replace all of these with images you own the rights to or AI-generated virtual portraits.
Summary
When a mini program is told to “add technical safeguards” after infringing on a public figure’s likeness, the solution isn’t to find a one-size-fits-all public figure recognition API. It’s to build a complete moderation pipeline. WeChat’s content safety API only covers general violations and can’t identify celebrities or influencers. Alibaba Cloud and Tencent Cloud offer public figure recognition capabilities that are a better fit for the Chinese market, but they require business verification. AWS Rekognition has the fewest barriers to entry, but its coverage of Chinese influencers is limited, and using it involves cross-border data transfers. Azure and Google are generally not available to regular developers.
For sole proprietors, the most practical approach is to first check whether a business license is enough to complete verification with a cloud provider. At the same time, deploy two safeguards: semantic filtering of prompts and initial screening by image type. Then add identity verification, authorization declarations, and manual review. Finally, provide reviewers with test recordings to show that the safeguards work.
We recommend using APIYI at apiyi.com to quickly build Large Language Model-based moderation for the first two layers. Test the block rate with real samples before submitting your application for review.
Author: APIYI Team, focused on putting AI Large Language Model APIs into practice. Visit APIYI at apiyi.com for more technical solutions and test credits.
