Skip to content

An open-source, privacy-first, self-hosted knowledge workspace where humans and AI agents work together 开源、隐私优先、自托管的知识工作空间,让人与智能体在此协作

:sparkles: AI Agent https://github.com/siyuan-note/siyuan/issues/17797

Daniel8d5b740f074e
diff --git a/app/src/layout/dock/AgentChat.ts b/app/src/layout/dock/AgentChat.ts
index 5250d7c23c..cfca4e1697 100644
--- a/app/src/layout/dock/AgentChat.ts
+++ b/app/src/layout/dock/AgentChat.ts
@@ -743,7 +743,6 @@ export class AgentChat extends Model {
const bubble = this.currentAIElement.querySelector(".agent-chat__bubble") as HTMLElement;
if (bubble) {
bubble.classList.remove("agent-chat__bubble--streaming");
- this.addCopyButton(this.currentAIElement);
}
this.currentAIElement = null;
this.currentContent = "";
@@ -849,6 +848,7 @@ export class AgentChat extends Model {
if (bubble) {
bubble.classList.remove("agent-chat__bubble--streaming");
}
+ this.addCopyButton(this.currentAIElement);
this.messages.push({role: "assistant", content: this.fullContent || " ", toolCalls: this.currentToolCalls.length > 0 ? this.currentToolCalls.slice() : undefined});
this.currentAIElement = null;
this.currentContent = "";