@context-engine-bridge/context-engine-mcp-bridge 0.0.62 → 0.0.64
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/package.json +1 -1
- package/src/mcpServer.js +8 -1
package/package.json
CHANGED
package/src/mcpServer.js
CHANGED
|
@@ -1293,7 +1293,7 @@ async function createBridgeServer(options) {
|
|
|
1293
1293
|
const fanOutCallTimeoutMs = Math.min(timeoutMs, 10000);
|
|
1294
1294
|
const fanOutDeadlineMs = Math.round(fanOutCallTimeoutMs * 0.8);
|
|
1295
1295
|
const fanOutPromises = additionalCollections.map(col => {
|
|
1296
|
-
const colArgs = { ...args, collection: col };
|
|
1296
|
+
const colArgs = { ...args, collection: col, output_format: "json", compact: false };
|
|
1297
1297
|
return targetClient.callTool(
|
|
1298
1298
|
{ name, arguments: colArgs },
|
|
1299
1299
|
undefined,
|
|
@@ -1936,12 +1936,19 @@ function _mergeResults(primaryText, additionalTexts) {
|
|
|
1936
1936
|
}
|
|
1937
1937
|
|
|
1938
1938
|
primary._cross_collection = true;
|
|
1939
|
+
const _aFirst = additionalTexts.length > 0 ? (() => { try { const a = JSON.parse(additionalTexts[0]); const ai = _unwrapSearchEnvelope(a); return { keys: Object.keys(ai), results_type: typeof ai.results, results_json_type: typeof ai.results_json, results_is_array: Array.isArray(ai.results), results_json_is_array: Array.isArray(ai.results_json) }; } catch(_) { return "parse_error"; } })() : null;
|
|
1939
1940
|
primary._fanout_debug = {
|
|
1940
1941
|
additional_texts_count: additionalTexts.length,
|
|
1941
1942
|
additional_ok_count: additionalTexts.filter(t => { try { return JSON.parse(t).ok; } catch(_) { return false; } }).length,
|
|
1942
1943
|
final_results_count: Array.isArray(resultsArr) ? resultsArr.length : 0,
|
|
1943
1944
|
original_limit: originalLimit || null,
|
|
1944
1945
|
envelope: pInner !== primary,
|
|
1946
|
+
p_inner_keys: Object.keys(pInner),
|
|
1947
|
+
p_results_type: typeof pInner.results,
|
|
1948
|
+
p_results_json_type: typeof pInner.results_json,
|
|
1949
|
+
p_results_is_array: Array.isArray(pInner.results),
|
|
1950
|
+
p_results_json_is_array: Array.isArray(pInner.results_json),
|
|
1951
|
+
a_first: _aFirst,
|
|
1945
1952
|
};
|
|
1946
1953
|
return JSON.stringify(primary);
|
|
1947
1954
|
} catch (_) {
|