Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 86077f0

Browse files
authored
fix: comment out skyfire input schema modification (#296)
1 parent 4d1ff67 commit 86077f0

File tree

1 file changed

+22
-24
lines changed

1 file changed

+22
-24
lines changed

src/mcp/server.ts

Lines changed: 22 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -26,10 +26,8 @@ import log from '@apify/log';
2626

2727
import { ApifyClient } from '../apify-client.js';
2828
import {
29-
HelperTools,
3029
SERVER_NAME,
3130
SERVER_VERSION,
32-
SKYFIRE_PAY_ID_PROPERTY_DESCRIPTION,
3331
SKYFIRE_README_CONTENT,
3432
SKYFIRE_TOOL_INSTRUCTIONS,
3533
} from '../const.js';
@@ -263,28 +261,28 @@ export class ActorsMcpServer {
263261
this.tools.set(wrap.tool.name, wrap);
264262
}
265263
// Handle Skyfire mode modifications once per tool upsert
266-
if (this.options.skyfireMode) {
267-
for (const wrap of tools) {
268-
if (wrap.type === 'actor'
269-
|| (wrap.type === 'internal' && wrap.tool.name === HelperTools.ACTOR_CALL)
270-
|| (wrap.type === 'internal' && wrap.tool.name === HelperTools.ACTOR_OUTPUT_GET)) {
271-
// Add Skyfire instructions to description if not already present
272-
if (!wrap.tool.description.includes(SKYFIRE_TOOL_INSTRUCTIONS)) {
273-
wrap.tool.description += `\n\n${SKYFIRE_TOOL_INSTRUCTIONS}`;
274-
}
275-
// Add skyfire-pay-id property if not present
276-
if (wrap.tool.inputSchema && 'properties' in wrap.tool.inputSchema) {
277-
const props = wrap.tool.inputSchema.properties as Record<string, unknown>;
278-
if (!props['skyfire-pay-id']) {
279-
props['skyfire-pay-id'] = {
280-
type: 'string',
281-
description: SKYFIRE_PAY_ID_PROPERTY_DESCRIPTION,
282-
};
283-
}
284-
}
285-
}
286-
}
287-
}
264+
// if (this.options.skyfireMode) {
265+
// for (const wrap of tools) {
266+
// if (wrap.type === 'actor'
267+
// || (wrap.type === 'internal' && wrap.tool.name === HelperTools.ACTOR_CALL)
268+
// || (wrap.type === 'internal' && wrap.tool.name === HelperTools.ACTOR_OUTPUT_GET)) {
269+
// // Add Skyfire instructions to description if not already present
270+
// if (!wrap.tool.description.includes(SKYFIRE_TOOL_INSTRUCTIONS)) {
271+
// wrap.tool.description += `\n\n${SKYFIRE_TOOL_INSTRUCTIONS}`;
272+
// }
273+
// // Add skyfire-pay-id property if not present
274+
// if (wrap.tool.inputSchema && 'properties' in wrap.tool.inputSchema) {
275+
// const props = wrap.tool.inputSchema.properties as Record<string, unknown>;
276+
// if (!props['skyfire-pay-id']) {
277+
// props['skyfire-pay-id'] = {
278+
// type: 'string',
279+
// description: SKYFIRE_PAY_ID_PROPERTY_DESCRIPTION,
280+
// };
281+
// }
282+
// }
283+
// }
284+
// }
285+
// }
288286
if (shouldNotifyToolsChangedHandler) this.notifyToolsChangedHandler();
289287
return tools;
290288
}

0 commit comments

Comments
 (0)