feat(ai): 新增 ChatClient 配置与控制器
- 添加 ChatClientConfig 配置类,初始化 ChatClient 并配置系统提示和顾问 - 创建 ChatClientController 控制器,支持普通对话与流式对话接口- 引入 lombok依赖并添加 MyLoggerAdvisor 日志顾问实现 - 调整 DeepSeekR1ChatController,优化流式输出内容处理逻辑 - 更新 application.yml 中默认模型名称及日志级别配置
This commit is contained in:
@@ -8,10 +8,13 @@ spring:
|
||||
base-url: https://api.deepseek.com # DeepSeek 的请求 URL, 可不填,默认值为 api.deepseek.com
|
||||
chat:
|
||||
options:
|
||||
model: deepseek-reasoner # 使用哪个模型
|
||||
model: deepseek-chat # 使用哪个模型
|
||||
temperature: 0.8 # 温度值
|
||||
jasypt:
|
||||
encryptor:
|
||||
password: ${jasypt.encryptor.password}
|
||||
algorithm: PBEWithHMACSHA512AndAES_256
|
||||
iv-generator-classname: org.jasypt.iv.RandomIvGenerator
|
||||
iv-generator-classname: org.jasypt.iv.RandomIvGenerator
|
||||
logging:
|
||||
level:
|
||||
org.springframework.ai.chat.client.advisor: debug
|
||||
Reference in New Issue
Block a user