ai-model-verifier 3.7.0 → 3.7.1
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.
|
@@ -8,11 +8,13 @@
|
|
|
8
8
|
*/
|
|
9
9
|
/**
|
|
10
10
|
* A strict comparison once condemned an honest upstream and cost it all ten of
|
|
11
|
-
* its Claude models, so this tolerates the
|
|
12
|
-
*
|
|
11
|
+
* its Claude models, so this tolerates the ways vendors legitimately spell the
|
|
12
|
+
* same model:
|
|
13
13
|
* - separator drift claude-opus-4.8 vs claude-opus-4-8
|
|
14
14
|
* - vendor-qualified ids anthropic/claude-opus-5 vs claude-opus-5
|
|
15
15
|
* - dated snapshots claude-haiku-4-5 vs claude-haiku-4-5-20251001
|
|
16
|
+
* - relay route tags [free]deepseek-v4.1-flash vs deepseek-ai/deepseek-v4.1-flash
|
|
17
|
+
* - Kimi without its k kimi-k2.7-code vs kimi-2.7 (seven a7 lanes echo it)
|
|
16
18
|
*/
|
|
17
19
|
export declare function modelsMatch(requested: string, served: string): boolean;
|
|
18
20
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"substitution.d.ts","sourceRoot":"","sources":["../../src/models/substitution.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH
|
|
1
|
+
{"version":3,"file":"substitution.d.ts","sourceRoot":"","sources":["../../src/models/substitution.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH;;;;;;;;;GASG;AACH,wBAAgB,WAAW,CAAC,SAAS,EAAE,MAAM,EAAE,MAAM,EAAE,MAAM,GAAG,OAAO,CActE;AAED;;;GAGG;AACH,wBAAgB,kBAAkB,CAChC,SAAS,EAAE,MAAM,EACjB,aAAa,EAAE,MAAM,GAAG,IAAI,GAAG,SAAS,GACvC,MAAM,GAAG,IAAI,CAGf"}
|
|
@@ -8,14 +8,21 @@
|
|
|
8
8
|
*/
|
|
9
9
|
/**
|
|
10
10
|
* A strict comparison once condemned an honest upstream and cost it all ten of
|
|
11
|
-
* its Claude models, so this tolerates the
|
|
12
|
-
*
|
|
11
|
+
* its Claude models, so this tolerates the ways vendors legitimately spell the
|
|
12
|
+
* same model:
|
|
13
13
|
* - separator drift claude-opus-4.8 vs claude-opus-4-8
|
|
14
14
|
* - vendor-qualified ids anthropic/claude-opus-5 vs claude-opus-5
|
|
15
15
|
* - dated snapshots claude-haiku-4-5 vs claude-haiku-4-5-20251001
|
|
16
|
+
* - relay route tags [free]deepseek-v4.1-flash vs deepseek-ai/deepseek-v4.1-flash
|
|
17
|
+
* - Kimi without its k kimi-k2.7-code vs kimi-2.7 (seven a7 lanes echo it)
|
|
16
18
|
*/
|
|
17
19
|
export function modelsMatch(requested, served) {
|
|
18
|
-
const norm = (s) => s
|
|
20
|
+
const norm = (s) => (s
|
|
21
|
+
.toLowerCase()
|
|
22
|
+
.replace(/^\[[^\]]*\]\s*/, "")
|
|
23
|
+
.replace(/[._]/g, "-")
|
|
24
|
+
.split("/")
|
|
25
|
+
.pop() ?? "").replace(/^kimi-k(?=\d)/, "kimi-");
|
|
19
26
|
const a = norm(requested);
|
|
20
27
|
const b = norm(served);
|
|
21
28
|
if (!a || !b)
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"substitution.js","sourceRoot":"","sources":["../../src/models/substitution.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH
|
|
1
|
+
{"version":3,"file":"substitution.js","sourceRoot":"","sources":["../../src/models/substitution.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAEH;;;;;;;;;GASG;AACH,MAAM,UAAU,WAAW,CAAC,SAAiB,EAAE,MAAc;IAC3D,MAAM,IAAI,GAAG,CAAC,CAAS,EAAE,EAAE,CACzB,CACE,CAAC;SACE,WAAW,EAAE;SACb,OAAO,CAAC,gBAAgB,EAAE,EAAE,CAAC;SAC7B,OAAO,CAAC,OAAO,EAAE,GAAG,CAAC;SACrB,KAAK,CAAC,GAAG,CAAC;SACV,GAAG,EAAE,IAAI,EAAE,CACf,CAAC,OAAO,CAAC,eAAe,EAAE,OAAO,CAAC,CAAC;IACtC,MAAM,CAAC,GAAG,IAAI,CAAC,SAAS,CAAC,CAAC;IAC1B,MAAM,CAAC,GAAG,IAAI,CAAC,MAAM,CAAC,CAAC;IACvB,IAAI,CAAC,CAAC,IAAI,CAAC,CAAC;QAAE,OAAO,IAAI,CAAC;IAC1B,OAAO,CAAC,KAAK,CAAC,IAAI,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,UAAU,CAAC,CAAC,CAAC,CAAC;AACvD,CAAC;AAED;;;GAGG;AACH,MAAM,UAAU,kBAAkB,CAChC,SAAiB,EACjB,aAAwC;IAExC,IAAI,CAAC,aAAa;QAAE,OAAO,IAAI,CAAC;IAChC,OAAO,WAAW,CAAC,SAAS,EAAE,aAAa,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,CAAC,aAAa,CAAC;AACtE,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "ai-model-verifier",
|
|
3
|
-
"version": "3.7.
|
|
3
|
+
"version": "3.7.1",
|
|
4
4
|
"description": "Verify an AI API endpoint really serves the model it claims: a vendor adapter per wire, a maker table for who trained what, a rule table over shared evidence, and per model facts. Model substitution, Claude thinking signatures, token billing accuracy, envelope and throughput evidence.",
|
|
5
5
|
"license": "AGPL-3.0-only",
|
|
6
6
|
"type": "module",
|