@koda-sl/baker-cli 0.192.4 → 0.193.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/README.md +19 -0
- package/dist/{chunk-ISZWNERZ.js → chunk-O5GXFPWC.js} +190 -159
- package/dist/chunk-O5GXFPWC.js.map +1 -0
- package/dist/cli.js +430 -207
- package/dist/cli.js.map +1 -1
- package/dist/engine/index.js +1 -1
- package/package.json +1 -1
- package/dist/chunk-ISZWNERZ.js.map +0 -1
package/dist/cli.js
CHANGED
|
@@ -47,7 +47,7 @@ import {
|
|
|
47
47
|
toModelSafeImage,
|
|
48
48
|
ulid,
|
|
49
49
|
validateCanvasDeep
|
|
50
|
-
} from "./chunk-
|
|
50
|
+
} from "./chunk-O5GXFPWC.js";
|
|
51
51
|
import {
|
|
52
52
|
csvOrJson,
|
|
53
53
|
daysAgoIso,
|
|
@@ -90,7 +90,7 @@ import {
|
|
|
90
90
|
} from "./chunk-YL3HDEIJ.js";
|
|
91
91
|
|
|
92
92
|
// src/cli.ts
|
|
93
|
-
import { defineCommand as
|
|
93
|
+
import { defineCommand as defineCommand210, runMain } from "citty";
|
|
94
94
|
|
|
95
95
|
// src/commands/actions/index.ts
|
|
96
96
|
import { defineCommand as defineCommand18 } from "citty";
|
|
@@ -172,9 +172,9 @@ function compactImage(image) {
|
|
|
172
172
|
};
|
|
173
173
|
}
|
|
174
174
|
function fullImage(image) {
|
|
175
|
-
const
|
|
175
|
+
const compact2 = compactImage(image);
|
|
176
176
|
return {
|
|
177
|
-
...
|
|
177
|
+
...compact2,
|
|
178
178
|
width: image.width ?? null,
|
|
179
179
|
height: image.height ?? null,
|
|
180
180
|
aspectRatio: formatAspectRatio(image.aspectRatio),
|
|
@@ -248,9 +248,9 @@ function sceneLines(value) {
|
|
|
248
248
|
});
|
|
249
249
|
}
|
|
250
250
|
function fullVideo(video) {
|
|
251
|
-
const
|
|
251
|
+
const compact2 = compactVideo(video);
|
|
252
252
|
return {
|
|
253
|
-
...
|
|
253
|
+
...compact2,
|
|
254
254
|
duration: video.duration ?? null,
|
|
255
255
|
muxPlaybackId: String(video.muxPlaybackId ?? ""),
|
|
256
256
|
source: String(video.source ?? ""),
|
|
@@ -291,9 +291,9 @@ function compactTestimonial(record) {
|
|
|
291
291
|
};
|
|
292
292
|
}
|
|
293
293
|
function fullTestimonial(record) {
|
|
294
|
-
const
|
|
294
|
+
const compact2 = compactTestimonial(record);
|
|
295
295
|
return {
|
|
296
|
-
...
|
|
296
|
+
...compact2,
|
|
297
297
|
reviewText: String(record.reviewText ?? ""),
|
|
298
298
|
highlight: record.highlight ?? null,
|
|
299
299
|
summary: record.summary ?? null,
|
|
@@ -335,10 +335,10 @@ function compactWinningAd(record) {
|
|
|
335
335
|
};
|
|
336
336
|
}
|
|
337
337
|
function fullWinningAd(record) {
|
|
338
|
-
const
|
|
338
|
+
const compact2 = compactWinningAd(record);
|
|
339
339
|
const dna = asRecord(record.dna);
|
|
340
340
|
return {
|
|
341
|
-
...
|
|
341
|
+
...compact2,
|
|
342
342
|
winner_category: String(record.winner_category ?? ""),
|
|
343
343
|
media_kind: record.media_kind ?? null,
|
|
344
344
|
days_active: record.days_active ?? null,
|
|
@@ -4853,7 +4853,8 @@ var imageSourceSchema = z14.enum([
|
|
|
4853
4853
|
"iconify",
|
|
4854
4854
|
"giphy",
|
|
4855
4855
|
"pinterest",
|
|
4856
|
-
"ai_generated"
|
|
4856
|
+
"ai_generated",
|
|
4857
|
+
"layer_edit"
|
|
4857
4858
|
]);
|
|
4858
4859
|
var imageStatusSchema = z14.enum(["uploading", "processing", "ready", "error"]);
|
|
4859
4860
|
var upscaleConfigSchema = z14.object({
|
|
@@ -5152,6 +5153,51 @@ var imagesIngestResponseSchema = z14.object({
|
|
|
5152
5153
|
deduped: z14.boolean(),
|
|
5153
5154
|
contentHash: z14.string()
|
|
5154
5155
|
});
|
|
5156
|
+
var imagesLayerizeRequestSchema = z14.object({
|
|
5157
|
+
imageId: z14.string().min(1, "Missing image ID"),
|
|
5158
|
+
/** Optional steer for what to separate; the model reads it as extraction instructions. */
|
|
5159
|
+
instructions: z14.string().max(600).optional()
|
|
5160
|
+
});
|
|
5161
|
+
var imageLayerTextSchema = z14.object({
|
|
5162
|
+
content: z14.string(),
|
|
5163
|
+
fontFamily: z14.string(),
|
|
5164
|
+
fontSize: z14.number(),
|
|
5165
|
+
fontWeight: z14.number(),
|
|
5166
|
+
color: z14.string(),
|
|
5167
|
+
align: z14.enum(["left", "center", "right"]),
|
|
5168
|
+
lineHeight: z14.number(),
|
|
5169
|
+
letterSpacing: z14.number()
|
|
5170
|
+
});
|
|
5171
|
+
var imageLayerSchema = z14.object({
|
|
5172
|
+
id: z14.string(),
|
|
5173
|
+
/** `art` is a transparent cutout; `text` is live copy with its typography. */
|
|
5174
|
+
kind: z14.enum(["art", "text"]),
|
|
5175
|
+
name: z14.string(),
|
|
5176
|
+
/** Art layers only: a permanent URL for the cutout, usable as a canvas input. */
|
|
5177
|
+
url: z14.string().optional(),
|
|
5178
|
+
x: z14.number(),
|
|
5179
|
+
y: z14.number(),
|
|
5180
|
+
width: z14.number(),
|
|
5181
|
+
height: z14.number(),
|
|
5182
|
+
visible: z14.boolean(),
|
|
5183
|
+
opacity: z14.number(),
|
|
5184
|
+
text: imageLayerTextSchema.optional()
|
|
5185
|
+
});
|
|
5186
|
+
var imagesLayersResponseSchema = z14.object({
|
|
5187
|
+
layeredImageId: z14.string(),
|
|
5188
|
+
imageId: z14.string(),
|
|
5189
|
+
status: z14.enum(["splitting", "ready", "failed"]),
|
|
5190
|
+
/** Product-language reason when `failed`; never a raw provider payload. */
|
|
5191
|
+
error: z14.string().optional(),
|
|
5192
|
+
/** The canvas the layers are measured in. The model may resize the source. */
|
|
5193
|
+
width: z14.number(),
|
|
5194
|
+
height: z14.number(),
|
|
5195
|
+
/** Bottom to top. Empty until the split settles. */
|
|
5196
|
+
layers: z14.array(imageLayerSchema),
|
|
5197
|
+
/** Set once a flattened composition has been saved back to the library. */
|
|
5198
|
+
savedImageId: z14.string().optional()
|
|
5199
|
+
});
|
|
5200
|
+
var imagesLayersRequestSchema = z14.object({ imageId: z14.string().min(1, "Missing image ID") });
|
|
5155
5201
|
|
|
5156
5202
|
// ../api/src/studio.ts
|
|
5157
5203
|
import { z as z15 } from "zod";
|
|
@@ -29563,7 +29609,7 @@ Full guide: __tooling__/docs/tools/baker/hubspot.md`
|
|
|
29563
29609
|
});
|
|
29564
29610
|
|
|
29565
29611
|
// src/commands/images/index.ts
|
|
29566
|
-
import { defineCommand as
|
|
29612
|
+
import { defineCommand as defineCommand142 } from "citty";
|
|
29567
29613
|
|
|
29568
29614
|
// src/commands/images/crop.ts
|
|
29569
29615
|
import { defineCommand as defineCommand118 } from "citty";
|
|
@@ -30418,8 +30464,181 @@ var ingestCommand = defineCommand128({
|
|
|
30418
30464
|
}
|
|
30419
30465
|
});
|
|
30420
30466
|
|
|
30421
|
-
// src/commands/images/
|
|
30467
|
+
// src/commands/images/layerize.ts
|
|
30422
30468
|
import { defineCommand as defineCommand129 } from "citty";
|
|
30469
|
+
registerSchema({
|
|
30470
|
+
command: "images.layerize",
|
|
30471
|
+
description: "Split a library image into editable layers: transparent PNG cutouts for each element, plus any headline recovered as EDITABLE TEXT with its font, size, colour and position. Waits for completion by default. Costs credits.",
|
|
30472
|
+
args: {
|
|
30473
|
+
"image-id": { type: "string", description: "Library image ID to split", required: true },
|
|
30474
|
+
instructions: {
|
|
30475
|
+
type: "string",
|
|
30476
|
+
description: "Optional steer for what to separate, e.g. 'keep the bottle and its shadow as one layer'",
|
|
30477
|
+
required: false
|
|
30478
|
+
},
|
|
30479
|
+
full: { type: "boolean", description: "Include geometry and typography for every layer", required: false },
|
|
30480
|
+
"max-wait": {
|
|
30481
|
+
type: "number",
|
|
30482
|
+
description: "Max wait ms (default 240000 = 4 min). Set 0 to fire-and-forget.",
|
|
30483
|
+
required: false,
|
|
30484
|
+
default: 24e4
|
|
30485
|
+
}
|
|
30486
|
+
}
|
|
30487
|
+
});
|
|
30488
|
+
var POLL_INTERVAL_MS3 = 4e3;
|
|
30489
|
+
function compact(doc) {
|
|
30490
|
+
return {
|
|
30491
|
+
layeredImageId: doc.layeredImageId,
|
|
30492
|
+
imageId: doc.imageId,
|
|
30493
|
+
status: doc.status,
|
|
30494
|
+
canvas: { width: doc.width, height: doc.height },
|
|
30495
|
+
layers: doc.layers.map((layer) => ({
|
|
30496
|
+
id: layer.id,
|
|
30497
|
+
kind: layer.kind,
|
|
30498
|
+
name: layer.name,
|
|
30499
|
+
...layer.url ? { url: layer.url } : {},
|
|
30500
|
+
...layer.text ? { text: layer.text.content } : {}
|
|
30501
|
+
}))
|
|
30502
|
+
};
|
|
30503
|
+
}
|
|
30504
|
+
function hintsFor2(doc) {
|
|
30505
|
+
const hints = [];
|
|
30506
|
+
const text = doc.layers.filter((layer) => layer.kind === "text");
|
|
30507
|
+
const art = doc.layers.filter((layer) => layer.kind === "art" && layer.id !== "layer-base");
|
|
30508
|
+
if (text.length > 0) {
|
|
30509
|
+
hints.push(
|
|
30510
|
+
`${text.length} text layer(s) recovered as editable copy \u2014 run with --full for the font, size and colour to reuse when rewriting it.`
|
|
30511
|
+
);
|
|
30512
|
+
}
|
|
30513
|
+
if (art.length > 0) {
|
|
30514
|
+
hints.push(
|
|
30515
|
+
`Each art layer's url is a transparent PNG on the media host: wire one straight into a canvas composition to reuse that element on its own.`
|
|
30516
|
+
);
|
|
30517
|
+
}
|
|
30518
|
+
hints.push(
|
|
30519
|
+
'"Original image" is the flat picture kept underneath. The model separates what was VISIBLE and does not repaint what sat behind a subject, so moving one can leave a gap.'
|
|
30520
|
+
);
|
|
30521
|
+
return hints;
|
|
30522
|
+
}
|
|
30523
|
+
async function pollUntilSettled(imageId, maxWait) {
|
|
30524
|
+
const start = Date.now();
|
|
30525
|
+
while (Date.now() - start < maxWait) {
|
|
30526
|
+
await new Promise((resolve5) => setTimeout(resolve5, POLL_INTERVAL_MS3));
|
|
30527
|
+
const doc = await apiGet("/api/images/layers", { imageId });
|
|
30528
|
+
if (doc.status !== "splitting") return doc;
|
|
30529
|
+
}
|
|
30530
|
+
return null;
|
|
30531
|
+
}
|
|
30532
|
+
var layerizeCommand = defineCommand129({
|
|
30533
|
+
meta: {
|
|
30534
|
+
name: "layerize",
|
|
30535
|
+
description: "Split a library image into editable layers \u2014 transparent cutouts per element, plus any baked-in headline recovered as editable text with its typography.\n\nStart here: baker images layerize j571abc123def\nExample: baker images layerize j571abc123def --full\nExample: baker images layerize j571abc123def --instructions 'keep the product and its shadow together'"
|
|
30536
|
+
},
|
|
30537
|
+
args: {
|
|
30538
|
+
"image-id": { type: "positional", description: "Library image ID", required: false },
|
|
30539
|
+
instructions: { type: "string", description: "Optional steer for what to separate", required: false },
|
|
30540
|
+
full: { type: "boolean", description: "Include geometry and typography", required: false },
|
|
30541
|
+
"max-wait": { type: "string", description: "Max wait ms (default 240000, 0 = no wait)", required: false }
|
|
30542
|
+
},
|
|
30543
|
+
run: async ({ args }) => {
|
|
30544
|
+
try {
|
|
30545
|
+
const imageId = args["image-id"];
|
|
30546
|
+
if (!imageId) {
|
|
30547
|
+
writeJson({ ok: false, error: { code: "VALIDATION_ERROR", message: "image-id is required" } });
|
|
30548
|
+
process.exit(1);
|
|
30549
|
+
}
|
|
30550
|
+
const maxWait = args["max-wait"] ? Number(args["max-wait"]) : 24e4;
|
|
30551
|
+
const full = Boolean(args.full);
|
|
30552
|
+
const started = await apiPost("/api/images/layerize", {
|
|
30553
|
+
imageId,
|
|
30554
|
+
instructions: args.instructions
|
|
30555
|
+
});
|
|
30556
|
+
const settled = maxWait === 0 || started.status !== "splitting" ? started : await pollUntilSettled(imageId, maxWait);
|
|
30557
|
+
if (!settled) {
|
|
30558
|
+
writeJson({
|
|
30559
|
+
ok: false,
|
|
30560
|
+
error: {
|
|
30561
|
+
code: "TIMEOUT",
|
|
30562
|
+
message: `Layers not ready within ${maxWait}ms`,
|
|
30563
|
+
fix: `The split is still running. Read it later with: baker images layers ${imageId}`
|
|
30564
|
+
}
|
|
30565
|
+
});
|
|
30566
|
+
process.exit(1);
|
|
30567
|
+
}
|
|
30568
|
+
if (settled.status === "failed") {
|
|
30569
|
+
writeJson({
|
|
30570
|
+
ok: false,
|
|
30571
|
+
error: {
|
|
30572
|
+
code: "IMAGE_PROCESSING_ERROR",
|
|
30573
|
+
message: settled.error ?? "That image couldn't be split into layers",
|
|
30574
|
+
fix: "Run the same command again \u2014 this provider rejects a valid request intermittently. If it fails twice more, carry on without layers."
|
|
30575
|
+
}
|
|
30576
|
+
});
|
|
30577
|
+
process.exit(1);
|
|
30578
|
+
}
|
|
30579
|
+
writeJson({ ok: true, data: full ? settled : compact(settled), hints: hintsFor2(settled) });
|
|
30580
|
+
} catch (err) {
|
|
30581
|
+
if (err instanceof ApiError) {
|
|
30582
|
+
writeJson({ ok: false, error: { code: err.code, message: err.message } });
|
|
30583
|
+
process.exit(1);
|
|
30584
|
+
}
|
|
30585
|
+
writeJson({
|
|
30586
|
+
ok: false,
|
|
30587
|
+
error: { code: "INTERNAL_ERROR", message: err instanceof Error ? err.message : "Unexpected error" }
|
|
30588
|
+
});
|
|
30589
|
+
process.exit(1);
|
|
30590
|
+
}
|
|
30591
|
+
}
|
|
30592
|
+
});
|
|
30593
|
+
registerSchema({
|
|
30594
|
+
command: "images.layers",
|
|
30595
|
+
description: "Read the layers of an image already split with `images layerize` \u2014 free, no provider call. Use it to see what an ad says and what its pieces are.",
|
|
30596
|
+
args: {
|
|
30597
|
+
"image-id": { type: "string", description: "Library image ID", required: true },
|
|
30598
|
+
full: { type: "boolean", description: "Include geometry and typography for every layer", required: false }
|
|
30599
|
+
}
|
|
30600
|
+
});
|
|
30601
|
+
var layersCommand = defineCommand129({
|
|
30602
|
+
meta: {
|
|
30603
|
+
name: "layers",
|
|
30604
|
+
description: "Read the layers of an image that has already been split. Free \u2014 no provider call.\n\nStart here: baker images layers j571abc123def\nExample: baker images layers j571abc123def --full"
|
|
30605
|
+
},
|
|
30606
|
+
args: {
|
|
30607
|
+
"image-id": { type: "positional", description: "Library image ID", required: false },
|
|
30608
|
+
full: { type: "boolean", description: "Include geometry and typography", required: false }
|
|
30609
|
+
},
|
|
30610
|
+
run: async ({ args }) => {
|
|
30611
|
+
try {
|
|
30612
|
+
const imageId = args["image-id"];
|
|
30613
|
+
if (!imageId) {
|
|
30614
|
+
writeJson({ ok: false, error: { code: "VALIDATION_ERROR", message: "image-id is required" } });
|
|
30615
|
+
process.exit(1);
|
|
30616
|
+
}
|
|
30617
|
+
const doc = await apiGet("/api/images/layers", { imageId });
|
|
30618
|
+
writeJson({ ok: true, data: args.full ? doc : compact(doc), hints: hintsFor2(doc) });
|
|
30619
|
+
} catch (err) {
|
|
30620
|
+
if (err instanceof ApiError) {
|
|
30621
|
+
writeJson({
|
|
30622
|
+
ok: false,
|
|
30623
|
+
error: {
|
|
30624
|
+
code: err.code,
|
|
30625
|
+
message: err.message,
|
|
30626
|
+
...err.code === "NOT_FOUND" ? { fix: `Split it first: baker images layerize ${args["image-id"]}` } : {}
|
|
30627
|
+
}
|
|
30628
|
+
});
|
|
30629
|
+
process.exit(1);
|
|
30630
|
+
}
|
|
30631
|
+
writeJson({
|
|
30632
|
+
ok: false,
|
|
30633
|
+
error: { code: "INTERNAL_ERROR", message: err instanceof Error ? err.message : "Unexpected error" }
|
|
30634
|
+
});
|
|
30635
|
+
process.exit(1);
|
|
30636
|
+
}
|
|
30637
|
+
}
|
|
30638
|
+
});
|
|
30639
|
+
|
|
30640
|
+
// src/commands/images/library.ts
|
|
30641
|
+
import { defineCommand as defineCommand130 } from "citty";
|
|
30423
30642
|
registerSchema({
|
|
30424
30643
|
command: "images.library",
|
|
30425
30644
|
description: "Search the company image library. Returns only ready images.",
|
|
@@ -30445,7 +30664,7 @@ registerSchema({
|
|
|
30445
30664
|
}
|
|
30446
30665
|
}
|
|
30447
30666
|
});
|
|
30448
|
-
var libraryCommand =
|
|
30667
|
+
var libraryCommand = defineCommand130({
|
|
30449
30668
|
meta: {
|
|
30450
30669
|
name: "library",
|
|
30451
30670
|
description: "Search the company image library (hybrid BM25 + vector + Cohere rerank). Use this BEFORE any external provider.\n\nExample: baker images library 'hero banner' --aspect-ratio 16:9 --source magnific"
|
|
@@ -30502,7 +30721,7 @@ var libraryCommand = defineCommand129({
|
|
|
30502
30721
|
});
|
|
30503
30722
|
|
|
30504
30723
|
// src/commands/images/logo.ts
|
|
30505
|
-
import { defineCommand as
|
|
30724
|
+
import { defineCommand as defineCommand131 } from "citty";
|
|
30506
30725
|
registerSchema({
|
|
30507
30726
|
command: "images.logo",
|
|
30508
30727
|
description: "Brand logo lookup via Brandfetch CDN (fallback/404). Auto-ingests by default.",
|
|
@@ -30527,7 +30746,7 @@ registerSchema({
|
|
|
30527
30746
|
}
|
|
30528
30747
|
}
|
|
30529
30748
|
});
|
|
30530
|
-
var logoCommand =
|
|
30749
|
+
var logoCommand = defineCommand131({
|
|
30531
30750
|
meta: {
|
|
30532
30751
|
name: "logo",
|
|
30533
30752
|
description: "Brand logo via Brandfetch CDN. Returns up to 5 variants (icon, light/dark logo, light/dark symbol). Auto-ingests the first variant.\n\nExample: baker images logo stripe.com --variant logo"
|
|
@@ -30565,7 +30784,7 @@ var logoCommand = defineCommand130({
|
|
|
30565
30784
|
});
|
|
30566
30785
|
|
|
30567
30786
|
// src/commands/images/normalize.ts
|
|
30568
|
-
import { defineCommand as
|
|
30787
|
+
import { defineCommand as defineCommand132 } from "citty";
|
|
30569
30788
|
|
|
30570
30789
|
// src/lib/image/color-changer.ts
|
|
30571
30790
|
import quantize from "quantize";
|
|
@@ -31297,7 +31516,7 @@ function coerceRawArgs(args) {
|
|
|
31297
31516
|
"dry-run": bool(args["dry-run"])
|
|
31298
31517
|
};
|
|
31299
31518
|
}
|
|
31300
|
-
var normalizeCommand =
|
|
31519
|
+
var normalizeCommand = defineCommand132({
|
|
31301
31520
|
meta: {
|
|
31302
31521
|
name: "normalize",
|
|
31303
31522
|
description: `Normalize logos / images: declarative recolor + bg removal + trim + resize. Operates on local files; writes in-place by default.
|
|
@@ -31352,7 +31571,7 @@ Examples:
|
|
|
31352
31571
|
});
|
|
31353
31572
|
|
|
31354
31573
|
// src/commands/images/pinterest.ts
|
|
31355
|
-
import { defineCommand as
|
|
31574
|
+
import { defineCommand as defineCommand133 } from "citty";
|
|
31356
31575
|
registerSchema({
|
|
31357
31576
|
command: "images.pinterest",
|
|
31358
31577
|
description: "Pinterest image search via ScrapeCreators. Reference-grade real-world photography, product styling, interiors, fashion, food, and aesthetic mood boards. Inspect before placing \u2014 Pinterest is unverified, trademark-bearing web content.",
|
|
@@ -31372,7 +31591,7 @@ registerSchema({
|
|
|
31372
31591
|
}
|
|
31373
31592
|
}
|
|
31374
31593
|
});
|
|
31375
|
-
var pinterestCommand =
|
|
31594
|
+
var pinterestCommand = defineCommand133({
|
|
31376
31595
|
meta: {
|
|
31377
31596
|
name: "pinterest",
|
|
31378
31597
|
description: "Pinterest image search via ScrapeCreators ($0.00188/request). Best for photo-realistic reference imagery \u2014 lifestyle, interiors, fashion, food, product styling, and mood boards to brief AI generation against. \u26A0 Unverified, trademark-bearing web content \u2014 inspect and respect rights before placing on a customer page. Browse first; auto-ingest only the pins you commit to.\n\nExamples:\n baker images pinterest 'scandinavian living room'\n baker images pinterest 'minimalist skincare product photography' --limit 20\n baker images pinterest 'cozy coffee shop interior' --auto-ingest 2 --context 'Mood reference for hero photography'"
|
|
@@ -31412,7 +31631,7 @@ var pinterestCommand = defineCommand132({
|
|
|
31412
31631
|
});
|
|
31413
31632
|
|
|
31414
31633
|
// src/commands/images/screenshot.ts
|
|
31415
|
-
import { defineCommand as
|
|
31634
|
+
import { defineCommand as defineCommand134 } from "citty";
|
|
31416
31635
|
registerSchema({
|
|
31417
31636
|
command: "images.screenshot",
|
|
31418
31637
|
description: "Capture a website screenshot via ScreenshotOne. Auto-ingests on success.",
|
|
@@ -31428,7 +31647,7 @@ registerSchema({
|
|
|
31428
31647
|
}
|
|
31429
31648
|
}
|
|
31430
31649
|
});
|
|
31431
|
-
var screenshotCommand =
|
|
31650
|
+
var screenshotCommand = defineCommand134({
|
|
31432
31651
|
meta: {
|
|
31433
31652
|
name: "screenshot",
|
|
31434
31653
|
description: "Screenshot a URL via ScreenshotOne. $0.009/capture. Auto-ingests to library.\n\nExample: baker images screenshot https://stripe.com --full-page"
|
|
@@ -31491,7 +31710,7 @@ var screenshotCommand = defineCommand133({
|
|
|
31491
31710
|
});
|
|
31492
31711
|
|
|
31493
31712
|
// src/commands/images/search.ts
|
|
31494
|
-
import { defineCommand as
|
|
31713
|
+
import { defineCommand as defineCommand135 } from "citty";
|
|
31495
31714
|
registerSchema({
|
|
31496
31715
|
command: "images.search",
|
|
31497
31716
|
description: "Search images by text query. Only returns ready images.",
|
|
@@ -31507,7 +31726,7 @@ registerSchema({
|
|
|
31507
31726
|
tags: { type: "string", description: "Comma-separated tags to filter by", required: false }
|
|
31508
31727
|
}
|
|
31509
31728
|
});
|
|
31510
|
-
var searchCommand =
|
|
31729
|
+
var searchCommand = defineCommand135({
|
|
31511
31730
|
meta: {
|
|
31512
31731
|
name: "search",
|
|
31513
31732
|
description: "Semantic search images by text query. Uses hybrid BM25 + vector + reranking. Example: baker images search 'hero banner' --aspect-ratio 16:9 --tags logo"
|
|
@@ -31567,7 +31786,7 @@ var searchCommand = defineCommand134({
|
|
|
31567
31786
|
});
|
|
31568
31787
|
|
|
31569
31788
|
// src/commands/images/sticker.ts
|
|
31570
|
-
import { defineCommand as
|
|
31789
|
+
import { defineCommand as defineCommand136 } from "citty";
|
|
31571
31790
|
registerSchema({
|
|
31572
31791
|
command: "images.sticker",
|
|
31573
31792
|
description: "Search Giphy stickers \u2014 transparent-background overlays for ad creative.",
|
|
@@ -31599,7 +31818,7 @@ registerSchema({
|
|
|
31599
31818
|
}
|
|
31600
31819
|
}
|
|
31601
31820
|
});
|
|
31602
|
-
var stickerCommand =
|
|
31821
|
+
var stickerCommand = defineCommand136({
|
|
31603
31822
|
meta: {
|
|
31604
31823
|
name: "sticker",
|
|
31605
31824
|
description: "Search Giphy's sticker corpus \u2014 transparent-background WebPs / GIFs ideal for overlaying on ad creative (Meta, TikTok, Stories). Same Giphy free API as `baker images gif`; results carry WebP + GIF + MP4 URLs in providerMeta.\n\nExample: baker images sticker 'thumbs up' --limit 10\nExample: baker images sticker celebration --rating g --auto-ingest 3\nExample: baker images sticker --trending --limit 25"
|
|
@@ -31646,7 +31865,7 @@ var stickerCommand = defineCommand135({
|
|
|
31646
31865
|
});
|
|
31647
31866
|
|
|
31648
31867
|
// src/commands/images/stock.ts
|
|
31649
|
-
import { defineCommand as
|
|
31868
|
+
import { defineCommand as defineCommand137 } from "citty";
|
|
31650
31869
|
var STOCK_ERROR_FIX = {
|
|
31651
31870
|
action: "use_different_resource",
|
|
31652
31871
|
explanation: "Switch provider instead of retrying stock search. Stock search is one of several image sources. Run `baker images find <query> --sources library,pinterest,google` (`--sources` is required \u2014 `find` alone searches the library only) or `baker studio generate` to make the asset. Never sleep-and-retry this command \u2014 the CLI already backs off on rate limits. If no image can be sourced, continue the rest of the task with a placeholder rather than aborting it."
|
|
@@ -31723,7 +31942,7 @@ function buildStockRequest(query, args) {
|
|
|
31723
31942
|
if (args.context) body.descriptionContext = args.context;
|
|
31724
31943
|
return body;
|
|
31725
31944
|
}
|
|
31726
|
-
var stockCommand =
|
|
31945
|
+
var stockCommand = defineCommand137({
|
|
31727
31946
|
meta: {
|
|
31728
31947
|
name: "stock",
|
|
31729
31948
|
description: "Stock search via Magnific \u2014 Freepik's developer API (~250M assets: photos, vectors, illustrations, icons, PSDs). $0.002/req. With --auto-ingest, ingested hits return Baker-owned URLs.\n\nExamples:\n baker images stock 'minimalist office'\n baker images stock 'flat office workers' --type vector\n baker images stock 'hero photo of a kitchen' --type photo --orientation landscape --ai exclude\n baker images stock 'brand pattern' --color '#0a0a0a' --license freemium --auto-ingest 2"
|
|
@@ -31779,7 +31998,7 @@ var stockCommand = defineCommand136({
|
|
|
31779
31998
|
});
|
|
31780
31999
|
|
|
31781
32000
|
// src/lib/tags-command.ts
|
|
31782
|
-
import { defineCommand as
|
|
32001
|
+
import { defineCommand as defineCommand138 } from "citty";
|
|
31783
32002
|
function makeTagsCommand(command, label, endpoint) {
|
|
31784
32003
|
registerSchema({
|
|
31785
32004
|
command: `${command}.tags`,
|
|
@@ -31788,7 +32007,7 @@ function makeTagsCommand(command, label, endpoint) {
|
|
|
31788
32007
|
output: { type: "string", description: "Output format: md|json", required: false, default: "md" }
|
|
31789
32008
|
}
|
|
31790
32009
|
});
|
|
31791
|
-
return
|
|
32010
|
+
return defineCommand138({
|
|
31792
32011
|
meta: {
|
|
31793
32012
|
name: "tags",
|
|
31794
32013
|
description: `List the available ${label} tag names (defaults + company custom tags). Use before filtering with --tags. Example: baker ${command} tags`
|
|
@@ -31824,7 +32043,7 @@ function makeTagsCommand(command, label, endpoint) {
|
|
|
31824
32043
|
var tagsCommand2 = makeTagsCommand("images", "image", "/api/images/tags");
|
|
31825
32044
|
|
|
31826
32045
|
// src/commands/images/upload.ts
|
|
31827
|
-
import { defineCommand as
|
|
32046
|
+
import { defineCommand as defineCommand139 } from "citty";
|
|
31828
32047
|
registerSchema({
|
|
31829
32048
|
command: "images.upload",
|
|
31830
32049
|
description: "Upload an image to the library \u2014 local file path or remote http(s) URL.",
|
|
@@ -31862,7 +32081,7 @@ registerSchema({
|
|
|
31862
32081
|
function isRemoteUrl2(value) {
|
|
31863
32082
|
return /^https?:\/\//i.test(value);
|
|
31864
32083
|
}
|
|
31865
|
-
var uploadCommand =
|
|
32084
|
+
var uploadCommand = defineCommand139({
|
|
31866
32085
|
meta: {
|
|
31867
32086
|
name: "upload",
|
|
31868
32087
|
description: "Upload an image to the library \u2014 accepts a local file path OR a remote http(s) URL.\n\nLocal: reads bytes, sends to /api/images/upload, content-type auto-detected from extension.\nRemote: dispatches to /api/images/ingest with hash-dedup on bytes + externalId.\n\nExamples:\n baker images upload ./logo.png --source uploaded\n baker images upload ./cert.png --context 'ISO 27001 badge \u2014 enterprise tier'\n baker images upload https://acme.com/hero.png --source firecrawl --context 'Acme competitor pricing hero'"
|
|
@@ -31955,7 +32174,7 @@ async function uploadLocal(target, args) {
|
|
|
31955
32174
|
}
|
|
31956
32175
|
|
|
31957
32176
|
// src/commands/images/upscale.ts
|
|
31958
|
-
import { defineCommand as
|
|
32177
|
+
import { defineCommand as defineCommand140 } from "citty";
|
|
31959
32178
|
registerSchema({
|
|
31960
32179
|
command: "images.upscale",
|
|
31961
32180
|
description: "Upscale a library image via the backend (Replicate, cost-tracked). Waits for completion by default. The image must be status 'ready' and raster (not SVG/AVIF).",
|
|
@@ -31969,8 +32188,8 @@ registerSchema({
|
|
|
31969
32188
|
}
|
|
31970
32189
|
}
|
|
31971
32190
|
});
|
|
31972
|
-
var
|
|
31973
|
-
var upscaleCommand =
|
|
32191
|
+
var POLL_INTERVAL_MS4 = 1500;
|
|
32192
|
+
var upscaleCommand = defineCommand140({
|
|
31974
32193
|
meta: {
|
|
31975
32194
|
name: "upscale",
|
|
31976
32195
|
description: "Upscale a library image via the Convex backend (Replicate, cost-tracked at $0.05/image). Waits for completion by default.\n\nExample: baker images upscale j571abc123def\nExample: baker images upscale j571abc123def --max-wait 0 # fire-and-forget"
|
|
@@ -32006,7 +32225,7 @@ var upscaleCommand = defineCommand139({
|
|
|
32006
32225
|
});
|
|
32007
32226
|
process.exit(1);
|
|
32008
32227
|
}
|
|
32009
|
-
await new Promise((resolve5) => setTimeout(resolve5,
|
|
32228
|
+
await new Promise((resolve5) => setTimeout(resolve5, POLL_INTERVAL_MS4));
|
|
32010
32229
|
}
|
|
32011
32230
|
writeJson({ ok: false, error: { code: "TIMEOUT", message: `Image not ready within ${maxWait}ms` } });
|
|
32012
32231
|
process.exit(1);
|
|
@@ -32025,7 +32244,7 @@ var upscaleCommand = defineCommand139({
|
|
|
32025
32244
|
});
|
|
32026
32245
|
|
|
32027
32246
|
// src/commands/images/use.ts
|
|
32028
|
-
import { defineCommand as
|
|
32247
|
+
import { defineCommand as defineCommand141 } from "citty";
|
|
32029
32248
|
registerSchema({
|
|
32030
32249
|
command: "images.use",
|
|
32031
32250
|
description: "Ingest a URL and wait for the library record to be ready.",
|
|
@@ -32040,8 +32259,8 @@ registerSchema({
|
|
|
32040
32259
|
}
|
|
32041
32260
|
}
|
|
32042
32261
|
});
|
|
32043
|
-
var
|
|
32044
|
-
var useCommand =
|
|
32262
|
+
var POLL_INTERVAL_MS5 = 1500;
|
|
32263
|
+
var useCommand = defineCommand141({
|
|
32045
32264
|
meta: {
|
|
32046
32265
|
name: "use",
|
|
32047
32266
|
description: "Sugar over `ingest`: download \u2192 store \u2192 wait until describe + embed complete \u2192 return ready library record.\n\nExample: baker images use https://cdn.example.com/hero.png --source uploaded"
|
|
@@ -32071,7 +32290,7 @@ var useCommand = defineCommand140({
|
|
|
32071
32290
|
writeJson({ ok: true, data: { ...ingestResult, image: doc } });
|
|
32072
32291
|
return;
|
|
32073
32292
|
}
|
|
32074
|
-
await new Promise((resolve5) => setTimeout(resolve5,
|
|
32293
|
+
await new Promise((resolve5) => setTimeout(resolve5, POLL_INTERVAL_MS5));
|
|
32075
32294
|
}
|
|
32076
32295
|
writeJson({ ok: false, error: { code: "TIMEOUT", message: `Image not ready within ${maxWait}ms` } });
|
|
32077
32296
|
process.exit(1);
|
|
@@ -32087,7 +32306,7 @@ var useCommand = defineCommand140({
|
|
|
32087
32306
|
});
|
|
32088
32307
|
|
|
32089
32308
|
// src/commands/images/index.ts
|
|
32090
|
-
var imagesCommand =
|
|
32309
|
+
var imagesCommand = defineCommand142({
|
|
32091
32310
|
meta: {
|
|
32092
32311
|
name: "images",
|
|
32093
32312
|
description: `Find, source, and normalize images. Subcommands route by provider so cost + license are explicit.
|
|
@@ -32129,6 +32348,8 @@ Taxonomy:
|
|
|
32129
32348
|
|
|
32130
32349
|
Paid transforms (run on the Convex backend, cost-tracked):
|
|
32131
32350
|
baker images upscale <imageId> Real-ESRGAN super-resolution ($0.05/image, waits for completion)
|
|
32351
|
+
baker images layerize <imageId> Split into editable layers; recovers baked-in copy as editable text (costs credits)
|
|
32352
|
+
baker images layers <imageId> Read the layers of an already-split image (free)
|
|
32132
32353
|
Full guide: __tooling__/docs/tools/baker/images.md`
|
|
32133
32354
|
},
|
|
32134
32355
|
subCommands: {
|
|
@@ -32153,18 +32374,20 @@ Full guide: __tooling__/docs/tools/baker/images.md`
|
|
|
32153
32374
|
normalize: normalizeCommand,
|
|
32154
32375
|
crop: cropCommand,
|
|
32155
32376
|
dimensions: dimensionsCommand,
|
|
32377
|
+
layerize: layerizeCommand,
|
|
32378
|
+
layers: layersCommand,
|
|
32156
32379
|
upscale: upscaleCommand,
|
|
32157
32380
|
tags: tagsCommand2
|
|
32158
32381
|
}
|
|
32159
32382
|
});
|
|
32160
32383
|
|
|
32161
32384
|
// src/commands/landing/index.ts
|
|
32162
|
-
import { defineCommand as
|
|
32385
|
+
import { defineCommand as defineCommand152 } from "citty";
|
|
32163
32386
|
|
|
32164
32387
|
// src/commands/landing/critique.ts
|
|
32165
32388
|
import { readdir as readdir8, stat as stat6 } from "fs/promises";
|
|
32166
32389
|
import path28 from "path";
|
|
32167
|
-
import { defineCommand as
|
|
32390
|
+
import { defineCommand as defineCommand143 } from "citty";
|
|
32168
32391
|
|
|
32169
32392
|
// src/engine/landing/lib/brand-tokens.ts
|
|
32170
32393
|
import { readFile as readFile20 } from "fs/promises";
|
|
@@ -33559,7 +33782,7 @@ function fail5(code, message, fix) {
|
|
|
33559
33782
|
);
|
|
33560
33783
|
process.exit(2);
|
|
33561
33784
|
}
|
|
33562
|
-
var critiqueCommand2 =
|
|
33785
|
+
var critiqueCommand2 = defineCommand143({
|
|
33563
33786
|
meta: {
|
|
33564
33787
|
name: "critique",
|
|
33565
33788
|
description: "Start here: `baker landing critique <slug>` after building or editing a landing. Deterministic design-quality critic (ADVISORY \u2014 findings never fail it). Flags the known AI design tells (gradient text, overused fonts, side-tab borders, cream palettes, buzzword copy, broken images) tiered block/warn/advisory, respecting the client's BRAND.md as the allowlist. Also records the critique that publishing requires \u2014 run it before finishing a landing."
|
|
@@ -33668,10 +33891,10 @@ async function isDir(p) {
|
|
|
33668
33891
|
}
|
|
33669
33892
|
|
|
33670
33893
|
// src/commands/landing/inspiration/index.ts
|
|
33671
|
-
import { defineCommand as
|
|
33894
|
+
import { defineCommand as defineCommand151 } from "citty";
|
|
33672
33895
|
|
|
33673
33896
|
// src/commands/landing/inspiration/add.ts
|
|
33674
|
-
import { defineCommand as
|
|
33897
|
+
import { defineCommand as defineCommand144 } from "citty";
|
|
33675
33898
|
|
|
33676
33899
|
// src/commands/landing/inspiration/shared.ts
|
|
33677
33900
|
var INSPIRATION_HINTS = {
|
|
@@ -33717,7 +33940,7 @@ registerSchema({
|
|
|
33717
33940
|
note: { type: "string", description: "Why this page is worth keeping", required: false }
|
|
33718
33941
|
}
|
|
33719
33942
|
});
|
|
33720
|
-
var addCommand =
|
|
33943
|
+
var addCommand = defineCommand144({
|
|
33721
33944
|
meta: {
|
|
33722
33945
|
name: "add",
|
|
33723
33946
|
description: "Add someone else's landing page to the reference library. Example: baker landing inspiration add https://linear.app --note 'the client likes this density'"
|
|
@@ -33755,7 +33978,7 @@ var addCommand = defineCommand143({
|
|
|
33755
33978
|
// src/commands/landing/inspiration/code.ts
|
|
33756
33979
|
import { mkdir as mkdir10, writeFile as writeFile13 } from "fs/promises";
|
|
33757
33980
|
import path29 from "path";
|
|
33758
|
-
import { defineCommand as
|
|
33981
|
+
import { defineCommand as defineCommand145 } from "citty";
|
|
33759
33982
|
registerSchema({
|
|
33760
33983
|
command: "landing.inspiration.code",
|
|
33761
33984
|
description: "Write a reference section's standalone HTML+CSS to .baker/inspiration/<id>/ so you can read how it is built. Reference only \u2014 the structure is the lesson, the words are not yours to reuse. Consulting a section records it, and `baker landing critique` blocks a publish that ships its copy verbatim.",
|
|
@@ -33764,7 +33987,7 @@ registerSchema({
|
|
|
33764
33987
|
full: { type: "boolean", description: "Print the markup inline as well as writing it", required: false }
|
|
33765
33988
|
}
|
|
33766
33989
|
});
|
|
33767
|
-
var codeCommand =
|
|
33990
|
+
var codeCommand = defineCommand145({
|
|
33768
33991
|
meta: {
|
|
33769
33992
|
name: "code",
|
|
33770
33993
|
description: "Write one reference section's standalone markup to disk. Example: baker landing inspiration code k57abc\u2026 \u2014 read it for structure, then build your own."
|
|
@@ -33821,7 +34044,7 @@ var codeCommand = defineCommand144({
|
|
|
33821
34044
|
});
|
|
33822
34045
|
|
|
33823
34046
|
// src/commands/landing/inspiration/favorites.ts
|
|
33824
|
-
import { defineCommand as
|
|
34047
|
+
import { defineCommand as defineCommand146 } from "citty";
|
|
33825
34048
|
registerSchema({
|
|
33826
34049
|
command: "landing.inspiration.favorites",
|
|
33827
34050
|
description: "List the reference sections this company has saved. This is what `search` looks at by default, so it is the client's own taste profile \u2014 read it before proposing a direction.",
|
|
@@ -33835,7 +34058,7 @@ registerSchema({
|
|
|
33835
34058
|
}
|
|
33836
34059
|
}
|
|
33837
34060
|
});
|
|
33838
|
-
var favoritesCommand =
|
|
34061
|
+
var favoritesCommand = defineCommand146({
|
|
33839
34062
|
meta: {
|
|
33840
34063
|
name: "favorites",
|
|
33841
34064
|
description: "List this company's saved reference sections. Example: baker landing inspiration favorites --type hero,pricing"
|
|
@@ -33895,7 +34118,7 @@ registerSchema({
|
|
|
33895
34118
|
note: { type: "string", description: "Why this is worth keeping", required: false }
|
|
33896
34119
|
}
|
|
33897
34120
|
});
|
|
33898
|
-
var favoriteCommand =
|
|
34121
|
+
var favoriteCommand = defineCommand146({
|
|
33899
34122
|
meta: {
|
|
33900
34123
|
name: "favorite",
|
|
33901
34124
|
description: "Save a reference section to this company. Example: baker landing inspiration favorite k57abc\u2026"
|
|
@@ -33933,7 +34156,7 @@ registerSchema({
|
|
|
33933
34156
|
page: { type: "boolean", description: "Treat the id as a page rather than a section", required: false }
|
|
33934
34157
|
}
|
|
33935
34158
|
});
|
|
33936
|
-
var unfavoriteCommand =
|
|
34159
|
+
var unfavoriteCommand = defineCommand146({
|
|
33937
34160
|
meta: {
|
|
33938
34161
|
name: "unfavorite",
|
|
33939
34162
|
description: "Remove a reference section from this company's saved set. Example: baker landing inspiration unfavorite k57abc\u2026"
|
|
@@ -33955,7 +34178,7 @@ var unfavoriteCommand = defineCommand145({
|
|
|
33955
34178
|
});
|
|
33956
34179
|
|
|
33957
34180
|
// src/commands/landing/inspiration/page.ts
|
|
33958
|
-
import { defineCommand as
|
|
34181
|
+
import { defineCommand as defineCommand147 } from "citty";
|
|
33959
34182
|
registerSchema({
|
|
33960
34183
|
command: "landing.inspiration.page",
|
|
33961
34184
|
description: "Show a whole reference page as a sequence: every section top to bottom with its type and the idea behind it. This is the view to use when the question is how a good page is ORDERED rather than what one section looks like.",
|
|
@@ -33972,7 +34195,7 @@ registerSchema({
|
|
|
33972
34195
|
}
|
|
33973
34196
|
}
|
|
33974
34197
|
});
|
|
33975
|
-
var pageCommand =
|
|
34198
|
+
var pageCommand = defineCommand147({
|
|
33976
34199
|
meta: {
|
|
33977
34200
|
name: "page",
|
|
33978
34201
|
description: "Show how a reference page sequences its sections. Example: baker landing inspiration page j91xyz\u2026 \u2014 the blueprint, not the pixels."
|
|
@@ -34037,7 +34260,7 @@ var pageCommand = defineCommand146({
|
|
|
34037
34260
|
// src/commands/landing/inspiration/scrape.ts
|
|
34038
34261
|
import { readFile as readFile23 } from "fs/promises";
|
|
34039
34262
|
import path32 from "path";
|
|
34040
|
-
import { defineCommand as
|
|
34263
|
+
import { defineCommand as defineCommand148 } from "citty";
|
|
34041
34264
|
|
|
34042
34265
|
// src/engine/landing/lib/capturedReferences.ts
|
|
34043
34266
|
var MAX_STRINGS_PER_SECTION = 40;
|
|
@@ -35832,7 +36055,7 @@ registerSchema({
|
|
|
35832
36055
|
report: { type: "boolean", description: "Write report.html. `--no-report` to skip", required: false }
|
|
35833
36056
|
}
|
|
35834
36057
|
});
|
|
35835
|
-
var scrapeCommand =
|
|
36058
|
+
var scrapeCommand = defineCommand148({
|
|
35836
36059
|
meta: {
|
|
35837
36060
|
name: "scrape",
|
|
35838
36061
|
description: "Capture a landing page to a directory, now. Example: baker landing inspiration scrape https://linear.app --out .baker/inspiration/linear.app"
|
|
@@ -35911,7 +36134,7 @@ var scrapeCommand = defineCommand147({
|
|
|
35911
36134
|
// src/commands/landing/inspiration/search.ts
|
|
35912
36135
|
import { mkdir as mkdir12, writeFile as writeFile16 } from "fs/promises";
|
|
35913
36136
|
import path33 from "path";
|
|
35914
|
-
import { defineCommand as
|
|
36137
|
+
import { defineCommand as defineCommand149 } from "citty";
|
|
35915
36138
|
registerSchema({
|
|
35916
36139
|
command: "landing.inspiration.search",
|
|
35917
36140
|
description: "Search the shared library of real landing-page sections for reference before you design. Start here: baker landing inspiration search 'pricing with a monthly/annual toggle'. Returns the idea behind each section plus a downloaded screenshot you can Read. Defaults to this company's saved sections; pass --scope all for the whole library.",
|
|
@@ -36015,7 +36238,7 @@ async function downloadShots(results) {
|
|
|
36015
36238
|
);
|
|
36016
36239
|
return saved;
|
|
36017
36240
|
}
|
|
36018
|
-
var searchCommand2 =
|
|
36241
|
+
var searchCommand2 = defineCommand149({
|
|
36019
36242
|
meta: {
|
|
36020
36243
|
name: "search",
|
|
36021
36244
|
description: "Search real landing-page sections for reference. Example: baker landing inspiration search 'dark developer hero with a terminal' --register dev-tool-minimal --scope all"
|
|
@@ -36103,7 +36326,7 @@ var searchCommand2 = defineCommand148({
|
|
|
36103
36326
|
// src/commands/landing/inspiration/view.ts
|
|
36104
36327
|
import { mkdir as mkdir13, writeFile as writeFile17 } from "fs/promises";
|
|
36105
36328
|
import path34 from "path";
|
|
36106
|
-
import { defineCommand as
|
|
36329
|
+
import { defineCommand as defineCommand150 } from "citty";
|
|
36107
36330
|
registerSchema({
|
|
36108
36331
|
command: "landing.inspiration.view",
|
|
36109
36332
|
description: "Everything known about one section: composition, motion, design tokens, the copy it uses, why it works, and what must change to make it yours. Downloads the desktop and mobile screenshots plus the motion filmstrip so you can look at them.",
|
|
@@ -36128,7 +36351,7 @@ async function download(url, file) {
|
|
|
36128
36351
|
return null;
|
|
36129
36352
|
}
|
|
36130
36353
|
}
|
|
36131
|
-
var viewCommand2 =
|
|
36354
|
+
var viewCommand2 = defineCommand150({
|
|
36132
36355
|
meta: {
|
|
36133
36356
|
name: "view",
|
|
36134
36357
|
description: "Full detail for one reference section. Example: baker landing inspiration view k57abc\u2026 \u2014 read the screenshots it saves before you build."
|
|
@@ -36211,7 +36434,7 @@ var viewCommand2 = defineCommand149({
|
|
|
36211
36434
|
});
|
|
36212
36435
|
|
|
36213
36436
|
// src/commands/landing/inspiration/index.ts
|
|
36214
|
-
var inspirationCommand =
|
|
36437
|
+
var inspirationCommand = defineCommand151({
|
|
36215
36438
|
meta: {
|
|
36216
36439
|
name: "inspiration",
|
|
36217
36440
|
description: `Reference library of real landing-page sections \u2014 look at how good pages actually solve a problem before you design one.
|
|
@@ -36253,7 +36476,7 @@ Full guide: __tooling__/docs/tools/baker/landing.md`
|
|
|
36253
36476
|
});
|
|
36254
36477
|
|
|
36255
36478
|
// src/commands/landing/index.ts
|
|
36256
|
-
var landingCommand =
|
|
36479
|
+
var landingCommand = defineCommand152({
|
|
36257
36480
|
meta: {
|
|
36258
36481
|
name: "landing",
|
|
36259
36482
|
description: `Design-quality tools for landing pages (src/pages/<slug>/).
|
|
@@ -36271,7 +36494,7 @@ Subcommands:
|
|
|
36271
36494
|
});
|
|
36272
36495
|
|
|
36273
36496
|
// src/commands/mcp/index.ts
|
|
36274
|
-
import { defineCommand as
|
|
36497
|
+
import { defineCommand as defineCommand153 } from "citty";
|
|
36275
36498
|
|
|
36276
36499
|
// src/commands/mcp/platforms.ts
|
|
36277
36500
|
function readsKey(label) {
|
|
@@ -36340,7 +36563,7 @@ registerSchema({
|
|
|
36340
36563
|
description: "List everything this chat can reach: managed integrations (Attio, Slack, Gmail, Google Sheets, \u2026), custom MCP servers, and the platforms the company signed in to (HubSpot, Google Ads, GA4, Search Console, Tag Manager) which you read through their own `baker` commands. Start here when the user mentions an external tool or platform.",
|
|
36341
36564
|
args: {}
|
|
36342
36565
|
});
|
|
36343
|
-
var connectedCommand =
|
|
36566
|
+
var connectedCommand = defineCommand153({
|
|
36344
36567
|
meta: {
|
|
36345
36568
|
name: "connected",
|
|
36346
36569
|
description: `Everything this chat can reach \u2014 managed integrations, custom MCP servers, and connected platforms.
|
|
@@ -36399,7 +36622,7 @@ registerSchema({
|
|
|
36399
36622
|
description: "List the custom MCP servers this company's chats see (org + company + your own user scope).",
|
|
36400
36623
|
args: {}
|
|
36401
36624
|
});
|
|
36402
|
-
var listCommand13 =
|
|
36625
|
+
var listCommand13 = defineCommand153({
|
|
36403
36626
|
meta: { name: "list", description: "List custom MCP servers visible to this company's chats." },
|
|
36404
36627
|
run: async () => {
|
|
36405
36628
|
try {
|
|
@@ -36436,7 +36659,7 @@ registerSchema({
|
|
|
36436
36659
|
header: { type: "string", description: 'Auth header "Key: Value" (repeatable)', required: false }
|
|
36437
36660
|
}
|
|
36438
36661
|
});
|
|
36439
|
-
var addCommand2 =
|
|
36662
|
+
var addCommand2 = defineCommand153({
|
|
36440
36663
|
meta: {
|
|
36441
36664
|
name: "add",
|
|
36442
36665
|
description: `Register a custom MCP server. Tools appear as mcp__<name>__* on the NEXT message.
|
|
@@ -36488,7 +36711,7 @@ registerSchema({
|
|
|
36488
36711
|
description: "Remove a company custom MCP server by name.",
|
|
36489
36712
|
args: { name: { type: "string", description: "Server name to remove", required: true } }
|
|
36490
36713
|
});
|
|
36491
|
-
var removeCommand4 =
|
|
36714
|
+
var removeCommand4 = defineCommand153({
|
|
36492
36715
|
meta: {
|
|
36493
36716
|
name: "remove",
|
|
36494
36717
|
description: `Remove a company custom MCP server by name.
|
|
@@ -36510,7 +36733,7 @@ Example:
|
|
|
36510
36733
|
}
|
|
36511
36734
|
}
|
|
36512
36735
|
});
|
|
36513
|
-
var mcpCommand =
|
|
36736
|
+
var mcpCommand = defineCommand153({
|
|
36514
36737
|
meta: {
|
|
36515
36738
|
name: "mcp",
|
|
36516
36739
|
description: `Third-party tools for this company \u2014 see what's connected, register custom HTTPS MCP endpoints.
|
|
@@ -36536,10 +36759,10 @@ Full guide: __tooling__/docs/tools/baker/mcp.md`
|
|
|
36536
36759
|
});
|
|
36537
36760
|
|
|
36538
36761
|
// src/commands/research/index.ts
|
|
36539
|
-
import { defineCommand as
|
|
36762
|
+
import { defineCommand as defineCommand164 } from "citty";
|
|
36540
36763
|
|
|
36541
36764
|
// src/commands/research/advertisers.ts
|
|
36542
|
-
import { defineCommand as
|
|
36765
|
+
import { defineCommand as defineCommand154 } from "citty";
|
|
36543
36766
|
|
|
36544
36767
|
// src/commands/research/output.ts
|
|
36545
36768
|
var RESEARCH_DATA_NOTE = "Estimates based on third-party SERP data \u2014 not exact figures. Use for directional insights, not precise measurement.";
|
|
@@ -36652,7 +36875,7 @@ var FIELDS3 = {
|
|
|
36652
36875
|
etv: "Estimated traffic value (USD)",
|
|
36653
36876
|
visibility: "SERP visibility score (0-1)"
|
|
36654
36877
|
};
|
|
36655
|
-
var advertisersCommand =
|
|
36878
|
+
var advertisersCommand = defineCommand154({
|
|
36656
36879
|
meta: {
|
|
36657
36880
|
name: "advertisers",
|
|
36658
36881
|
description: `Find domains competing for a keyword in Google SERPs.
|
|
@@ -36699,7 +36922,7 @@ Examples:
|
|
|
36699
36922
|
});
|
|
36700
36923
|
|
|
36701
36924
|
// src/commands/research/autocomplete.ts
|
|
36702
|
-
import { defineCommand as
|
|
36925
|
+
import { defineCommand as defineCommand155 } from "citty";
|
|
36703
36926
|
registerSchema({
|
|
36704
36927
|
command: "research.autocomplete",
|
|
36705
36928
|
description: "Get Google Autocomplete suggestions for a seed keyword. Useful for keyword expansion and discovering what people actually search for. IMPORTANT: If --location and --language are omitted, defaults to United States (us) and English (en).",
|
|
@@ -36722,7 +36945,7 @@ registerSchema({
|
|
|
36722
36945
|
var FIELDS4 = {
|
|
36723
36946
|
suggestion: "Autocomplete suggestion from Google"
|
|
36724
36947
|
};
|
|
36725
|
-
var autocompleteCommand =
|
|
36948
|
+
var autocompleteCommand = defineCommand155({
|
|
36726
36949
|
meta: {
|
|
36727
36950
|
name: "autocomplete",
|
|
36728
36951
|
description: `Get Google Autocomplete suggestions for keyword expansion.
|
|
@@ -36768,7 +36991,7 @@ Examples:
|
|
|
36768
36991
|
});
|
|
36769
36992
|
|
|
36770
36993
|
// src/commands/research/countries.ts
|
|
36771
|
-
import { defineCommand as
|
|
36994
|
+
import { defineCommand as defineCommand156 } from "citty";
|
|
36772
36995
|
registerSchema({
|
|
36773
36996
|
command: "research.countries",
|
|
36774
36997
|
description: "List all supported country codes for --location flag in research commands.",
|
|
@@ -36825,7 +37048,7 @@ var FIELDS5 = {
|
|
|
36825
37048
|
code: "Country code to pass as --location",
|
|
36826
37049
|
name: "Country name"
|
|
36827
37050
|
};
|
|
36828
|
-
var countriesCommand =
|
|
37051
|
+
var countriesCommand = defineCommand156({
|
|
36829
37052
|
meta: {
|
|
36830
37053
|
name: "countries",
|
|
36831
37054
|
description: "List all supported country codes for --location flag."
|
|
@@ -36836,7 +37059,7 @@ var countriesCommand = defineCommand155({
|
|
|
36836
37059
|
});
|
|
36837
37060
|
|
|
36838
37061
|
// src/commands/research/intent.ts
|
|
36839
|
-
import { defineCommand as
|
|
37062
|
+
import { defineCommand as defineCommand157 } from "citty";
|
|
36840
37063
|
registerSchema({
|
|
36841
37064
|
command: "research.intent",
|
|
36842
37065
|
description: "Classify Google Search intent for keywords. Determines if someone searching is looking to buy, research, or navigate. IMPORTANT: If --language is omitted, defaults to English (en). The response includes a query_context object showing which language was used.",
|
|
@@ -36859,7 +37082,7 @@ var FIELDS6 = {
|
|
|
36859
37082
|
intent: "Primary Google Search intent: informational, navigational, commercial, transactional",
|
|
36860
37083
|
probability: "Confidence score 0.0-1.0"
|
|
36861
37084
|
};
|
|
36862
|
-
var intentCommand =
|
|
37085
|
+
var intentCommand = defineCommand157({
|
|
36863
37086
|
meta: {
|
|
36864
37087
|
name: "intent",
|
|
36865
37088
|
description: `Classify Google Search intent for keywords. Returns intent type and confidence.
|
|
@@ -36907,7 +37130,7 @@ Examples:
|
|
|
36907
37130
|
});
|
|
36908
37131
|
|
|
36909
37132
|
// src/commands/research/keyword-gap.ts
|
|
36910
|
-
import { defineCommand as
|
|
37133
|
+
import { defineCommand as defineCommand158 } from "citty";
|
|
36911
37134
|
registerSchema({
|
|
36912
37135
|
command: "research.keyword-gap",
|
|
36913
37136
|
description: "Find keywords a competitor ranks for (organic or paid) that you don't. Discovers expansion opportunities. IMPORTANT: If --location and --language are omitted, defaults to United States (us) and English (en). The response includes a query_context object showing which location/language were used.",
|
|
@@ -36936,7 +37159,7 @@ var FIELDS7 = {
|
|
|
36936
37159
|
cpc: "Cost per click USD",
|
|
36937
37160
|
their_position: "Competitor's ranking position"
|
|
36938
37161
|
};
|
|
36939
|
-
var keywordGapCommand =
|
|
37162
|
+
var keywordGapCommand = defineCommand158({
|
|
36940
37163
|
meta: {
|
|
36941
37164
|
name: "keyword-gap",
|
|
36942
37165
|
description: `Find keywords a competitor has that you don't. Supports pagination via --offset.
|
|
@@ -37010,7 +37233,7 @@ Examples:
|
|
|
37010
37233
|
});
|
|
37011
37234
|
|
|
37012
37235
|
// src/commands/research/keywords-for-site.ts
|
|
37013
|
-
import { defineCommand as
|
|
37236
|
+
import { defineCommand as defineCommand159 } from "citty";
|
|
37014
37237
|
registerSchema({
|
|
37015
37238
|
command: "research.keywords-for-site",
|
|
37016
37239
|
description: "Get keywords a competitor targets in Google. Use --type paid to see only paid keywords, --type organic for organic only. IMPORTANT: If --location and --language are omitted, defaults to United States (us) and English (en). The response includes a query_context object showing which location/language were used.",
|
|
@@ -37043,7 +37266,7 @@ var FIELDS8 = {
|
|
|
37043
37266
|
competition: "LOW, MEDIUM, or HIGH",
|
|
37044
37267
|
competition_index: "Competition score 0-100"
|
|
37045
37268
|
};
|
|
37046
|
-
var keywordsForSiteCommand =
|
|
37269
|
+
var keywordsForSiteCommand = defineCommand159({
|
|
37047
37270
|
meta: {
|
|
37048
37271
|
name: "keywords-for-site",
|
|
37049
37272
|
description: `Get keywords a competitor targets in Google. Use --type to filter paid/organic.
|
|
@@ -37096,7 +37319,7 @@ Examples:
|
|
|
37096
37319
|
});
|
|
37097
37320
|
|
|
37098
37321
|
// src/commands/research/languages.ts
|
|
37099
|
-
import { defineCommand as
|
|
37322
|
+
import { defineCommand as defineCommand160 } from "citty";
|
|
37100
37323
|
registerSchema({
|
|
37101
37324
|
command: "research.languages",
|
|
37102
37325
|
description: "List all supported language codes for --language flag in research commands.",
|
|
@@ -37126,7 +37349,7 @@ var FIELDS9 = {
|
|
|
37126
37349
|
code: "Language code to pass as --language",
|
|
37127
37350
|
name: "Language name (also accepted by --language)"
|
|
37128
37351
|
};
|
|
37129
|
-
var languagesCommand2 =
|
|
37352
|
+
var languagesCommand2 = defineCommand160({
|
|
37130
37353
|
meta: {
|
|
37131
37354
|
name: "languages",
|
|
37132
37355
|
description: "List all supported language codes for --language flag."
|
|
@@ -37137,7 +37360,7 @@ var languagesCommand2 = defineCommand159({
|
|
|
37137
37360
|
});
|
|
37138
37361
|
|
|
37139
37362
|
// src/commands/research/lighthouse.ts
|
|
37140
|
-
import { defineCommand as
|
|
37363
|
+
import { defineCommand as defineCommand161 } from "citty";
|
|
37141
37364
|
registerSchema({
|
|
37142
37365
|
command: "research.lighthouse",
|
|
37143
37366
|
description: "Landing page performance audit. Returns metrics that affect Google Ads Quality Score and CPC.",
|
|
@@ -37156,7 +37379,7 @@ var FIELDS10 = {
|
|
|
37156
37379
|
speed_index_ms: "Speed Index in ms (good: < 3400)",
|
|
37157
37380
|
interactive_ms: "Time to Interactive in ms (good: < 3800)"
|
|
37158
37381
|
};
|
|
37159
|
-
var lighthouseCommand =
|
|
37382
|
+
var lighthouseCommand = defineCommand161({
|
|
37160
37383
|
meta: {
|
|
37161
37384
|
name: "lighthouse",
|
|
37162
37385
|
description: `Landing page performance audit. Metrics affecting Google Ads Quality Score.
|
|
@@ -37194,7 +37417,7 @@ Examples:
|
|
|
37194
37417
|
});
|
|
37195
37418
|
|
|
37196
37419
|
// src/commands/research/relevant-pages.ts
|
|
37197
|
-
import { defineCommand as
|
|
37420
|
+
import { defineCommand as defineCommand162 } from "citty";
|
|
37198
37421
|
registerSchema({
|
|
37199
37422
|
command: "research.relevant-pages",
|
|
37200
37423
|
description: "Get the top pages of a competitor domain with organic traffic and ranking data. Shows which pages drive the most traffic. IMPORTANT: If --location and --language are omitted, defaults to United States (us) and English (en).",
|
|
@@ -37220,7 +37443,7 @@ var FIELDS11 = {
|
|
|
37220
37443
|
keywords: "Total organic keywords the page ranks for",
|
|
37221
37444
|
top_10: "Keywords in positions 1-10"
|
|
37222
37445
|
};
|
|
37223
|
-
var relevantPagesCommand =
|
|
37446
|
+
var relevantPagesCommand = defineCommand162({
|
|
37224
37447
|
meta: {
|
|
37225
37448
|
name: "relevant-pages",
|
|
37226
37449
|
description: `Get the top pages of a competitor domain with traffic data.
|
|
@@ -37266,7 +37489,7 @@ Examples:
|
|
|
37266
37489
|
});
|
|
37267
37490
|
|
|
37268
37491
|
// src/commands/research/web.ts
|
|
37269
|
-
import { defineCommand as
|
|
37492
|
+
import { defineCommand as defineCommand163 } from "citty";
|
|
37270
37493
|
registerSchema({
|
|
37271
37494
|
command: "research.web",
|
|
37272
37495
|
description: "Search the web with AI to answer marketing questions \u2014 competitors, ICP, pricing, pain points, market trends. Three depth levels: medium (quick, default), high (thorough), xhigh (exhaustive deep research).",
|
|
@@ -37317,7 +37540,7 @@ async function runDeepResearch(question) {
|
|
|
37317
37540
|
}
|
|
37318
37541
|
throw new Error("Deep research timed out");
|
|
37319
37542
|
}
|
|
37320
|
-
var webCommand =
|
|
37543
|
+
var webCommand = defineCommand163({
|
|
37321
37544
|
meta: {
|
|
37322
37545
|
name: "web",
|
|
37323
37546
|
description: `Search the web with AI to answer any open-ended marketing question. Uses live internet data via Google Search.
|
|
@@ -37377,7 +37600,7 @@ Examples:
|
|
|
37377
37600
|
});
|
|
37378
37601
|
|
|
37379
37602
|
// src/commands/research/index.ts
|
|
37380
|
-
var researchCommand =
|
|
37603
|
+
var researchCommand = defineCommand164({
|
|
37381
37604
|
meta: {
|
|
37382
37605
|
name: "research",
|
|
37383
37606
|
description: `Competitive intelligence and AI-powered research commands.
|
|
@@ -37418,10 +37641,10 @@ Full guide: __tooling__/docs/tools/baker/research.md`
|
|
|
37418
37641
|
});
|
|
37419
37642
|
|
|
37420
37643
|
// src/commands/scheduled-actions/index.ts
|
|
37421
|
-
import { defineCommand as
|
|
37644
|
+
import { defineCommand as defineCommand171 } from "citty";
|
|
37422
37645
|
|
|
37423
37646
|
// src/commands/scheduled-actions/create.ts
|
|
37424
|
-
import { defineCommand as
|
|
37647
|
+
import { defineCommand as defineCommand165 } from "citty";
|
|
37425
37648
|
|
|
37426
37649
|
// src/commands/scheduled-actions/shared.ts
|
|
37427
37650
|
var TEMP_SCHEDULED_ACTION_PREFIX = "temp_sched_";
|
|
@@ -37536,7 +37759,7 @@ registerSchema({
|
|
|
37536
37759
|
prompt: { type: "string", description: "Additional prompt instructions for the spawned agent", required: false }
|
|
37537
37760
|
}
|
|
37538
37761
|
});
|
|
37539
|
-
var createCommand2 =
|
|
37762
|
+
var createCommand2 = defineCommand165({
|
|
37540
37763
|
meta: {
|
|
37541
37764
|
name: "create",
|
|
37542
37765
|
description: 'Stage a scheduled action. Example: baker scheduled-actions create --name "Weekly report" --description "..." --cron "0 9 * * MON"'
|
|
@@ -37585,7 +37808,7 @@ var createCommand2 = defineCommand164({
|
|
|
37585
37808
|
});
|
|
37586
37809
|
|
|
37587
37810
|
// src/commands/scheduled-actions/delete.ts
|
|
37588
|
-
import { defineCommand as
|
|
37811
|
+
import { defineCommand as defineCommand166 } from "citty";
|
|
37589
37812
|
registerSchema({
|
|
37590
37813
|
command: "scheduled-actions.delete",
|
|
37591
37814
|
description: "Stage deletion of a published scheduled action or cancellation of a temp_sched_* draft creation.",
|
|
@@ -37593,7 +37816,7 @@ registerSchema({
|
|
|
37593
37816
|
id: { type: "string", description: "Published scheduled action ID or temp_sched_* draft ID", required: true }
|
|
37594
37817
|
}
|
|
37595
37818
|
});
|
|
37596
|
-
var deleteCommand2 =
|
|
37819
|
+
var deleteCommand2 = defineCommand166({
|
|
37597
37820
|
meta: {
|
|
37598
37821
|
name: "delete",
|
|
37599
37822
|
description: "Stage scheduled action deletion. Example: baker scheduled-actions delete <id-or-temp_sched_id>"
|
|
@@ -37622,7 +37845,7 @@ var deleteCommand2 = defineCommand165({
|
|
|
37622
37845
|
});
|
|
37623
37846
|
|
|
37624
37847
|
// src/commands/scheduled-actions/get.ts
|
|
37625
|
-
import { defineCommand as
|
|
37848
|
+
import { defineCommand as defineCommand167 } from "citty";
|
|
37626
37849
|
registerSchema({
|
|
37627
37850
|
command: "scheduled-actions.get",
|
|
37628
37851
|
description: "Get a published scheduled action or a temp_sched_* draft-created scheduled action.",
|
|
@@ -37631,7 +37854,7 @@ registerSchema({
|
|
|
37631
37854
|
chat: { type: "string", description: CHAT_READ_ARG.description, required: false }
|
|
37632
37855
|
}
|
|
37633
37856
|
});
|
|
37634
|
-
var getCommand3 =
|
|
37857
|
+
var getCommand3 = defineCommand167({
|
|
37635
37858
|
meta: {
|
|
37636
37859
|
name: "get",
|
|
37637
37860
|
description: "Get a scheduled action. Example: baker scheduled-actions get <id-or-temp_sched_id>"
|
|
@@ -37670,7 +37893,7 @@ var getCommand3 = defineCommand166({
|
|
|
37670
37893
|
});
|
|
37671
37894
|
|
|
37672
37895
|
// src/commands/scheduled-actions/list.ts
|
|
37673
|
-
import { defineCommand as
|
|
37896
|
+
import { defineCommand as defineCommand168 } from "citty";
|
|
37674
37897
|
registerSchema({
|
|
37675
37898
|
command: "scheduled-actions.list",
|
|
37676
37899
|
description: "List published scheduled actions. Includes draft state when BAKER_CHAT_ID is set, or --chat <id> to read an earlier chat's staged schedules instead.",
|
|
@@ -37678,7 +37901,7 @@ registerSchema({
|
|
|
37678
37901
|
chat: { type: "string", description: CHAT_READ_ARG.description, required: false }
|
|
37679
37902
|
}
|
|
37680
37903
|
});
|
|
37681
|
-
var listCommand14 =
|
|
37904
|
+
var listCommand14 = defineCommand168({
|
|
37682
37905
|
meta: {
|
|
37683
37906
|
name: "list",
|
|
37684
37907
|
description: "List scheduled actions. Includes staged draft ops when BAKER_CHAT_ID is set, or --chat <id> to read an earlier chat's staged schedules instead."
|
|
@@ -37701,7 +37924,7 @@ var listCommand14 = defineCommand167({
|
|
|
37701
37924
|
});
|
|
37702
37925
|
|
|
37703
37926
|
// src/commands/scheduled-actions/trigger.ts
|
|
37704
|
-
import { defineCommand as
|
|
37927
|
+
import { defineCommand as defineCommand169 } from "citty";
|
|
37705
37928
|
registerSchema({
|
|
37706
37929
|
command: "scheduled-actions.trigger",
|
|
37707
37930
|
description: "Immediately trigger a published scheduled action. Does not require BAKER_CHAT_ID and rejects temp_sched_* IDs.",
|
|
@@ -37709,7 +37932,7 @@ registerSchema({
|
|
|
37709
37932
|
id: { type: "string", description: "Published scheduled action ID", required: true }
|
|
37710
37933
|
}
|
|
37711
37934
|
});
|
|
37712
|
-
var triggerCommand =
|
|
37935
|
+
var triggerCommand = defineCommand169({
|
|
37713
37936
|
meta: {
|
|
37714
37937
|
name: "trigger",
|
|
37715
37938
|
description: "Immediately trigger a published scheduled action. Example: baker scheduled-actions trigger <id>"
|
|
@@ -37746,7 +37969,7 @@ var triggerCommand = defineCommand168({
|
|
|
37746
37969
|
});
|
|
37747
37970
|
|
|
37748
37971
|
// src/commands/scheduled-actions/update.ts
|
|
37749
|
-
import { defineCommand as
|
|
37972
|
+
import { defineCommand as defineCommand170 } from "citty";
|
|
37750
37973
|
registerSchema({
|
|
37751
37974
|
command: "scheduled-actions.update",
|
|
37752
37975
|
description: "Stage an update to a published scheduled action or temp_sched_* draft-created scheduled action.",
|
|
@@ -37771,7 +37994,7 @@ registerSchema({
|
|
|
37771
37994
|
prompt: { type: "string", description: "Replacement additional spawned-agent instructions", required: false }
|
|
37772
37995
|
}
|
|
37773
37996
|
});
|
|
37774
|
-
var updateCommand2 =
|
|
37997
|
+
var updateCommand2 = defineCommand170({
|
|
37775
37998
|
meta: {
|
|
37776
37999
|
name: "update",
|
|
37777
38000
|
description: "Stage a scheduled action update. Example: baker scheduled-actions update <id> --enabled false"
|
|
@@ -37842,7 +38065,7 @@ var updateCommand2 = defineCommand169({
|
|
|
37842
38065
|
});
|
|
37843
38066
|
|
|
37844
38067
|
// src/commands/scheduled-actions/index.ts
|
|
37845
|
-
var scheduledActionsCommand =
|
|
38068
|
+
var scheduledActionsCommand = defineCommand171({
|
|
37846
38069
|
meta: {
|
|
37847
38070
|
name: "scheduled-actions",
|
|
37848
38071
|
description: `Manage Scheduled Actions. Subcommands: list, get, create, update, delete, trigger.
|
|
@@ -37869,14 +38092,14 @@ Full guide: __tooling__/docs/tools/baker/scheduled-actions.md`
|
|
|
37869
38092
|
});
|
|
37870
38093
|
|
|
37871
38094
|
// src/commands/schema.ts
|
|
37872
|
-
import { defineCommand as
|
|
38095
|
+
import { defineCommand as defineCommand172 } from "citty";
|
|
37873
38096
|
function narrowToFamily(commandName, available) {
|
|
37874
38097
|
const segments = commandName.split(".");
|
|
37875
38098
|
const prefix = segments[0] === "ads" && segments[1] ? `ads.${segments[1]}.` : `${segments[0]}.`;
|
|
37876
38099
|
const siblings = available.filter((name) => name.startsWith(prefix));
|
|
37877
38100
|
return siblings.length > 0 ? siblings : available;
|
|
37878
38101
|
}
|
|
37879
|
-
var schemaCommand =
|
|
38102
|
+
var schemaCommand = defineCommand172({
|
|
37880
38103
|
meta: {
|
|
37881
38104
|
name: "schema",
|
|
37882
38105
|
description: "Inspect command argument schemas (for AI agent introspection). Lists all commands if no argument given. Example: baker schema images.search"
|
|
@@ -37920,14 +38143,14 @@ var schemaCommand = defineCommand171({
|
|
|
37920
38143
|
});
|
|
37921
38144
|
|
|
37922
38145
|
// src/commands/studio/index.ts
|
|
37923
|
-
import { defineCommand as
|
|
38146
|
+
import { defineCommand as defineCommand181 } from "citty";
|
|
37924
38147
|
|
|
37925
38148
|
// src/commands/studio/animate.ts
|
|
37926
|
-
import { defineCommand as
|
|
38149
|
+
import { defineCommand as defineCommand173 } from "citty";
|
|
37927
38150
|
|
|
37928
38151
|
// src/commands/studio/batch.ts
|
|
37929
38152
|
function projectBatch(generation, full) {
|
|
37930
|
-
const
|
|
38153
|
+
const compact2 = {
|
|
37931
38154
|
generationId: generation.generationId,
|
|
37932
38155
|
kind: generation.kind,
|
|
37933
38156
|
status: generation.status,
|
|
@@ -37944,9 +38167,9 @@ function projectBatch(generation, full) {
|
|
|
37944
38167
|
...variant.error ? { error: variant.error } : {}
|
|
37945
38168
|
}))
|
|
37946
38169
|
};
|
|
37947
|
-
if (!full) return
|
|
38170
|
+
if (!full) return compact2;
|
|
37948
38171
|
return {
|
|
37949
|
-
...
|
|
38172
|
+
...compact2,
|
|
37950
38173
|
...generation.skillId ? { skillId: generation.skillId } : {},
|
|
37951
38174
|
...generation.imageSettings ? { imageSettings: generation.imageSettings } : {},
|
|
37952
38175
|
...generation.clipSettings ? { clipSettings: generation.clipSettings } : {},
|
|
@@ -38012,7 +38235,7 @@ function resolveMaxWaitMs(wait, maxWait, defaultMs) {
|
|
|
38012
38235
|
const parsed = Number(maxWait);
|
|
38013
38236
|
return Number.isFinite(parsed) && parsed >= 0 ? parsed : defaultMs;
|
|
38014
38237
|
}
|
|
38015
|
-
var
|
|
38238
|
+
var POLL_INTERVAL_MS6 = 3e3;
|
|
38016
38239
|
var defaultPollDeps = {
|
|
38017
38240
|
get: async (generationId) => {
|
|
38018
38241
|
const response = await apiGet(`/api/studio/generations/${generationId}`);
|
|
@@ -38025,7 +38248,7 @@ async function pollBatch(generationId, maxWaitMs, deps = defaultPollDeps) {
|
|
|
38025
38248
|
while (Date.now() < deadline) {
|
|
38026
38249
|
const generation = await deps.get(generationId);
|
|
38027
38250
|
if (generation.status !== "running") return generation;
|
|
38028
|
-
await deps.sleep(
|
|
38251
|
+
await deps.sleep(POLL_INTERVAL_MS6);
|
|
38029
38252
|
}
|
|
38030
38253
|
return null;
|
|
38031
38254
|
}
|
|
@@ -38368,7 +38591,7 @@ function costHintsFor(body) {
|
|
|
38368
38591
|
}
|
|
38369
38592
|
return hints;
|
|
38370
38593
|
}
|
|
38371
|
-
var animateCommand =
|
|
38594
|
+
var animateCommand = defineCommand173({
|
|
38372
38595
|
meta: {
|
|
38373
38596
|
name: "animate",
|
|
38374
38597
|
description: "Render a clip. With an image the look is already fixed, so the prompt describes MOVEMENT \u2014 what the camera does, what the subject does, in what order. With --from text there is no image and the prompt is the whole shot.\n\nA rendered clip is NOT usable anywhere until you keep it: `baker studio keep <id> --slot N` is what puts it in the video library. Takes nobody keeps are never ingested, which is what makes a rejected batch cheap.\n\nFor anything longer than 15 seconds, or to build on footage that already exists, use --model bytedance/seedance-2.5: it renders 4-30s and is the only model that reads an existing clip or an existing soundtrack.\n\nExamples:\n baker studio animate 'slow push in, model turns to camera and smiles' --image j57abc123def456ghi789\n baker studio animate 'handheld drift right, steam rising from the cup' --image './out/hero.png' --duration 6 --quality 1080p\n baker studio animate 'product rotates once on a turntable' --image j57abc\u2026,j57def\u2026 --from references\n baker studio animate 'she keeps walking, camera stays with her, then she stops and looks up' --image j57abc\u2026 --from references --from-clip j57batch\u2026:0 --model bytedance/seedance-2.5 --duration 20\n baker studio animate 'hold on the product, then a slow push-in' --from references --from-video j57vid\u2026 --model bytedance/seedance-2.5\n baker studio animate 'slow drone pull-back over a solar farm at golden hour, no people' --from text --model bytedance/seedance-2.5 --duration 12"
|
|
@@ -38487,7 +38710,7 @@ var animateCommand = defineCommand172({
|
|
|
38487
38710
|
});
|
|
38488
38711
|
|
|
38489
38712
|
// src/commands/studio/generate.ts
|
|
38490
|
-
import { defineCommand as
|
|
38713
|
+
import { defineCommand as defineCommand174 } from "citty";
|
|
38491
38714
|
var MODEL_LIST2 = IMAGE_MODEL_IDS;
|
|
38492
38715
|
var DEFAULT_MAX_WAIT_MS2 = 24e4;
|
|
38493
38716
|
registerSchema({
|
|
@@ -38617,7 +38840,7 @@ function buildGenerateBody(args, prompt) {
|
|
|
38617
38840
|
}
|
|
38618
38841
|
return body;
|
|
38619
38842
|
}
|
|
38620
|
-
var generateCommand =
|
|
38843
|
+
var generateCommand = defineCommand174({
|
|
38621
38844
|
meta: {
|
|
38622
38845
|
name: "generate",
|
|
38623
38846
|
description: "Start here to make an image. Renders 1-8 takes of one brief, ingests each into the media library as it lands, and shows the batch in the dashboard Studio next to the ones the client ran.\n\nModel choice: google/gemini-3.1-flash-image-preview (default \u2014 fast, best at editing a reference and at extreme ratios), google/gemini-3-pro-image-preview (highest fidelity, slower), openai/gpt-image-2 (photoreal and the cleanest in-image text \u2014 no --image-size, no 4:5 / 5:4), recraft/recraft-v4.1-pro-vector (vector/flat marks with palette control).\n\n--reference is the biggest quality lever there is: a real logo, product shot, Pinterest pin or sandbox screenshot beats any amount of adjectives.\n\nExamples:\n baker studio generate 'matte black bottle on wet marble, hard studio light, 35mm' --aspect-ratio 3:2 --count 3\n baker studio generate 'this bottle on a sunlit kitchen counter' --reference './src/brand/product.png,https://\u2026/kitchen.jpg'\n baker studio generate 'founder-style selfie, kitchen background, natural light' --skill ugc-selfie-hook\n baker studio generate 'flat geometric mascot, brand palette' --model recraft/recraft-v4.1-pro-vector --rgb-colors '[[10,10,10],[255,80,0]]'"
|
|
@@ -38695,7 +38918,7 @@ var generateCommand = defineCommand173({
|
|
|
38695
38918
|
});
|
|
38696
38919
|
|
|
38697
38920
|
// src/commands/studio/get.ts
|
|
38698
|
-
import { defineCommand as
|
|
38921
|
+
import { defineCommand as defineCommand175 } from "citty";
|
|
38699
38922
|
registerSchema({
|
|
38700
38923
|
command: "studio.get",
|
|
38701
38924
|
description: "Read one Studio batch: every take, where it lives, and why a take is missing. This is how you pick up a batch that was still rendering when the start command returned.",
|
|
@@ -38704,7 +38927,7 @@ registerSchema({
|
|
|
38704
38927
|
full: { type: "boolean", description: "Include settings, references and attribution", required: false }
|
|
38705
38928
|
}
|
|
38706
38929
|
});
|
|
38707
|
-
var getCommand4 =
|
|
38930
|
+
var getCommand4 = defineCommand175({
|
|
38708
38931
|
meta: {
|
|
38709
38932
|
name: "get",
|
|
38710
38933
|
description: "Read one Studio batch \u2014 the takes, their urls, whether each is in the library, and the reason for any that failed.\n\nExample: baker studio get j57abc123def456ghi789\nExample: baker studio get j57abc123def456ghi789 --full"
|
|
@@ -38733,7 +38956,7 @@ var getCommand4 = defineCommand174({
|
|
|
38733
38956
|
});
|
|
38734
38957
|
|
|
38735
38958
|
// src/commands/studio/improve.ts
|
|
38736
|
-
import { defineCommand as
|
|
38959
|
+
import { defineCommand as defineCommand176 } from "citty";
|
|
38737
38960
|
var DESCRIPTION = "Sharpen a rough brief into directed art direction \u2014 the same rewrite the client gets from the wand in the Studio prompt bar. Reach for it when you are relaying the CLIENT's own words and want them shaped without substituting your voice; when you are writing the art direction yourself, just write it, because you will do a better job than this does.";
|
|
38738
38961
|
registerSchema({
|
|
38739
38962
|
command: "studio.improve",
|
|
@@ -38758,7 +38981,7 @@ registerSchema({
|
|
|
38758
38981
|
}
|
|
38759
38982
|
}
|
|
38760
38983
|
});
|
|
38761
|
-
var improveCommand =
|
|
38984
|
+
var improveCommand = defineCommand176({
|
|
38762
38985
|
meta: {
|
|
38763
38986
|
name: "improve",
|
|
38764
38987
|
description: `${DESCRIPTION}
|
|
@@ -38802,7 +39025,7 @@ Examples:
|
|
|
38802
39025
|
});
|
|
38803
39026
|
|
|
38804
39027
|
// src/commands/studio/keep.ts
|
|
38805
|
-
import { defineCommand as
|
|
39028
|
+
import { defineCommand as defineCommand177 } from "citty";
|
|
38806
39029
|
registerSchema({
|
|
38807
39030
|
command: "studio.keep",
|
|
38808
39031
|
description: "Mark one take as the keeper. For an image this stars it, so the client reviewing the batch sees which one you used. For a CLIP it is the step that puts it in the video library \u2014 until then the clip cannot be used in a canvas, a landing, or an ad.",
|
|
@@ -38812,7 +39035,7 @@ registerSchema({
|
|
|
38812
39035
|
undo: { type: "boolean", description: "Un-star an image, or take a kept clip back out", required: false }
|
|
38813
39036
|
}
|
|
38814
39037
|
});
|
|
38815
|
-
var keepCommand =
|
|
39038
|
+
var keepCommand = defineCommand177({
|
|
38816
39039
|
meta: {
|
|
38817
39040
|
name: "keep",
|
|
38818
39041
|
description: "Mark one take as the keeper. An image gets starred (it was already in the library); a clip gets INGESTED into the video library, which is what makes it usable anywhere else.\n\nExample: baker studio keep j57abc123def456ghi789 --slot 2\nExample: baker studio keep j57abc123def456ghi789 --slot 2 --undo"
|
|
@@ -38863,7 +39086,7 @@ var keepCommand = defineCommand176({
|
|
|
38863
39086
|
});
|
|
38864
39087
|
|
|
38865
39088
|
// src/commands/studio/list.ts
|
|
38866
|
-
import { defineCommand as
|
|
39089
|
+
import { defineCommand as defineCommand178 } from "citty";
|
|
38867
39090
|
registerSchema({
|
|
38868
39091
|
command: "studio.list",
|
|
38869
39092
|
description: "Recent Studio batches for THIS conversation, newest first \u2014 what you have already generated, so you re-use a take instead of paying for it twice. `--all` widens it to everything the company generated, including what people ran themselves in the dashboard.",
|
|
@@ -38874,7 +39097,7 @@ registerSchema({
|
|
|
38874
39097
|
full: { type: "boolean", description: "Include settings, references and attribution", required: false }
|
|
38875
39098
|
}
|
|
38876
39099
|
});
|
|
38877
|
-
var listCommand15 =
|
|
39100
|
+
var listCommand15 = defineCommand178({
|
|
38878
39101
|
meta: {
|
|
38879
39102
|
name: "list",
|
|
38880
39103
|
description: "Recent Studio batches, newest first. Scoped to this conversation unless you pass --all.\n\nExample: baker studio list\nExample: baker studio list --kind video --limit 5\nExample: baker studio list --all # includes batches the client ran in the dashboard"
|
|
@@ -38908,7 +39131,7 @@ var listCommand15 = defineCommand177({
|
|
|
38908
39131
|
});
|
|
38909
39132
|
|
|
38910
39133
|
// src/commands/studio/models.ts
|
|
38911
|
-
import { defineCommand as
|
|
39134
|
+
import { defineCommand as defineCommand179 } from "citty";
|
|
38912
39135
|
var DESCRIPTION2 = "What each Studio model actually accepts: its shapes, resolutions, clip lengths, prompt character cap, how many reference images it takes, and which knobs it has. Read this before a batch you care about \u2014 the models disagree far more than they look like they do, and a setting the chosen model does not have is REFUSED, not ignored.";
|
|
38913
39136
|
registerSchema({
|
|
38914
39137
|
command: "studio.models",
|
|
@@ -38995,7 +39218,7 @@ function buildModelCards(kind, model) {
|
|
|
38995
39218
|
const selected = model ? ids.filter((id) => id === model) : ids;
|
|
38996
39219
|
return selected.map((id) => build(id));
|
|
38997
39220
|
}
|
|
38998
|
-
var modelsCommand =
|
|
39221
|
+
var modelsCommand = defineCommand179({
|
|
38999
39222
|
meta: {
|
|
39000
39223
|
name: "models",
|
|
39001
39224
|
description: `${DESCRIPTION2}
|
|
@@ -39042,13 +39265,13 @@ Examples:
|
|
|
39042
39265
|
});
|
|
39043
39266
|
|
|
39044
39267
|
// src/commands/studio/skills.ts
|
|
39045
|
-
import { defineCommand as
|
|
39268
|
+
import { defineCommand as defineCommand180 } from "citty";
|
|
39046
39269
|
registerSchema({
|
|
39047
39270
|
command: "studio.skills",
|
|
39048
39271
|
description: "The craft directions `studio generate --skill <id>` accepts. Each one carries directed art direction plus the model, shape and take count it wants, so you pick a look by name instead of writing the boilerplate yourself.",
|
|
39049
39272
|
args: {}
|
|
39050
39273
|
});
|
|
39051
|
-
var skillsCommand =
|
|
39274
|
+
var skillsCommand = defineCommand180({
|
|
39052
39275
|
meta: {
|
|
39053
39276
|
name: "skills",
|
|
39054
39277
|
description: "List the craft directions available to `baker studio generate --skill <id>` \u2014 what each one is for, whether it wants a reference image, and the model/shape/count it defaults to.\n\nExample: baker studio skills"
|
|
@@ -39072,7 +39295,7 @@ var skillsCommand = defineCommand179({
|
|
|
39072
39295
|
});
|
|
39073
39296
|
|
|
39074
39297
|
// src/commands/studio/index.ts
|
|
39075
|
-
var studioCommand =
|
|
39298
|
+
var studioCommand = defineCommand181({
|
|
39076
39299
|
meta: {
|
|
39077
39300
|
name: "studio",
|
|
39078
39301
|
description: `Make new imagery and clips. Every batch is recorded and shows up in the dashboard Studio for the client to review, labelled with this conversation.
|
|
@@ -39115,10 +39338,10 @@ Full guide: __tooling__/docs/tools/baker/studio.md`
|
|
|
39115
39338
|
});
|
|
39116
39339
|
|
|
39117
39340
|
// src/commands/tag-manager/index.ts
|
|
39118
|
-
import { defineCommand as
|
|
39341
|
+
import { defineCommand as defineCommand185 } from "citty";
|
|
39119
39342
|
|
|
39120
39343
|
// src/commands/tag-manager/draft.ts
|
|
39121
|
-
import { defineCommand as
|
|
39344
|
+
import { defineCommand as defineCommand182 } from "citty";
|
|
39122
39345
|
|
|
39123
39346
|
// src/commands/tag-manager/shared.ts
|
|
39124
39347
|
import { readFileSync as readFileSync13 } from "fs";
|
|
@@ -39241,13 +39464,13 @@ registerSchema({
|
|
|
39241
39464
|
chat: { type: "string", description: CHAT_READ_ARG.description, required: false }
|
|
39242
39465
|
}
|
|
39243
39466
|
});
|
|
39244
|
-
var draftCommand4 =
|
|
39467
|
+
var draftCommand4 = defineCommand182({
|
|
39245
39468
|
meta: {
|
|
39246
39469
|
name: "draft",
|
|
39247
39470
|
description: "List, show, amend, remove, or clear staged Tag Manager changes for this chat. `list` and `show` take --chat <id> to read an earlier chat's changes instead."
|
|
39248
39471
|
},
|
|
39249
39472
|
subCommands: {
|
|
39250
|
-
list:
|
|
39473
|
+
list: defineCommand182({
|
|
39251
39474
|
meta: {
|
|
39252
39475
|
name: "list",
|
|
39253
39476
|
description: "Review everything staged on this chat (--json for the raw envelope)"
|
|
@@ -39260,7 +39483,7 @@ var draftCommand4 = defineCommand181({
|
|
|
39260
39483
|
await draftList2(args.json === true, args.chat);
|
|
39261
39484
|
}
|
|
39262
39485
|
}),
|
|
39263
|
-
show:
|
|
39486
|
+
show: defineCommand182({
|
|
39264
39487
|
meta: {
|
|
39265
39488
|
name: "show",
|
|
39266
39489
|
description: "Print the full staged payload for one change \u2014 the receipt to verify it looks right before publish (never truncated)."
|
|
@@ -39277,7 +39500,7 @@ var draftCommand4 = defineCommand181({
|
|
|
39277
39500
|
);
|
|
39278
39501
|
}
|
|
39279
39502
|
}),
|
|
39280
|
-
amend:
|
|
39503
|
+
amend: defineCommand182({
|
|
39281
39504
|
meta: {
|
|
39282
39505
|
name: "amend",
|
|
39283
39506
|
description: "Update a staged change in place \u2014 merges a JSON patch into its payload (objects deep-merge, null deletes a key, arrays/scalars replace) and re-validates. Use this instead of remove + re-create."
|
|
@@ -39294,7 +39517,7 @@ var draftCommand4 = defineCommand181({
|
|
|
39294
39517
|
});
|
|
39295
39518
|
}
|
|
39296
39519
|
}),
|
|
39297
|
-
remove:
|
|
39520
|
+
remove: defineCommand182({
|
|
39298
39521
|
meta: { name: "remove", description: "Remove one staged change (cascades to anything depending on it)" },
|
|
39299
39522
|
args: { ref: { type: "positional", description: "Staged ref (gtm_temp_*) or target", required: false } },
|
|
39300
39523
|
run: async ({ args }) => {
|
|
@@ -39303,7 +39526,7 @@ var draftCommand4 = defineCommand181({
|
|
|
39303
39526
|
});
|
|
39304
39527
|
}
|
|
39305
39528
|
}),
|
|
39306
|
-
clear:
|
|
39529
|
+
clear: defineCommand182({
|
|
39307
39530
|
meta: { name: "clear", description: "Discard all Tag Manager changes staged on this chat" },
|
|
39308
39531
|
run: async () => {
|
|
39309
39532
|
await draftAction3("/api/tag-manager/draft/clear", {});
|
|
@@ -39313,7 +39536,7 @@ var draftCommand4 = defineCommand181({
|
|
|
39313
39536
|
});
|
|
39314
39537
|
|
|
39315
39538
|
// src/commands/tag-manager/read.ts
|
|
39316
|
-
import { defineCommand as
|
|
39539
|
+
import { defineCommand as defineCommand183 } from "citty";
|
|
39317
39540
|
registerSchema({
|
|
39318
39541
|
command: "tagManager.containers",
|
|
39319
39542
|
description: "List the Google Tag Manager containers this company's connection can reach. Every container the company connected is flagged `connected: true` \u2014 there can be several, and Baker may read and change all of them. Start here to confirm which containers you are managing.",
|
|
@@ -39354,7 +39577,7 @@ function containersHints(containers) {
|
|
|
39354
39577
|
}))
|
|
39355
39578
|
});
|
|
39356
39579
|
}
|
|
39357
|
-
var containersCommand =
|
|
39580
|
+
var containersCommand = defineCommand183({
|
|
39358
39581
|
meta: {
|
|
39359
39582
|
name: "containers",
|
|
39360
39583
|
description: `List Tag Manager containers reachable by this company's connection.
|
|
@@ -39371,7 +39594,7 @@ Start here:
|
|
|
39371
39594
|
}
|
|
39372
39595
|
}
|
|
39373
39596
|
});
|
|
39374
|
-
var readCommand =
|
|
39597
|
+
var readCommand = defineCommand183({
|
|
39375
39598
|
meta: {
|
|
39376
39599
|
name: "read",
|
|
39377
39600
|
description: `Read the current contents of the Tag Manager container \u2014 always do this before staging changes.
|
|
@@ -39413,7 +39636,7 @@ Examples:
|
|
|
39413
39636
|
});
|
|
39414
39637
|
|
|
39415
39638
|
// src/commands/tag-manager/write-commands.ts
|
|
39416
|
-
import { defineCommand as
|
|
39639
|
+
import { defineCommand as defineCommand184 } from "citty";
|
|
39417
39640
|
var CONTAINER_ARG_DESCRIPTION = "Numeric container id (optional only when one container is connected \u2014 run `baker tag-manager containers`)";
|
|
39418
39641
|
var ENTITIES = [
|
|
39419
39642
|
{
|
|
@@ -39469,10 +39692,10 @@ for (const { entity, noun, createHint } of ENTITIES) {
|
|
|
39469
39692
|
});
|
|
39470
39693
|
}
|
|
39471
39694
|
function entityCommand(entity, noun, example) {
|
|
39472
|
-
return
|
|
39695
|
+
return defineCommand184({
|
|
39473
39696
|
meta: { name: entity, description: `Stage ${noun} changes on this chat's Tag Manager draft` },
|
|
39474
39697
|
subCommands: {
|
|
39475
|
-
create:
|
|
39698
|
+
create: defineCommand184({
|
|
39476
39699
|
meta: {
|
|
39477
39700
|
name: "create",
|
|
39478
39701
|
description: `Stage a new ${noun}
|
|
@@ -39494,7 +39717,7 @@ Examples:
|
|
|
39494
39717
|
});
|
|
39495
39718
|
}
|
|
39496
39719
|
}),
|
|
39497
|
-
update:
|
|
39720
|
+
update: defineCommand184({
|
|
39498
39721
|
meta: {
|
|
39499
39722
|
name: "update",
|
|
39500
39723
|
description: `Stage an update to an existing ${noun} (pass its id or path)`
|
|
@@ -39514,7 +39737,7 @@ Examples:
|
|
|
39514
39737
|
});
|
|
39515
39738
|
}
|
|
39516
39739
|
}),
|
|
39517
|
-
delete:
|
|
39740
|
+
delete: defineCommand184({
|
|
39518
39741
|
meta: { name: "delete", description: `Stage the deletion of a ${noun} (pass its id or path)` },
|
|
39519
39742
|
args: {
|
|
39520
39743
|
id: { type: "positional", description: `${noun} id or path`, required: false },
|
|
@@ -39555,7 +39778,7 @@ function builtinTypes(args) {
|
|
|
39555
39778
|
}
|
|
39556
39779
|
return raw.split(",").map((entry) => entry.trim());
|
|
39557
39780
|
}
|
|
39558
|
-
var builtinCommand =
|
|
39781
|
+
var builtinCommand = defineCommand184({
|
|
39559
39782
|
meta: {
|
|
39560
39783
|
name: "builtin",
|
|
39561
39784
|
description: `Enable or disable built-in variables
|
|
@@ -39565,7 +39788,7 @@ Examples:
|
|
|
39565
39788
|
baker tag-manager builtin disable --types formId`
|
|
39566
39789
|
},
|
|
39567
39790
|
subCommands: {
|
|
39568
|
-
enable:
|
|
39791
|
+
enable: defineCommand184({
|
|
39569
39792
|
meta: { name: "enable", description: "Stage enabling built-in variables" },
|
|
39570
39793
|
args: {
|
|
39571
39794
|
types: { type: "string", description: "Comma-separated types", required: false },
|
|
@@ -39579,7 +39802,7 @@ Examples:
|
|
|
39579
39802
|
});
|
|
39580
39803
|
}
|
|
39581
39804
|
}),
|
|
39582
|
-
disable:
|
|
39805
|
+
disable: defineCommand184({
|
|
39583
39806
|
meta: { name: "disable", description: "Stage disabling built-in variables" },
|
|
39584
39807
|
args: {
|
|
39585
39808
|
types: { type: "string", description: "Comma-separated types", required: false },
|
|
@@ -39597,7 +39820,7 @@ Examples:
|
|
|
39597
39820
|
});
|
|
39598
39821
|
|
|
39599
39822
|
// src/commands/tag-manager/index.ts
|
|
39600
|
-
var tagManagerCommand =
|
|
39823
|
+
var tagManagerCommand = defineCommand185({
|
|
39601
39824
|
meta: {
|
|
39602
39825
|
name: "tag-manager",
|
|
39603
39826
|
description: `Read and change what lives inside the client's Google Tag Manager container \u2014 tags, triggers, variables, folders and built-in variables.
|
|
@@ -39634,7 +39857,7 @@ Full guide: __tooling__/docs/tools/baker/tag-manager.md`
|
|
|
39634
39857
|
});
|
|
39635
39858
|
|
|
39636
39859
|
// src/commands/tags/index.ts
|
|
39637
|
-
import { defineCommand as
|
|
39860
|
+
import { defineCommand as defineCommand186 } from "citty";
|
|
39638
39861
|
|
|
39639
39862
|
// src/commands/tags/shared.ts
|
|
39640
39863
|
function failApi3(err) {
|
|
@@ -39703,7 +39926,7 @@ async function listTags(json) {
|
|
|
39703
39926
|
var listArgs9 = {
|
|
39704
39927
|
json: { type: "boolean", description: "Print the raw JSON envelope instead of the readable list" }
|
|
39705
39928
|
};
|
|
39706
|
-
var listCommand16 =
|
|
39929
|
+
var listCommand16 = defineCommand186({
|
|
39707
39930
|
meta: {
|
|
39708
39931
|
name: "list",
|
|
39709
39932
|
description: "Effective tags for this chat (production + staged), with each tag's full readable config (secrets excluded) \u2014 reuse a stored value to pre-fill a change rather than asking the user. Refs printed here are what flow side-effect tagIds should use. Example: baker tags list"
|
|
@@ -39722,7 +39945,7 @@ async function listDraft3(chat) {
|
|
|
39722
39945
|
failApi3(err);
|
|
39723
39946
|
}
|
|
39724
39947
|
}
|
|
39725
|
-
var draftCommand5 =
|
|
39948
|
+
var draftCommand5 = defineCommand186({
|
|
39726
39949
|
meta: {
|
|
39727
39950
|
name: "draft",
|
|
39728
39951
|
description: "Review the tag changes staged in this chat (read-only). Staged changes were approved via request_tag_input and apply when the chat is published; to amend or drop one, propose a follow-up change through the same tool (a delete on a tag_temp_* ref drops the staged create). Takes --chat <id> to read an earlier chat's staged changes instead."
|
|
@@ -39732,7 +39955,7 @@ var draftCommand5 = defineCommand185({
|
|
|
39732
39955
|
await listDraft3(args.chat);
|
|
39733
39956
|
}
|
|
39734
39957
|
});
|
|
39735
|
-
var tagsCommand3 =
|
|
39958
|
+
var tagsCommand3 = defineCommand186({
|
|
39736
39959
|
meta: {
|
|
39737
39960
|
name: "tags",
|
|
39738
39961
|
description: `Read the client's marketing/analytics tags (Meta pixel, GA4, Google Ads, GTM, Clarity, Hotjar, \u2026) \u2014 production tags plus the changes staged in this chat.
|
|
@@ -39761,10 +39984,10 @@ Full guide: __tooling__/docs/tools/baker/tags.md`
|
|
|
39761
39984
|
});
|
|
39762
39985
|
|
|
39763
39986
|
// src/commands/testimonials/index.ts
|
|
39764
|
-
import { defineCommand as
|
|
39987
|
+
import { defineCommand as defineCommand190 } from "citty";
|
|
39765
39988
|
|
|
39766
39989
|
// src/commands/testimonials/get.ts
|
|
39767
|
-
import { defineCommand as
|
|
39990
|
+
import { defineCommand as defineCommand187 } from "citty";
|
|
39768
39991
|
registerSchema({
|
|
39769
39992
|
command: "testimonials.get",
|
|
39770
39993
|
description: "Get a single testimonial by ID",
|
|
@@ -39772,7 +39995,7 @@ registerSchema({
|
|
|
39772
39995
|
id: { type: "string", description: "Testimonial ID", required: true }
|
|
39773
39996
|
}
|
|
39774
39997
|
});
|
|
39775
|
-
var getCommand5 =
|
|
39998
|
+
var getCommand5 = defineCommand187({
|
|
39776
39999
|
meta: { name: "get", description: "Get a single testimonial by ID. Example: baker testimonials get j571abc123" },
|
|
39777
40000
|
args: {
|
|
39778
40001
|
id: { type: "positional", description: "Testimonial ID", required: false },
|
|
@@ -39809,7 +40032,7 @@ var getCommand5 = defineCommand186({
|
|
|
39809
40032
|
});
|
|
39810
40033
|
|
|
39811
40034
|
// src/commands/testimonials/list.ts
|
|
39812
|
-
import { defineCommand as
|
|
40035
|
+
import { defineCommand as defineCommand188 } from "citty";
|
|
39813
40036
|
registerSchema({
|
|
39814
40037
|
command: "testimonials.list",
|
|
39815
40038
|
description: "List testimonials with optional filters.",
|
|
@@ -39839,7 +40062,7 @@ registerSchema({
|
|
|
39839
40062
|
limit: { type: "number", description: "Max results (default 50)", required: false, default: 50 }
|
|
39840
40063
|
}
|
|
39841
40064
|
});
|
|
39842
|
-
var listCommand17 =
|
|
40065
|
+
var listCommand17 = defineCommand188({
|
|
39843
40066
|
meta: {
|
|
39844
40067
|
name: "list",
|
|
39845
40068
|
description: "List testimonials with optional filters. Example: baker testimonials list --source google --sentiment positive"
|
|
@@ -39888,7 +40111,7 @@ var listCommand17 = defineCommand187({
|
|
|
39888
40111
|
});
|
|
39889
40112
|
|
|
39890
40113
|
// src/commands/testimonials/search.ts
|
|
39891
|
-
import { defineCommand as
|
|
40114
|
+
import { defineCommand as defineCommand189 } from "citty";
|
|
39892
40115
|
function languageBiasHint(results, requestedLanguage) {
|
|
39893
40116
|
if (requestedLanguage) {
|
|
39894
40117
|
return null;
|
|
@@ -39966,7 +40189,7 @@ function buildSearchRequest(query, args) {
|
|
|
39966
40189
|
}
|
|
39967
40190
|
return body;
|
|
39968
40191
|
}
|
|
39969
|
-
var searchCommand3 =
|
|
40192
|
+
var searchCommand3 = defineCommand189({
|
|
39970
40193
|
meta: {
|
|
39971
40194
|
name: "search",
|
|
39972
40195
|
description: "Semantic search testimonials by text query. Uses hybrid BM25 + vector + reranking. Example: baker testimonials search 'great service' --rating-min 4"
|
|
@@ -40022,7 +40245,7 @@ var searchCommand3 = defineCommand188({
|
|
|
40022
40245
|
var tagsCommand4 = makeTagsCommand("testimonials", "testimonial", "/api/testimonials/tags");
|
|
40023
40246
|
|
|
40024
40247
|
// src/commands/testimonials/index.ts
|
|
40025
|
-
var testimonialsCommand =
|
|
40248
|
+
var testimonialsCommand = defineCommand190({
|
|
40026
40249
|
meta: {
|
|
40027
40250
|
name: "testimonials",
|
|
40028
40251
|
description: `Find and browse testimonials in Baker. Subcommands: search, get, list, tags.
|
|
@@ -40044,10 +40267,10 @@ Full guide: __tooling__/docs/tools/baker/testimonials.md`
|
|
|
40044
40267
|
});
|
|
40045
40268
|
|
|
40046
40269
|
// src/commands/videos/index.ts
|
|
40047
|
-
import { defineCommand as
|
|
40270
|
+
import { defineCommand as defineCommand196 } from "citty";
|
|
40048
40271
|
|
|
40049
40272
|
// src/commands/videos/delete.ts
|
|
40050
|
-
import { defineCommand as
|
|
40273
|
+
import { defineCommand as defineCommand191 } from "citty";
|
|
40051
40274
|
registerSchema({
|
|
40052
40275
|
command: "videos.delete",
|
|
40053
40276
|
description: "Delete a video by ID",
|
|
@@ -40061,7 +40284,7 @@ registerSchema({
|
|
|
40061
40284
|
}
|
|
40062
40285
|
}
|
|
40063
40286
|
});
|
|
40064
|
-
var deleteCommand3 =
|
|
40287
|
+
var deleteCommand3 = defineCommand191({
|
|
40065
40288
|
meta: {
|
|
40066
40289
|
name: "delete",
|
|
40067
40290
|
description: "Delete a video by ID. Use --dry-run to preview. Example: baker videos delete j571abc123 --dry-run"
|
|
@@ -40102,7 +40325,7 @@ var deleteCommand3 = defineCommand190({
|
|
|
40102
40325
|
});
|
|
40103
40326
|
|
|
40104
40327
|
// src/commands/videos/get.ts
|
|
40105
|
-
import { defineCommand as
|
|
40328
|
+
import { defineCommand as defineCommand192 } from "citty";
|
|
40106
40329
|
registerSchema({
|
|
40107
40330
|
command: "videos.get",
|
|
40108
40331
|
description: "Get a single video by ID",
|
|
@@ -40110,7 +40333,7 @@ registerSchema({
|
|
|
40110
40333
|
id: { type: "string", description: "Video ID", required: true }
|
|
40111
40334
|
}
|
|
40112
40335
|
});
|
|
40113
|
-
var getCommand6 =
|
|
40336
|
+
var getCommand6 = defineCommand192({
|
|
40114
40337
|
meta: { name: "get", description: "Get a single video by ID. Example: baker videos get j571abc123" },
|
|
40115
40338
|
args: {
|
|
40116
40339
|
id: { type: "positional", description: "Video ID", required: false },
|
|
@@ -40147,7 +40370,7 @@ var getCommand6 = defineCommand191({
|
|
|
40147
40370
|
});
|
|
40148
40371
|
|
|
40149
40372
|
// src/commands/videos/group.ts
|
|
40150
|
-
import { defineCommand as
|
|
40373
|
+
import { defineCommand as defineCommand193 } from "citty";
|
|
40151
40374
|
registerSchema({
|
|
40152
40375
|
command: "videos.group",
|
|
40153
40376
|
description: "List every clip and image that arrived in the same set as this video (carousel slides, one page)",
|
|
@@ -40156,7 +40379,7 @@ registerSchema({
|
|
|
40156
40379
|
"group-key": { type: "string", description: "The set key directly, when you already have it", required: false }
|
|
40157
40380
|
}
|
|
40158
40381
|
});
|
|
40159
|
-
var groupCommand2 =
|
|
40382
|
+
var groupCommand2 = defineCommand193({
|
|
40160
40383
|
meta: {
|
|
40161
40384
|
name: "group",
|
|
40162
40385
|
description: "List every asset that arrived in the same set as this clip \u2014 the other slides of the Instagram post it came from, stills included. A carousel is authored to be read in order, so a clip pulled out of one is usually missing half its meaning. Example: baker videos group <videoId>"
|
|
@@ -40176,7 +40399,7 @@ var groupCommand2 = defineCommand192({
|
|
|
40176
40399
|
});
|
|
40177
40400
|
|
|
40178
40401
|
// src/commands/videos/search.ts
|
|
40179
|
-
import { defineCommand as
|
|
40402
|
+
import { defineCommand as defineCommand194 } from "citty";
|
|
40180
40403
|
registerSchema({
|
|
40181
40404
|
command: "videos.search",
|
|
40182
40405
|
description: "Search videos by text query. Only returns ready videos.",
|
|
@@ -40186,7 +40409,7 @@ registerSchema({
|
|
|
40186
40409
|
tags: { type: "string", description: "Comma-separated tags to filter by", required: false }
|
|
40187
40410
|
}
|
|
40188
40411
|
});
|
|
40189
|
-
var searchCommand4 =
|
|
40412
|
+
var searchCommand4 = defineCommand194({
|
|
40190
40413
|
meta: {
|
|
40191
40414
|
name: "search",
|
|
40192
40415
|
description: "Semantic search videos by text query. Uses hybrid BM25 + vector + reranking. Example: baker videos search 'product demo' --tags tutorial"
|
|
@@ -40238,7 +40461,7 @@ var tagsCommand5 = makeTagsCommand("videos", "video", "/api/videos/tags");
|
|
|
40238
40461
|
// src/commands/videos/upload.ts
|
|
40239
40462
|
import { readFile as readFile24, stat as stat7 } from "fs/promises";
|
|
40240
40463
|
import { basename as basename2, extname as extname3 } from "path";
|
|
40241
|
-
import { defineCommand as
|
|
40464
|
+
import { defineCommand as defineCommand195 } from "citty";
|
|
40242
40465
|
var MIME_MAP = {
|
|
40243
40466
|
".mp4": "video/mp4",
|
|
40244
40467
|
".mov": "video/quicktime",
|
|
@@ -40277,7 +40500,7 @@ function detectContentType(filePath) {
|
|
|
40277
40500
|
}
|
|
40278
40501
|
return mime;
|
|
40279
40502
|
}
|
|
40280
|
-
var uploadCommand2 =
|
|
40503
|
+
var uploadCommand2 = defineCommand195({
|
|
40281
40504
|
meta: {
|
|
40282
40505
|
name: "upload",
|
|
40283
40506
|
description: "Upload a video file to Baker via Mux direct upload. Auto-detects content type. Example: baker videos upload ./demo.mp4"
|
|
@@ -40347,7 +40570,7 @@ var uploadCommand2 = defineCommand194({
|
|
|
40347
40570
|
});
|
|
40348
40571
|
|
|
40349
40572
|
// src/commands/videos/index.ts
|
|
40350
|
-
var videosCommand =
|
|
40573
|
+
var videosCommand = defineCommand196({
|
|
40351
40574
|
meta: {
|
|
40352
40575
|
name: "videos",
|
|
40353
40576
|
description: `Find and manage videos in Baker. Subcommands: search, get, upload, delete, tags.
|
|
@@ -40372,10 +40595,10 @@ Full guide: __tooling__/docs/tools/baker/videos.md`
|
|
|
40372
40595
|
});
|
|
40373
40596
|
|
|
40374
40597
|
// src/commands/winning-ads/index.ts
|
|
40375
|
-
import { defineCommand as
|
|
40598
|
+
import { defineCommand as defineCommand209 } from "citty";
|
|
40376
40599
|
|
|
40377
40600
|
// src/commands/winning-ads/advertisers.ts
|
|
40378
|
-
import { defineCommand as
|
|
40601
|
+
import { defineCommand as defineCommand197 } from "citty";
|
|
40379
40602
|
|
|
40380
40603
|
// src/commands/winning-ads/shared.ts
|
|
40381
40604
|
function splitList2(value) {
|
|
@@ -40415,12 +40638,12 @@ function compactAdvertiser(record) {
|
|
|
40415
40638
|
};
|
|
40416
40639
|
}
|
|
40417
40640
|
function advertiserNormalizer(record, full) {
|
|
40418
|
-
const
|
|
40641
|
+
const compact2 = compactAdvertiser(record);
|
|
40419
40642
|
if (!full) {
|
|
40420
|
-
return
|
|
40643
|
+
return compact2;
|
|
40421
40644
|
}
|
|
40422
40645
|
return {
|
|
40423
|
-
...
|
|
40646
|
+
...compact2,
|
|
40424
40647
|
scraped_name: record.scraped_name ?? null,
|
|
40425
40648
|
image_url: record.image_url ?? null,
|
|
40426
40649
|
platforms: Array.isArray(record.platforms) ? record.platforms : [],
|
|
@@ -40428,7 +40651,7 @@ function advertiserNormalizer(record, full) {
|
|
|
40428
40651
|
last_synced_at: record.last_synced_at ?? null
|
|
40429
40652
|
};
|
|
40430
40653
|
}
|
|
40431
|
-
var advertisersCommand2 =
|
|
40654
|
+
var advertisersCommand2 = defineCommand197({
|
|
40432
40655
|
meta: {
|
|
40433
40656
|
name: "advertisers",
|
|
40434
40657
|
description: 'List corpus advertisers by name or domain. Find your own advertiser for --exclude-advertiser, or a competitor for --advertiser-id / winners. Example: baker winning-ads advertisers "Deel" --output md'
|
|
@@ -40486,7 +40709,7 @@ var advertisersCommand2 = defineCommand196({
|
|
|
40486
40709
|
});
|
|
40487
40710
|
|
|
40488
40711
|
// src/commands/winning-ads/brief.ts
|
|
40489
|
-
import { defineCommand as
|
|
40712
|
+
import { defineCommand as defineCommand198 } from "citty";
|
|
40490
40713
|
registerSchema({
|
|
40491
40714
|
command: "winning-ads.brief",
|
|
40492
40715
|
description: "Generate a creative brief grounded in strategically-similar winning ads. Optionally describe the target creative with --dna (JSON) and steer with --notes.",
|
|
@@ -40532,7 +40755,7 @@ function parseDna(raw) {
|
|
|
40532
40755
|
}
|
|
40533
40756
|
return parsed;
|
|
40534
40757
|
}
|
|
40535
|
-
var briefCommand =
|
|
40758
|
+
var briefCommand = defineCommand198({
|
|
40536
40759
|
meta: {
|
|
40537
40760
|
name: "brief",
|
|
40538
40761
|
description: `Generate a creative brief from winning references. Example: baker winning-ads brief --dna '{"angle":"cost savings"}' --notes "B2B, LinkedIn video" --k 8`
|
|
@@ -40568,7 +40791,7 @@ var briefCommand = defineCommand197({
|
|
|
40568
40791
|
});
|
|
40569
40792
|
|
|
40570
40793
|
// src/commands/winning-ads/content.ts
|
|
40571
|
-
import { defineCommand as
|
|
40794
|
+
import { defineCommand as defineCommand199 } from "citty";
|
|
40572
40795
|
registerSchema({
|
|
40573
40796
|
command: "winning-ads.content",
|
|
40574
40797
|
description: "Read what's INSIDE one winning ad: the spoken transcript, the on-screen text, and the ad copy. Use this after `search`/`winners`/`feed` return a shortlist \u2014 pass an ad_id to understand a reference before reproducing it. Add --full for speech, pacing, and soundtrack detail. Video ads carry the transcript/on-screen text; static ads carry only the copy.",
|
|
@@ -40581,7 +40804,7 @@ registerSchema({
|
|
|
40581
40804
|
}
|
|
40582
40805
|
}
|
|
40583
40806
|
});
|
|
40584
|
-
var contentCommand =
|
|
40807
|
+
var contentCommand = defineCommand199({
|
|
40585
40808
|
meta: {
|
|
40586
40809
|
name: "content",
|
|
40587
40810
|
description: "Read the transcript + on-screen text + copy of one winning ad. Example: baker winning-ads content adg_123 --platform meta --full --output md"
|
|
@@ -40630,7 +40853,7 @@ var contentCommand = defineCommand198({
|
|
|
40630
40853
|
});
|
|
40631
40854
|
|
|
40632
40855
|
// src/commands/winning-ads/feed.ts
|
|
40633
|
-
import { defineCommand as
|
|
40856
|
+
import { defineCommand as defineCommand200 } from "citty";
|
|
40634
40857
|
function buildFeedParams(input) {
|
|
40635
40858
|
const params = {};
|
|
40636
40859
|
const advertiser = splitList2(input.advertiser);
|
|
@@ -40682,7 +40905,7 @@ registerSchema({
|
|
|
40682
40905
|
format: { type: "string", description: "Comma-separated formats to include (e.g. static,video)", required: false }
|
|
40683
40906
|
}
|
|
40684
40907
|
});
|
|
40685
|
-
var feedCommand =
|
|
40908
|
+
var feedCommand = defineCommand200({
|
|
40686
40909
|
meta: {
|
|
40687
40910
|
name: "feed",
|
|
40688
40911
|
description: "Winners across every brand you follow (browse, then trim per advertiser). Example: baker winning-ads feed --per-advertiser 5 --output md"
|
|
@@ -40767,7 +40990,7 @@ var feedCommand = defineCommand199({
|
|
|
40767
40990
|
});
|
|
40768
40991
|
|
|
40769
40992
|
// src/commands/winning-ads/follow.ts
|
|
40770
|
-
import { defineCommand as
|
|
40993
|
+
import { defineCommand as defineCommand201 } from "citty";
|
|
40771
40994
|
var PLATFORMS = ["meta", "linkedin"];
|
|
40772
40995
|
registerSchema({
|
|
40773
40996
|
command: "winning-ads.follow",
|
|
@@ -40782,7 +41005,7 @@ registerSchema({
|
|
|
40782
41005
|
label: { type: "string", description: "Optional display label (defaults to the resolved name)", required: false }
|
|
40783
41006
|
}
|
|
40784
41007
|
});
|
|
40785
|
-
var followCommand =
|
|
41008
|
+
var followCommand = defineCommand201({
|
|
40786
41009
|
meta: {
|
|
40787
41010
|
name: "follow",
|
|
40788
41011
|
description: 'Follow a brand to track ALL its ads \u2014 every platform and country. --platform is how we read your input, not a limit. A domain tracks both Meta + LinkedIn. Example: baker winning-ads follow "deel.com" --platform meta'
|
|
@@ -40829,7 +41052,7 @@ var followCommand = defineCommand200({
|
|
|
40829
41052
|
});
|
|
40830
41053
|
|
|
40831
41054
|
// src/commands/winning-ads/follow-competitors.ts
|
|
40832
|
-
import { defineCommand as
|
|
41055
|
+
import { defineCommand as defineCommand202 } from "citty";
|
|
40833
41056
|
var PLATFORMS2 = ["meta", "linkedin"];
|
|
40834
41057
|
var BATCH_TIMEOUT_MS = 3e5;
|
|
40835
41058
|
function buildFollowBatchBody(input) {
|
|
@@ -40862,7 +41085,7 @@ registerSchema({
|
|
|
40862
41085
|
}
|
|
40863
41086
|
}
|
|
40864
41087
|
});
|
|
40865
|
-
var followCompetitorsCommand =
|
|
41088
|
+
var followCompetitorsCommand = defineCommand202({
|
|
40866
41089
|
meta: {
|
|
40867
41090
|
name: "follow-competitors",
|
|
40868
41091
|
description: 'Follow many brands at once by domain \u2014 add every competitor in one call. Example: baker winning-ads follow-competitors "deel.com,notion.so,hubspot.com"'
|
|
@@ -40937,7 +41160,7 @@ var followCompetitorsCommand = defineCommand201({
|
|
|
40937
41160
|
});
|
|
40938
41161
|
|
|
40939
41162
|
// src/commands/winning-ads/following.ts
|
|
40940
|
-
import { defineCommand as
|
|
41163
|
+
import { defineCommand as defineCommand203 } from "citty";
|
|
40941
41164
|
registerSchema({
|
|
40942
41165
|
command: "winning-ads.following",
|
|
40943
41166
|
description: "List the brands you follow in your ad-dna library, with each one's status (ready vs still adding) and cached ad counts.",
|
|
@@ -40960,17 +41183,17 @@ function compactFollowed(record) {
|
|
|
40960
41183
|
};
|
|
40961
41184
|
}
|
|
40962
41185
|
function followingNormalizer(record, full) {
|
|
40963
|
-
const
|
|
41186
|
+
const compact2 = compactFollowed(record);
|
|
40964
41187
|
if (!full) {
|
|
40965
|
-
return
|
|
41188
|
+
return compact2;
|
|
40966
41189
|
}
|
|
40967
41190
|
return {
|
|
40968
|
-
...
|
|
41191
|
+
...compact2,
|
|
40969
41192
|
image_url: record.image_url ?? null,
|
|
40970
41193
|
platforms: Array.isArray(record.platforms) ? record.platforms : []
|
|
40971
41194
|
};
|
|
40972
41195
|
}
|
|
40973
|
-
var followingCommand =
|
|
41196
|
+
var followingCommand = defineCommand203({
|
|
40974
41197
|
meta: {
|
|
40975
41198
|
name: "following",
|
|
40976
41199
|
description: "List brands you follow, with status (ready / adding\u2026) and cached counts. Example: baker winning-ads following --output md"
|
|
@@ -41005,7 +41228,7 @@ var followingCommand = defineCommand202({
|
|
|
41005
41228
|
});
|
|
41006
41229
|
|
|
41007
41230
|
// src/commands/winning-ads/patterns.ts
|
|
41008
|
-
import { defineCommand as
|
|
41231
|
+
import { defineCommand as defineCommand204 } from "citty";
|
|
41009
41232
|
registerSchema({
|
|
41010
41233
|
command: "winning-ads.patterns",
|
|
41011
41234
|
description: "Mine what separates two cohorts of ads: pass a comma-list of winning ad ids (--winners) and a comma-list of weaker ad ids (--duds). Returns the discriminating DNA fields.",
|
|
@@ -41044,7 +41267,7 @@ function discriminatorRow(record) {
|
|
|
41044
41267
|
top_values_duds: Array.isArray(record.top_values_b) ? record.top_values_b.join(", ") : ""
|
|
41045
41268
|
};
|
|
41046
41269
|
}
|
|
41047
|
-
var patternsCommand =
|
|
41270
|
+
var patternsCommand = defineCommand204({
|
|
41048
41271
|
meta: {
|
|
41049
41272
|
name: "patterns",
|
|
41050
41273
|
description: "Discover what separates winning ads from weak ones. Example: baker winning-ads patterns --winners a_1,a_2,a_3 --duds a_9,a_8 --output md"
|
|
@@ -41100,7 +41323,7 @@ var patternsCommand = defineCommand203({
|
|
|
41100
41323
|
});
|
|
41101
41324
|
|
|
41102
41325
|
// src/commands/winning-ads/search.ts
|
|
41103
|
-
import { defineCommand as
|
|
41326
|
+
import { defineCommand as defineCommand205 } from "citty";
|
|
41104
41327
|
registerSchema({
|
|
41105
41328
|
command: "winning-ads.search",
|
|
41106
41329
|
description: "Search the ad-dna corpus of scored winning ads. Returns a lean shortlist (advertiser, summary, scores, media_url) to pick a reference to reproduce.",
|
|
@@ -41208,7 +41431,7 @@ function buildSearchBody2(args) {
|
|
|
41208
41431
|
}
|
|
41209
41432
|
return body;
|
|
41210
41433
|
}
|
|
41211
|
-
var searchCommand5 =
|
|
41434
|
+
var searchCommand5 = defineCommand205({
|
|
41212
41435
|
meta: {
|
|
41213
41436
|
name: "search",
|
|
41214
41437
|
description: "Search winning reference ads. Example: baker winning-ads search 'B2B SaaS before/after AI automation' --platform meta --format static --winner-category winner --exclude-advertiser adv_123 --output md"
|
|
@@ -41323,7 +41546,7 @@ var searchCommand5 = defineCommand204({
|
|
|
41323
41546
|
});
|
|
41324
41547
|
|
|
41325
41548
|
// src/commands/winning-ads/seeds.ts
|
|
41326
|
-
import { defineCommand as
|
|
41549
|
+
import { defineCommand as defineCommand206 } from "citty";
|
|
41327
41550
|
function leanRow(r) {
|
|
41328
41551
|
return {
|
|
41329
41552
|
key: r.key,
|
|
@@ -41351,7 +41574,7 @@ function makeSeedCommand(opts) {
|
|
|
41351
41574
|
limit: { type: "number", description: "Max keys 1-100 (default 20)", required: false, default: 20 }
|
|
41352
41575
|
}
|
|
41353
41576
|
});
|
|
41354
|
-
return
|
|
41577
|
+
return defineCommand206({
|
|
41355
41578
|
meta: { name: opts.name, description: opts.description },
|
|
41356
41579
|
args: {
|
|
41357
41580
|
platform: { type: "string", description: "Single platform to segment on", required: false },
|
|
@@ -41400,7 +41623,7 @@ var formatsCommand = makeSeedCommand({
|
|
|
41400
41623
|
});
|
|
41401
41624
|
|
|
41402
41625
|
// src/commands/winning-ads/unfollow.ts
|
|
41403
|
-
import { defineCommand as
|
|
41626
|
+
import { defineCommand as defineCommand207 } from "citty";
|
|
41404
41627
|
registerSchema({
|
|
41405
41628
|
command: "winning-ads.unfollow",
|
|
41406
41629
|
description: "Stop following a brand \u2014 removes it from your ad-dna library by advertiser id.",
|
|
@@ -41408,7 +41631,7 @@ registerSchema({
|
|
|
41408
41631
|
advertiser: { type: "string", description: "Advertiser id to unfollow", required: true }
|
|
41409
41632
|
}
|
|
41410
41633
|
});
|
|
41411
|
-
var unfollowCommand =
|
|
41634
|
+
var unfollowCommand = defineCommand207({
|
|
41412
41635
|
meta: {
|
|
41413
41636
|
name: "unfollow",
|
|
41414
41637
|
description: "Stop following a brand by advertiser id. Example: baker winning-ads unfollow adv_123"
|
|
@@ -41429,7 +41652,7 @@ var unfollowCommand = defineCommand206({
|
|
|
41429
41652
|
});
|
|
41430
41653
|
|
|
41431
41654
|
// src/commands/winning-ads/winners.ts
|
|
41432
|
-
import { defineCommand as
|
|
41655
|
+
import { defineCommand as defineCommand208 } from "citty";
|
|
41433
41656
|
registerSchema({
|
|
41434
41657
|
command: "winning-ads.winners",
|
|
41435
41658
|
description: "Top winning ads for one advertiser id (from `advertisers` or `following`). Returns lean winner cards; add --full for DNA + longevity.",
|
|
@@ -41439,7 +41662,7 @@ registerSchema({
|
|
|
41439
41662
|
platform: { type: "string", description: "Filter to a single platform: meta|linkedin", required: false }
|
|
41440
41663
|
}
|
|
41441
41664
|
});
|
|
41442
|
-
var winnersCommand =
|
|
41665
|
+
var winnersCommand = defineCommand208({
|
|
41443
41666
|
meta: {
|
|
41444
41667
|
name: "winners",
|
|
41445
41668
|
description: "Top winning ads for a specific advertiser id. Example: baker winning-ads winners adv_123 --top 15 --output md"
|
|
@@ -41489,7 +41712,7 @@ var winnersCommand = defineCommand207({
|
|
|
41489
41712
|
});
|
|
41490
41713
|
|
|
41491
41714
|
// src/commands/winning-ads/index.ts
|
|
41492
|
-
var winningAdsCommand =
|
|
41715
|
+
var winningAdsCommand = defineCommand209({
|
|
41493
41716
|
meta: {
|
|
41494
41717
|
name: "winning-ads",
|
|
41495
41718
|
description: `Search the ad-dna corpus of scored "winning" ads for reference creatives to reproduce, and manage the brands your library tracks. Proxied through the Baker backend (BAKER_API_KEY) \u2014 no separate token needed.
|
|
@@ -41561,7 +41784,7 @@ function getCliVersion() {
|
|
|
41561
41784
|
}
|
|
41562
41785
|
|
|
41563
41786
|
// src/cli.ts
|
|
41564
|
-
var main =
|
|
41787
|
+
var main = defineCommand210({
|
|
41565
41788
|
meta: {
|
|
41566
41789
|
name: "baker",
|
|
41567
41790
|
version: getCliVersion(),
|