crosscheck-mcp 0.2.23 → 0.2.24
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/dist/browser-ext.cjs +17 -6
- package/dist/browser-ext.cjs.map +1 -1
- package/dist/browser-ext.js +17 -6
- package/dist/browser-ext.js.map +1 -1
- package/dist/node-stdio.cjs +17 -6
- package/dist/node-stdio.cjs.map +1 -1
- package/dist/node-stdio.js +17 -6
- package/dist/node-stdio.js.map +1 -1
- package/package.json +1 -1
package/dist/node-stdio.cjs
CHANGED
|
@@ -1306,7 +1306,7 @@ init_cjs_shims();
|
|
|
1306
1306
|
var CREDIT_RE = /insufficient|no\s+credit|credits?|billing|quota|payment\s*required|exceeded your current quota|not\s+enough|fund|no active subscription|spend limit/i;
|
|
1307
1307
|
function isCreditsFailure(status, bodyText) {
|
|
1308
1308
|
if (status === 402) return true;
|
|
1309
|
-
if (status === 401 || status === 403 || status ===
|
|
1309
|
+
if (status === 401 || status === 403 || status === 400) {
|
|
1310
1310
|
return CREDIT_RE.test(bodyText);
|
|
1311
1311
|
}
|
|
1312
1312
|
return false;
|
|
@@ -1343,7 +1343,7 @@ function httpFailureToProviderError(provider, status, bodyText, retryAfterS, mod
|
|
|
1343
1343
|
if (status === 429) {
|
|
1344
1344
|
return new ProviderError(
|
|
1345
1345
|
"rate_limit",
|
|
1346
|
-
`${provider}: rate limited (HTTP 429). Detail: ${detail}`,
|
|
1346
|
+
`${provider}: rate limited (HTTP 429) \u2014 retrying with backoff. Note that some providers word a rate limit as a balance problem; check your balance before topping up. Detail: ${detail}`,
|
|
1347
1347
|
{ status, ...retryAfterS !== void 0 ? { retryAfterS } : {} }
|
|
1348
1348
|
);
|
|
1349
1349
|
}
|
|
@@ -2133,10 +2133,20 @@ function fallbackModelsFor(env, provider) {
|
|
|
2133
2133
|
if (pinned && pinned !== DEFAULT_MODELS[provider]) return [];
|
|
2134
2134
|
return DEFAULT_FALLBACKS[provider] ?? [];
|
|
2135
2135
|
}
|
|
2136
|
+
var DEFAULT_EXCLUDED_PROVIDERS = ["mistral", "groq"];
|
|
2137
|
+
function excludedProviders(env) {
|
|
2138
|
+
const parse = (v) => (v ?? "").split(",").map((x) => x.trim().toLowerCase()).filter((x) => x !== "");
|
|
2139
|
+
const excluded = new Set(
|
|
2140
|
+
parse(env["CROSSCHECK_EXCLUDE_PROVIDERS"]).length > 0 ? parse(env["CROSSCHECK_EXCLUDE_PROVIDERS"]) : DEFAULT_EXCLUDED_PROVIDERS
|
|
2141
|
+
);
|
|
2142
|
+
for (const name of parse(env["CROSSCHECK_ENABLE_PROVIDERS"])) excluded.delete(name);
|
|
2143
|
+
return excluded;
|
|
2144
|
+
}
|
|
2136
2145
|
function buildProviders(opts) {
|
|
2137
2146
|
const out = {};
|
|
2147
|
+
const excluded = excludedProviders(opts.env);
|
|
2138
2148
|
const anthropicKey = opts.env["ANTHROPIC_API_KEY"];
|
|
2139
|
-
if (anthropicKey) {
|
|
2149
|
+
if (anthropicKey && !excluded.has("anthropic")) {
|
|
2140
2150
|
const model = opts.env["ANTHROPIC_MODEL"] ?? DEFAULT_MODELS.anthropic;
|
|
2141
2151
|
out["anthropic"] = makeAnthropicProvider(model, anthropicKey, opts, fallbackModelsFor(opts.env, "anthropic"));
|
|
2142
2152
|
}
|
|
@@ -2152,11 +2162,12 @@ function buildProviders(opts) {
|
|
|
2152
2162
|
for (const s of openAiCompatSpec) {
|
|
2153
2163
|
const apiKey = opts.env[s.keyEnv];
|
|
2154
2164
|
if (!apiKey) continue;
|
|
2165
|
+
if (excluded.has(s.name)) continue;
|
|
2155
2166
|
const model = opts.env[s.modelEnv] ?? s.defaultModel;
|
|
2156
2167
|
out[s.name] = makeOpenAICompatibleProvider(s.name, model, apiKey, opts, fallbackModelsFor(opts.env, s.name));
|
|
2157
2168
|
}
|
|
2158
2169
|
const geminiKey = opts.env["GEMINI_API_KEY"];
|
|
2159
|
-
if (geminiKey) {
|
|
2170
|
+
if (geminiKey && !excluded.has("gemini")) {
|
|
2160
2171
|
const model = opts.env["GEMINI_MODEL"] ?? DEFAULT_MODELS.gemini;
|
|
2161
2172
|
out["gemini"] = makeGeminiProvider(model, geminiKey, opts, fallbackModelsFor(opts.env, "gemini"));
|
|
2162
2173
|
}
|
|
@@ -2352,7 +2363,7 @@ var import_zod = require("zod");
|
|
|
2352
2363
|
// src/server-meta.ts
|
|
2353
2364
|
init_cjs_shims();
|
|
2354
2365
|
var SERVER_NAME = "crosscheck-agent";
|
|
2355
|
-
var SERVER_VERSION = true ? "0.2.
|
|
2366
|
+
var SERVER_VERSION = true ? "0.2.24" : "0.0.0-dev";
|
|
2356
2367
|
|
|
2357
2368
|
// src/tools/audit.ts
|
|
2358
2369
|
init_cjs_shims();
|
|
@@ -12914,7 +12925,7 @@ var CHECK_INTERVAL_SECONDS = 3 * 24 * 60 * 60;
|
|
|
12914
12925
|
var DEFAULT_PACKAGE = "crosscheck-cli";
|
|
12915
12926
|
var FETCH_TIMEOUT_MS = 3e3;
|
|
12916
12927
|
function engineVersion() {
|
|
12917
|
-
return true ? "0.2.
|
|
12928
|
+
return true ? "0.2.24" : "0.0.0-dev";
|
|
12918
12929
|
}
|
|
12919
12930
|
function defaultUpdateCachePath() {
|
|
12920
12931
|
const base = process.env["CROSSCHECK_DATA_DIR"] || import_node_path13.default.join(import_node_os2.default.homedir() || import_node_os2.default.tmpdir(), ".crosscheck");
|