feat(aia): Protocol Agent MVP complete with one-click generation and Word export

- Add one-click research protocol generation with streaming output

- Implement Word document export via Pandoc integration

- Add dynamic dual-panel layout with resizable split pane

- Implement collapsible content for StatePanel stages

- Add conversation history management with title auto-update

- Fix scroll behavior, markdown rendering, and UI layout issues

- Simplify conversation creation logic for reliability
This commit is contained in:
2026-01-25 19:16:36 +08:00
parent 4d7d97ca19
commit 303dd78c54
332 changed files with 6204 additions and 617 deletions

View File

@@ -1,16 +1,16 @@
# AIA AI智能问答模块 - 当前状态与开发指南
> **文档版本:** v3.0
> **文档版本:** v3.1
> **创建日期:** 2026-01-14
> **维护者:** AIA模块开发团队
> **最后更新:** 2026-01-24 🎉 **V3.0版本发布 - Protocol Agent MVP完**
> **最后更新:** 2026-01-25 🎉 **V3.1版本发布 - Protocol Agent MVP完整交付**
> **重大里程碑:**
> - 🏆 通用流式响应服务OpenAI Compatible
> - 🎨 现代感UI100%还原原型图V11
> - 🚀 Ant Design X 深度集成
> - ✨ 12个智能体配置完成
> - 🆕 Prompt管理系统集成灰度预览、版本管理
> - 🎉 **Protocol Agent MVP完可复用Agent框架+5阶段对话流程**
> - 🎉 **Protocol Agent MVP完整交付(一键生成研究方案+Word导出**
---
@@ -42,9 +42,9 @@ AIAAI Intelligent Assistant模块提供覆盖临床研究全生命周期
### 当前状态
- **开发阶段:** **V3.0 Protocol Agent MVP完**
- **架构版本:** V3.0通用Agent框架 + Protocol Agent
- **完成度:** 75%MVP核心流程完成,待前后端联调
- **开发阶段:** 🎉 **V3.1 Protocol Agent MVP完整交付**
- **架构版本:** V3.1通用Agent框架 + Protocol Agent + 一键生成
- **完成度:** 90%MVP完整可用,待生产测试
### ✅ V2.1 新增功能2026-01-18
@@ -85,7 +85,40 @@ AIAAI Intelligent Assistant模块提供覆盖临床研究全生命周期
- [x] 前端三栏布局5阶段状态面板100%还原原型图
- [x] 5阶段流程科学问题→PICO→研究设计→样本量→观察指标
**待完成:** 前后端联调、一键生成、Word导出
---
### 🎉 V3.1 Protocol Agent 完整交付2026-01-25
**一键生成研究方案:**
- [x] 动态双面板布局ResizableSplitPane可拖拽调整
- [x] 视图切换(研究摘要 / 完整方案)
- [x] A4 纸张预览效果DocumentPanel
- [x] 流式生成 + Markdown 渲染 + 滚动跟随
- [x] 12章节完整临床研究方案结构
**Word 文档导出:**
- [x] Python 微服务pypandoc + Pandoc
- [x] Node.js API 端点(/export/docx
- [x] 前端一键下载
**用户体验优化:**
- [x] StatePanel 折叠/展开CollapsibleContent
- [x] 科学问题/PICO/样本量/观察指标完整显示
- [x] 延迟创建对话(避免空记录)
- [x] 对话标题自动更新
- [x] Prompt 工程优化(阶段约束、数据凝练放宽)
**Bug 修复:**
- [x] 滚动条显示问题flex min-height: 0
- [x] 模型阶段混乱问题Prompt 增强)
- [x] 数据类型错误toArray 辅助函数)
- [x] 顶部标题两行、欢迎语过大、列表编号错误
**代码统计:**
- 前端新增:~1,200行累计~3,300行
- 后端新增:~400行累计~4,700行
- Python新增~110行
- **总计:~8,500行**
---