Skip to main content
Glama

frs__DetectLiveFaceByBase64

Detects whether a face in a Base64-encoded image comes from a live person, helping block printed photos, screen replays, and video spoofing; supports one face per image.

Instructions

[FRS] 静默活体检测是基于人脸图片中可能存在的畸变、摩尔纹、反光、倒影、边框等信息,判断图片中的人脸是否来自于真人活体,有效抵御纸质翻拍照、电子翻拍照以及视频翻拍等各种攻击方式。静默活体检测支持单张图片,不支持多人脸图片。

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "image_base64": "<image_base64>",
      "project_id": "<project_id>"
    },
    "name": "frs__DetectLiveFaceByBase64"
  }
}

Input Schema

NameRequiredDescriptionDefault
project_idYes项目ID,获取方法请参见[获取项目ID/账号租户名/AK/SK](https://support.huaweicloud.com/api-face/face_02_0056.html)。
image_base64Yes图像数据,Base64编码,要求:

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.4.0

TDQS

B3.4/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

With no annotations supplied, the description carries the burden of behavioral disclosure. It usefully discloses what the detector defends against and that only one face per image is allowed, but it says nothing about the result format (liveness verdict versus score), accuracy thresholds, failure behavior on multi-face input, authentication or quota constraints.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Roughly three sentences, front-loaded with the detection purpose, then the defensive capability, then the input constraint. The attack-type list is slightly promotional but still conveys real information, so there is little waste.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

There is no output schema and no annotations, so the description is the only place to explain what comes back from a liveness check, and it omits that entirely. For a two-parameter detection tool it covers purpose and input limits adequately but leaves the agent guessing about the response shape.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 100%, so both parameters are already documented in structured form. The description only adds a constraint that maps to image_base64 (single face, no group photos), which is modest value beyond the schema; it says nothing extra about project_id.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description names a specific operation (silent liveness detection) and states exactly what it judges (whether a face comes from a live person), including the cues it uses (moire patterns, reflections, borders). It also scopes input to a single image and excludes multi-face images, which helps distinguish it. It stops short of contrasting itself with the ByFile/ByUrl/DetectLiveByBase64 siblings, so the differentiation is only partial.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines3/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The single-face constraint and the enumeration of attack types imply the intended use case (anti-spoofing checks on one uploaded photo), but there is no explicit 'use this when...' or 'use the file/URL variant instead' guidance. The agent must infer routing from the tool name alone.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Deploy Server

Other Tools