Compare commits

...

6 Commits

Author SHA1 Message Date
lik
344b1d7332 tmp 2026-06-14 11:45:21 +08:00
lik
162e63d887 tmp 2026-06-13 19:20:17 +08:00
lik
8cfc022460 tmp 2026-06-13 19:11:22 +08:00
lik
6672d3ad65 增加了ai问题列表api 2026-06-13 18:57:26 +08:00
lik
ab5e35b796 prompt 2026-06-12 16:03:55 +08:00
lik
0f35130500 修改了prompt 2026-06-12 15:25:12 +08:00
6 changed files with 29 additions and 9 deletions

View File

@@ -5,7 +5,7 @@
## 长期记忆 ## 长期记忆
当用户分享以下信息时,使用 `write_file` 将其保存到 `/memories/user_memory.txt` 当用户分享以下信息时,使用 `write_file` 将其保存到 `/memories/user_memory.txt`
- 个人基本信息、生活习惯 - 个人基本信息、生活习惯、个人喜好
- 健康或医疗相关的任何信息(身体健康、看病、住院、手术、病情、用药、过敏、体质、病历、检查报告、长期健康目标等) - 健康或医疗相关的任何信息(身体健康、看病、住院、手术、病情、用药、过敏、体质、病历、检查报告、长期健康目标等)
- 医疗信息要记录对应的日期时间,如果用户没有提供具体的,要根据前后信息记录大概时间。 - 医疗信息要记录对应的日期时间,如果用户没有提供具体的,要根据前后信息记录大概时间。
- 如果有些信息需要准确的时间点,请跟用户确认时间后记录下来。 - 如果有些信息需要准确的时间点,请跟用户确认时间后记录下来。

View File

@@ -34,22 +34,23 @@ class Prompts {
# 能力 # 能力
- 基于服务项目和服务协议,解答陪诊流程、价格、注意事项 - 基于服务项目和服务协议,解答陪诊流程、价格、注意事项
- 提供就诊准备建议(不提供医疗诊断) - 提供就医规划,就诊准备建议,情绪价值(不提供医疗诊断)
- 就诊准备要专业,符合医疗规范
- 调用工具查询天气、路线、医院、医生等信息 - 调用工具查询天气、路线、医院、医生等信息
# 铁律 # 铁律
1. 服务相关回答必须基于参考信息,不编造。 1. 服务相关回答必须基于参考信息,不编造。
2. 用户有需求时自然引导下单,无需求时不推销 2. 感知用户情绪,给予共情回应
3. 感知用户情绪,给予共情回应 3. 涉及医疗问题,提醒以医生诊断为准
4. 涉及医疗问题,提醒以医生诊断为准 4. 超出能力范围,引导联系客服
5. 超出能力范围,引导联系客服 5. 保护用户隐私提示AI内容需甄别
6. 保护用户隐私提示AI内容需甄别。
## 参考信息 ## 参考信息
用户信息:${userInfo_str}; 用户信息:${userInfo_str};
用户记忆:${usermem_str}; 用户记忆:${usermem_str};
服务项目:${JSON.stringify(services)}; 服务项目:${JSON.stringify(services)};
服务协议:${JSON.stringify(agreement)}; 服务协议:${JSON.stringify(agreement)};
联系电话: 18618162956(微信同号)
`; `;
} }
} }

View File

@@ -2,6 +2,7 @@ import ResponseUtil from "../utils/responseUtil.js";
import services from "../resource/services.js"; import services from "../resource/services.js";
import agreement from "../resource/agreement.js"; import agreement from "../resource/agreement.js";
import hospitalInfo from "../resource/hospital_info.js"; import hospitalInfo from "../resource/hospital_info.js";
import aiquick_questions from "../resource/aiquick_questions.js";
import { hospitalRanking, departmentRankings } from "../resource/fudan_hospital_ranking.js"; import { hospitalRanking, departmentRankings } from "../resource/fudan_hospital_ranking.js";
class HandlerResource { class HandlerResource {
@@ -52,6 +53,15 @@ class HandlerResource {
return ResponseUtil.internalError(ctx, err.message); return ResponseUtil.internalError(ctx, err.message);
} }
} }
// 获取陪诊服务问题
async getAiQuickQuestions(ctx) {
try {
return ResponseUtil.success(ctx, { aiquick_questions }, "查询成功");
} catch (err) {
return ResponseUtil.internalError(ctx, err.message);
}
}
} }
export { HandlerResource }; export { HandlerResource };

View File

@@ -0,0 +1,8 @@
const aiquick_questions = [
'陪诊服务的流程是什么?',
'如何预约陪诊服务?',
'陪诊服务收费标准?',
'怎么加客服微信?',
]
export default aiquick_questions

View File

@@ -93,7 +93,7 @@ const services = [
id: 3, id: 3,
title: '代问诊', title: '代问诊',
subtitle: '代您到医院与医生进行问诊', subtitle: '代您到医院与医生进行问诊',
price: '268.00', price: '260.00',
image: '/images/wz1.jpg', image: '/images/wz1.jpg',
icon: 'heart', icon: 'heart',
tag: '', tag: '',
@@ -183,7 +183,7 @@ const services = [
id: 5, id: 5,
title: '出入院代办', title: '出入院代办',
subtitle: '出入院手续代办', subtitle: '出入院手续代办',
price: '198.00', price: '268.00',
image: '/images/yy.jpg', image: '/images/yy.jpg',
icon: 'user-checked', icon: 'user-checked',
tag: '', tag: '',

View File

@@ -30,6 +30,7 @@ function registerRoutes(app) {
router.get("/hospital-info", handlerResource.getHospitalInfo.bind(handlerResource)); router.get("/hospital-info", handlerResource.getHospitalInfo.bind(handlerResource));
router.get("/hospital-ranking", handlerResource.getHospitalRanking.bind(handlerResource)); router.get("/hospital-ranking", handlerResource.getHospitalRanking.bind(handlerResource));
router.get("/department-rankings", handlerResource.getDepartmentRankings.bind(handlerResource)); router.get("/department-rankings", handlerResource.getDepartmentRankings.bind(handlerResource));
router.get("/ai-quick-questions", handlerResource.getAiQuickQuestions.bind(handlerResource));
app.use(router.routes()); app.use(router.routes());
app.use(router.allowedMethods()); app.use(router.allowedMethods());