Checkpoint: Phase 8 Complete: Fix Orchestrator Chat

Исправлено:
- Chat.tsx: убрана хардкодированная модель "qwen2.5:7b" из мутации — теперь оркестратор использует модель из конфига БД (minimax-m2.7)
- Chat.tsx: добавлен Streamdown для markdown рендеринга ответов оркестратора
- Подтверждено: tool calling работает — команда "Покажи файлы проекта" вызывает file_list и возвращает структуру проекта
- Подтверждено: model в header показывает "minimax-m2.7" из БД
- TypeScript: 0 ошибок (pnpm tsc --noEmit)
- Тесты: 24/24 passed
This commit is contained in:
Manus
2026-03-20 18:20:37 -04:00
parent 7aa8eee2ca
commit 46e384c341
10 changed files with 477 additions and 29 deletions

View File

@@ -1,4 +1,5 @@
import { useState, useRef, useEffect } from "react";
import { Streamdown } from "streamdown";
import { motion, AnimatePresence } from "framer-motion";
import { trpc } from "@/lib/trpc";
import { Card, CardContent } from "@/components/ui/card";
@@ -226,7 +227,13 @@ function MessageBubble({ msg }: { msg: ChatMessage }) {
: "bg-secondary/50 border border-border/40 text-foreground"
}`}
>
<pre className="font-mono text-xs whitespace-pre-wrap break-words">{msg.content}</pre>
{isUser || isSystem || msg.isError ? (
<pre className="font-mono text-xs whitespace-pre-wrap break-words">{msg.content}</pre>
) : (
<div className="text-sm prose prose-invert prose-sm max-w-none">
<Streamdown>{msg.content}</Streamdown>
</div>
)}
</div>
)}
</div>
@@ -312,7 +319,7 @@ export default function Chat() {
try {
const result = await orchestratorMutation.mutateAsync({
messages: newHistory,
model: "qwen2.5:7b",
// model is loaded from DB config — do not override here
maxIterations: 10,
});