Skip to content

A reactive notebook for Python — run reproducible experiments, query with SQL, execute as a script, deploy as an app, and version with git. Stored as pure Python. All in a modern, AI-native editor.

feat(ai): hide unused providers when allow_provider_config is false (#10590)

Shahmir Varqha3524643328cf
diff --git a/frontend/src/components/ai/__tests__/ai-utils.test.ts b/frontend/src/components/ai/__tests__/ai-utils.test.ts
index 217f9347ea..3ee62b8048 100644
--- a/frontend/src/components/ai/__tests__/ai-utils.test.ts
+++ b/frontend/src/components/ai/__tests__/ai-utils.test.ts
@@ -46,6 +46,13 @@ vi.mock("@marimo-team/llm-info/models.json", () => {
description: "Ollama Llama 2 model",
}),
],
+ marimo: [
+ make({
+ name: "Best for chat",
+ model: "best-for-chat",
+ description: "marimo hosted chat model",
+ }),
+ ],
};
return { models };
@@ -54,8 +61,9 @@ vi.mock("@marimo-team/llm-info/models.json", () => {
// Must import after mock
import {
autoPopulateModels,
- getConfiguredProvider,
getRecommendedModel,
+ listConfiguredProviders,
+ listModelsForAiSettings,
} from "../ai-utils";
describe("ai-utils", () => {
@@ -63,82 +71,72 @@ describe("ai-utils", () => {
vi.clearAllMocks();
});
- describe("getConfiguredProvider", () => {
- it("should return undefined when no AI config", () => {
- const config: UserConfig = {} as UserConfig;
- expect(getConfiguredProvider(config.ai)).toBeUndefined();
- });
-
- it("should return undefined when AI config has no credentials", () => {
- const config: UserConfig = {
- ai: {},
- } as UserConfig;
- expect(getConfiguredProvider(config.ai)).toBeUndefined();
- });
-
- it("should return openai when OpenAI API key is set", () => {
- const config: UserConfig = {
- ai: {
+ describe("listConfiguredProviders", () => {
+ it("returns known providers with credentials, then custom providers with a base URL", () => {
+ expect(
+ listConfiguredProviders({
+ wandb: { api_key: "unused" },
open_ai: { api_key: "sk-test" },
- },
- } as UserConfig;
- expect(getConfiguredProvider(config.ai)).toBe("openai");
- });
-
- it("should return anthropic when Anthropic API key is set", () => {
- const config: UserConfig = {
- ai: {
- anthropic: { api_key: "sk-ant-test" },
- },
- } as UserConfig;
- expect(getConfiguredProvider(config.ai)).toBe("anthropic");
+ open_ai_compatible: { api_key: "unused", base_url: "https://x" },
+ custom_providers: {
+ groq: { base_url: "https://api.groq.com" },
+ empty: {},
+ },
+ }),
+ ).toEqual(["openai", "wandb", "marimo", "groq"]);
});
- it("should return google when Google API key is set", () => {
- const config: UserConfig = {
- ai: {
- google: { api_key: "google-key" },
- },
- } as UserConfig;
- expect(getConfiguredProvider(config.ai)).toBe("google");
+ it("treats marimo as configured when open_ai_compatible has a base URL", () => {
+ expect(
+ listConfiguredProviders({
+ open_ai_compatible: { api_key: "unused", base_url: "https://x" },
+ }),
+ ).toEqual(["marimo"]);
});
- it("should return ollama when Ollama base URL is set", () => {
- const config: UserConfig = {
- ai: {
- ollama: { base_url: "http://localhost:11434" },
- },
- } as UserConfig;
- expect(getConfiguredProvider(config.ai)).toBe("ollama");
+ it("omits openai-compatible as its own provider id", () => {
+ expect(
+ listConfiguredProviders({
+ open_ai: {},
+ open_ai_compatible: { api_key: "unused" },
+ }),
+ ).toEqual([]);
});
+ });
- it("should return azure only when both API key and base URL are set", () => {
- const config: UserConfig = {
- ai: {
- azure: { api_key: "azure-key", base_url: "https://azure.com" },
- },
- } as UserConfig;
- expect(getConfiguredProvider(config.ai)).toBe("azure");
+ describe("listModelsForAiSettings", () => {
+ const entries: [string, number][] = [
+ ["openai", 1],
+ ["anthropic", 2],
+ ["wandb", 3],
+ ["marimo", 4],
+ ];
+
+ it("returns all groups when provider config is allowed", () => {
+ expect(
+ listModelsForAiSettings(entries, {
+ allow_provider_config: true,
+ wandb: { api_key: "unused" },
+ }),
+ ).toEqual(entries);
});
- it("should return undefined for azure with only API key", () => {
- const config: UserConfig = {
- ai: {
- azure: { api_key: "azure-key" },
- },
- } as UserConfig;
- expect(getConfiguredProvider(config.ai)).toBeUndefined();
+ it("filters to configured providers when provider config is locked", () => {
+ expect(
+ listModelsForAiSettings(entries, {
+ allow_provider_config: false,
+ wandb: { api_key: "unused" },
+ }),
+ ).toEqual([["wandb", 3]]);
});
- it("should return custom provider when configured", () => {
- const config = {
- ai: {
- custom_providers: {
- my_provider: { base_url: "https://my-api.com" },
- },
- },
- } as unknown as UserConfig;
- expect(getConfiguredProvider(config.ai)).toBe("my_provider");
+ it("keeps marimo models when locked with an openai-compatible gateway", () => {
+ expect(
+ listModelsForAiSettings(entries, {
+ allow_provider_config: false,
+ open_ai_compatible: { base_url: "https://ai.marimo.app/molab/v1" },
+ }),
+ ).toEqual([["marimo", 4]]);
});
});
diff --git a/frontend/src/components/ai/ai-model-dropdown.tsx b/frontend/src/components/ai/ai-model-dropdown.tsx
index 2782ae99d8..a7e1d9b30a 100644
--- a/frontend/src/components/ai/ai-model-dropdown.tsx
+++ b/frontend/src/components/ai/ai-model-dropdown.tsx
@@ -33,6 +33,7 @@ import {
} from "../ui/dropdown-menu";
import { Tooltip } from "../ui/tooltip";
import { AiProviderIcon } from "./ai-provider-icon";
+import { listModelsForAiSettings } from "./ai-utils";
import { getCurrentRoleTooltip, getTagColour } from "./display-helpers";
interface AIModelDropdownProps {
@@ -84,7 +85,10 @@ export const AIModelDropdown = ({
].filter(Boolean),
displayedModels: ai?.models?.displayed_models,
});
- const modelsByProvider = aiModelRegistry.getListModelsByProvider();
+ const modelsByProvider = listModelsForAiSettings(
+ aiModelRegistry.getListModelsByProvider(),
+ ai,
+ );
const activeModel =
forRole === "autocomplete"
diff --git a/frontend/src/components/ai/ai-utils.ts b/frontend/src/components/ai/ai-utils.ts
index 4f65efea07..915ab4e333 100644
--- a/frontend/src/components/ai/ai-utils.ts
+++ b/frontend/src/components/ai/ai-utils.ts
@@ -24,39 +24,55 @@ const CREDENTIAL_CHECKERS: Record<KnownProviderId, CredentialChecker> = {
"opencode-go": (ai) => Boolean(ai?.opencode_go?.api_key),
bedrock: (ai) => Boolean(ai?.bedrock?.region_name),
ollama: (ai) => Boolean(ai?.ollama?.base_url),
- // These providers don't have user-configurable credentials in the UI
+ // No user-configurable credentials in the UI.
deepseek: () => false,
- marimo: () => false,
+ // Hosted marimo models (marimo.app / molab) route through open_ai_compatible.
+ marimo: (ai) => Boolean(ai?.open_ai_compatible?.base_url),
};
/**
- * Returns the first configured provider based on credentials.
+ * Known providers with credentials, then custom providers with a base URL.
*/
-export function getConfiguredProvider(
- config: UserConfig["ai"],
-): ProviderId | undefined {
- for (const provider of KNOWN_PROVIDERS) {
- if (CREDENTIAL_CHECKERS[provider](config)) {
- return provider;
- }
- }
+export function listConfiguredProviders(
+ ai: AiConfig | undefined,
+): ProviderId[] {
+ const knownProviders = KNOWN_PROVIDERS.filter((provider) =>
+ CREDENTIAL_CHECKERS[provider](ai),
+ );
+ const customProviders = Object.entries(ai?.custom_providers ?? {})
+ .filter(([, providerConfig]) => Boolean(providerConfig?.base_url))
+ .map(([name]) => name);
+ return [...knownProviders, ...customProviders];
+}
- // Check custom providers
- const customProviders = config?.custom_providers;
- if (customProviders) {
- const firstCustomProvider = Object.entries(customProviders).find(
- ([_, providerConfig]) => providerConfig?.base_url,
- );
- if (firstCustomProvider) {
- return firstCustomProvider[0];
- }
+/**
+ * Keep provider groups whose provider has credentials configured.
+ */
+export function filterToConfiguredProviders<T>(
+ entries: readonly [ProviderId, T][],
+ ai: AiConfig | undefined,
+): [ProviderId, T][] {
+ const configured = new Set<string>(listConfiguredProviders(ai));
+ return entries.filter(([provider]) => configured.has(provider));
+}
+
+/**
+ * When provider setup is locked, only show models for configured providers.
+ */
+export function listModelsForAiSettings<T>(
+ entries: readonly [ProviderId, T][],
+ ai: AiConfig | undefined,
+): [ProviderId, T][] {
+ if (ai?.allow_provider_config !== false) {
+ return [...entries];
}
+ return filterToConfiguredProviders(entries, ai);
}
export function getRecommendedModel(
config: UserConfig["ai"],
): string | undefined {
- const provider = getConfiguredProvider(config);
+ const provider = listConfiguredProviders(config)[0];
if (!provider) {
return undefined;
}
diff --git a/frontend/src/components/app-config/ai-config.tsx b/frontend/src/components/app-config/ai-config.tsx
index 765eee2659..e9e9a15469 100644
--- a/frontend/src/components/app-config/ai-config.tsx
+++ b/frontend/src/components/app-config/ai-config.tsx
@@ -1,6 +1,6 @@
/* Copyright 2026 Marimo. All rights reserved. */
-import { useAtom } from "jotai";
+import { useAtom, useAtomValue } from "jotai";
import {
BotIcon,
BrainIcon,
@@ -43,6 +43,7 @@ import {
} from "@/core/ai/ids/ids";
import { type AiModel, AiModelRegistry } from "@/core/ai/model-registry";
import { CopilotConfig } from "@/core/codemirror/copilot/copilot-config";
+import { resolvedMarimoConfigAtom } from "@/core/config/config";
import { DEFAULT_AI_MODEL, type UserConfig } from "@/core/config/config-schema";
import { isWasm } from "@/core/wasm/utils";
import { cn } from "@/utils/cn";
@@ -53,6 +54,10 @@ import {
AiProviderIcon,
type AiProviderIconProps,
} from "../ai/ai-provider-icon";
+import {
+ listConfiguredProviders,
+ listModelsForAiSettings,
+} from "../ai/ai-utils";
import { getTagColour } from "../ai/display-helpers";
import {
Accordion,
@@ -575,6 +580,11 @@ export const AiCodeCompletionConfig: React.FC<AiConfigProps> = ({
);
};
+function useAllowProviderConfig(): boolean {
+ const ai = useAtomValue(resolvedMarimoConfigAtom).ai;
+ return ai?.allow_provider_config !== false;
+}
+
const AccordionFormItem = ({
title,
triggerClassName,
@@ -867,17 +877,55 @@ export const CustomProvidersConfig: React.FC<AiConfigProps> = ({
);
};
+const LockedProvidersList: React.FC = () => {
+ const resolvedAi = useAtomValue(resolvedMarimoConfigAtom).ai;
+ const providers = listConfiguredProviders(resolvedAi);
+
+ return (
+ <SettingGroup>
+ <p className="text-sm text-muted-secondary">
+ AI providers are configured for this environment. You cannot add your
+ own keys or custom providers.
+ </p>
+ {providers.length === 0 ? (
+ <p className="text-sm text-muted-foreground">
+ No AI providers are configured.
+ </p>
+ ) : (
+ <div className="flex flex-col divide-y border rounded-md">
+ {providers.map((provider) => (
+ <div key={provider} className="flex items-center gap-2 px-3 py-2">
+ <AiProviderIcon provider={provider} className="h-4 w-4" />
+ <span className="text-sm font-medium">
+ {getProviderLabel(provider)}
+ </span>
+ <span className="ml-auto px-1 rounded bg-muted text-xs font-medium border">
+ Configured
+ </span>
+ </div>
+ ))}
+ </div>
+ )}
+ </SettingGroup>
+ );
+};
+
export const AiProvidersConfig: React.FC<AiConfigProps> = ({
form,
config,
onSubmit,
}) => {
const isWasmRuntime = isWasm();
+ const allowProviderConfig = useAllowProviderConfig();
const hasValue = (name: FieldPath<UserConfig>) => {
return !!form.getValues(name);
};
+ if (!allowProviderConfig) {
+ return <LockedProvidersList />;
+ }
+
return (
<SettingGroup>
<p className="text-sm text-muted-secondary">
@@ -1508,6 +1556,8 @@ export const AiModelDisplayConfig: React.FC<AiConfigProps> = ({
form,
onSubmit,
}) => {
+ const resolvedAi = useAtomValue(resolvedMarimoConfigAtom).ai;
+
const customModels = useWatch({
control: form.control,
name: "ai.models.custom_models",
@@ -1518,10 +1568,14 @@ export const AiModelDisplayConfig: React.FC<AiConfigProps> = ({
name: "ai.custom_providers",
}) as Record<string, CustomProviderConfig> | undefined;
- const customProviderNames = useMemo(
- () => Object.keys(customProviders || {}),
- [customProviders],
- );
+ const customProviderNames = useMemo(() => {
+ return [
+ ...new Set([
+ ...Object.keys(customProviders || {}),
+ ...Object.keys(resolvedAi?.custom_providers || {}),
+ ]),
+ ];
+ }, [customProviders, resolvedAi]);
const aiModelRegistry = useMemo(
() =>
@@ -1538,7 +1592,10 @@ export const AiModelDisplayConfig: React.FC<AiConfigProps> = ({
}) as QualifiedModelId[];
const currentDisplayedModelsSet = new Set(currentDisplayedModels);
const modelsByProvider = aiModelRegistry.getGroupedModelsByProvider();
- const listModelsByProvider = aiModelRegistry.getListModelsByProvider();
+ const listModelsByProvider = listModelsForAiSettings(
+ aiModelRegistry.getListModelsByProvider(),
+ resolvedAi,
+ );
const toggleModelDisplay = useEvent((modelId: QualifiedModelId) => {
const newModels = currentDisplayedModelsSet.has(modelId)
@@ -1676,6 +1733,9 @@ export const AddModelForm: React.FC<{
};
const providerClassName = "w-40 truncate";
+ const knownProviders = KNOWN_PROVIDERS.filter(
+ (p) => p !== "marimo" && !customProviderNames.includes(p),
+ );
const providerSelect = (
<div className="flex flex-col gap-2">
@@ -1718,14 +1778,14 @@ export const AddModelForm: React.FC<{
</div>
</SelectItem>
))}
- <p className="px-2 py-1 text-xs text-muted-secondary font-medium mt-1">
- Built-in Providers
- </p>
+ {knownProviders.length > 0 && (
+ <p className="px-2 py-1 text-xs text-muted-secondary font-medium mt-1">
+ Built-in Providers
+ </p>
+ )}
</>
)}
- {KNOWN_PROVIDERS.filter(
- (p) => p !== "marimo" && !customProviderNames.includes(p),
- ).map((p) => (
+ {knownProviders.map((p) => (
<SelectItem key={p} value={p}>
<div className="flex items-center gap-2">
<AiProviderIcon provider={p} className="h-4 w-4" />
@@ -1733,18 +1793,20 @@ export const AddModelForm: React.FC<{
</div>
</SelectItem>
))}
- <p className="px-2 py-1 text-xs text-muted-secondary font-medium mt-1">
- Other
- </p>
- <SelectItem value="custom">
- <div className="flex items-center gap-2">
- <AiProviderIcon
- provider="openai-compatible"
- className="h-4 w-4"
- />
- <span>Enter provider name</span>
- </div>
- </SelectItem>
+ <>
+ <p className="px-2 py-1 text-xs text-muted-secondary font-medium mt-1">
+ Other
+ </p>
+ <SelectItem value="custom">
+ <div className="flex items-center gap-2">
+ <AiProviderIcon
+ provider="openai-compatible"
+ className="h-4 w-4"
+ />
+ <span>Enter provider name</span>
+ </div>
+ </SelectItem>
+ </>
</SelectGroup>
</SelectContent>
</Select>
diff --git a/frontend/src/components/app-config/user-config-form.tsx b/frontend/src/components/app-config/user-config-form.tsx
index d0d4d41483..2e03a12f36 100644
--- a/frontend/src/components/app-config/user-config-form.tsx
+++ b/frontend/src/components/app-config/user-config-form.tsx
@@ -2,7 +2,6 @@
import { zodResolver } from "@hookform/resolvers/zod";
import { atom, useAtom, useAtomValue, useSetAtom } from "jotai";
-import { merge } from "lodash-es";
import {
AlertTriangleIcon,
BrainIcon,
@@ -35,7 +34,7 @@ import { NumberField } from "@/components/ui/number-field";
import { Tabs, TabsList, TabsTrigger } from "@/components/ui/tabs";
import { KEYMAP_PRESETS } from "@/core/codemirror/keymaps/keymaps";
import { capabilitiesAtom } from "@/core/config/capabilities";
-import { useUserConfig } from "@/core/config/config";
+import { mergeConfig, useUserConfig } from "@/core/config/config";
import {
PackageManagerNames,
type UserConfig,
@@ -203,7 +202,7 @@ export const UserConfigForm: React.FC = () => {
await saveUserConfig({ config: dirtyValues });
// Only apply the changed keys; this avoids stale request responses
// overwriting newer config changes.
- setConfig((prev) => merge({}, prev, dirtyValues));
+ setConfig((prev) => mergeConfig(prev, dirtyValues));
};
const onSubmit = useDebouncedCallback(onSubmitNotDebounced, FORM_DEBOUNCE);
diff --git a/frontend/src/core/ai/config.ts b/frontend/src/core/ai/config.ts
index 89dc2997b5..2649010a16 100644
--- a/frontend/src/core/ai/config.ts
+++ b/frontend/src/core/ai/config.ts
@@ -2,9 +2,8 @@
import type { Role } from "@marimo-team/llm-info";
import { useSetAtom } from "jotai";
-import { merge } from "lodash-es";
import type { QualifiedModelId } from "@/core/ai/ids/ids";
-import { userConfigAtom } from "@/core/config/config";
+import { mergeConfig, userConfigAtom } from "@/core/config/config";
import type {
AIModelKey,
CopilotMode,
@@ -41,7 +40,7 @@ export const useAIConfigActions = () => {
const saveConfig = async (aiConfig: AiConfigPatch) => {
const newConfig = { ai: aiConfig };
await saveUserConfig({ config: newConfig }).then(() => {
- setUserConfig((prev) => merge({}, prev, newConfig));
+ setUserConfig((prev) => mergeConfig(prev, newConfig));
});
};
diff --git a/frontend/src/core/config/__tests__/config-schema.test.ts b/frontend/src/core/config/__tests__/config-schema.test.ts
index c9a26d3a27..cac08c3f2c 100644
--- a/frontend/src/core/config/__tests__/config-schema.test.ts
+++ b/frontend/src/core/config/__tests__/config-schema.test.ts
@@ -5,6 +5,7 @@ import { expect, test } from "vitest";
import {
configOverridesAtom,
connectionTransportTypeAtom,
+ mergeConfig,
resolvedMarimoConfigAtom,
userConfigAtom,
} from "../config";
@@ -46,6 +47,7 @@ test("default UserConfig - empty", () => {
expect(defaultConfig).toMatchInlineSnapshot(`
{
"ai": {
+ "allow_provider_config": true,
"custom_providers": {},
"enabled": true,
"inline_tooltip": false,
@@ -120,6 +122,7 @@ test("default UserConfig - one level", () => {
expect(defaultConfig).toMatchInlineSnapshot(`
{
"ai": {
+ "allow_provider_config": true,
"custom_providers": {},
"enabled": true,
"inline_tooltip": false,
@@ -315,3 +318,31 @@ test("connectionTransportTypeAtom reads server.transport", () => {
});
expect(store.get(connectionTransportTypeAtom)).toBe("sse");
});
+
+test("mergeConfig replaces arrays instead of merging by index", () => {
+ const prev = {
+ ai: {
+ models: {
+ displayed_models: ["wandb/a", "wandb/b", "wandb/c"],
+ custom_models: ["wandb/custom"],
+ },
+ },
+ };
+ const patch = {
+ ai: {
+ models: {
+ displayed_models: ["wandb/a"],
+ custom_models: [],
+ },
+ },
+ };
+
+ expect(mergeConfig(prev, patch)).toEqual({
+ ai: {
+ models: {
+ displayed_models: ["wandb/a"],
+ custom_models: [],
+ },
+ },
+ });
+});
diff --git a/frontend/src/core/config/config-schema.ts b/frontend/src/core/config/config-schema.ts
index 80bc3ba19c..b75af26b69 100644
--- a/frontend/src/core/config/config-schema.ts
+++ b/frontend/src/core/config/config-schema.ts
@@ -169,6 +169,7 @@ export const UserConfigSchema = z
max_tokens: z.number().int().positive().nullable().optional(),
mode: z.enum(COPILOT_MODES).prefault("manual"),
inline_tooltip: z.boolean().prefault(false),
+ allow_provider_config: z.boolean().prefault(true),
open_ai: AiConfigSchema.optional(),
anthropic: AiConfigSchema.optional(),
google: AiConfigSchema.optional(),
diff --git a/frontend/src/core/config/config.ts b/frontend/src/core/config/config.ts
index e1c9e753d0..4ec7106845 100644
--- a/frontend/src/core/config/config.ts
+++ b/frontend/src/core/config/config.ts
@@ -1,6 +1,6 @@
/* Copyright 2026 Marimo. All rights reserved. */
import { atom, useAtom, useAtomValue, useSetAtom } from "jotai";
-import { merge } from "lodash-es";
+import { mergeWith } from "lodash-es";
import { OverridingHotkeyProvider } from "../hotkeys/hotkeys";
import { type Platform, resolvePlatform } from "../hotkeys/shortcuts";
import { store } from "../state/jotai";
@@ -11,6 +11,19 @@ import {
type UserConfig,
} from "./config-schema";
+/**
+ * Deep-merge config objects, replacing arrays instead of merging them by
+ * index. Lodash `merge` keeps leftover tail items. Python `deep_merge` replaces arrays.
+ */
+export function mergeConfig<T extends object>(...sources: object[]): T {
+ return mergeWith({}, ...sources, (_obj: unknown, src: unknown) => {
+ if (Array.isArray(src)) {
+ return [...src];
+ }
+ return undefined;
+ }) as T;
+}
+
/**
* Atom for storing the user config.
*/
@@ -21,7 +34,7 @@ export const configOverridesAtom = atom<{}>({});
export const resolvedMarimoConfigAtom = atom<UserConfig>((get) => {
const overrides = get(configOverridesAtom);
const userConfig = get(userConfigAtom);
- return merge({}, userConfig, overrides);
+ return mergeConfig(userConfig, overrides);
});
export const autoInstantiateAtom = atom((get) => {
diff --git a/marimo/_config/config.py b/marimo/_config/config.py
index 1639bdf695..17a26cf9fb 100644
--- a/marimo/_config/config.py
+++ b/marimo/_config/config.py
@@ -315,6 +315,7 @@ class AiConfig(TypedDict, total=False):
- `max_tokens`: the maximum number of tokens to use in AI completions
- `mode`: the mode to use for AI completions. Can be one of: `"ask"` or `"manual"`
- `inline_tooltip`: if `True`, enable inline AI tooltip suggestions
+ - `allow_provider_config`: if `False`, lock provider setup in the settings UI, making them read-only. Users cannot bring their own credentials or add custom providers. Default `True`.
- `models`: the models to use for AI completions
- `open_ai`: the OpenAI config
- `anthropic`: the Anthropic config
@@ -335,6 +336,7 @@ class AiConfig(TypedDict, total=False):
max_tokens: NotRequired[int]
mode: NotRequired[CopilotMode]
inline_tooltip: NotRequired[bool]
+ allow_provider_config: NotRequired[bool]
models: AiModelConfig
# providers
open_ai: OpenAiConfig
@@ -808,6 +810,7 @@ DEFAULT_CONFIG: MarimoConfig = {
},
"ai": {
"enabled": True,
+ "allow_provider_config": True,
"models": {
"displayed_models": [],
"custom_models": [],
diff --git a/packages/openapi/api.yaml b/packages/openapi/api.yaml
index 93149a18a4..8bb7beaa66 100644
--- a/packages/openapi/api.yaml
+++ b/packages/openapi/api.yaml
@@ -123,16 +123,20 @@ components:
\ the maximum number of tokens to use in AI completions\n - `mode`: the\
\ mode to use for AI completions. Can be one of: `\"ask\"` or `\"manual\"\
`\n - `inline_tooltip`: if `True`, enable inline AI tooltip suggestions\n\
- \ - `models`: the models to use for AI completions\n - `open_ai`: the\
- \ OpenAI config\n - `anthropic`: the Anthropic config\n - `google`:\
- \ the Google AI config\n - `bedrock`: the Bedrock config\n - `azure`:\
- \ the Azure config\n - `ollama`: the Ollama config\n - `github`: the\
- \ GitHub config\n - `openrouter`: the OpenRouter config\n - `wandb`:\
- \ the Weights & Biases config\n - `opencode_go`: the OpenCode Go config\n\
- \ - `custom_providers`: a dict of custom OpenAI-compatible providers\n\
- \ - `open_ai_compatible`: the OpenAI-compatible config (deprecated, use\
- \ custom_providers)"
- properties:
+ \ - `allow_provider_config`: if `False`, lock provider setup in the settings\
+ \ UI, making them read-only. Users cannot bring their own credentials or add\
+ \ custom providers. Default `True`.\n - `models`: the models to use for\
+ \ AI completions\n - `open_ai`: the OpenAI config\n - `anthropic`: the\
+ \ Anthropic config\n - `google`: the Google AI config\n - `bedrock`:\
+ \ the Bedrock config\n - `azure`: the Azure config\n - `ollama`: the\
+ \ Ollama config\n - `github`: the GitHub config\n - `openrouter`: the\
+ \ OpenRouter config\n - `wandb`: the Weights & Biases config\n - `opencode_go`:\
+ \ the OpenCode Go config\n - `custom_providers`: a dict of custom OpenAI-compatible\
+ \ providers\n - `open_ai_compatible`: the OpenAI-compatible config (deprecated,\
+ \ use custom_providers)"
+ properties:
+ allow_provider_config:
+ type: boolean
anthropic:
$ref: '#/components/schemas/AnthropicConfig'
azure:
diff --git a/packages/openapi/src/api.ts b/packages/openapi/src/api.ts
index 69006608a6..1d0b69177e 100644
--- a/packages/openapi/src/api.ts
+++ b/packages/openapi/src/api.ts
@@ -3728,6 +3728,7 @@ export interface components {
* - `max_tokens`: the maximum number of tokens to use in AI completions
* - `mode`: the mode to use for AI completions. Can be one of: `"ask"` or `"manual"`
* - `inline_tooltip`: if `True`, enable inline AI tooltip suggestions
+ * - `allow_provider_config`: if `False`, lock provider setup in the settings UI, making them read-only. Users cannot bring their own credentials or add custom providers. Default `True`.
* - `models`: the models to use for AI completions
* - `open_ai`: the OpenAI config
* - `anthropic`: the Anthropic config
@@ -3743,6 +3744,7 @@ export interface components {
* - `open_ai_compatible`: the OpenAI-compatible config (deprecated, use custom_providers)
*/
AiConfig: {
+ allow_provider_config?: boolean;
anthropic?: components["schemas"]["AnthropicConfig"];
azure?: components["schemas"]["OpenAiConfig"];
bedrock?: components["schemas"]["BedrockConfig"];
diff --git a/tests/_config/test_config.py b/tests/_config/test_config.py
index d78104d6ab..5e9fc215a8 100644
--- a/tests/_config/test_config.py
+++ b/tests/_config/test_config.py
@@ -15,6 +15,17 @@ def assert_config(override: MarimoConfig | PartialMarimoConfig) -> None:
assert user_config == {**DEFAULT_CONFIG, **override}
+def test_allow_provider_config_defaults_true() -> None:
+ assert DEFAULT_CONFIG["ai"]["allow_provider_config"] is True
+
+
+def test_allow_provider_config_can_be_disabled() -> None:
+ merged = merge_default_config(
+ PartialMarimoConfig(ai={"allow_provider_config": False})
+ )
+ assert merged["ai"]["allow_provider_config"] is False
+
+
def test_configure_partial_keymap() -> None:
assert_config(
PartialMarimoConfig(keymap={"preset": "vim", "overrides": {}})
diff --git a/tests/_server/templates/snapshots/export1.txt b/tests/_server/templates/snapshots/export1.txt
index 58f4db78fa..a3aafbfe7c 100644
--- a/tests/_server/templates/snapshots/export1.txt
+++ b/tests/_server/templates/snapshots/export1.txt
@@ -100,7 +100,7 @@
"mode": "read",
"version": "0.0.0",
"serverToken": "token",
- "config": {"ai": {"custom_providers": {}, "enabled": true, "models": {"custom_models": [], "displayed_models": []}}, "completion": {"activate_on_typing": true, "auto_close_pairs": true, "copilot": false, "signature_hint_on_typing": false}, "diagnostics": {"sql_linter": true}, "display": {"cell_output": "below", "code_editor_font_size": 14, "code_lens": true, "dataframes": "rich", "default_table_max_columns": 50, "default_table_page_size": 10, "default_width": "medium", "reference_highlighting": true, "theme": "light"}, "formatting": {"line_length": 79}, "keymap": {"overrides": {}, "preset": "default"}, "language_servers": {"pylsp": {"enable_flake8": false, "enable_mypy": true, "enable_pydocstyle": false, "enable_pyflakes": false, "enable_pylint": false, "enable_ruff": true, "enabled": false}}, "mcp": {"mcpServers": {}, "presets": []}, "package_management": {"manager": "uv"}, "runtime": {"auto_instantiate": false, "auto_reload": "off", "default_csv_encoding": "utf-8", "default_sql_output": "auto", "on_cell_change": "autorun", "output_max_bytes": 8000000, "reactive_tests": true, "show_tracebacks": false, "std_stream_max_bytes": 1000000, "watcher_on_save": "lazy"}, "save": {"autosave": "after_delay", "autosave_delay": 1000, "format_on_save": false}, "server": {"browser": "default", "follow_symlink": false}, "snippets": {"custom_paths": [], "include_default_snippets": true}},
+ "config": {"ai": {"allow_provider_config": true, "custom_providers": {}, "enabled": true, "models": {"custom_models": [], "displayed_models": []}}, "completion": {"activate_on_typing": true, "auto_close_pairs": true, "copilot": false, "signature_hint_on_typing": false}, "diagnostics": {"sql_linter": true}, "display": {"cell_output": "below", "code_editor_font_size": 14, "code_lens": true, "dataframes": "rich", "default_table_max_columns": 50, "default_table_page_size": 10, "default_width": "medium", "reference_highlighting": true, "theme": "light"}, "formatting": {"line_length": 79}, "keymap": {"overrides": {}, "preset": "default"}, "language_servers": {"pylsp": {"enable_flake8": false, "enable_mypy": true, "enable_pydocstyle": false, "enable_pyflakes": false, "enable_pylint": false, "enable_ruff": true, "enabled": false}}, "mcp": {"mcpServers": {}, "presets": []}, "package_management": {"manager": "uv"}, "runtime": {"auto_instantiate": false, "auto_reload": "off", "default_csv_encoding": "utf-8", "default_sql_output": "auto", "on_cell_change": "autorun", "output_max_bytes": 8000000, "reactive_tests": true, "show_tracebacks": false, "std_stream_max_bytes": 1000000, "watcher_on_save": "lazy"}, "save": {"autosave": "after_delay", "autosave_delay": 1000, "format_on_save": false}, "server": {"browser": "default", "follow_symlink": false}, "snippets": {"custom_paths": [], "include_default_snippets": true}},
"configOverrides": {"formatting": {"line_length": 100}},
"appConfig": {"sql_output": "auto", "width": "compact"},
"view": {"showAppCode": true},
diff --git a/tests/_server/templates/snapshots/export2.txt b/tests/_server/templates/snapshots/export2.txt
index 93a8770ae2..a4c3041430 100644
--- a/tests/_server/templates/snapshots/export2.txt
+++ b/tests/_server/templates/snapshots/export2.txt
@@ -100,7 +100,7 @@
"mode": "read",
"version": "0.0.0",
"serverToken": "token",
- "config": {"ai": {"custom_providers": {}, "enabled": true, "models": {"custom_models": [], "displayed_models": []}}, "completion": {"activate_on_typing": true, "auto_close_pairs": true, "copilot": false, "signature_hint_on_typing": false}, "diagnostics": {"sql_linter": true}, "display": {"cell_output": "below", "code_editor_font_size": 14, "code_lens": true, "dataframes": "rich", "default_table_max_columns": 50, "default_table_page_size": 10, "default_width": "medium", "reference_highlighting": true, "theme": "light"}, "formatting": {"line_length": 79}, "keymap": {"overrides": {}, "preset": "default"}, "language_servers": {"pylsp": {"enable_flake8": false, "enable_mypy": true, "enable_pydocstyle": false, "enable_pyflakes": false, "enable_pylint": false, "enable_ruff": true, "enabled": false}}, "mcp": {"mcpServers": {}, "presets": []}, "package_management": {"manager": "uv"}, "runtime": {"auto_instantiate": false, "auto_reload": "off", "default_csv_encoding": "utf-8", "default_sql_output": "auto", "on_cell_change": "autorun", "output_max_bytes": 8000000, "reactive_tests": true, "show_tracebacks": false, "std_stream_max_bytes": 1000000, "watcher_on_save": "lazy"}, "save": {"autosave": "after_delay", "autosave_delay": 1000, "format_on_save": false}, "server": {"browser": "default", "follow_symlink": false}, "snippets": {"custom_paths": [], "include_default_snippets": true}},
+ "config": {"ai": {"allow_provider_config": true, "custom_providers": {}, "enabled": true, "models": {"custom_models": [], "displayed_models": []}}, "completion": {"activate_on_typing": true, "auto_close_pairs": true, "copilot": false, "signature_hint_on_typing": false}, "diagnostics": {"sql_linter": true}, "display": {"cell_output": "below", "code_editor_font_size": 14, "code_lens": true, "dataframes": "rich", "default_table_max_columns": 50, "default_table_page_size": 10, "default_width": "medium", "reference_highlighting": true, "theme": "light"}, "formatting": {"line_length": 79}, "keymap": {"overrides": {}, "preset": "default"}, "language_servers": {"pylsp": {"enable_flake8": false, "enable_mypy": true, "enable_pydocstyle": false, "enable_pyflakes": false, "enable_pylint": false, "enable_ruff": true, "enabled": false}}, "mcp": {"mcpServers": {}, "presets": []}, "package_management": {"manager": "uv"}, "runtime": {"auto_instantiate": false, "auto_reload": "off", "default_csv_encoding": "utf-8", "default_sql_output": "auto", "on_cell_change": "autorun", "output_max_bytes": 8000000, "reactive_tests": true, "show_tracebacks": false, "std_stream_max_bytes": 1000000, "watcher_on_save": "lazy"}, "save": {"autosave": "after_delay", "autosave_delay": 1000, "format_on_save": false}, "server": {"browser": "default", "follow_symlink": false}, "snippets": {"custom_paths": [], "include_default_snippets": true}},
"configOverrides": {"formatting": {"line_length": 100}},
"appConfig": {"sql_output": "auto", "width": "compact"},
"view": {"showAppCode": true},
diff --git a/tests/_server/templates/snapshots/export3.txt b/tests/_server/templates/snapshots/export3.txt
index 2ee0d35413..91f2a5f537 100644
--- a/tests/_server/templates/snapshots/export3.txt
+++ b/tests/_server/templates/snapshots/export3.txt
@@ -100,7 +100,7 @@
"mode": "read",
"version": "0.0.0",
"serverToken": "token",
- "config": {"ai": {"custom_providers": {}, "enabled": true, "models": {"custom_models": [], "displayed_models": []}}, "completion": {"activate_on_typing": true, "auto_close_pairs": true, "copilot": false, "signature_hint_on_typing": false}, "diagnostics": {"sql_linter": true}, "display": {"cell_output": "below", "code_editor_font_size": 14, "code_lens": true, "dataframes": "rich", "default_table_max_columns": 50, "default_table_page_size": 10, "default_width": "medium", "reference_highlighting": true, "theme": "light"}, "formatting": {"line_length": 79}, "keymap": {"overrides": {}, "preset": "default"}, "language_servers": {"pylsp": {"enable_flake8": false, "enable_mypy": true, "enable_pydocstyle": false, "enable_pyflakes": false, "enable_pylint": false, "enable_ruff": true, "enabled": false}}, "mcp": {"mcpServers": {}, "presets": []}, "package_management": {"manager": "uv"}, "runtime": {"auto_instantiate": false, "auto_reload": "off", "default_csv_encoding": "utf-8", "default_sql_output": "auto", "on_cell_change": "autorun", "output_max_bytes": 8000000, "reactive_tests": true, "show_tracebacks": false, "std_stream_max_bytes": 1000000, "watcher_on_save": "lazy"}, "save": {"autosave": "after_delay", "autosave_delay": 1000, "format_on_save": false}, "server": {"browser": "default", "follow_symlink": false}, "snippets": {"custom_paths": [], "include_default_snippets": true}},
+ "config": {"ai": {"allow_provider_config": true, "custom_providers": {}, "enabled": true, "models": {"custom_models": [], "displayed_models": []}}, "completion": {"activate_on_typing": true, "auto_close_pairs": true, "copilot": false, "signature_hint_on_typing": false}, "diagnostics": {"sql_linter": true}, "display": {"cell_output": "below", "code_editor_font_size": 14, "code_lens": true, "dataframes": "rich", "default_table_max_columns": 50, "default_table_page_size": 10, "default_width": "medium", "reference_highlighting": true, "theme": "light"}, "formatting": {"line_length": 79}, "keymap": {"overrides": {}, "preset": "default"}, "language_servers": {"pylsp": {"enable_flake8": false, "enable_mypy": true, "enable_pydocstyle": false, "enable_pyflakes": false, "enable_pylint": false, "enable_ruff": true, "enabled": false}}, "mcp": {"mcpServers": {}, "presets": []}, "package_management": {"manager": "uv"}, "runtime": {"auto_instantiate": false, "auto_reload": "off", "default_csv_encoding": "utf-8", "default_sql_output": "auto", "on_cell_change": "autorun", "output_max_bytes": 8000000, "reactive_tests": true, "show_tracebacks": false, "std_stream_max_bytes": 1000000, "watcher_on_save": "lazy"}, "save": {"autosave": "after_delay", "autosave_delay": 1000, "format_on_save": false}, "server": {"browser": "default", "follow_symlink": false}, "snippets": {"custom_paths": [], "include_default_snippets": true}},
"configOverrides": {"formatting": {"line_length": 100}},
"appConfig": {"sql_output": "auto", "width": "compact"},
"view": {"showAppCode": true},
diff --git a/tests/_server/templates/snapshots/export4.txt b/tests/_server/templates/snapshots/export4.txt
index fcfb41581b..d0e36a64b9 100644
--- a/tests/_server/templates/snapshots/export4.txt
+++ b/tests/_server/templates/snapshots/export4.txt
@@ -100,7 +100,7 @@
"mode": "read",
"version": "0.0.0",
"serverToken": "token",
- "config": {"ai": {"custom_providers": {}, "enabled": true, "models": {"custom_models": [], "displayed_models": []}}, "completion": {"activate_on_typing": true, "auto_close_pairs": true, "copilot": false, "signature_hint_on_typing": false}, "diagnostics": {"sql_linter": true}, "display": {"cell_output": "below", "code_editor_font_size": 14, "code_lens": true, "dataframes": "rich", "default_table_max_columns": 50, "default_table_page_size": 10, "default_width": "medium", "reference_highlighting": true, "theme": "light"}, "formatting": {"line_length": 79}, "keymap": {"overrides": {}, "preset": "default"}, "language_servers": {"pylsp": {"enable_flake8": false, "enable_mypy": true, "enable_pydocstyle": false, "enable_pyflakes": false, "enable_pylint": false, "enable_ruff": true, "enabled": false}}, "mcp": {"mcpServers": {}, "presets": []}, "package_management": {"manager": "uv"}, "runtime": {"auto_instantiate": false, "auto_reload": "off", "default_csv_encoding": "utf-8", "default_sql_output": "auto", "on_cell_change": "autorun", "output_max_bytes": 8000000, "reactive_tests": true, "show_tracebacks": false, "std_stream_max_bytes": 1000000, "watcher_on_save": "lazy"}, "save": {"autosave": "after_delay", "autosave_delay": 1000, "format_on_save": false}, "server": {"browser": "default", "follow_symlink": false}, "snippets": {"custom_paths": [], "include_default_snippets": true}},
+ "config": {"ai": {"allow_provider_config": true, "custom_providers": {}, "enabled": true, "models": {"custom_models": [], "displayed_models": []}}, "completion": {"activate_on_typing": true, "auto_close_pairs": true, "copilot": false, "signature_hint_on_typing": false}, "diagnostics": {"sql_linter": true}, "display": {"cell_output": "below", "code_editor_font_size": 14, "code_lens": true, "dataframes": "rich", "default_table_max_columns": 50, "default_table_page_size": 10, "default_width": "medium", "reference_highlighting": true, "theme": "light"}, "formatting": {"line_length": 79}, "keymap": {"overrides": {}, "preset": "default"}, "language_servers": {"pylsp": {"enable_flake8": false, "enable_mypy": true, "enable_pydocstyle": false, "enable_pyflakes": false, "enable_pylint": false, "enable_ruff": true, "enabled": false}}, "mcp": {"mcpServers": {}, "presets": []}, "package_management": {"manager": "uv"}, "runtime": {"auto_instantiate": false, "auto_reload": "off", "default_csv_encoding": "utf-8", "default_sql_output": "auto", "on_cell_change": "autorun", "output_max_bytes": 8000000, "reactive_tests": true, "show_tracebacks": false, "std_stream_max_bytes": 1000000, "watcher_on_save": "lazy"}, "save": {"autosave": "after_delay", "autosave_delay": 1000, "format_on_save": false}, "server": {"browser": "default", "follow_symlink": false}, "snippets": {"custom_paths": [], "include_default_snippets": true}},
"configOverrides": {"formatting": {"line_length": 100}},
"appConfig": {"css_file": "custom.css", "sql_output": "auto", "width": "compact"},
"view": {"showAppCode": true},
diff --git a/tests/_server/templates/snapshots/export5.txt b/tests/_server/templates/snapshots/export5.txt
index a7462b0190..af55fed968 100644
--- a/tests/_server/templates/snapshots/export5.txt
+++ b/tests/_server/templates/snapshots/export5.txt
@@ -112,7 +112,7 @@
"mode": "read",
"version": "0.0.0",
"serverToken": "token",
- "config": {"ai": {"custom_providers": {}, "enabled": true, "models": {"custom_models": [], "displayed_models": []}}, "completion": {"activate_on_typing": true, "auto_close_pairs": true, "copilot": false, "signature_hint_on_typing": false}, "diagnostics": {"sql_linter": true}, "display": {"cell_output": "below", "code_editor_font_size": 14, "code_lens": true, "dataframes": "rich", "default_table_max_columns": 50, "default_table_page_size": 10, "default_width": "medium", "reference_highlighting": true, "theme": "light"}, "formatting": {"line_length": 79}, "keymap": {"overrides": {}, "preset": "default"}, "language_servers": {"pylsp": {"enable_flake8": false, "enable_mypy": true, "enable_pydocstyle": false, "enable_pyflakes": false, "enable_pylint": false, "enable_ruff": true, "enabled": false}}, "mcp": {"mcpServers": {}, "presets": []}, "package_management": {"manager": "uv"}, "runtime": {"auto_instantiate": false, "auto_reload": "off", "default_csv_encoding": "utf-8", "default_sql_output": "auto", "on_cell_change": "autorun", "output_max_bytes": 8000000, "reactive_tests": true, "show_tracebacks": false, "std_stream_max_bytes": 1000000, "watcher_on_save": "lazy"}, "save": {"autosave": "after_delay", "autosave_delay": 1000, "format_on_save": false}, "server": {"browser": "default", "follow_symlink": false}, "snippets": {"custom_paths": [], "include_default_snippets": true}},
+ "config": {"ai": {"allow_provider_config": true, "custom_providers": {}, "enabled": true, "models": {"custom_models": [], "displayed_models": []}}, "completion": {"activate_on_typing": true, "auto_close_pairs": true, "copilot": false, "signature_hint_on_typing": false}, "diagnostics": {"sql_linter": true}, "display": {"cell_output": "below", "code_editor_font_size": 14, "code_lens": true, "dataframes": "rich", "default_table_max_columns": 50, "default_table_page_size": 10, "default_width": "medium", "reference_highlighting": true, "theme": "light"}, "formatting": {"line_length": 79}, "keymap": {"overrides": {}, "preset": "default"}, "language_servers": {"pylsp": {"enable_flake8": false, "enable_mypy": true, "enable_pydocstyle": false, "enable_pyflakes": false, "enable_pylint": false, "enable_ruff": true, "enabled": false}}, "mcp": {"mcpServers": {}, "presets": []}, "package_management": {"manager": "uv"}, "runtime": {"auto_instantiate": false, "auto_reload": "off", "default_csv_encoding": "utf-8", "default_sql_output": "auto", "on_cell_change": "autorun", "output_max_bytes": 8000000, "reactive_tests": true, "show_tracebacks": false, "std_stream_max_bytes": 1000000, "watcher_on_save": "lazy"}, "save": {"autosave": "after_delay", "autosave_delay": 1000, "format_on_save": false}, "server": {"browser": "default", "follow_symlink": false}, "snippets": {"custom_paths": [], "include_default_snippets": true}},
"configOverrides": {"formatting": {"line_length": 100}},
"appConfig": {"app_title": "My App", "html_head_file": "head.html", "sql_output": "auto", "width": "compact"},
"view": {"showAppCode": true},
diff --git a/tests/_server/templates/snapshots/export6.txt b/tests/_server/templates/snapshots/export6.txt
index 793397b4b5..d95c2a7573 100644
--- a/tests/_server/templates/snapshots/export6.txt
+++ b/tests/_server/templates/snapshots/export6.txt
@@ -101,7 +101,7 @@
"mode": "read",
"version": "0.0.0",
"serverToken": "token",
- "config": {"ai": {"custom_providers": {}, "enabled": true, "models": {"custom_models": [], "displayed_models": []}}, "completion": {"activate_on_typing": true, "auto_close_pairs": true, "copilot": false, "signature_hint_on_typing": false}, "diagnostics": {"sql_linter": true}, "display": {"cell_output": "below", "code_editor_font_size": 14, "code_lens": true, "custom_css": ["custom1.css", "custom2.css"], "dataframes": "rich", "default_table_max_columns": 50, "default_table_page_size": 10, "default_width": "medium", "reference_highlighting": true, "theme": "light"}, "formatting": {"line_length": 79}, "keymap": {"overrides": {}, "preset": "default"}, "language_servers": {"pylsp": {"enable_flake8": false, "enable_mypy": true, "enable_pydocstyle": false, "enable_pyflakes": false, "enable_pylint": false, "enable_ruff": true, "enabled": false}}, "mcp": {"mcpServers": {}, "presets": []}, "package_management": {"manager": "uv"}, "runtime": {"auto_instantiate": false, "auto_reload": "off", "default_csv_encoding": "utf-8", "default_sql_output": "auto", "on_cell_change": "autorun", "output_max_bytes": 8000000, "reactive_tests": true, "show_tracebacks": false, "std_stream_max_bytes": 1000000, "watcher_on_save": "lazy"}, "save": {"autosave": "after_delay", "autosave_delay": 1000, "format_on_save": false}, "server": {"browser": "default", "follow_symlink": false}, "snippets": {"custom_paths": [], "include_default_snippets": true}},
+ "config": {"ai": {"allow_provider_config": true, "custom_providers": {}, "enabled": true, "models": {"custom_models": [], "displayed_models": []}}, "completion": {"activate_on_typing": true, "auto_close_pairs": true, "copilot": false, "signature_hint_on_typing": false}, "diagnostics": {"sql_linter": true}, "display": {"cell_output": "below", "code_editor_font_size": 14, "code_lens": true, "custom_css": ["custom1.css", "custom2.css"], "dataframes": "rich", "default_table_max_columns": 50, "default_table_page_size": 10, "default_width": "medium", "reference_highlighting": true, "theme": "light"}, "formatting": {"line_length": 79}, "keymap": {"overrides": {}, "preset": "default"}, "language_servers": {"pylsp": {"enable_flake8": false, "enable_mypy": true, "enable_pydocstyle": false, "enable_pyflakes": false, "enable_pylint": false, "enable_ruff": true, "enabled": false}}, "mcp": {"mcpServers": {}, "presets": []}, "package_management": {"manager": "uv"}, "runtime": {"auto_instantiate": false, "auto_reload": "off", "default_csv_encoding": "utf-8", "default_sql_output": "auto", "on_cell_change": "autorun", "output_max_bytes": 8000000, "reactive_tests": true, "show_tracebacks": false, "std_stream_max_bytes": 1000000, "watcher_on_save": "lazy"}, "save": {"autosave": "after_delay", "autosave_delay": 1000, "format_on_save": false}, "server": {"browser": "default", "follow_symlink": false}, "snippets": {"custom_paths": [], "include_default_snippets": true}},
"configOverrides": {"formatting": {"line_length": 100}},
"appConfig": {"sql_output": "auto", "width": "compact"},
"view": {"showAppCode": true},