@loggie-ai/openclaw-plugin 0.1.1 → 0.1.2
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.
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { join } from "node:path";
|
|
1
2
|
import { fetchLoggieTranscriptDetail } from "../loggie-client.js";
|
|
2
3
|
import { buildLoggieRouteSessionKey, buildLoggieSessionId, meetingConversationId } from "../routing.js";
|
|
3
4
|
import { formatTranscriptReadyPrompt } from "./transcript-format.js";
|
|
@@ -95,9 +96,12 @@ export function createOpenClawTranscriptDispatcher(params) {
|
|
|
95
96
|
runDispatch: async () => {
|
|
96
97
|
const agentRuntime = await getAgentRuntime();
|
|
97
98
|
const workspaceDir = agentRuntime.resolveAgentWorkspaceDir(params.cfg, params.account.agentId);
|
|
99
|
+
const agentDir = agentRuntime.resolveAgentDir(params.cfg, params.account.agentId);
|
|
100
|
+
const sessionFile = join(agentDir, "sessions", `${sessionId}.jsonl`);
|
|
98
101
|
await agentRuntime.ensureAgentWorkspace?.({ dir: workspaceDir });
|
|
99
102
|
return agentRuntime.runEmbeddedAgent({
|
|
100
103
|
sessionId,
|
|
104
|
+
sessionFile,
|
|
101
105
|
sessionKey: routeSessionKey,
|
|
102
106
|
agentId: params.account.agentId,
|
|
103
107
|
messageChannel: "loggie",
|
|
@@ -115,7 +119,7 @@ export function createOpenClawTranscriptDispatcher(params) {
|
|
|
115
119
|
currentMessageId: event.eventId,
|
|
116
120
|
chatId: conversationId,
|
|
117
121
|
workspaceDir,
|
|
118
|
-
agentDir
|
|
122
|
+
agentDir,
|
|
119
123
|
config: params.cfg,
|
|
120
124
|
prompt: body,
|
|
121
125
|
transcriptPrompt: body,
|
package/openclaw.plugin.json
CHANGED
package/package.json
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { join } from "node:path";
|
|
1
2
|
import type { OpenClawConfig, PluginRuntime } from "openclaw/plugin-sdk/channel-core";
|
|
2
3
|
import type { ResolvedLoggieAccount } from "../account.js";
|
|
3
4
|
import type { LoggieTranscriptReadyEvent } from "../event-types.js";
|
|
@@ -137,9 +138,12 @@ export function createOpenClawTranscriptDispatcher(params: {
|
|
|
137
138
|
params.cfg,
|
|
138
139
|
params.account.agentId,
|
|
139
140
|
);
|
|
141
|
+
const agentDir = agentRuntime.resolveAgentDir(params.cfg, params.account.agentId);
|
|
142
|
+
const sessionFile = join(agentDir, "sessions", `${sessionId}.jsonl`);
|
|
140
143
|
await agentRuntime.ensureAgentWorkspace?.({ dir: workspaceDir });
|
|
141
144
|
return agentRuntime.runEmbeddedAgent({
|
|
142
145
|
sessionId,
|
|
146
|
+
sessionFile,
|
|
143
147
|
sessionKey: routeSessionKey,
|
|
144
148
|
agentId: params.account.agentId,
|
|
145
149
|
messageChannel: "loggie",
|
|
@@ -157,7 +161,7 @@ export function createOpenClawTranscriptDispatcher(params: {
|
|
|
157
161
|
currentMessageId: event.eventId,
|
|
158
162
|
chatId: conversationId,
|
|
159
163
|
workspaceDir,
|
|
160
|
-
agentDir
|
|
164
|
+
agentDir,
|
|
161
165
|
config: params.cfg,
|
|
162
166
|
prompt: body,
|
|
163
167
|
transcriptPrompt: body,
|