Skip to content

Commit cb27309

Browse files
authored
Merge pull request #12156 from RomneyDa/add-mercury-2
2 parents 9f9ded7 + b576e39 commit cb27309

5 files changed

Lines changed: 76 additions & 0 deletions

File tree

core/llm/toolSupport.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -270,6 +270,10 @@ export const PROVIDER_TOOL_SUPPORT: Record<string, (model: string) => boolean> =
270270

271271
return false;
272272
},
273+
inception: (model) => {
274+
const lower = model.toLowerCase();
275+
return lower.startsWith("mercury-2");
276+
},
273277
deepseek: (model) => {
274278
// https://api-docs.deepseek.com/quick_start/pricing
275279
// https://api-docs.deepseek.com/guides/function_calling

gui/src/pages/AddNewModel/configs/models.ts

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3325,4 +3325,20 @@ export const models: { [key: string]: ModelPackage } = {
33253325
icon: "mimo.png",
33263326
isOpenSource: false,
33273327
},
3328+
3329+
// Inception Labs models
3330+
mercury2: {
3331+
title: "Mercury 2",
3332+
description:
3333+
"Inception Labs' fastest reasoning LLM with 128k context, tool calling, and structured outputs.",
3334+
refUrl: "https://docs.inceptionlabs.ai/",
3335+
params: {
3336+
title: "Mercury 2",
3337+
model: "mercury-2",
3338+
contextLength: 128_000,
3339+
},
3340+
providerOptions: ["inception"],
3341+
icon: "inception.png",
3342+
isOpenSource: false,
3343+
},
33283344
};

gui/src/pages/AddNewModel/configs/providers.ts

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -590,6 +590,28 @@ Select the \`GPT-4o\` model below to complete your provider configuration, but n
590590
],
591591
apiKeyUrl: "https://platform.minimax.io",
592592
},
593+
inception: {
594+
title: "Inception Labs",
595+
provider: "inception",
596+
icon: "inception.png",
597+
description:
598+
"Inception Labs provides Mercury 2, a fast diffusion model with 128k context and tool calling.",
599+
longDescription:
600+
"To get started with Inception Labs, obtain an API key from the [Inception Labs platform](https://platform.inceptionlabs.ai/). Mercury 2 is OpenAI-compatible and supports chat, tool calling, and structured outputs.",
601+
tags: [ModelProviderTags.RequiresApiKey],
602+
collectInputFor: [
603+
{
604+
inputType: "text",
605+
key: "apiKey",
606+
label: "API Key",
607+
placeholder: "Enter your Inception Labs API key",
608+
required: true,
609+
},
610+
...completionParamsInputsConfigs,
611+
],
612+
packages: [models.mercury2],
613+
apiKeyUrl: "https://platform.inceptionlabs.ai/",
614+
},
593615
deepseek: {
594616
title: "DeepSeek",
595617
provider: "deepseek",

packages/llm-info/src/index.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import { Bedrock } from "./providers/bedrock.js";
44
import { Cohere } from "./providers/cohere.js";
55
import { CometAPI } from "./providers/cometapi.js";
66
import { Gemini } from "./providers/gemini.js";
7+
import { Inception } from "./providers/inception.js";
78
import { MiniMax } from "./providers/minimax.js";
89
import { Mistral } from "./providers/mistral.js";
910
import { Ollama } from "./providers/ollama.js";
@@ -26,6 +27,7 @@ export const allModelProviders: ModelProvider[] = [
2627
Bedrock,
2728
Cohere,
2829
CometAPI,
30+
Inception,
2931
MiniMax,
3032
xAI,
3133
zAI,
Lines changed: 32 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,32 @@
1+
import { ModelProvider } from "../types.js";
2+
3+
export const Inception: ModelProvider = {
4+
models: [
5+
{
6+
model: "mercury-2",
7+
displayName: "Mercury 2",
8+
contextLength: 128000,
9+
description:
10+
"Inception Labs' fastest reasoning diffusion model and their most powerful model, with tool calling and structured outputs support.",
11+
regex: /mercury-2/i,
12+
recommendedFor: ["chat"],
13+
},
14+
{
15+
model: "mercury-edit-2",
16+
displayName: "Mercury Edit 2",
17+
contextLength: 32000,
18+
description:
19+
"Inception Labs' code editing model for autocomplete, apply edit, and next edit suggestions.",
20+
regex: /mercury-edit-2/i,
21+
recommendedFor: ["autocomplete"],
22+
},
23+
{
24+
model: "mercury-coder-small",
25+
displayName: "Mercury Coder Small",
26+
contextLength: 32000,
27+
regex: /mercury-coder-small/i,
28+
},
29+
],
30+
id: "inception",
31+
displayName: "Inception Labs",
32+
};

0 commit comments

Comments
 (0)