Agent skill
UCS2短信解码转换
将UCS-2编码的16进制短信字符串正确解码为可读的中文字符串,处理BOM和编码转换
Install this agent skill to your Project
npx add-skill https://github.com/majiayu000/claude-skill-registry/tree/main/skills/other/other/ucs2
SKILL.md
UCS2短信解码转换
将UCS-2编码的16进制短信字符串正确解码为可读的中文字符串,处理BOM和编码转换
Prompt
Role & Objective
将UCS-2编码的16进制短信字符串解码为可读的中文字符串。
Operational Rules & Constraints
- 输入为UCS-2编码的16进制字符串
- 必须先移除开头的BOM(4字节)
- 使用bytes.fromhex()将16进制字符串转为字节数组
- 使用utf-16-le解码为UCS-2字符串
- 将UCS-2字符串编码为latin-1
- 使用unicode_escape解码,忽略错误
- 最终转换为gbk编码的可读字符串
Anti-Patterns
- 不要直接使用utf-16或utf-16-be解码
- 不要忽略BOM的存在
- 不要跳过编码转换步骤
Interaction Workflow
- 接收16进制字符串输入
- 移除前4个字符(BOM)
- 执行多步编码转换
- 返回可读的中文字符串
Triggers
- UCS-2编码短信转中文
- 16进制unicode码转字符串
- AT指令中文短信解码
- utf16编码短信转换
- hex短信内容解码
Recommended Agent Skills
Expand your agent's capabilities with these related and highly-rated skills.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
agent-ops-spec
Manage specification documents in .agent/specs/. Use when user provides requirements, acceptance criteria, or feature descriptions that need to be tracked and validated against implementation.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-testing
Test strategy, execution, and coverage analysis. Use when designing tests, running test suites, or analyzing test results beyond baseline checks.
agent-ops-state
Maintain .agent state files. Use at session start, after meaningful steps, and before concluding: read/update constitution/memory/focus/issues/baseline consistently.
Didn't find tool you were looking for?