Skip to content

Commit 7a3f2e7

Browse files
authored
Remove superset mcp (#2154)
Fixes OPS-3958.
1 parent 80ab4af commit 7a3f2e7

10 files changed

Lines changed: 1 addition & 135 deletions

File tree

.devcontainer/Dockerfile

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -63,13 +63,6 @@ RUN <<-```
6363
ENV PATH="/opt/google-cloud-sdk/bin:$PATH"
6464

6565
SHELL ["/bin/bash", "-c"]
66-
WORKDIR /root/.mcp/superset
67-
RUN <<-```
68-
set -ex
69-
git clone https://github.com/openops-cloud/superset-mcp .
70-
wget -qO- https://astral.sh/uv/install.sh | sh && source $HOME/.local/bin/env
71-
uv venv && uv pip install .
72-
```
7366

7467
WORKDIR /root/.mcp/openops-mcp
7568
RUN <<-```

Dockerfile

Lines changed: 1 addition & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -13,15 +13,6 @@ RUN <<-```
1313
yarn config set python /usr/bin/python3
1414
```
1515

16-
WORKDIR /root/.mcp/superset
17-
RUN <<-```
18-
set -ex
19-
git clone https://github.com/openops-cloud/superset-mcp .
20-
git checkout 1c391f7d0a261ee51f7b1e6c413f1930418d17fe
21-
wget -qO- https://astral.sh/uv/install.sh | sh
22-
python3 -m venv .venv && .venv/bin/pip install .
23-
```
24-
2516
WORKDIR /root/.mcp/openops-mcp
2617
RUN <<-```
2718
set -ex
@@ -75,4 +66,4 @@ COPY docker-entrypoint.sh .
7566
RUN chmod +x docker-entrypoint.sh
7667
ENTRYPOINT ["./docker-entrypoint.sh"]
7768

78-
EXPOSE 80
69+
EXPOSE 80

ai-prompts/mcp-analytics.txt

Lines changed: 0 additions & 28 deletions
This file was deleted.

packages/server/api/src/app/ai/chat/prompts.service.ts

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -33,13 +33,6 @@ export const getMcpSystemPrompt = async ({
3333
promptsToLoad.push('mcp-tables.txt');
3434
}
3535

36-
if (
37-
queryClassification.includes(QueryClassification.analytics) &&
38-
hasToolProvider(selectedTools, 'superset')
39-
) {
40-
promptsToLoad.push('mcp-analytics.txt');
41-
}
42-
4336
if (
4437
queryClassification.includes(QueryClassification.openops) &&
4538
hasToolProvider(selectedTools, 'openops')

packages/server/api/src/app/ai/mcp/llm-query-router.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -22,8 +22,6 @@ export type ToolsAndQueryResult = {
2222

2323
const baseQueryClassificationDescriptions: Record<QueryClassification, string> =
2424
{
25-
[QueryClassification.analytics]:
26-
'requires data visualization, charts, dashboards, or Superset-related functionality',
2725
[QueryClassification.tables]:
2826
'requires database access, schema information, or table operations',
2927
[QueryClassification.openops]:

packages/server/api/src/app/ai/mcp/superset-tools.ts

Lines changed: 0 additions & 57 deletions
This file was deleted.

packages/server/api/src/app/ai/mcp/tools-initializer.ts

Lines changed: 0 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,10 @@
1-
import { AppSystemProp, system } from '@openops/server-shared';
21
import { ToolSet } from 'ai';
32
import { FastifyInstance } from 'fastify';
43
import { getCostTools } from './cost-tools';
54
import { getDocsTools } from './docs-tools';
65
import { safeGetTools } from './load-tools-guard';
76
import { getOpenOpsTools } from './openops-tools';
8-
import { getSupersetTools } from './superset-tools';
97
import { getTablesTools } from './tables-tools';
10-
import { MCPTool } from './types';
118

129
export const startMCPTools = async (
1310
app: FastifyInstance,
@@ -40,22 +37,7 @@ export const startMCPTools = async (
4037
toolSet: billingAndCostManagement.toolSet,
4138
};
4239

43-
const loadExperimentalTools = system.getBoolean(
44-
AppSystemProp.LOAD_EXPERIMENTAL_MCP_TOOLS,
45-
);
46-
const analyticsEnabled = system.isAnalyticsEnabled();
47-
48-
let supersetTools: Partial<MCPTool> = {
49-
client: undefined,
50-
toolSet: {},
51-
};
52-
53-
if (loadExperimentalTools && analyticsEnabled) {
54-
supersetTools = await safeGetTools('superset', getSupersetTools);
55-
}
56-
5740
const toolSet = {
58-
...supersetTools.toolSet,
5941
...docsTools.toolSet,
6042
...tablesTools.toolSet,
6143
...openopsTools.toolSet,
@@ -66,7 +48,6 @@ export const startMCPTools = async (
6648

6749
return {
6850
mcpClients: [
69-
supersetTools.client,
7051
docsTools.client,
7152
tablesTools.client,
7253
openopsTools.client,

packages/server/api/src/app/ai/mcp/types.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ export type AssistantUITools = Record<
1616
>;
1717

1818
export const QueryClassification = {
19-
analytics: 'analytics',
2019
tables: 'tables',
2120
openops: 'openops',
2221
aws_cost: 'aws_cost',

packages/server/shared/src/lib/system/system-prop.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -103,9 +103,7 @@ export enum AppSystemProp {
103103

104104
AI_PROMPTS_LOCATION = 'AI_PROMPTS_LOCATION',
105105

106-
SUPERSET_MCP_SERVER_PATH = 'SUPERSET_MCP_SERVER_PATH',
107106
DOCS_MCP_SERVER_PATH = 'DOCS_MCP_SERVER_PATH',
108-
LOAD_EXPERIMENTAL_MCP_TOOLS = 'LOAD_EXPERIMENTAL_MCP_TOOLS',
109107

110108
OPENOPS_MCP_SERVER_PATH = 'OPENOPS_MCP_SERVER_PATH',
111109

packages/server/shared/src/lib/system/system.ts

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -94,9 +94,7 @@ const systemPropDefaultValues: Partial<Record<SystemProp, string>> = {
9494
[AppSystemProp.CODE_BLOCK_MEMORY_LIMIT_IN_MB]: '128',
9595
[AppSystemProp.AI_PROMPTS_LOCATION]:
9696
'https://raw.githubusercontent.com/openops-cloud/openops/main/ai-prompts',
97-
[AppSystemProp.SUPERSET_MCP_SERVER_PATH]: '/root/.mcp/superset',
9897
[AppSystemProp.DOCS_MCP_SERVER_PATH]: 'https://docs.openops.com/mcp',
99-
[AppSystemProp.LOAD_EXPERIMENTAL_MCP_TOOLS]: 'false',
10098
[SharedSystemProp.AWS_ENABLE_IMPLICIT_ROLE]: 'false',
10199
[AppSystemProp.OPENOPS_MCP_SERVER_PATH]: '/root/.mcp/openops-mcp',
102100
[AppSystemProp.AWS_MCP_COST_PATH]: '/root/.mcp/aws-cost',

0 commit comments

Comments
 (0)