opencode-avatar 0.3.15 → 0.3.16
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/index.js +10 -0
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -13049,6 +13049,11 @@ var AvatarPlugin = async ({ client }) => {
|
|
|
13049
13049
|
if (userMessage?.text && !isThinking) {
|
|
13050
13050
|
idleTriggered = false;
|
|
13051
13051
|
isThinking = true;
|
|
13052
|
+
const sessionId = output.sessionID || currentAgentName || "unknown";
|
|
13053
|
+
const trackingName = currentAgentName || sessionId;
|
|
13054
|
+
updateToolUsage(client, trackingName, sessionId, "thinking").catch((err) => {
|
|
13055
|
+
console.error(`[Avatar] Failed to update thinking state:`, err);
|
|
13056
|
+
});
|
|
13052
13057
|
requestAvatarGeneration(THINKING_PROMPT, false).catch(() => {
|
|
13053
13058
|
isThinking = false;
|
|
13054
13059
|
});
|
|
@@ -13089,6 +13094,11 @@ var AvatarPlugin = async ({ client }) => {
|
|
|
13089
13094
|
isThinking = false;
|
|
13090
13095
|
isToolActive = false;
|
|
13091
13096
|
currentRequestId = null;
|
|
13097
|
+
const sessionId = event.sessionID || currentAgentName || "unknown";
|
|
13098
|
+
const trackingName = currentAgentName || sessionId;
|
|
13099
|
+
updateToolUsage(client, trackingName, sessionId, "idle").catch((err) => {
|
|
13100
|
+
console.error(`[Avatar] Failed to update idle state:`, err);
|
|
13101
|
+
});
|
|
13092
13102
|
await setAvatarViaHttp(undefined, undefined, true);
|
|
13093
13103
|
}
|
|
13094
13104
|
},
|