@mafdet/cli 1.4.29 → 1.5.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/CHANGELOG.md +15 -3
- package/dist/api/models.d.ts +8 -0
- package/dist/api/models.d.ts.map +1 -1
- package/dist/api/models.js +9 -0
- package/dist/commands/models.js +24 -12
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,9 +2,21 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to `@mafdet/cli`.
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
Package versions follow Mafdet AI product releases. JSON output shapes and
|
|
6
|
+
exit codes remain backward compatible within the current major version.
|
|
7
|
+
|
|
8
|
+
## 1.5.0 - 2026-10-29
|
|
9
|
+
|
|
10
|
+
- `models show` displays live sell-price dimensions with their units, including
|
|
11
|
+
audio tokens, image counts and video seconds. Missing non-token prices are no
|
|
12
|
+
longer presented as free.
|
|
13
|
+
- The shared catalog adds seven verified model options and updates GA labels
|
|
14
|
+
and Kimi migration guidance. Existing model IDs remain compatible.
|
|
15
|
+
|
|
16
|
+
## 1.4.40 - 2026-10-25
|
|
17
|
+
|
|
18
|
+
- `mafdet models show` includes the live catalogue description, including Kimi
|
|
19
|
+
K2 migration notices and DeepSeek's server-side Search/Fetch limitation.
|
|
8
20
|
|
|
9
21
|
## 0.4.13 - 2026-08-17
|
|
10
22
|
|
package/dist/api/models.d.ts
CHANGED
|
@@ -1,4 +1,10 @@
|
|
|
1
1
|
import type { HttpClient } from "./http.js";
|
|
2
|
+
export interface PublicPriceDimension {
|
|
3
|
+
dimension: string;
|
|
4
|
+
unit: string;
|
|
5
|
+
unitScale: string;
|
|
6
|
+
sellPriceMicroUsd: string;
|
|
7
|
+
}
|
|
2
8
|
/** What the data plane says: an id this key may call. Metadata is unreliable. */
|
|
3
9
|
export interface DataPlaneModel {
|
|
4
10
|
id: string;
|
|
@@ -7,6 +13,8 @@ export interface DataPlaneModel {
|
|
|
7
13
|
export interface CatalogModel {
|
|
8
14
|
modelId: string;
|
|
9
15
|
displayName?: string;
|
|
16
|
+
priceDimensions?: PublicPriceDimension[];
|
|
17
|
+
description?: string | null;
|
|
10
18
|
provider?: string;
|
|
11
19
|
capabilities?: string[];
|
|
12
20
|
apiSurface?: string;
|
package/dist/api/models.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"models.d.ts","sourceRoot":"","sources":["../../src/api/models.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;
|
|
1
|
+
{"version":3,"file":"models.d.ts","sourceRoot":"","sources":["../../src/api/models.ts"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,WAAW,CAAC;AAW5C,MAAM,WAAW,oBAAoB;IACnC,SAAS,EAAE,MAAM,CAAC;IAClB,IAAI,EAAE,MAAM,CAAC;IACb,SAAS,EAAE,MAAM,CAAC;IAClB,iBAAiB,EAAE,MAAM,CAAC;CAC3B;AAiCD,iFAAiF;AACjF,MAAM,WAAW,cAAc;IAC7B,EAAE,EAAE,MAAM,CAAC;CACZ;AAED,0CAA0C;AAC1C,MAAM,WAAW,YAAY;IAC3B,OAAO,EAAE,MAAM,CAAC;IAChB,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,eAAe,CAAC,EAAE,oBAAoB,EAAE,CAAC;IACzC,WAAW,CAAC,EAAE,MAAM,GAAG,IAAI,CAAC;IAC5B,QAAQ,CAAC,EAAE,MAAM,CAAC;IAClB,YAAY,CAAC,EAAE,MAAM,EAAE,CAAC;IACxB,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,aAAa,CAAC,EAAE,MAAM,CAAC;IACvB,uBAAuB,CAAC,EAAE,MAAM,CAAC;IACjC,wBAAwB,CAAC,EAAE,MAAM,CAAC;IAClC,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,UAAU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ACf,MAAM,EAAE,MAAM,EACd,QAAQ,EAAE,MAAM;CAO5B"}
|
package/dist/api/models.js
CHANGED
|
@@ -9,6 +9,15 @@ const catalogModelSchema = z
|
|
|
9
9
|
.object({
|
|
10
10
|
modelId: z.string().refine(isUsableModelId),
|
|
11
11
|
displayName: z.string().optional(),
|
|
12
|
+
priceDimensions: z
|
|
13
|
+
.array(z.object({
|
|
14
|
+
dimension: z.string(),
|
|
15
|
+
unit: z.string(),
|
|
16
|
+
unitScale: z.string(),
|
|
17
|
+
sellPriceMicroUsd: z.string().regex(/^\d+$/),
|
|
18
|
+
}))
|
|
19
|
+
.optional(),
|
|
20
|
+
description: z.string().nullable().optional(),
|
|
12
21
|
provider: z.string().optional(),
|
|
13
22
|
capabilities: z.array(z.string()).optional(),
|
|
14
23
|
apiSurface: z.string().optional(),
|
package/dist/commands/models.js
CHANGED
|
@@ -144,23 +144,35 @@ function showModel(sets, args, format, io) {
|
|
|
144
144
|
io.stdout(renderRecord([
|
|
145
145
|
["model", clean(model.modelId)],
|
|
146
146
|
["name", clean(model.displayName ?? "-")],
|
|
147
|
+
["description", clean(model.description ?? "-")],
|
|
147
148
|
["provider", clean(model.provider ?? "-")],
|
|
148
149
|
["surface", clean(model.apiSurface ?? "-")],
|
|
149
150
|
["context", String(model.contextLength ?? "-")],
|
|
150
151
|
["capabilities", clean((model.capabilities ?? []).join(", ")) || "-"],
|
|
151
152
|
["agent eligible", model.agentEligible ? "yes" : "no"],
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
153
|
+
...(model.priceDimensions?.length
|
|
154
|
+
? model.priceDimensions.map((price) => [
|
|
155
|
+
clean(price.dimension.toLowerCase().replaceAll("_", " ")),
|
|
156
|
+
`${formatUsd(price.sellPriceMicroUsd)} / ${clean(price.unit)}`,
|
|
157
|
+
])
|
|
158
|
+
: (model.apiSurface ?? "CHAT_COMPLETIONS") === "CHAT_COMPLETIONS"
|
|
159
|
+
? [
|
|
160
|
+
[
|
|
161
|
+
"input / 1M",
|
|
162
|
+
isMicroUsd(model.inputPricePer1mMicroUsd)
|
|
163
|
+
? formatUsd(model.inputPricePer1mMicroUsd)
|
|
164
|
+
: "-",
|
|
165
|
+
],
|
|
166
|
+
[
|
|
167
|
+
"output / 1M",
|
|
168
|
+
isMicroUsd(model.outputPricePer1mMicroUsd)
|
|
169
|
+
? formatUsd(model.outputPricePer1mMicroUsd)
|
|
170
|
+
: "-",
|
|
171
|
+
],
|
|
172
|
+
]
|
|
173
|
+
: [
|
|
174
|
+
["pricing", "Unavailable; see model documentation"],
|
|
175
|
+
]),
|
|
164
176
|
[
|
|
165
177
|
"deprecated",
|
|
166
178
|
model.deprecated
|