diff --git a/renderer/public/iconfont.css b/renderer/public/iconfont.css index fd355cf..2f0615f 100644 --- a/renderer/public/iconfont.css +++ b/renderer/public/iconfont.css @@ -1,8 +1,8 @@ @font-face { font-family: "iconfont"; /* Project id 4870215 */ - src: url('iconfont.woff2?t=1744201767604') format('woff2'), - url('iconfont.woff?t=1744201767604') format('woff'), - url('iconfont.ttf?t=1744201767604') format('truetype'); + src: url('iconfont.woff2?t=1744276722320') format('woff2'), + url('iconfont.woff?t=1744276722320') format('woff'), + url('iconfont.ttf?t=1744276722320') format('truetype'); } .iconfont { @@ -13,6 +13,10 @@ -moz-osx-font-smoothing: grayscale; } +.icon-double-loading:before { + content: "\e8fc"; +} + .icon-stop:before { content: "\e708"; } diff --git a/renderer/public/iconfont.woff2 b/renderer/public/iconfont.woff2 index dbe8675..fad5f13 100644 Binary files a/renderer/public/iconfont.woff2 and b/renderer/public/iconfont.woff2 differ diff --git a/renderer/public/mcp.css b/renderer/public/mcp.css index 5613211..489e074 100644 --- a/renderer/public/mcp.css +++ b/renderer/public/mcp.css @@ -155,6 +155,23 @@ a { padding: 5px 10px; } +.inner .openmcp-code-block { + border: none; + margin: 0; + padding: 0; +} + +.inner .code-header { + display: none; + color: var(--foreground); + background-color: transparent !important; + padding: 0; +} + +.inner pre { + margin: 0 !important; +} + .lang-id { font-weight: bold; } diff --git a/renderer/src/components/main-panel/chat/chat.ts b/renderer/src/components/main-panel/chat/chat.ts index 9c757fc..b4a7732 100644 --- a/renderer/src/components/main-panel/chat/chat.ts +++ b/renderer/src/components/main-panel/chat/chat.ts @@ -6,6 +6,7 @@ export interface ChatMessage { content: string; tool_call_id?: string name?: string // 工具名称,当 role 为 tool + tool_calls?: ToolCall[] } // 新增状态和工具数据 @@ -31,8 +32,12 @@ export interface ChatStorage { export interface ToolCall { id?: string; - name: string; - arguments: string; + index?: number; + type: string; + function: { + name: string; + arguments: string; + } } export const allTools = ref([]); diff --git a/renderer/src/components/main-panel/chat/index.vue b/renderer/src/components/main-panel/chat/index.vue index 3ac41bc..bd716db 100644 --- a/renderer/src/components/main-panel/chat/index.vue +++ b/renderer/src/components/main-panel/chat/index.vue @@ -2,13 +2,13 @@
-
-
+
+
- +
@@ -16,26 +16,72 @@
- -
+ +
Agent
-
- +
- -
-
Tool
-
-
- 正在调用工具: {{ streamingToolCalls[0].name }} + +
+
+ Agent + + 正在使用工具 + + + +
+
+
+ +
+
+
+ {{ call.function.name }} + {{ call.type }} +
+
+
+
+
+
+
+
+ + +
+
+ {{ "响应" }} + + + +
+
+
+
+
+
+
+ +
+
{{ item.text }}
+
{{ JSON.stringify(item) }}
+
+
+
- {{ message.content }}
-
@@ -72,15 +118,13 @@ \ No newline at end of file diff --git a/renderer/src/components/main-panel/chat/setting.vue b/renderer/src/components/main-panel/chat/setting.vue index d6c9eb7..16063ad 100644 --- a/renderer/src/components/main-panel/chat/setting.vue +++ b/renderer/src/components/main-panel/chat/setting.vue @@ -1,7 +1,7 @@