@shop-os/modelkit 0.3.3 → 0.3.5
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 +19 -0
- package/dist/catalog.cjs +69 -8
- package/dist/catalog.cjs.map +1 -1
- package/dist/catalog.d.cts +10 -1
- package/dist/catalog.d.ts +10 -1
- package/dist/catalog.js +69 -8
- package/dist/catalog.js.map +1 -1
- package/dist/index.cjs +80 -11
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +10 -1
- package/dist/index.d.ts +10 -1
- package/dist/index.js +80 -11
- package/dist/index.js.map +1 -1
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -9,6 +9,25 @@ header in the release PR.
|
|
|
9
9
|
|
|
10
10
|
## [Unreleased]
|
|
11
11
|
|
|
12
|
+
## [0.3.5] - Unreleased
|
|
13
|
+
|
|
14
|
+
### Fixed
|
|
15
|
+
- `dataOnlyCapable` reports a `video-tool` row as servable when its adapter has `submitVideoTool` (fal). It tested such a row against the adapter's text surface, so it answered "fal cannot serve video-tool rows" and pro-backend refused every admin save of a listed video-tool row.
|
|
16
|
+
|
|
17
|
+
## [0.3.4] - Unreleased
|
|
18
|
+
|
|
19
|
+
### Added
|
|
20
|
+
- Snapshot rows `flux-video-upscale-precise` and `flux-video-upscale-creative` (fal `blackforestlabs/flux-video-upscale`, `type: "video-tool"`, upscale 1.5x to 3x, 4K long-edge limit, 20-second source), listed on `space_builder`. They share one endpoint and differ only in fal's `creativity` mode, which fal prices differently, so pricing keys them as two models.
|
|
21
|
+
- `constraints.tool.prompt` on upscale rows and `VideoToolRequest.prompt`: a row that sets it sends a trimmed, non-empty prompt to the provider. Other rows ignore the prompt.
|
|
22
|
+
- `providerOptions.fal.input` on video-tool rows: fixed body fields sent on every call. The source, factor and prompt are set after them, so a row cannot replace those.
|
|
23
|
+
|
|
24
|
+
### Changed
|
|
25
|
+
- `topaz-precision` and `topaz-starlight` are also listed on `space_builder`.
|
|
26
|
+
- An upscale row with no Topaz model name (`providerOptions.fal.model`) no longer gets `model` or `H264_output` in its body. Both Topaz upscale rows name a model, so their bodies are unchanged.
|
|
27
|
+
|
|
28
|
+
### Live rows to add after publish
|
|
29
|
+
Add the two FLUX rows, and add `space_builder` to the live Topaz Precision and Starlight rows, only after every app that calls them runs 0.3.4. An older kit sends `H264_output`, drops `creativity`, and so runs the precise row in creative mode.
|
|
30
|
+
|
|
12
31
|
## [0.3.3] - Unreleased
|
|
13
32
|
|
|
14
33
|
### Added
|
package/dist/catalog.cjs
CHANGED
|
@@ -2066,8 +2066,16 @@ var VIDEO_MODELS = [
|
|
|
2066
2066
|
|
|
2067
2067
|
// src/catalog/video-tools.ts
|
|
2068
2068
|
var TOPAZ_LOGO = "https://cdn.jsdelivr.net/npm/@lobehub/icons-static-png@1.97.0/light/topazlabs.png";
|
|
2069
|
+
var FLUX_LOGO = "https://cdn.jsdelivr.net/npm/@lobehub/icons-static-png@1.97.0/light/flux.png";
|
|
2069
2070
|
var TOPAZ_SOURCE_SECONDS = { max: 300 };
|
|
2070
|
-
var
|
|
2071
|
+
var SECONDS_USAGE = { unit: "seconds" };
|
|
2072
|
+
var FLUX_SOURCE_SECONDS = { max: 20 };
|
|
2073
|
+
var FLUX_UPSCALE_TOOL = {
|
|
2074
|
+
kind: "upscale",
|
|
2075
|
+
upscaleFactor: { min: 1.5, max: 3 },
|
|
2076
|
+
maxOutputLongEdge: 3840,
|
|
2077
|
+
prompt: true
|
|
2078
|
+
};
|
|
2071
2079
|
var VIDEO_TOOL_MODELS = [
|
|
2072
2080
|
{
|
|
2073
2081
|
id: "topaz-precision",
|
|
@@ -2077,7 +2085,7 @@ var VIDEO_TOOL_MODELS = [
|
|
|
2077
2085
|
adapter: "fal",
|
|
2078
2086
|
providerModelId: "topaz/upscale/video/precision",
|
|
2079
2087
|
lifecycle: "active",
|
|
2080
|
-
exposure: ["cowork"],
|
|
2088
|
+
exposure: ["cowork", "space_builder"],
|
|
2081
2089
|
constraints: {
|
|
2082
2090
|
supports: [],
|
|
2083
2091
|
sourceVideoSeconds: TOPAZ_SOURCE_SECONDS,
|
|
@@ -2085,7 +2093,7 @@ var VIDEO_TOOL_MODELS = [
|
|
|
2085
2093
|
},
|
|
2086
2094
|
defaults: {},
|
|
2087
2095
|
providerOptions: { fal: { model: "Proteus" } },
|
|
2088
|
-
usage:
|
|
2096
|
+
usage: SECONDS_USAGE,
|
|
2089
2097
|
pricingKind: "video_per_second",
|
|
2090
2098
|
display: {
|
|
2091
2099
|
provider: "topaz",
|
|
@@ -2102,7 +2110,7 @@ var VIDEO_TOOL_MODELS = [
|
|
|
2102
2110
|
adapter: "fal",
|
|
2103
2111
|
providerModelId: "topaz/upscale/video/generative",
|
|
2104
2112
|
lifecycle: "active",
|
|
2105
|
-
exposure: ["cowork"],
|
|
2113
|
+
exposure: ["cowork", "space_builder"],
|
|
2106
2114
|
constraints: {
|
|
2107
2115
|
supports: [],
|
|
2108
2116
|
sourceVideoSeconds: TOPAZ_SOURCE_SECONDS,
|
|
@@ -2110,7 +2118,7 @@ var VIDEO_TOOL_MODELS = [
|
|
|
2110
2118
|
},
|
|
2111
2119
|
defaults: {},
|
|
2112
2120
|
providerOptions: { fal: { model: "Starlight Precise 2.6" } },
|
|
2113
|
-
usage:
|
|
2121
|
+
usage: SECONDS_USAGE,
|
|
2114
2122
|
pricingKind: "video_per_second",
|
|
2115
2123
|
display: {
|
|
2116
2124
|
provider: "topaz",
|
|
@@ -2135,7 +2143,7 @@ var VIDEO_TOOL_MODELS = [
|
|
|
2135
2143
|
},
|
|
2136
2144
|
defaults: {},
|
|
2137
2145
|
providerOptions: { fal: { model: "Apollo" } },
|
|
2138
|
-
usage:
|
|
2146
|
+
usage: SECONDS_USAGE,
|
|
2139
2147
|
pricingKind: "video_per_second",
|
|
2140
2148
|
display: {
|
|
2141
2149
|
provider: "topaz",
|
|
@@ -2158,13 +2166,63 @@ var VIDEO_TOOL_MODELS = [
|
|
|
2158
2166
|
tool: { kind: "hdr", outputFormats: ["h265", "prores"] }
|
|
2159
2167
|
},
|
|
2160
2168
|
defaults: {},
|
|
2161
|
-
usage:
|
|
2169
|
+
usage: SECONDS_USAGE,
|
|
2162
2170
|
pricingKind: "video_per_second",
|
|
2163
2171
|
display: {
|
|
2164
2172
|
provider: "topaz",
|
|
2165
2173
|
logo: TOPAZ_LOGO,
|
|
2166
2174
|
description: "Topaz Hyperion 2.5 SDR to HDR: a 10-bit HDR master in H.265 (HDR10) or ProRes 422 HQ, at the source's size and frame rate."
|
|
2167
2175
|
}
|
|
2176
|
+
},
|
|
2177
|
+
{
|
|
2178
|
+
id: "flux-video-upscale-precise",
|
|
2179
|
+
aliases: [],
|
|
2180
|
+
label: "FLUX Upscale Precise",
|
|
2181
|
+
type: "video-tool",
|
|
2182
|
+
adapter: "fal",
|
|
2183
|
+
providerModelId: "blackforestlabs/flux-video-upscale",
|
|
2184
|
+
lifecycle: "active",
|
|
2185
|
+
exposure: ["space_builder"],
|
|
2186
|
+
constraints: {
|
|
2187
|
+
supports: [],
|
|
2188
|
+
sourceVideoSeconds: FLUX_SOURCE_SECONDS,
|
|
2189
|
+
tool: FLUX_UPSCALE_TOOL
|
|
2190
|
+
},
|
|
2191
|
+
defaults: {},
|
|
2192
|
+
providerOptions: { fal: { input: { creativity: 0 } } },
|
|
2193
|
+
usage: SECONDS_USAGE,
|
|
2194
|
+
pricingKind: "video_per_second",
|
|
2195
|
+
display: {
|
|
2196
|
+
provider: "black-forest-labs",
|
|
2197
|
+
logo: FLUX_LOGO,
|
|
2198
|
+
description: "FLUX 3 super-resolution, source-faithful: 1.5x to 3x, up to 4K, for clips up to 20 seconds.",
|
|
2199
|
+
sortOrder: 30
|
|
2200
|
+
}
|
|
2201
|
+
},
|
|
2202
|
+
{
|
|
2203
|
+
id: "flux-video-upscale-creative",
|
|
2204
|
+
aliases: [],
|
|
2205
|
+
label: "FLUX Upscale Creative",
|
|
2206
|
+
type: "video-tool",
|
|
2207
|
+
adapter: "fal",
|
|
2208
|
+
providerModelId: "blackforestlabs/flux-video-upscale",
|
|
2209
|
+
lifecycle: "active",
|
|
2210
|
+
exposure: ["space_builder"],
|
|
2211
|
+
constraints: {
|
|
2212
|
+
supports: [],
|
|
2213
|
+
sourceVideoSeconds: FLUX_SOURCE_SECONDS,
|
|
2214
|
+
tool: FLUX_UPSCALE_TOOL
|
|
2215
|
+
},
|
|
2216
|
+
defaults: {},
|
|
2217
|
+
providerOptions: { fal: { input: { creativity: 1 } } },
|
|
2218
|
+
usage: SECONDS_USAGE,
|
|
2219
|
+
pricingKind: "video_per_second",
|
|
2220
|
+
display: {
|
|
2221
|
+
provider: "black-forest-labs",
|
|
2222
|
+
logo: FLUX_LOGO,
|
|
2223
|
+
description: "FLUX 3 super-resolution that adds fine detail, optionally guided by a prompt: 1.5x to 3x, up to 4K, for clips up to 20 seconds. Costs more than Precise.",
|
|
2224
|
+
sortOrder: 40
|
|
2225
|
+
}
|
|
2168
2226
|
}
|
|
2169
2227
|
];
|
|
2170
2228
|
|
|
@@ -2671,6 +2729,7 @@ var VideoToolConstraintsSchema = import_zod3.z.looseObject({
|
|
|
2671
2729
|
kind: import_zod3.z.enum(["upscale", "interpolate", "hdr"]),
|
|
2672
2730
|
upscaleFactor: RangeSchema.optional(),
|
|
2673
2731
|
maxOutputLongEdge: import_zod3.z.number().positive().optional(),
|
|
2732
|
+
prompt: import_zod3.z.boolean().optional(),
|
|
2674
2733
|
fps: RangeSchema.optional(),
|
|
2675
2734
|
outputFormats: import_zod3.z.array(import_zod3.z.enum(["h265", "prores"])).min(1).optional()
|
|
2676
2735
|
});
|
|
@@ -3129,6 +3188,7 @@ var ToolSchema = import_zod6.z.object({
|
|
|
3129
3188
|
kind: import_zod6.z.enum(["upscale", "interpolate", "hdr"]),
|
|
3130
3189
|
upscaleFactor: RangeSchema2.optional(),
|
|
3131
3190
|
maxOutputLongEdge: import_zod6.z.number().positive().optional(),
|
|
3191
|
+
prompt: import_zod6.z.boolean().optional(),
|
|
3132
3192
|
fps: RangeSchema2.optional(),
|
|
3133
3193
|
outputFormats: import_zod6.z.array(import_zod6.z.enum(["h265", "prores"])).min(1).optional()
|
|
3134
3194
|
});
|
|
@@ -3136,11 +3196,12 @@ function videoToolConstraints(row) {
|
|
|
3136
3196
|
if (row.type !== "video-tool") return void 0;
|
|
3137
3197
|
const parsed = ToolSchema.safeParse(row.constraints.tool);
|
|
3138
3198
|
if (!parsed.success) return void 0;
|
|
3139
|
-
const { kind, upscaleFactor, maxOutputLongEdge, fps, outputFormats } = parsed.data;
|
|
3199
|
+
const { kind, upscaleFactor, maxOutputLongEdge, prompt, fps, outputFormats } = parsed.data;
|
|
3140
3200
|
return {
|
|
3141
3201
|
kind,
|
|
3142
3202
|
...upscaleFactor !== void 0 && { upscaleFactor },
|
|
3143
3203
|
...maxOutputLongEdge !== void 0 && { maxOutputLongEdge },
|
|
3204
|
+
...prompt !== void 0 && { prompt },
|
|
3144
3205
|
...fps !== void 0 && { fps },
|
|
3145
3206
|
...outputFormats !== void 0 && { outputFormats }
|
|
3146
3207
|
};
|