extract_chinese_text
Extracts Chinese characters from mixed text, removing non-Chinese elements, and returns the Chinese-only text and its character count. Useful for copy length checks and word counts.
Instructions
抽取文本中的中文字符,剔除标点、空格、英文、数字等其它字符。
Args: text: 待处理的文本,长度上限 200000 个字符。
Returns: chinese_text 为仅由中文字符按原顺序组成的文本; chinese_count 为抽取出的中文字数; error 为失败原因,成功时为空字符串。
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| text | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| error | Yes | ||
| chinese_text | Yes | ||
| chinese_count | Yes |