From 110cb429885481a1c841ffeff964b37e2f0e83c9 Mon Sep 17 00:00:00 2001 From: Nate Sesti Date: Thu, 20 Jun 2024 16:36:13 -0700 Subject: [PATCH] truncate api.deepseek.com stop tokens list --- core/index.d.ts | 3 +++ core/llm/llms/OpenAI.ts | 1 + docs/docusaurus.config.js | 4 ++-- 3 files changed, 6 insertions(+), 2 deletions(-) diff --git a/core/index.d.ts b/core/index.d.ts index 406e82d27..4dd2aeee0 100644 --- a/core/index.d.ts +++ b/core/index.d.ts @@ -772,6 +772,7 @@ interface ExperimentalConfig { promptPath?: string; } +// config.json export interface SerializedContinueConfig { env?: string[]; allowAnonymousTelemetry?: boolean; @@ -799,6 +800,7 @@ export type ContinueRcJson = Partial & { mergeBehavior: ConfigMergeType; }; +// config.ts - give users simplified interfaces export interface Config { /** If set to true, Continue will collect anonymous usage data to improve the product. If set to false, we will collect nothing. Read here to learn more: https://docs.continue.dev/telemetry */ allowAnonymousTelemetry?: boolean; @@ -842,6 +844,7 @@ export interface Config { experimental?: ExperimentalConfig; } +// in the actual Continue source code export interface ContinueConfig { allowAnonymousTelemetry?: boolean; models: ILLM[]; diff --git a/core/llm/llms/OpenAI.ts b/core/llm/llms/OpenAI.ts index 08b728f2f..0574fed31 100644 --- a/core/llm/llms/OpenAI.ts +++ b/core/llm/llms/OpenAI.ts @@ -96,6 +96,7 @@ class OpenAI extends BaseLLM { : url.port === "1337" || url.host === "api.openai.com" || url.host === "api.groq.com" || + url.host === "api.deepseek.com" || this.apiType === "azure" ? options.stop?.slice(0, 4) : options.stop, diff --git a/docs/docusaurus.config.js b/docs/docusaurus.config.js index 84127d2e4..80ec065ae 100644 --- a/docs/docusaurus.config.js +++ b/docs/docusaurus.config.js @@ -86,13 +86,13 @@ const config = { to: "https://github.com/continuedev/continue", label: "GitHub", position: "right", - className: 'github-navbar', + className: "github-navbar", }, { to: "https://discord.gg/vapESyrFmJ", label: "Discord", position: "right", - className: 'discord-navbar', + className: "discord-navbar", }, ], },