MCPcopy Create free account
hub / github.com/anomalyco/opencode / assistantToolMessage

Function assistantToolMessage

packages/opencode/test/acp/event.test.ts:207–225  ·  view source on GitHub ↗
(part: ToolPart)

Source from the content-addressed store, hash-verified

205}
206
207function assistantToolMessage(part: ToolPart) {
208 return {
209 info: {
210 id: part.messageID,
211 sessionID: part.sessionID,
212 role: "assistant",
213 time: { created: Date.now() },
214 parentID: "msg_parent",
215 modelID: "model",
216 providerID: "provider",
217 mode: "build",
218 agent: "build",
219 path: { cwd: "/workspace", root: "/workspace" },
220 cost: 0,
221 tokens: { input: 0, output: 0, reasoning: 0, cache: { read: 0, write: 0 } },
222 },
223 parts: [part],
224 } satisfies SessionMessageResponse
225}
226
227function runningTool(
228 sessionID: string,

Callers 1

event.test.tsFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected