@lutery/vision-mcp 1.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +428 -0
- package/dist/adapters/base-adapter.d.ts +69 -0
- package/dist/adapters/base-adapter.d.ts.map +1 -0
- package/dist/adapters/base-adapter.js +143 -0
- package/dist/adapters/base-adapter.js.map +1 -0
- package/dist/adapters/claude-adapter.d.ts +38 -0
- package/dist/adapters/claude-adapter.d.ts.map +1 -0
- package/dist/adapters/claude-adapter.js +251 -0
- package/dist/adapters/claude-adapter.js.map +1 -0
- package/dist/adapters/glm-adapter.d.ts +15 -0
- package/dist/adapters/glm-adapter.d.ts.map +1 -0
- package/dist/adapters/glm-adapter.js +131 -0
- package/dist/adapters/glm-adapter.js.map +1 -0
- package/dist/adapters/modelscope-adapter.d.ts +20 -0
- package/dist/adapters/modelscope-adapter.d.ts.map +1 -0
- package/dist/adapters/modelscope-adapter.js +142 -0
- package/dist/adapters/modelscope-adapter.js.map +1 -0
- package/dist/adapters/openai-adapter.d.ts +20 -0
- package/dist/adapters/openai-adapter.d.ts.map +1 -0
- package/dist/adapters/openai-adapter.js +194 -0
- package/dist/adapters/openai-adapter.js.map +1 -0
- package/dist/adapters/siliconflow-adapter.d.ts +21 -0
- package/dist/adapters/siliconflow-adapter.d.ts.map +1 -0
- package/dist/adapters/siliconflow-adapter.js +145 -0
- package/dist/adapters/siliconflow-adapter.js.map +1 -0
- package/dist/config/model-config.d.ts +39 -0
- package/dist/config/model-config.d.ts.map +1 -0
- package/dist/config/model-config.js +115 -0
- package/dist/config/model-config.js.map +1 -0
- package/dist/index.d.ts +17 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +186 -0
- package/dist/index.js.map +1 -0
- package/dist/prompts/system.d.ts +75 -0
- package/dist/prompts/system.d.ts.map +1 -0
- package/dist/prompts/system.js +272 -0
- package/dist/prompts/system.js.map +1 -0
- package/dist/providers/provider-registry.d.ts +58 -0
- package/dist/providers/provider-registry.d.ts.map +1 -0
- package/dist/providers/provider-registry.js +173 -0
- package/dist/providers/provider-registry.js.map +1 -0
- package/dist/src/adapters/base-adapter.d.ts +59 -0
- package/dist/src/adapters/base-adapter.d.ts.map +1 -0
- package/dist/src/adapters/base-adapter.js +83 -0
- package/dist/src/adapters/base-adapter.js.map +1 -0
- package/dist/src/adapters/glm-adapter.d.ts +15 -0
- package/dist/src/adapters/glm-adapter.d.ts.map +1 -0
- package/dist/src/adapters/glm-adapter.js +116 -0
- package/dist/src/adapters/glm-adapter.js.map +1 -0
- package/dist/src/adapters/siliconflow-adapter.d.ts +21 -0
- package/dist/src/adapters/siliconflow-adapter.d.ts.map +1 -0
- package/dist/src/adapters/siliconflow-adapter.js +130 -0
- package/dist/src/adapters/siliconflow-adapter.js.map +1 -0
- package/dist/src/config/model-config.d.ts +40 -0
- package/dist/src/config/model-config.d.ts.map +1 -0
- package/dist/src/config/model-config.js +126 -0
- package/dist/src/config/model-config.js.map +1 -0
- package/dist/src/index.d.ts +17 -0
- package/dist/src/index.d.ts.map +1 -0
- package/dist/src/index.js +188 -0
- package/dist/src/index.js.map +1 -0
- package/dist/src/prompts/system.d.ts +75 -0
- package/dist/src/prompts/system.d.ts.map +1 -0
- package/dist/src/prompts/system.js +272 -0
- package/dist/src/prompts/system.js.map +1 -0
- package/dist/src/tools/vision-tool.d.ts +91 -0
- package/dist/src/tools/vision-tool.d.ts.map +1 -0
- package/dist/src/tools/vision-tool.js +171 -0
- package/dist/src/tools/vision-tool.js.map +1 -0
- package/dist/src/utils/errors.d.ts +65 -0
- package/dist/src/utils/errors.d.ts.map +1 -0
- package/dist/src/utils/errors.js +146 -0
- package/dist/src/utils/errors.js.map +1 -0
- package/dist/src/utils/image-input.d.ts +45 -0
- package/dist/src/utils/image-input.d.ts.map +1 -0
- package/dist/src/utils/image-input.js +226 -0
- package/dist/src/utils/image-input.js.map +1 -0
- package/dist/src/utils/logger.d.ts +63 -0
- package/dist/src/utils/logger.d.ts.map +1 -0
- package/dist/src/utils/logger.js +157 -0
- package/dist/src/utils/logger.js.map +1 -0
- package/dist/test/integration.test.d.ts +10 -0
- package/dist/test/integration.test.d.ts.map +1 -0
- package/dist/test/integration.test.js +270 -0
- package/dist/test/integration.test.js.map +1 -0
- package/dist/test/test-utils.d.ts +45 -0
- package/dist/test/test-utils.d.ts.map +1 -0
- package/dist/test/test-utils.js +107 -0
- package/dist/test/test-utils.js.map +1 -0
- package/dist/test/vision-tool.test.d.ts +9 -0
- package/dist/test/vision-tool.test.d.ts.map +1 -0
- package/dist/test/vision-tool.test.js +167 -0
- package/dist/test/vision-tool.test.js.map +1 -0
- package/dist/tools/vision-tool.d.ts +91 -0
- package/dist/tools/vision-tool.d.ts.map +1 -0
- package/dist/tools/vision-tool.js +167 -0
- package/dist/tools/vision-tool.js.map +1 -0
- package/dist/utils/data-url-parser.d.ts +27 -0
- package/dist/utils/data-url-parser.d.ts.map +1 -0
- package/dist/utils/data-url-parser.js +53 -0
- package/dist/utils/data-url-parser.js.map +1 -0
- package/dist/utils/errors.d.ts +65 -0
- package/dist/utils/errors.d.ts.map +1 -0
- package/dist/utils/errors.js +146 -0
- package/dist/utils/errors.js.map +1 -0
- package/dist/utils/image-input.d.ts +45 -0
- package/dist/utils/image-input.d.ts.map +1 -0
- package/dist/utils/image-input.js +238 -0
- package/dist/utils/image-input.js.map +1 -0
- package/dist/utils/logger.d.ts +63 -0
- package/dist/utils/logger.d.ts.map +1 -0
- package/dist/utils/logger.js +157 -0
- package/dist/utils/logger.js.map +1 -0
- package/dist/utils/thinking-extractors.d.ts +34 -0
- package/dist/utils/thinking-extractors.d.ts.map +1 -0
- package/dist/utils/thinking-extractors.js +83 -0
- package/dist/utils/thinking-extractors.js.map +1 -0
- package/dist/utils/thinking-filter.d.ts +32 -0
- package/dist/utils/thinking-filter.d.ts.map +1 -0
- package/dist/utils/thinking-filter.js +147 -0
- package/dist/utils/thinking-filter.js.map +1 -0
- package/package.json +41 -0
|
@@ -0,0 +1,147 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Thinking/Reasoning Content Filter
|
|
3
|
+
*
|
|
4
|
+
* @description Filters thinking/reasoning content from model responses to prevent
|
|
5
|
+
* exposing internal reasoning to MCP clients. Supports multiple models and response formats.
|
|
6
|
+
*
|
|
7
|
+
* Architecture Decision: Keep thinking enabled at model level but strip reasoning
|
|
8
|
+
* content before returning to MCP client.
|
|
9
|
+
*/
|
|
10
|
+
import { logger } from './logger.js';
|
|
11
|
+
import { extractGLMThinking, extractOpenAIThinking, extractClaudeThinking } from './thinking-extractors.js';
|
|
12
|
+
/**
|
|
13
|
+
* Thinking content patterns to filter from text
|
|
14
|
+
* These patterns match common thinking/reasoning content markers used by various models
|
|
15
|
+
*/
|
|
16
|
+
const THINKING_PATTERNS = [
|
|
17
|
+
// HTML-style thinking tags
|
|
18
|
+
/<thinking>[\s\S]*?<\/thinking>/gi,
|
|
19
|
+
// Analysis tags
|
|
20
|
+
/<<analysis>>[\s\S]*?<<analysis>>/gi,
|
|
21
|
+
// Reasoning patterns (match from Reasoning:/Thoughts:/Analysis: to end of line)
|
|
22
|
+
/^\s*(Reasoning|Thoughts|Analysis):.*$/gim,
|
|
23
|
+
// Markdown thinking sections
|
|
24
|
+
/```(?:thinking|reasoning)[\s\S]*?```/gi,
|
|
25
|
+
// Inline thinking markers
|
|
26
|
+
/\[thinking\][\s\S]*?\[\/thinking\]/gi,
|
|
27
|
+
// Match leftover thinking markers to ensure they don't appear
|
|
28
|
+
/(<thinking>|<\/thinking>|<<analysis>>)/gi,
|
|
29
|
+
// Optional: Add more patterns as new models are discovered
|
|
30
|
+
];
|
|
31
|
+
/**
|
|
32
|
+
* Registry of thinking extractors by model type
|
|
33
|
+
* Uses imported extractor functions to avoid circular dependencies
|
|
34
|
+
*/
|
|
35
|
+
export const THINKING_EXTRACTORS = {
|
|
36
|
+
'glm-4.6v': extractGLMThinking,
|
|
37
|
+
'glm-4v': extractGLMThinking,
|
|
38
|
+
'siliconflow': extractOpenAIThinking,
|
|
39
|
+
'openai': extractOpenAIThinking,
|
|
40
|
+
'claude': extractClaudeThinking,
|
|
41
|
+
// Add more model extractors as needed
|
|
42
|
+
};
|
|
43
|
+
/**
|
|
44
|
+
* Strips thinking content from text using pattern matching
|
|
45
|
+
* @param text - The text to clean
|
|
46
|
+
* @returns Cleaned text with thinking content removed
|
|
47
|
+
*/
|
|
48
|
+
function stripThinkingPatterns(text) {
|
|
49
|
+
if (!text || typeof text !== 'string') {
|
|
50
|
+
return '';
|
|
51
|
+
}
|
|
52
|
+
let cleaned = text;
|
|
53
|
+
let removedCount = 0;
|
|
54
|
+
// Apply each pattern to remove thinking content
|
|
55
|
+
for (const pattern of THINKING_PATTERNS) {
|
|
56
|
+
let beforeLength = cleaned.length;
|
|
57
|
+
cleaned = cleaned.replace(pattern, '');
|
|
58
|
+
// Loop to replace all occurrences of the pattern
|
|
59
|
+
while (cleaned.length < beforeLength) {
|
|
60
|
+
removedCount++;
|
|
61
|
+
beforeLength = cleaned.length;
|
|
62
|
+
cleaned = cleaned.replace(pattern, '');
|
|
63
|
+
}
|
|
64
|
+
}
|
|
65
|
+
// Log if we removed thinking content
|
|
66
|
+
if (removedCount > 0) {
|
|
67
|
+
logger.debug(`Stripped thinking patterns from content`, {
|
|
68
|
+
patternsRemoved: removedCount,
|
|
69
|
+
sizeReduction: text.length - cleaned.length
|
|
70
|
+
});
|
|
71
|
+
}
|
|
72
|
+
// Clean up extra whitespace
|
|
73
|
+
return cleaned.trim().replace(/\n\s*\n\s*\n/g, '\n\n');
|
|
74
|
+
}
|
|
75
|
+
/**
|
|
76
|
+
* Strips thinking content from model response envelope
|
|
77
|
+
* @param envelope - Response envelope that may contain thinking content
|
|
78
|
+
* @returns Cleaned content string with all thinking content removed
|
|
79
|
+
*/
|
|
80
|
+
export function stripThinking(envelope) {
|
|
81
|
+
const { content, reasoning, thinking } = envelope;
|
|
82
|
+
// Start with the main content
|
|
83
|
+
let cleaned = content || '';
|
|
84
|
+
// If there's explicit reasoning/thinking content, ignore it
|
|
85
|
+
// We NEVER return thinking content to the client
|
|
86
|
+
if (reasoning || thinking) {
|
|
87
|
+
logger.debug('Ignoring explicit thinking/reasoning field', {
|
|
88
|
+
hasReasoning: !!reasoning,
|
|
89
|
+
hasThinking: !!thinking,
|
|
90
|
+
reasoningLength: reasoning?.length || 0,
|
|
91
|
+
thinkingLength: thinking?.length || 0
|
|
92
|
+
});
|
|
93
|
+
}
|
|
94
|
+
// Strip any thinking patterns from the content itself
|
|
95
|
+
cleaned = stripThinkingPatterns(cleaned);
|
|
96
|
+
// If after cleaning the content is very short and we have reasoning,
|
|
97
|
+
// this might indicate the model only returned thinking content
|
|
98
|
+
// In this case, we return empty string, not the thinking content
|
|
99
|
+
if (cleaned.length < 10 && (reasoning || thinking)) {
|
|
100
|
+
logger.warn('Model response appears to contain only thinking content', {
|
|
101
|
+
contentLength: content?.length || 0,
|
|
102
|
+
reasoningLength: reasoning?.length || 0,
|
|
103
|
+
thinkingLength: thinking?.length || 0
|
|
104
|
+
});
|
|
105
|
+
return '';
|
|
106
|
+
}
|
|
107
|
+
return cleaned;
|
|
108
|
+
}
|
|
109
|
+
/**
|
|
110
|
+
* Filters thinking content from raw model response
|
|
111
|
+
* This is the main entry point for filtering thinking content
|
|
112
|
+
*
|
|
113
|
+
* @param rawResponse - The raw response from the model API
|
|
114
|
+
* @param modelType - The type of model (e.g., 'glm-4.6v', 'siliconflow')
|
|
115
|
+
* @returns Cleaned content string with thinking content removed
|
|
116
|
+
*/
|
|
117
|
+
export function filterThinkingContent(rawResponse, modelType) {
|
|
118
|
+
// modelType is now required - validate it
|
|
119
|
+
if (!modelType) {
|
|
120
|
+
logger.error('modelType is required for thinking filter but was not provided');
|
|
121
|
+
throw new Error('modelType is required for thinking filter');
|
|
122
|
+
}
|
|
123
|
+
try {
|
|
124
|
+
// Use local extractor map to avoid circular dependency with provider-registry
|
|
125
|
+
const extractor = THINKING_EXTRACTORS[modelType.toLowerCase()] || extractOpenAIThinking;
|
|
126
|
+
if (!THINKING_EXTRACTORS[modelType.toLowerCase()]) {
|
|
127
|
+
logger.warn(`No extractor found for model type: ${modelType}, using generic extraction`);
|
|
128
|
+
}
|
|
129
|
+
// 提取 thinking content
|
|
130
|
+
const envelope = extractor(rawResponse);
|
|
131
|
+
return stripThinking(envelope);
|
|
132
|
+
}
|
|
133
|
+
catch (error) {
|
|
134
|
+
logger.error('Failed to filter thinking content', { error, modelType });
|
|
135
|
+
// Fallback: try to extract content directly from response
|
|
136
|
+
try {
|
|
137
|
+
// @ts-ignore
|
|
138
|
+
const content = rawResponse?.choices?.[0]?.message?.content || '';
|
|
139
|
+
return stripThinkingPatterns(content);
|
|
140
|
+
}
|
|
141
|
+
catch (fallbackError) {
|
|
142
|
+
logger.error('Fallback content extraction also failed', { error: fallbackError });
|
|
143
|
+
return '';
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
//# sourceMappingURL=thinking-filter.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"thinking-filter.js","sourceRoot":"","sources":["../../src/utils/thinking-filter.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AAEH,OAAO,EAAE,MAAM,EAAE,MAAM,aAAa,CAAC;AACrC,OAAO,EAGL,kBAAkB,EAClB,qBAAqB,EACrB,qBAAqB,EACtB,MAAM,0BAA0B,CAAC;AAKlC;;;GAGG;AACH,MAAM,iBAAiB,GAAG;IACxB,2BAA2B;IAC3B,kCAAkC;IAClC,gBAAgB;IAChB,oCAAoC;IACpC,gFAAgF;IAChF,0CAA0C;IAC1C,6BAA6B;IAC7B,wCAAwC;IACxC,0BAA0B;IAC1B,sCAAsC;IACtC,8DAA8D;IAC9D,0CAA0C;IAC1C,2DAA2D;CAC5D,CAAC;AAEF;;;GAGG;AACH,MAAM,CAAC,MAAM,mBAAmB,GAAsC;IACpE,UAAU,EAAE,kBAAkB;IAC9B,QAAQ,EAAE,kBAAkB;I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WAAW,EAAE,CAAC,EAAE,CAAC;YAClD,MAAM,CAAC,IAAI,CAAC,sCAAsC,SAAS,4BAA4B,CAAC,CAAC;QAC3F,CAAC;QAED,sBAAsB;QACtB,MAAM,QAAQ,GAAG,SAAS,CAAC,WAAW,CAAC,CAAC;QACxC,OAAO,aAAa,CAAC,QAAQ,CAAC,CAAC;IAEjC,CAAC;IAAC,OAAO,KAAK,EAAE,CAAC;QACf,MAAM,CAAC,KAAK,CAAC,mCAAmC,EAAE,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC,CAAC;QAExE,0DAA0D;QAC1D,IAAI,CAAC;YACH,aAAa;YACb,MAAM,OAAO,GAAG,WAAW,EAAE,OAAO,EAAE,CAAC,CAAC,CAAC,EAAE,OAAO,EAAE,OAAO,IAAI,EAAE,CAAC;YAClE,OAAO,qBAAqB,CAAC,OAAO,CAAC,CAAC;QACxC,CAAC;QAAC,OAAO,aAAa,EAAE,CAAC;YACvB,MAAM,CAAC,KAAK,CAAC,yCAAyC,EAAE,EAAE,KAAK,EAAE,aAAa,EAAE,CAAC,CAAC;YAClF,OAAO,EAAE,CAAC;QACZ,CAAC;IACH,CAAC;AACH,CAAC"}
|
package/package.json
ADDED
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "@lutery/vision-mcp",
|
|
3
|
+
"version": "1.0.0",
|
|
4
|
+
"description": "MCP Server providing vision capabilities for LLMs via GLM-4.6V, SiliconFlow, and ModelScope",
|
|
5
|
+
"type": "module",
|
|
6
|
+
"bin": {
|
|
7
|
+
"vision-mcp": "dist/index.js"
|
|
8
|
+
},
|
|
9
|
+
"files": [
|
|
10
|
+
"dist"
|
|
11
|
+
],
|
|
12
|
+
"scripts": {
|
|
13
|
+
"build": "tsc -p tsconfig.json",
|
|
14
|
+
"prepublishOnly": "npm run build",
|
|
15
|
+
"test": "npm run build && node -r dotenv/config test/simple-test.js",
|
|
16
|
+
"test:complex": "npm run build && node -r dotenv/config test/run-tests.js",
|
|
17
|
+
"test:unit": "node test/thinking-filter.test.js && node test/data-url-parser.test.js && node test/thinking-extractors.test.js && node test/claude-adapter.test.js",
|
|
18
|
+
"test:integration": "npm run build && node -r dotenv/config test/simple-test.js"
|
|
19
|
+
},
|
|
20
|
+
"keywords": [
|
|
21
|
+
"mcp",
|
|
22
|
+
"vision",
|
|
23
|
+
"llm",
|
|
24
|
+
"glm-4.6v",
|
|
25
|
+
"siliconflow"
|
|
26
|
+
],
|
|
27
|
+
"author": "",
|
|
28
|
+
"license": "MIT",
|
|
29
|
+
"dependencies": {
|
|
30
|
+
"@modelcontextprotocol/sdk": "^1.0.4",
|
|
31
|
+
"zod": "^3.22.4",
|
|
32
|
+
"dotenv": "^16.4.7"
|
|
33
|
+
},
|
|
34
|
+
"devDependencies": {
|
|
35
|
+
"typescript": "^5.6.0",
|
|
36
|
+
"@types/node": "^20.17.0"
|
|
37
|
+
},
|
|
38
|
+
"engines": {
|
|
39
|
+
"node": ">=18"
|
|
40
|
+
}
|
|
41
|
+
}
|