feat(medications): 添加药品分析日志记录功能
This commit is contained in:
@@ -43,10 +43,12 @@ export class MedicationAnalysisService {
|
||||
* @returns 流式文本响应
|
||||
*/
|
||||
async analyzeMedication(medicationId: string, userId: string): Promise<Readable> {
|
||||
this.logger.log(`开始分析药品: ${medicationId}`)
|
||||
try {
|
||||
// 1. 获取药品信息
|
||||
const medication = await this.medicationsService.findOne(medicationId, userId);
|
||||
|
||||
this.logger.log(`获取到药品信息: ${JSON.stringify(medication, null, 2)}`)
|
||||
// 2. 构建专业医药分析提示
|
||||
const prompt = this.buildMedicationAnalysisPrompt(medication);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user