关于 itsm-chat-reply-recommendation
面向 ITSM 实时聊天支持人员的技能,根据事件背景、聊天记录和相关知识内容生成回复建议。它还会参考相似事件与已知问题,并提供故障排查或升级交接措辞。
主要功能
- 01读取事件背景与聊天记录
- 02搜索知识文章和相似事件
- 03查找已知问题及解决方案
- 04生成适配上下文的回复建议
- 05提供升级与交接消息
适用场景
- 01为实时聊天中的技术问题拟定回复
- 02依据知识文章解释已知解决方案
- 03为超出处理范围的问题准备交接
MCP 相关
该技能使用 MCP 工具读取事件与互动记录,搜索知识文章、相似事件和已知问题,并可记录建议或更新事件。
安装
复制下面的命令,在终端中运行。
npx skills add https:/ / github.com/ happy-technologies-llc/ happy-platform-skills --skill itsm-chat-reply-recommendation安装后在 Claude Code 中输入/itsm-chat-reply-recommendation确认已加载。
详细介绍
聊天回复建议
概述
此技能为处理实时支持对话的 ITSM 客服人员提供了一套生成聊天回复建议的结构化方法。内容包括:
- 分析事件上下文,了解用户的问题和历史记录
- 将问题与知识库文章进行匹配,查找已知解决方案
- 查看类似历史事件的解决记录
- 生成结合上下文且包含适当技术细节的回复建议
- 根据用户的技术熟练程度调整语气和复杂度
- 当问题超出客服人员的处理范围时,提供升级和移交消息
适用场景: 实时聊天客服人员在支持对话中需要协助,以便拟定准确且有帮助的回复,尤其是遇到复杂技术问题或需要快速查找知识库内容时。
所需插件: com.snc.incident(事件管理),可选 com.glide.interaction(Agent Workspace)
前提条件
- 角色:
itil、sn_interaction_read或agent_workspace_user - 访问权限: 对
incident、kb_knowledge、problem、interaction的读取权限 - 知识: 熟悉常见 IT 支持场景、知识库结构和聊天礼仪
- 插件: 必须激活
com.snc.incident;建议激活com.glide.interaction,以获取聊天上下文
操作步骤
第 1 步:获取当前事件的上下文
获取与聊天会话关联的事件。
使用 MCP:
Tool: SN-Get-Record
Parameters:
table_name: incident
sys_id: [incident_sys_id]
fields: sys_id,number,short_description,description,state,priority,category,subcategory,assignment_group,assigned_to,caller_id,caller_id.name,caller_id.vip,cmdb_ci,business_service,opened_at,work_notes_list
使用 REST API:
GET /api/now/table/incident/[incident_sys_id]?sysparm_fields=sys_id,number,short_description,description,state,priority,category,subcategory,assignment_group,assigned_to,caller_id,cmdb_ci,business_service,opened_at&sysparm_display_value=true
第 2 步:查看聊天/交互历史记录
获取对话线程,了解已讨论的内容。
使用 MCP:
Tool: SN-Query-Table
Parameters:
table_name: interaction
query: document=incident^document_id=[incident_sys_id]^ORDERBYDESCsys_created_on
fields: sys_id,type,direction,message,opened_for,assigned_to,state,channel,sys_created_on
limit: 20
使用 REST API:
GET /api/now/table/interaction?sysparm_query=document=incident^document_id=[incident_sys_id]^ORDERBYDESCsys_created_on&sysparm_fields=sys_id,type,direction,message,opened_for,assigned_to,state,channel,sys_created_on&sysparm_display_value=true&sysparm_limit=20
第 3 步:搜索知识库中的解决方案
查找与事件描述匹配的相关知识文章。
使用 MCP:
Tool: SN-Query-Table
Parameters:
table_name: kb_knowledge
query: workflow_state=published^short_descriptionLIKE[keyword1]^ORtextLIKE[keyword1]
fields: sys_id,number,short_description,text,kb_category,workflow_state,rating
limit: 5
使用 REST API:
GET /api/now/table/kb_knowledge?sysparm_query=workflow_state=published^short_descriptionLIKE[keyword1]^ORtextLIKE[keyword1]&sysparm_fields=sys_id,number,short_description,text,kb_category&sysparm_display_value=true&sysparm_limit=5
第 4 步:查找类似的已解决事件
查找描述相似且已解决的历史事件。
使用 MCP:
Tool: SN-Query-Table
Parameters:
table_name: incident
query: state=6^ORstate=7^short_descriptionLIKE[keyword]^ORcategoryLIKE[category]^ORDERBYDESCresolved_at
fields: sys_id,number,short_description,close_code,close_notes,resolved_at,category
limit: 10
使用 REST API:
GET /api/now/table/incident?sysparm_query=state=6^ORstate=7^short_descriptionLIKE[keyword]^ORDERBYDESCresolved_at&sysparm_fields=sys_id,number,short_description,close_code,close_notes,resolved_at,category&sysparm_display_value=true&sysparm_limit=10
第 5 步:检查已知问题
确认问题是否关联到已有解决方法的已知问题。
使用 MCP:
Tool: SN-Query-Table
Parameters:
table_name: problem
query: active=true^known_error=true^short_descriptionLIKE[keyword]
fields: sys_id,number,short_description,workaround,fix,state,known_error
limit: 5
使用 REST API:
GET /api/now/table/problem?sysparm_query=active=true^known_error=true^short_descriptionLIKE[keyword]&sysparm_fields=sys_id,number,short_description,workaround,fix,state,known_error&sysparm_display_value=true&sysparm_limit=5
第 6 步:生成聊天回复建议
根据收集到的上下文,生成合适的回复选项。
按场景分类的回复模板:
场景 1:找到已知解决方案(匹配到知识库文章)
Hi [Name], I found a solution that should help with this issue.
Here are the steps:
1. [Step from KB article]
2. [Step from KB article]
3. [Step from KB article]
You can also find detailed instructions in our knowledge base: KB[number] - [Article Title]
Could you try these steps and let me know if the issue is resolved?
场景 2:已知错误且有解决方法
Hi [Name], this is a known issue that our team is actively working to resolve permanently.
In the meantime, here is a workaround that should get you back up and running:
[Workaround steps]
I have linked your incident to the known problem (PRB[number]) so you will be notified when the permanent fix is deployed.
场景 3:需要进行故障排查
Hi [Name], I would like to help you troubleshoot this issue. Could you provide a few more details?
1. When did this issue first start?
2. Are you seeing any error messages? If so, could you share them?
3. Has anything changed recently (software updates, new hardware, etc.)?
This will help me narrow down the cause and find the right solution for you.
场景 4:需要升级处理
Hi [Name], thank you for your patience. Based on what we have found so far, this issue requires specialized support from our [Team Name] team.
I am going to transfer you to a specialist who can assist further. Here is a summary of what we have covered:
- [Summary point 1]
- [Summary point 2]
Your incident [INC number] will stay open, and the specialist will have all the context from our conversation.
场景 5:VIP 来电者
Hello [Name], thank you for reaching out. I understand this issue is affecting your work, and I want to make sure we get it resolved as quickly as possible.
I am prioritizing your request and [action being taken]. I will provide you with an update within [timeframe].
Is there anything else I can assist with in the meantime?
第 7 步:记录交互
记录建议的回复以及已采取的措施。
使用 MCP:
Tool: SN-Add-Work-Notes
Parameters:
table_name: incident
sys_id: [incident_sys_id]
work_notes: |
=== CHAT REPLY RECOMMENDATION ===
Context: [Brief issue summary]
KB Match: KB[number] - [Title] (confidence: high/medium/low)
Similar Incidents: [INC numbers]
Known Error: [PRB number if applicable]
Recommended Reply: [Reply type - Solution/Workaround/Troubleshooting/Escalation]
[Reply text used]
工具用法
MCP 工具参考
| 工具 | 适用场景 |
|---|---|
SN-Get-Record | 获取事件和用户上下文 |
SN-Query-Table | 搜索交互记录、知识库文章、类似事件和已知错误 |
SN-Natural-Language-Search | 使用自然语言搜索知识库 |
SN-Update-Record | 在聊天期间更新事件状态或指派信息 |
SN-Add-Work-Notes | 记录建议的回复和采取的措施 |
SN-Execute-Background-Script | 执行复杂匹配逻辑或批量分析回复建议 |
REST API 参考
| 端点 | 方法 | 用途 |
|---|---|---|
/api/now/table/incident | GET | 查询事件上下文 |
/api/now/table/kb_knowledge | GET | 搜索知识库 |
/api/now/table/problem | GET | 查找已知错误 |
/api/now/table/interaction | GET | 查看聊天历史记录 |
/api/now/table/sys_user | GET | 查看来电者详情和 VIP 状态 |
最佳实践
- 回复前先阅读: 务必查看聊天记录,避免询问已回答过的问题
- 匹配技术水平: 根据用户是否具备技术背景调整语言复杂度
- 提供选项: 如果有多种解决方案,先介绍最简单的方案,再提供其他选项
- 明确预期: 务必告知预计解决时间或后续步骤
- 留意 VIP 用户: 检查来电者的 VIP 标记,并相应调整优先级和语气
- 链接知识库文章: 引用具体的知识库文章,方便用户今后自行解决问题
- 确认问题已解决: 关闭前务必请用户确认问题已解决
故障排除
未找到匹配的知识库内容
原因: 搜索词过于具体,或知识库中没有该主题的内容
解决方案: 扩大搜索范围。尝试按类别搜索,而不是按确切描述搜索。也可参考类似事件的解决模式。
无法获取聊天记录
原因: 未创建交互记录,或聊天是通过其他渠道进行的
解决方案: 检查 sys_journal_field 中事件的评论。查看 sys_email 中基于电子邮件的通信记录。
建议回复过于技术化
原因: 回复基于技术性知识库文章生成,未进行简化
解决方案: 查看来电者的角色和部门。用通俗语言重写技术步骤,并提出可以陪同用户逐步操作。
升级目标不明确
原因: 未明确特定问题类型的分配组路由规则
解决方案: 查询 sys_user_group,查找与事件类别匹配的组。检查分配查找规则,或使用标准升级矩阵。
示例
示例 1:密码重置聊天
# 1. Get incident context
Tool: SN-Get-Record
Parameters:
table_name: incident
sys_id: [sys_id]
fields: number,short_description,caller_id.name,category
# 2. Find KB article
Tool: SN-Query-Table
Parameters:
table_name: kb_knowledge
query: workflow_state=published^123TEXTQUERY321=password reset self-service
fields: number,short_description,text
limit: 3
# Recommended reply:
# "Hi [Name], I can help you reset your password. You can do this
# yourself anytime by visiting [Self-Service Portal URL] and clicking
# 'Forgot Password'. Would you like me to walk you through it, or
# would you prefer I initiate a reset from my end?"
示例 2:已知问题导致的应用程序错误
# 1. Check for known errors
Tool: SN-Query-Table
Parameters:
table_name: problem
query: known_error=true^short_descriptionLIKESAP login
fields: number,short_description,workaround
limit: 3
示例 3:批量回复分析
Tool: SN-Execute-Background-Script
Parameters:
description: Analyze most common chat topics and recommended replies
script: |
gs.info('=== CHAT TOPIC ANALYSIS ===');
var ga = new GlideAggregate('incident');
ga.addQuery('contact_type', 'chat');
ga.addQuery('sys_created_on', '>=', gs.daysAgo(30));
ga.addAggregate('COUNT');
ga.groupBy('category');
ga.orderByAggregate('COUNT', 'DESC');
ga.setLimit(10);
ga.query();
while (ga.next()) {
gs.info('Category: ' + ga.category.getDisplayValue() + ' | Chat Incidents: ' + ga.getAggregate('COUNT'));
}
相关技能
itsm/email-recommendation- 基于电子邮件的回复建议itsm/incident-triage- 用于聊天路由的分诊上下文itsm/kb-generation- 为聊天推荐的解决方案生成知识库文章itsm/incident-summarization- 为升级交接总结事件