aboutsummaryrefslogtreecommitdiffstats
path: root/apps/workers/inference.ts
diff options
context:
space:
mode:
Diffstat (limited to 'apps/workers/inference.ts')
-rw-r--r--apps/workers/inference.ts3
1 files changed, 3 insertions, 0 deletions
diff --git a/apps/workers/inference.ts b/apps/workers/inference.ts
index 071f4742..41ceffd6 100644
--- a/apps/workers/inference.ts
+++ b/apps/workers/inference.ts
@@ -104,6 +104,9 @@ class OllamaInferenceClient implements InferenceClient {
format: "json",
stream: true,
keep_alive: serverConfig.inference.ollamaKeepAlive,
+ options: {
+ num_ctx: serverConfig.inference.contextLength,
+ },
messages: [
{ role: "user", content: prompt, images: image ? [image] : undefined },
],