feat(simulation): add driver controlled backend LLM (#35186)
This commit is contained in:
@@ -14,6 +14,7 @@
|
||||
"dependencies": {
|
||||
"@opencode-ai/core": "workspace:*",
|
||||
"@opencode-ai/protocol": "workspace:*",
|
||||
"@opencode-ai/simulation": "workspace:*",
|
||||
"drizzle-orm": "catalog:",
|
||||
"effect": "catalog:"
|
||||
},
|
||||
|
||||
@@ -72,7 +72,7 @@ function makeRoutes<AuthError, AuthServices>(
|
||||
const serviceLayer = simulationEnabled()
|
||||
? Layer.unwrap(
|
||||
Effect.gen(function* () {
|
||||
const { simulationReplacements } = yield* Effect.promise(() => import("./simulation"))
|
||||
const { simulationReplacements } = yield* Effect.promise(() => import("@opencode-ai/simulation/backend"))
|
||||
return AppNodeBuilder.build(applicationServices, [...replacements, ...simulationReplacements])
|
||||
}),
|
||||
)
|
||||
|
||||
@@ -1,14 +0,0 @@
|
||||
import { LayerNode } from "@opencode-ai/core/effect/layer-node"
|
||||
|
||||
/**
|
||||
* Layer replacements applied when the server is built in simulation mode.
|
||||
*
|
||||
* Empty for now; simulation-mode implementations will populate this with
|
||||
* replacement nodes/layers that swap real services for simulated ones (e.g.
|
||||
* a fake filesystem). The server merges these into the app node build when
|
||||
* `OPENCODE_SIMULATION` is enabled, via a dynamic import so this module is
|
||||
* never loaded eagerly.
|
||||
*/
|
||||
export const simulationReplacements: LayerNode.Replacements = []
|
||||
|
||||
export * as Simulation from "./index"
|
||||
Reference in New Issue
Block a user