feat: VisionTool 集成多模态 LLM 直接调用 — OCR/视觉分析

- VisionTool 改为接受可选 llm.LLMProvider,有模型时直接调用视觉模型分析,
  无模型时回退 base64 data URL 模式,不影响基本功能
- ModelSelector 新增 PurposeVision 路由用途
- main.go 按 vision routing 自动发现并注入视觉模型 provider
- 支持 models.json 中 qwen3.6-flash / qwen-vl-ocr-latest fallback 链

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
2026-05-24 16:25:56 +08:00
parent 47f9de2409
commit 189f7b999b
3 changed files with 77 additions and 20 deletions
+1
View File
@@ -18,6 +18,7 @@ const (
PurposeIntentAnalysis ModelPurpose = "intent_analysis"
PurposeToolCalling ModelPurpose = "tool_calling"
PurposeMemoryExtraction ModelPurpose = "memory_extraction"
PurposeVision ModelPurpose = "vision"
)
// ErrModelNotRequired is returned when an optional model is unavailable.