MCPcopy Index your code
hub / github.com/anomalyco/opencode / reduce

Function reduce

packages/opencode/test/cli/run/session-data.test.ts:6–14  ·  view source on GitHub ↗
(data: ReturnType<typeof createSessionData>, event: unknown, thinking = true)

Source from the content-addressed store, hash-verified

4import type { StreamCommit } from "@/cli/cmd/run/types"
5
6function reduce(data: ReturnType<typeof createSessionData>, event: unknown, thinking = true) {
7 return reduceSessionData({
8 data,
9 event: event as Event,
10 sessionID: "session-1",
11 thinking,
12 limits: {},
13 })
14}
15
16function assistant(id: string, extra: Record<string, unknown> = {}) {
17 return {

Callers 1

Calls 1

reduceSessionDataFunction · 0.90

Tested by

no test coverage detected