@koda-sl/baker-cli 0.274.0 → 0.275.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 +48 -0
- package/dist/cli.js +343 -122
- package/dist/cli.js.map +1 -1
- package/package.json +1 -1
package/dist/cli.js
CHANGED
|
@@ -109,7 +109,7 @@ import {
|
|
|
109
109
|
} from "./chunk-DZUVUGEP.js";
|
|
110
110
|
|
|
111
111
|
// src/cli.ts
|
|
112
|
-
import { defineCommand as
|
|
112
|
+
import { defineCommand as defineCommand230, runMain } from "citty";
|
|
113
113
|
|
|
114
114
|
// src/cache-flag.ts
|
|
115
115
|
var NO_CACHE_ARG = {
|
|
@@ -6048,6 +6048,43 @@ var researchFetchResponseSchema = z18.object({
|
|
|
6048
6048
|
truncated: z18.boolean(),
|
|
6049
6049
|
provider: z18.literal("firecrawl")
|
|
6050
6050
|
});
|
|
6051
|
+
var RESEARCH_KEYWORD_METRICS_MAX_KEYWORDS = 700;
|
|
6052
|
+
var RESEARCH_KEYWORD_METRICS_MAX_KEYWORD_CHARS = 80;
|
|
6053
|
+
var researchKeywordMetricsRequestSchema = z18.object({
|
|
6054
|
+
keywords: z18.array(z18.string().min(1).max(RESEARCH_KEYWORD_METRICS_MAX_KEYWORD_CHARS)).min(1).max(RESEARCH_KEYWORD_METRICS_MAX_KEYWORDS),
|
|
6055
|
+
/** Country code (`mx`, `br`, …) or a DataForSEO location code. */
|
|
6056
|
+
location: z18.union([z18.string(), z18.number()]).optional(),
|
|
6057
|
+
language: z18.string().optional(),
|
|
6058
|
+
/**
|
|
6059
|
+
* Ask for DataForSEO's own panel-derived volume alongside Google's. Off by
|
|
6060
|
+
* default because it doubles the price of the request — and because the
|
|
6061
|
+
* Google number is the one every other Baker surface quotes.
|
|
6062
|
+
*/
|
|
6063
|
+
includeClickstream: z18.boolean().default(false),
|
|
6064
|
+
skipCache: z18.boolean().optional()
|
|
6065
|
+
});
|
|
6066
|
+
var monthlySearchSchema = z18.object({
|
|
6067
|
+
year: z18.number(),
|
|
6068
|
+
month: z18.number(),
|
|
6069
|
+
search_volume: z18.number()
|
|
6070
|
+
});
|
|
6071
|
+
var researchKeywordMetricsRowSchema = z18.object({
|
|
6072
|
+
keyword: z18.string(),
|
|
6073
|
+
search_volume: z18.number().nullable(),
|
|
6074
|
+
cpc: z18.number().nullable(),
|
|
6075
|
+
low_top_of_page_bid: z18.number().nullable(),
|
|
6076
|
+
high_top_of_page_bid: z18.number().nullable(),
|
|
6077
|
+
competition: z18.string().nullable(),
|
|
6078
|
+
competition_index: z18.number().nullable(),
|
|
6079
|
+
keyword_difficulty: z18.number().nullable(),
|
|
6080
|
+
main_intent: z18.string().nullable(),
|
|
6081
|
+
monthly_searches: z18.array(monthlySearchSchema),
|
|
6082
|
+
/** Populated only when `includeClickstream` was set. */
|
|
6083
|
+
clickstream_search_volume: z18.number().nullable()
|
|
6084
|
+
});
|
|
6085
|
+
var researchKeywordMetricsResponseSchema = z18.object({
|
|
6086
|
+
data: z18.array(researchKeywordMetricsRowSchema)
|
|
6087
|
+
});
|
|
6051
6088
|
|
|
6052
6089
|
// ../api/src/scheduledTaskModes.ts
|
|
6053
6090
|
var TASK_MODES = {
|
|
@@ -48150,7 +48187,7 @@ Full guide: __tooling__/docs/tools/baker/mcp.md`
|
|
|
48150
48187
|
});
|
|
48151
48188
|
|
|
48152
48189
|
// src/commands/research/index.ts
|
|
48153
|
-
import { defineCommand as
|
|
48190
|
+
import { defineCommand as defineCommand182 } from "citty";
|
|
48154
48191
|
|
|
48155
48192
|
// src/commands/research/advertisers.ts
|
|
48156
48193
|
import { defineCommand as defineCommand170 } from "citty";
|
|
@@ -48221,6 +48258,25 @@ function webDepthHints({
|
|
|
48221
48258
|
}
|
|
48222
48259
|
return [`Thin answer (${answer.length} chars, ${sourceCount} source(s)). ${escalation}`];
|
|
48223
48260
|
}
|
|
48261
|
+
function keywordMetricsHints({
|
|
48262
|
+
rows,
|
|
48263
|
+
asked,
|
|
48264
|
+
clickstream,
|
|
48265
|
+
queryContext
|
|
48266
|
+
}) {
|
|
48267
|
+
if (rows.length === 0) {
|
|
48268
|
+
return noSerpRowsHints(0, queryContext);
|
|
48269
|
+
}
|
|
48270
|
+
const provenance = "DataForSEO resells Google's Keyword Planner volume \u2014 planner_search_volume here is the SAME number `baker ads google keywords metrics` returns, not an independent reading of it. Quoting the two as agreeing sources is not corroboration." + (clickstream ? " clickstream_search_volume IS independent (DataForSEO's own panels); when the two disagree, say which one you are quoting." : " For a genuinely independent estimate of demand, re-run with --clickstream (costs 2x), or use first-party data: `baker gsc query` for what already reaches the site, or the account's own search terms.");
|
|
48271
|
+
const hints2 = [provenance];
|
|
48272
|
+
const empty = rows.filter((row) => row.search_volume === null).map((row) => row.keyword);
|
|
48273
|
+
if (empty.length > 0) {
|
|
48274
|
+
hints2.push(
|
|
48275
|
+
`${empty.length} of ${asked.length} keywords came back with no data in ${queryContext.location} / ${queryContext.language}: ${empty.join(", ")}. That is missing coverage, NOT zero demand \u2014 do not report them as unsearched, and do not re-query them reworded. \`baker research autocomplete\` on the head term is the way to find the phrasing that market uses.`
|
|
48276
|
+
);
|
|
48277
|
+
}
|
|
48278
|
+
return hints2;
|
|
48279
|
+
}
|
|
48224
48280
|
|
|
48225
48281
|
// src/commands/research/output.ts
|
|
48226
48282
|
var RESEARCH_DATA_NOTE = "Estimates based on third-party SERP data \u2014 not exact figures. Use for directional insights, not precise measurement.";
|
|
@@ -48862,8 +48918,170 @@ Examples:
|
|
|
48862
48918
|
}
|
|
48863
48919
|
});
|
|
48864
48920
|
|
|
48865
|
-
// src/commands/research/
|
|
48921
|
+
// src/commands/research/keyword-metrics.ts
|
|
48866
48922
|
import { defineCommand as defineCommand176 } from "citty";
|
|
48923
|
+
|
|
48924
|
+
// src/commands/research/keyword-metrics-rows.ts
|
|
48925
|
+
var KEYWORD_METRICS_SOURCE = "keyword_planner_estimate_via_dataforseo";
|
|
48926
|
+
function toOutputRow(row, options) {
|
|
48927
|
+
const out = {
|
|
48928
|
+
source: KEYWORD_METRICS_SOURCE,
|
|
48929
|
+
keyword: row.keyword,
|
|
48930
|
+
planner_search_volume: row.search_volume,
|
|
48931
|
+
planner_cpc: row.cpc,
|
|
48932
|
+
planner_low_top_of_page_bid: row.low_top_of_page_bid,
|
|
48933
|
+
planner_high_top_of_page_bid: row.high_top_of_page_bid,
|
|
48934
|
+
planner_competition: row.competition,
|
|
48935
|
+
planner_competition_index: row.competition_index
|
|
48936
|
+
};
|
|
48937
|
+
if (options.clickstream) {
|
|
48938
|
+
out.clickstream_search_volume = row.clickstream_search_volume;
|
|
48939
|
+
}
|
|
48940
|
+
if (options.full) {
|
|
48941
|
+
out.keyword_difficulty = row.keyword_difficulty;
|
|
48942
|
+
out.main_intent = row.main_intent;
|
|
48943
|
+
out.planner_monthly_searches = row.monthly_searches;
|
|
48944
|
+
}
|
|
48945
|
+
return out;
|
|
48946
|
+
}
|
|
48947
|
+
function keywordMetricsFields(options) {
|
|
48948
|
+
const fields = {
|
|
48949
|
+
source: `Always "${KEYWORD_METRICS_SOURCE}". Every planner_ column below is Google's Keyword Planner ESTIMATE of total market volume, resold by DataForSEO \u2014 the same number \`baker ads google keywords metrics\` returns, not an independent measurement of it. Columns without the planner_ prefix are DataForSEO's own.`,
|
|
48950
|
+
keyword: "The keyword asked for. A row with every metric null means DataForSEO holds no data on it \u2014 not that nobody searches it.",
|
|
48951
|
+
planner_search_volume: "ESTIMATE: average monthly searches across the whole market, last 12 months",
|
|
48952
|
+
planner_cpc: "ESTIMATE: average cost per click in USD (a single blended figure, not a top-of-page range)",
|
|
48953
|
+
planner_low_top_of_page_bid: "ESTIMATE: low-range top-of-page bid in USD",
|
|
48954
|
+
planner_high_top_of_page_bid: "ESTIMATE: high-range top-of-page bid in USD",
|
|
48955
|
+
planner_competition: "ESTIMATE: competition level \u2014 LOW, MEDIUM or HIGH",
|
|
48956
|
+
planner_competition_index: "ESTIMATE: competition index 0-100 (higher = more advertisers)"
|
|
48957
|
+
};
|
|
48958
|
+
if (options.clickstream) {
|
|
48959
|
+
fields.clickstream_search_volume = "DataForSEO's OWN volume estimate, from clickstream panels \u2014 not Google's, and the only number here that is a genuine second opinion on demand. Expect it to differ from planner_search_volume; that is the point.";
|
|
48960
|
+
}
|
|
48961
|
+
if (options.full) {
|
|
48962
|
+
fields.keyword_difficulty = "DataForSEO's 0-100 estimate of how hard ranking in the organic top 10 would be";
|
|
48963
|
+
fields.main_intent = "DataForSEO's intent classification: informational, navigational, commercial or transactional";
|
|
48964
|
+
fields.planner_monthly_searches = "ESTIMATE: 12-month volume breakdown ({year, month, search_volume})";
|
|
48965
|
+
}
|
|
48966
|
+
return fields;
|
|
48967
|
+
}
|
|
48968
|
+
|
|
48969
|
+
// src/commands/research/keyword-metrics.ts
|
|
48970
|
+
registerSchema({
|
|
48971
|
+
command: "research.keyword-metrics",
|
|
48972
|
+
description: "Search volume, CPC, top-of-page bids and competition for a list of keywords YOU name \u2014 no domain needed. This is the command for sizing a market you have keywords for; the domain-bound ones (keywords-for-site, keyword-gap) answer a different question and should not be used as a workaround for this one. The volume is Google's Keyword Planner figure resold by DataForSEO, so it is NOT a second opinion on `baker ads google keywords metrics` \u2014 for that, pass --clickstream. 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.",
|
|
48973
|
+
args: {
|
|
48974
|
+
keywords: {
|
|
48975
|
+
type: "string",
|
|
48976
|
+
description: `Comma-separated keywords (max ${RESEARCH_KEYWORD_METRICS_MAX_KEYWORDS}, 80 chars each)`,
|
|
48977
|
+
required: true
|
|
48978
|
+
},
|
|
48979
|
+
location: {
|
|
48980
|
+
type: "string",
|
|
48981
|
+
description: "Country code (us, mx, br, es...) or DataForSEO location code. DEFAULTS TO us (United States) if omitted \u2014 always set this for non-US markets",
|
|
48982
|
+
required: false
|
|
48983
|
+
},
|
|
48984
|
+
language: {
|
|
48985
|
+
type: "string",
|
|
48986
|
+
description: "Language code or name. DEFAULTS TO en (English) if omitted \u2014 always set this for non-English markets",
|
|
48987
|
+
required: false
|
|
48988
|
+
},
|
|
48989
|
+
clickstream: {
|
|
48990
|
+
type: "boolean",
|
|
48991
|
+
description: "Also return DataForSEO's own panel-derived volume (clickstream_search_volume), the only genuinely independent estimate of demand available here. Costs 2x.",
|
|
48992
|
+
required: false
|
|
48993
|
+
},
|
|
48994
|
+
full: {
|
|
48995
|
+
type: "boolean",
|
|
48996
|
+
description: "Add keyword difficulty, search intent and the 12-month volume trend to each row",
|
|
48997
|
+
required: false
|
|
48998
|
+
},
|
|
48999
|
+
"no-cache": { type: "boolean", description: "Skip server cache, hit API directly", required: false }
|
|
49000
|
+
}
|
|
49001
|
+
});
|
|
49002
|
+
var keywordMetricsCommand = defineCommand176({
|
|
49003
|
+
meta: {
|
|
49004
|
+
name: "keyword-metrics",
|
|
49005
|
+
description: `Volume, CPC and competition for keywords you name. No domain required.
|
|
49006
|
+
|
|
49007
|
+
Numbers are Keyword Planner ESTIMATES of total market volume, resold by DataForSEO \u2014 every column carrying one is named planner_. Pass --clickstream for DataForSEO's own independent estimate alongside.
|
|
49008
|
+
|
|
49009
|
+
Examples:
|
|
49010
|
+
baker research keyword-metrics "chatbot whatsapp,agente whatsapp ecommerce" --location mx --language es
|
|
49011
|
+
baker research keyword-metrics "chatbot whatsapp" --location br --language pt --clickstream
|
|
49012
|
+
baker research keyword-metrics "crm software,best crm" --full --output md`
|
|
49013
|
+
},
|
|
49014
|
+
args: {
|
|
49015
|
+
keywords: { type: "positional", description: "Comma-separated keywords", required: true },
|
|
49016
|
+
location: { type: "string", description: "Country code or location code (default: us)", required: false },
|
|
49017
|
+
language: { type: "string", description: "Language code or name (default: en)", required: false },
|
|
49018
|
+
clickstream: { type: "boolean", description: "Add DataForSEO's own volume estimate (costs 2x)", required: false },
|
|
49019
|
+
full: { type: "boolean", description: "Add difficulty, intent and the 12-month trend", required: false },
|
|
49020
|
+
output: { type: "string", description: "Format: json|csv|md|jsonl", required: false, default: "json" },
|
|
49021
|
+
"no-cache": { type: "boolean", description: "Skip server cache, hit API directly", required: false }
|
|
49022
|
+
},
|
|
49023
|
+
run: async ({ args }) => {
|
|
49024
|
+
const keywords = args.keywords.split(",").map((k) => k.trim()).filter(Boolean);
|
|
49025
|
+
if (keywords.length === 0) {
|
|
49026
|
+
writeResearchJson({
|
|
49027
|
+
ok: false,
|
|
49028
|
+
error: { code: "VALIDATION_ERROR", message: "Provide at least one keyword" }
|
|
49029
|
+
});
|
|
49030
|
+
process.exit(1);
|
|
49031
|
+
}
|
|
49032
|
+
if (keywords.length > RESEARCH_KEYWORD_METRICS_MAX_KEYWORDS) {
|
|
49033
|
+
writeResearchJson({
|
|
49034
|
+
ok: false,
|
|
49035
|
+
error: {
|
|
49036
|
+
code: "VALIDATION_ERROR",
|
|
49037
|
+
message: `Maximum ${RESEARCH_KEYWORD_METRICS_MAX_KEYWORDS} keywords per request`,
|
|
49038
|
+
fix: {
|
|
49039
|
+
action: "retry_with_changes",
|
|
49040
|
+
explanation: `You sent ${keywords.length}. Split the list into batches of ${RESEARCH_KEYWORD_METRICS_MAX_KEYWORDS} and run the command once per batch \u2014 each batch is a separate charge, so batch by priority.`
|
|
49041
|
+
}
|
|
49042
|
+
}
|
|
49043
|
+
});
|
|
49044
|
+
process.exit(1);
|
|
49045
|
+
}
|
|
49046
|
+
const location2 = args.location || void 0;
|
|
49047
|
+
const language = args.language || void 0;
|
|
49048
|
+
const clickstream = Boolean(args.clickstream);
|
|
49049
|
+
const full = Boolean(args.full);
|
|
49050
|
+
const queryContext = buildResearchQueryContext(location2, language);
|
|
49051
|
+
try {
|
|
49052
|
+
const result = await apiPost("/api/research/keyword-metrics", {
|
|
49053
|
+
keywords,
|
|
49054
|
+
location: location2,
|
|
49055
|
+
language,
|
|
49056
|
+
includeClickstream: clickstream,
|
|
49057
|
+
skipCache: args["no-cache"] ? true : void 0
|
|
49058
|
+
});
|
|
49059
|
+
const columns = { clickstream, full };
|
|
49060
|
+
const rows = result.data.map((row) => toOutputRow(row, columns));
|
|
49061
|
+
const hints2 = keywordMetricsHints({ rows: result.data, asked: keywords, clickstream, queryContext });
|
|
49062
|
+
warnDefaults(queryContext);
|
|
49063
|
+
const format = args.output || "json";
|
|
49064
|
+
if (format !== "json") {
|
|
49065
|
+
writeResearchOutput(rows, format);
|
|
49066
|
+
writeResearchHints([...hints2, RESEARCH_DATA_NOTE], format);
|
|
49067
|
+
return;
|
|
49068
|
+
}
|
|
49069
|
+
writeResearchJson({
|
|
49070
|
+
ok: true,
|
|
49071
|
+
data: rows,
|
|
49072
|
+
fields: keywordMetricsFields(columns),
|
|
49073
|
+
note: RESEARCH_DATA_NOTE,
|
|
49074
|
+
hints: hints2,
|
|
49075
|
+
query_context: queryContext
|
|
49076
|
+
});
|
|
49077
|
+
} catch (err) {
|
|
49078
|
+
handleResearchError(err);
|
|
49079
|
+
}
|
|
49080
|
+
}
|
|
49081
|
+
});
|
|
49082
|
+
|
|
49083
|
+
// src/commands/research/keywords-for-site.ts
|
|
49084
|
+
import { defineCommand as defineCommand177 } from "citty";
|
|
48867
49085
|
registerSchema({
|
|
48868
49086
|
command: "research.keywords-for-site",
|
|
48869
49087
|
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.",
|
|
@@ -48896,7 +49114,7 @@ var FIELDS9 = {
|
|
|
48896
49114
|
competition: "LOW, MEDIUM, or HIGH",
|
|
48897
49115
|
competition_index: "Competition score 0-100"
|
|
48898
49116
|
};
|
|
48899
|
-
var keywordsForSiteCommand =
|
|
49117
|
+
var keywordsForSiteCommand = defineCommand177({
|
|
48900
49118
|
meta: {
|
|
48901
49119
|
name: "keywords-for-site",
|
|
48902
49120
|
description: `Get keywords a competitor targets in Google. Use --type to filter paid/organic.
|
|
@@ -48958,7 +49176,7 @@ Examples:
|
|
|
48958
49176
|
});
|
|
48959
49177
|
|
|
48960
49178
|
// src/commands/research/languages.ts
|
|
48961
|
-
import { defineCommand as
|
|
49179
|
+
import { defineCommand as defineCommand178 } from "citty";
|
|
48962
49180
|
registerSchema({
|
|
48963
49181
|
command: "research.languages",
|
|
48964
49182
|
description: "List all supported language codes for --language flag in research commands.",
|
|
@@ -48988,7 +49206,7 @@ var FIELDS10 = {
|
|
|
48988
49206
|
code: "Language code to pass as --language",
|
|
48989
49207
|
name: "Language name (also accepted by --language)"
|
|
48990
49208
|
};
|
|
48991
|
-
var languagesCommand2 =
|
|
49209
|
+
var languagesCommand2 = defineCommand178({
|
|
48992
49210
|
meta: {
|
|
48993
49211
|
name: "languages",
|
|
48994
49212
|
description: "List all supported language codes for --language flag."
|
|
@@ -48999,7 +49217,7 @@ var languagesCommand2 = defineCommand177({
|
|
|
48999
49217
|
});
|
|
49000
49218
|
|
|
49001
49219
|
// src/commands/research/lighthouse.ts
|
|
49002
|
-
import { defineCommand as
|
|
49220
|
+
import { defineCommand as defineCommand179 } from "citty";
|
|
49003
49221
|
registerSchema({
|
|
49004
49222
|
command: "research.lighthouse",
|
|
49005
49223
|
description: "Landing page performance audit. Returns metrics that affect Google Ads Quality Score and CPC.",
|
|
@@ -49018,7 +49236,7 @@ var FIELDS11 = {
|
|
|
49018
49236
|
speed_index_ms: "Speed Index in ms (good: < 3400)",
|
|
49019
49237
|
interactive_ms: "Time to Interactive in ms (good: < 3800)"
|
|
49020
49238
|
};
|
|
49021
|
-
var lighthouseCommand =
|
|
49239
|
+
var lighthouseCommand = defineCommand179({
|
|
49022
49240
|
meta: {
|
|
49023
49241
|
name: "lighthouse",
|
|
49024
49242
|
description: `Landing page performance audit. Metrics affecting Google Ads Quality Score.
|
|
@@ -49056,7 +49274,7 @@ Examples:
|
|
|
49056
49274
|
});
|
|
49057
49275
|
|
|
49058
49276
|
// src/commands/research/relevant-pages.ts
|
|
49059
|
-
import { defineCommand as
|
|
49277
|
+
import { defineCommand as defineCommand180 } from "citty";
|
|
49060
49278
|
registerSchema({
|
|
49061
49279
|
command: "research.relevant-pages",
|
|
49062
49280
|
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).",
|
|
@@ -49082,7 +49300,7 @@ var FIELDS12 = {
|
|
|
49082
49300
|
keywords: "Total organic keywords the page ranks for",
|
|
49083
49301
|
top_10: "Keywords in positions 1-10"
|
|
49084
49302
|
};
|
|
49085
|
-
var relevantPagesCommand =
|
|
49303
|
+
var relevantPagesCommand = defineCommand180({
|
|
49086
49304
|
meta: {
|
|
49087
49305
|
name: "relevant-pages",
|
|
49088
49306
|
description: `Get the top pages of a competitor domain with traffic data.
|
|
@@ -49129,7 +49347,7 @@ Examples:
|
|
|
49129
49347
|
});
|
|
49130
49348
|
|
|
49131
49349
|
// src/commands/research/web.ts
|
|
49132
|
-
import { defineCommand as
|
|
49350
|
+
import { defineCommand as defineCommand181 } from "citty";
|
|
49133
49351
|
registerSchema({
|
|
49134
49352
|
command: "research.web",
|
|
49135
49353
|
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).",
|
|
@@ -49180,7 +49398,7 @@ async function runDeepResearch(question) {
|
|
|
49180
49398
|
}
|
|
49181
49399
|
throw new Error("Deep research timed out");
|
|
49182
49400
|
}
|
|
49183
|
-
var webCommand =
|
|
49401
|
+
var webCommand = defineCommand181({
|
|
49184
49402
|
meta: {
|
|
49185
49403
|
name: "web",
|
|
49186
49404
|
description: `Search the web with AI to answer any open-ended marketing question. Uses live internet data via Google Search.
|
|
@@ -49242,7 +49460,7 @@ Examples:
|
|
|
49242
49460
|
});
|
|
49243
49461
|
|
|
49244
49462
|
// src/commands/research/index.ts
|
|
49245
|
-
var researchCommand =
|
|
49463
|
+
var researchCommand = defineCommand182({
|
|
49246
49464
|
meta: {
|
|
49247
49465
|
name: "research",
|
|
49248
49466
|
description: `Competitive intelligence and AI-powered research commands.
|
|
@@ -49253,6 +49471,7 @@ Commands:
|
|
|
49253
49471
|
advertisers \u2014 Who's bidding on a keyword?
|
|
49254
49472
|
autocomplete \u2014 Google Autocomplete suggestions
|
|
49255
49473
|
intent \u2014 Google Search intent classification
|
|
49474
|
+
keyword-metrics \u2014 Volume/CPC/competition for keywords you name (no domain)
|
|
49256
49475
|
keywords-for-site \u2014 Keywords a domain bids on
|
|
49257
49476
|
keyword-gap \u2014 Keywords they have that we don't
|
|
49258
49477
|
relevant-pages \u2014 Top pages of a competitor domain
|
|
@@ -49266,6 +49485,7 @@ Examples:
|
|
|
49266
49485
|
baker research fetch "https://competitor.com/pricing"
|
|
49267
49486
|
baker research advertisers "running shoes"
|
|
49268
49487
|
baker research intent "buy running shoes,best running shoes 2026"
|
|
49488
|
+
baker research keyword-metrics "chatbot whatsapp,crm whatsapp" --location mx --language es
|
|
49269
49489
|
baker research keywords-for-site "competitor.com"
|
|
49270
49490
|
baker research keyword-gap "them.com" "us.com"
|
|
49271
49491
|
Full guide: __tooling__/docs/tools/baker/research.md`
|
|
@@ -49277,6 +49497,7 @@ Full guide: __tooling__/docs/tools/baker/research.md`
|
|
|
49277
49497
|
autocomplete: autocompleteCommand,
|
|
49278
49498
|
countries: countriesCommand,
|
|
49279
49499
|
intent: intentCommand,
|
|
49500
|
+
"keyword-metrics": keywordMetricsCommand,
|
|
49280
49501
|
"keywords-for-site": keywordsForSiteCommand,
|
|
49281
49502
|
"keyword-gap": keywordGapCommand,
|
|
49282
49503
|
languages: languagesCommand2,
|
|
@@ -49286,10 +49507,10 @@ Full guide: __tooling__/docs/tools/baker/research.md`
|
|
|
49286
49507
|
});
|
|
49287
49508
|
|
|
49288
49509
|
// src/commands/scheduled-actions/index.ts
|
|
49289
|
-
import { defineCommand as
|
|
49510
|
+
import { defineCommand as defineCommand190 } from "citty";
|
|
49290
49511
|
|
|
49291
49512
|
// src/commands/scheduled-actions/create.ts
|
|
49292
|
-
import { defineCommand as
|
|
49513
|
+
import { defineCommand as defineCommand183 } from "citty";
|
|
49293
49514
|
|
|
49294
49515
|
// src/commands/scheduled-actions/shared.ts
|
|
49295
49516
|
var TEMP_SCHEDULED_ACTION_PREFIX = "temp_sched_";
|
|
@@ -49445,7 +49666,7 @@ registerSchema({
|
|
|
49445
49666
|
}
|
|
49446
49667
|
}
|
|
49447
49668
|
});
|
|
49448
|
-
var createCommand3 =
|
|
49669
|
+
var createCommand3 = defineCommand183({
|
|
49449
49670
|
meta: {
|
|
49450
49671
|
name: "create",
|
|
49451
49672
|
description: 'Stage a scheduled action. Example: baker scheduled-actions create --name "Weekly report" --description "..." --cron "0 9 * * MON"'
|
|
@@ -49504,7 +49725,7 @@ var createCommand3 = defineCommand182({
|
|
|
49504
49725
|
});
|
|
49505
49726
|
|
|
49506
49727
|
// src/commands/scheduled-actions/delete.ts
|
|
49507
|
-
import { defineCommand as
|
|
49728
|
+
import { defineCommand as defineCommand184 } from "citty";
|
|
49508
49729
|
registerSchema({
|
|
49509
49730
|
command: "scheduled-actions.delete",
|
|
49510
49731
|
description: "Stage deletion of a published scheduled action or cancellation of a temp_sched_* draft creation.",
|
|
@@ -49512,7 +49733,7 @@ registerSchema({
|
|
|
49512
49733
|
id: { type: "string", description: "Published scheduled action ID or temp_sched_* draft ID", required: true }
|
|
49513
49734
|
}
|
|
49514
49735
|
});
|
|
49515
|
-
var deleteCommand3 =
|
|
49736
|
+
var deleteCommand3 = defineCommand184({
|
|
49516
49737
|
meta: {
|
|
49517
49738
|
name: "delete",
|
|
49518
49739
|
description: "Stage scheduled action deletion. Example: baker scheduled-actions delete <id-or-temp_sched_id>"
|
|
@@ -49541,7 +49762,7 @@ var deleteCommand3 = defineCommand183({
|
|
|
49541
49762
|
});
|
|
49542
49763
|
|
|
49543
49764
|
// src/commands/scheduled-actions/get.ts
|
|
49544
|
-
import { defineCommand as
|
|
49765
|
+
import { defineCommand as defineCommand185 } from "citty";
|
|
49545
49766
|
registerSchema({
|
|
49546
49767
|
command: "scheduled-actions.get",
|
|
49547
49768
|
description: "Get a published scheduled action or a temp_sched_* draft-created scheduled action.",
|
|
@@ -49550,7 +49771,7 @@ registerSchema({
|
|
|
49550
49771
|
chat: { type: "string", description: CHAT_READ_ARG.description, required: false }
|
|
49551
49772
|
}
|
|
49552
49773
|
});
|
|
49553
|
-
var getCommand4 =
|
|
49774
|
+
var getCommand4 = defineCommand185({
|
|
49554
49775
|
meta: {
|
|
49555
49776
|
name: "get",
|
|
49556
49777
|
description: "Get a scheduled action. Example: baker scheduled-actions get <id-or-temp_sched_id>"
|
|
@@ -49589,7 +49810,7 @@ var getCommand4 = defineCommand184({
|
|
|
49589
49810
|
});
|
|
49590
49811
|
|
|
49591
49812
|
// src/commands/scheduled-actions/list.ts
|
|
49592
|
-
import { defineCommand as
|
|
49813
|
+
import { defineCommand as defineCommand186 } from "citty";
|
|
49593
49814
|
registerSchema({
|
|
49594
49815
|
command: "scheduled-actions.list",
|
|
49595
49816
|
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.",
|
|
@@ -49597,7 +49818,7 @@ registerSchema({
|
|
|
49597
49818
|
chat: { type: "string", description: CHAT_READ_ARG.description, required: false }
|
|
49598
49819
|
}
|
|
49599
49820
|
});
|
|
49600
|
-
var listCommand15 =
|
|
49821
|
+
var listCommand15 = defineCommand186({
|
|
49601
49822
|
meta: {
|
|
49602
49823
|
name: "list",
|
|
49603
49824
|
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."
|
|
@@ -49622,7 +49843,7 @@ var listCommand15 = defineCommand185({
|
|
|
49622
49843
|
// src/commands/scheduled-actions/templates.ts
|
|
49623
49844
|
import { readFile as readFile23 } from "fs/promises";
|
|
49624
49845
|
import path36 from "path";
|
|
49625
|
-
import { defineCommand as
|
|
49846
|
+
import { defineCommand as defineCommand187 } from "citty";
|
|
49626
49847
|
registerSchema({
|
|
49627
49848
|
command: "scheduled-actions.templates",
|
|
49628
49849
|
description: "The recipes available to this company: the ones Baker ships plus the ones they wrote themselves, each with its id, what it produces and how often it is meant to run. Read this before proposing a company's automation, so every recipe you name is one that exists. Also how a company gets a recipe of its own \u2014 save a brief, prove it runs, then publish it.",
|
|
@@ -49677,7 +49898,7 @@ registerSchema({
|
|
|
49677
49898
|
}
|
|
49678
49899
|
}
|
|
49679
49900
|
});
|
|
49680
|
-
var templatesCommand =
|
|
49901
|
+
var templatesCommand = defineCommand187({
|
|
49681
49902
|
meta: {
|
|
49682
49903
|
name: "templates",
|
|
49683
49904
|
description: `The recipes this company can run \u2014 Baker's own plus theirs, with what each one produces.
|
|
@@ -49769,7 +49990,7 @@ Full guide: __tooling__/docs/tools/baker/scheduled-actions.md`
|
|
|
49769
49990
|
});
|
|
49770
49991
|
|
|
49771
49992
|
// src/commands/scheduled-actions/trigger.ts
|
|
49772
|
-
import { defineCommand as
|
|
49993
|
+
import { defineCommand as defineCommand188 } from "citty";
|
|
49773
49994
|
registerSchema({
|
|
49774
49995
|
command: "scheduled-actions.trigger",
|
|
49775
49996
|
description: "Immediately trigger a published scheduled action. Does not require BAKER_CHAT_ID and rejects temp_sched_* IDs.",
|
|
@@ -49777,7 +49998,7 @@ registerSchema({
|
|
|
49777
49998
|
id: { type: "string", description: "Published scheduled action ID", required: true }
|
|
49778
49999
|
}
|
|
49779
50000
|
});
|
|
49780
|
-
var triggerCommand =
|
|
50001
|
+
var triggerCommand = defineCommand188({
|
|
49781
50002
|
meta: {
|
|
49782
50003
|
name: "trigger",
|
|
49783
50004
|
description: "Immediately trigger a published scheduled action. Example: baker scheduled-actions trigger <id>"
|
|
@@ -49814,7 +50035,7 @@ var triggerCommand = defineCommand187({
|
|
|
49814
50035
|
});
|
|
49815
50036
|
|
|
49816
50037
|
// src/commands/scheduled-actions/update.ts
|
|
49817
|
-
import { defineCommand as
|
|
50038
|
+
import { defineCommand as defineCommand189 } from "citty";
|
|
49818
50039
|
registerSchema({
|
|
49819
50040
|
command: "scheduled-actions.update",
|
|
49820
50041
|
description: "Stage an update to a published scheduled action or temp_sched_* draft-created scheduled action.",
|
|
@@ -49845,7 +50066,7 @@ registerSchema({
|
|
|
49845
50066
|
prompt: { type: "string", description: "Replacement additional spawned-agent instructions", required: false }
|
|
49846
50067
|
}
|
|
49847
50068
|
});
|
|
49848
|
-
var updateCommand3 =
|
|
50069
|
+
var updateCommand3 = defineCommand189({
|
|
49849
50070
|
meta: {
|
|
49850
50071
|
name: "update",
|
|
49851
50072
|
description: "Stage a scheduled action update. Examples: baker scheduled-actions update <id> --enabled false | baker scheduled-actions update <id> --mode publish"
|
|
@@ -49923,7 +50144,7 @@ var updateCommand3 = defineCommand188({
|
|
|
49923
50144
|
});
|
|
49924
50145
|
|
|
49925
50146
|
// src/commands/scheduled-actions/index.ts
|
|
49926
|
-
var scheduledActionsCommand =
|
|
50147
|
+
var scheduledActionsCommand = defineCommand190({
|
|
49927
50148
|
meta: {
|
|
49928
50149
|
name: "scheduled-actions",
|
|
49929
50150
|
description: `Manage Scheduled Actions. Subcommands: list, get, create, update, delete, trigger, templates.
|
|
@@ -49952,14 +50173,14 @@ Full guide: __tooling__/docs/tools/baker/scheduled-actions.md`
|
|
|
49952
50173
|
});
|
|
49953
50174
|
|
|
49954
50175
|
// src/commands/schema.ts
|
|
49955
|
-
import { defineCommand as
|
|
50176
|
+
import { defineCommand as defineCommand191 } from "citty";
|
|
49956
50177
|
function narrowToFamily(commandName, available) {
|
|
49957
50178
|
const segments = commandName.split(".");
|
|
49958
50179
|
const prefix = segments[0] === "ads" && segments[1] ? `ads.${segments[1]}.` : `${segments[0]}.`;
|
|
49959
50180
|
const siblings = available.filter((name) => name.startsWith(prefix));
|
|
49960
50181
|
return siblings.length > 0 ? siblings : available;
|
|
49961
50182
|
}
|
|
49962
|
-
var schemaCommand2 =
|
|
50183
|
+
var schemaCommand2 = defineCommand191({
|
|
49963
50184
|
meta: {
|
|
49964
50185
|
name: "schema",
|
|
49965
50186
|
description: "Inspect command argument schemas (for AI agent introspection). Lists all commands if no argument given. Example: baker schema images.search"
|
|
@@ -50003,10 +50224,10 @@ var schemaCommand2 = defineCommand190({
|
|
|
50003
50224
|
});
|
|
50004
50225
|
|
|
50005
50226
|
// src/commands/studio/index.ts
|
|
50006
|
-
import { defineCommand as
|
|
50227
|
+
import { defineCommand as defineCommand200 } from "citty";
|
|
50007
50228
|
|
|
50008
50229
|
// src/commands/studio/animate.ts
|
|
50009
|
-
import { defineCommand as
|
|
50230
|
+
import { defineCommand as defineCommand192 } from "citty";
|
|
50010
50231
|
|
|
50011
50232
|
// src/commands/studio/batch.ts
|
|
50012
50233
|
function projectBatch(generation, full) {
|
|
@@ -50457,7 +50678,7 @@ function costHintsFor(body) {
|
|
|
50457
50678
|
}
|
|
50458
50679
|
return hints2;
|
|
50459
50680
|
}
|
|
50460
|
-
var animateCommand =
|
|
50681
|
+
var animateCommand = defineCommand192({
|
|
50461
50682
|
meta: {
|
|
50462
50683
|
name: "animate",
|
|
50463
50684
|
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"
|
|
@@ -50576,7 +50797,7 @@ var animateCommand = defineCommand191({
|
|
|
50576
50797
|
});
|
|
50577
50798
|
|
|
50578
50799
|
// src/commands/studio/generate.ts
|
|
50579
|
-
import { defineCommand as
|
|
50800
|
+
import { defineCommand as defineCommand193 } from "citty";
|
|
50580
50801
|
var MODEL_LIST2 = IMAGE_MODEL_IDS;
|
|
50581
50802
|
var DEFAULT_MAX_WAIT_MS2 = 24e4;
|
|
50582
50803
|
registerSchema({
|
|
@@ -50712,7 +50933,7 @@ function buildGenerateBody(args, prompt) {
|
|
|
50712
50933
|
}
|
|
50713
50934
|
return body;
|
|
50714
50935
|
}
|
|
50715
|
-
var generateCommand =
|
|
50936
|
+
var generateCommand = defineCommand193({
|
|
50716
50937
|
meta: {
|
|
50717
50938
|
name: "generate",
|
|
50718
50939
|
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]]'"
|
|
@@ -50790,7 +51011,7 @@ var generateCommand = defineCommand192({
|
|
|
50790
51011
|
});
|
|
50791
51012
|
|
|
50792
51013
|
// src/commands/studio/get.ts
|
|
50793
|
-
import { defineCommand as
|
|
51014
|
+
import { defineCommand as defineCommand194 } from "citty";
|
|
50794
51015
|
registerSchema({
|
|
50795
51016
|
command: "studio.get",
|
|
50796
51017
|
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.",
|
|
@@ -50799,7 +51020,7 @@ registerSchema({
|
|
|
50799
51020
|
full: { type: "boolean", description: "Include settings, references and attribution", required: false }
|
|
50800
51021
|
}
|
|
50801
51022
|
});
|
|
50802
|
-
var getCommand5 =
|
|
51023
|
+
var getCommand5 = defineCommand194({
|
|
50803
51024
|
meta: {
|
|
50804
51025
|
name: "get",
|
|
50805
51026
|
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"
|
|
@@ -50828,7 +51049,7 @@ var getCommand5 = defineCommand193({
|
|
|
50828
51049
|
});
|
|
50829
51050
|
|
|
50830
51051
|
// src/commands/studio/improve.ts
|
|
50831
|
-
import { defineCommand as
|
|
51052
|
+
import { defineCommand as defineCommand195 } from "citty";
|
|
50832
51053
|
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.";
|
|
50833
51054
|
registerSchema({
|
|
50834
51055
|
command: "studio.improve",
|
|
@@ -50853,7 +51074,7 @@ registerSchema({
|
|
|
50853
51074
|
}
|
|
50854
51075
|
}
|
|
50855
51076
|
});
|
|
50856
|
-
var improveCommand =
|
|
51077
|
+
var improveCommand = defineCommand195({
|
|
50857
51078
|
meta: {
|
|
50858
51079
|
name: "improve",
|
|
50859
51080
|
description: `${DESCRIPTION}
|
|
@@ -50897,7 +51118,7 @@ Examples:
|
|
|
50897
51118
|
});
|
|
50898
51119
|
|
|
50899
51120
|
// src/commands/studio/keep.ts
|
|
50900
|
-
import { defineCommand as
|
|
51121
|
+
import { defineCommand as defineCommand196 } from "citty";
|
|
50901
51122
|
registerSchema({
|
|
50902
51123
|
command: "studio.keep",
|
|
50903
51124
|
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.",
|
|
@@ -50907,7 +51128,7 @@ registerSchema({
|
|
|
50907
51128
|
undo: { type: "boolean", description: "Un-star an image, or take a kept clip back out", required: false }
|
|
50908
51129
|
}
|
|
50909
51130
|
});
|
|
50910
|
-
var keepCommand =
|
|
51131
|
+
var keepCommand = defineCommand196({
|
|
50911
51132
|
meta: {
|
|
50912
51133
|
name: "keep",
|
|
50913
51134
|
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"
|
|
@@ -50958,7 +51179,7 @@ var keepCommand = defineCommand195({
|
|
|
50958
51179
|
});
|
|
50959
51180
|
|
|
50960
51181
|
// src/commands/studio/list.ts
|
|
50961
|
-
import { defineCommand as
|
|
51182
|
+
import { defineCommand as defineCommand197 } from "citty";
|
|
50962
51183
|
registerSchema({
|
|
50963
51184
|
command: "studio.list",
|
|
50964
51185
|
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.",
|
|
@@ -50969,7 +51190,7 @@ registerSchema({
|
|
|
50969
51190
|
full: { type: "boolean", description: "Include settings, references and attribution", required: false }
|
|
50970
51191
|
}
|
|
50971
51192
|
});
|
|
50972
|
-
var listCommand16 =
|
|
51193
|
+
var listCommand16 = defineCommand197({
|
|
50973
51194
|
meta: {
|
|
50974
51195
|
name: "list",
|
|
50975
51196
|
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"
|
|
@@ -51003,7 +51224,7 @@ var listCommand16 = defineCommand196({
|
|
|
51003
51224
|
});
|
|
51004
51225
|
|
|
51005
51226
|
// src/commands/studio/models.ts
|
|
51006
|
-
import { defineCommand as
|
|
51227
|
+
import { defineCommand as defineCommand198 } from "citty";
|
|
51007
51228
|
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.";
|
|
51008
51229
|
registerSchema({
|
|
51009
51230
|
command: "studio.models",
|
|
@@ -51090,7 +51311,7 @@ function buildModelCards(kind, model) {
|
|
|
51090
51311
|
const selected = model ? ids.filter((id) => id === model) : ids;
|
|
51091
51312
|
return selected.map((id) => build(id));
|
|
51092
51313
|
}
|
|
51093
|
-
var modelsCommand =
|
|
51314
|
+
var modelsCommand = defineCommand198({
|
|
51094
51315
|
meta: {
|
|
51095
51316
|
name: "models",
|
|
51096
51317
|
description: `${DESCRIPTION2}
|
|
@@ -51137,13 +51358,13 @@ Examples:
|
|
|
51137
51358
|
});
|
|
51138
51359
|
|
|
51139
51360
|
// src/commands/studio/skills.ts
|
|
51140
|
-
import { defineCommand as
|
|
51361
|
+
import { defineCommand as defineCommand199 } from "citty";
|
|
51141
51362
|
registerSchema({
|
|
51142
51363
|
command: "studio.skills",
|
|
51143
51364
|
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.",
|
|
51144
51365
|
args: {}
|
|
51145
51366
|
});
|
|
51146
|
-
var skillsCommand =
|
|
51367
|
+
var skillsCommand = defineCommand199({
|
|
51147
51368
|
meta: {
|
|
51148
51369
|
name: "skills",
|
|
51149
51370
|
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"
|
|
@@ -51167,7 +51388,7 @@ var skillsCommand = defineCommand198({
|
|
|
51167
51388
|
});
|
|
51168
51389
|
|
|
51169
51390
|
// src/commands/studio/index.ts
|
|
51170
|
-
var studioCommand =
|
|
51391
|
+
var studioCommand = defineCommand200({
|
|
51171
51392
|
meta: {
|
|
51172
51393
|
name: "studio",
|
|
51173
51394
|
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.
|
|
@@ -51210,10 +51431,10 @@ Full guide: __tooling__/docs/tools/baker/studio.md`
|
|
|
51210
51431
|
});
|
|
51211
51432
|
|
|
51212
51433
|
// src/commands/tag-manager/index.ts
|
|
51213
|
-
import { defineCommand as
|
|
51434
|
+
import { defineCommand as defineCommand204 } from "citty";
|
|
51214
51435
|
|
|
51215
51436
|
// src/commands/tag-manager/draft.ts
|
|
51216
|
-
import { defineCommand as
|
|
51437
|
+
import { defineCommand as defineCommand201 } from "citty";
|
|
51217
51438
|
|
|
51218
51439
|
// src/commands/tag-manager/shared.ts
|
|
51219
51440
|
import { readFileSync as readFileSync16 } from "fs";
|
|
@@ -51336,13 +51557,13 @@ registerSchema({
|
|
|
51336
51557
|
chat: { type: "string", description: CHAT_READ_ARG.description, required: false }
|
|
51337
51558
|
}
|
|
51338
51559
|
});
|
|
51339
|
-
var draftCommand4 =
|
|
51560
|
+
var draftCommand4 = defineCommand201({
|
|
51340
51561
|
meta: {
|
|
51341
51562
|
name: "draft",
|
|
51342
51563
|
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."
|
|
51343
51564
|
},
|
|
51344
51565
|
subCommands: {
|
|
51345
|
-
list:
|
|
51566
|
+
list: defineCommand201({
|
|
51346
51567
|
meta: {
|
|
51347
51568
|
name: "list",
|
|
51348
51569
|
description: "Review everything staged on this chat (--json for the raw envelope)"
|
|
@@ -51355,7 +51576,7 @@ var draftCommand4 = defineCommand200({
|
|
|
51355
51576
|
await draftList2(args.json === true, args.chat);
|
|
51356
51577
|
}
|
|
51357
51578
|
}),
|
|
51358
|
-
show:
|
|
51579
|
+
show: defineCommand201({
|
|
51359
51580
|
meta: {
|
|
51360
51581
|
name: "show",
|
|
51361
51582
|
description: "Print the full staged payload for one change \u2014 the receipt to verify it looks right before publish (never truncated)."
|
|
@@ -51372,7 +51593,7 @@ var draftCommand4 = defineCommand200({
|
|
|
51372
51593
|
);
|
|
51373
51594
|
}
|
|
51374
51595
|
}),
|
|
51375
|
-
amend:
|
|
51596
|
+
amend: defineCommand201({
|
|
51376
51597
|
meta: {
|
|
51377
51598
|
name: "amend",
|
|
51378
51599
|
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."
|
|
@@ -51389,7 +51610,7 @@ var draftCommand4 = defineCommand200({
|
|
|
51389
51610
|
});
|
|
51390
51611
|
}
|
|
51391
51612
|
}),
|
|
51392
|
-
remove:
|
|
51613
|
+
remove: defineCommand201({
|
|
51393
51614
|
meta: { name: "remove", description: "Remove one staged change (cascades to anything depending on it)" },
|
|
51394
51615
|
args: { ref: { type: "positional", description: "Staged ref (gtm_temp_*) or target", required: false } },
|
|
51395
51616
|
run: async ({ args }) => {
|
|
@@ -51398,7 +51619,7 @@ var draftCommand4 = defineCommand200({
|
|
|
51398
51619
|
});
|
|
51399
51620
|
}
|
|
51400
51621
|
}),
|
|
51401
|
-
clear:
|
|
51622
|
+
clear: defineCommand201({
|
|
51402
51623
|
meta: { name: "clear", description: "Discard all Tag Manager changes staged on this chat" },
|
|
51403
51624
|
run: async () => {
|
|
51404
51625
|
await draftAction3("/api/tag-manager/draft/clear", {});
|
|
@@ -51408,7 +51629,7 @@ var draftCommand4 = defineCommand200({
|
|
|
51408
51629
|
});
|
|
51409
51630
|
|
|
51410
51631
|
// src/commands/tag-manager/read.ts
|
|
51411
|
-
import { defineCommand as
|
|
51632
|
+
import { defineCommand as defineCommand202 } from "citty";
|
|
51412
51633
|
registerSchema({
|
|
51413
51634
|
command: "tagManager.containers",
|
|
51414
51635
|
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.",
|
|
@@ -51449,7 +51670,7 @@ function containersHints(containers) {
|
|
|
51449
51670
|
}))
|
|
51450
51671
|
});
|
|
51451
51672
|
}
|
|
51452
|
-
var containersCommand =
|
|
51673
|
+
var containersCommand = defineCommand202({
|
|
51453
51674
|
meta: {
|
|
51454
51675
|
name: "containers",
|
|
51455
51676
|
description: `List Tag Manager containers reachable by this company's connection.
|
|
@@ -51466,7 +51687,7 @@ Start here:
|
|
|
51466
51687
|
}
|
|
51467
51688
|
}
|
|
51468
51689
|
});
|
|
51469
|
-
var readCommand =
|
|
51690
|
+
var readCommand = defineCommand202({
|
|
51470
51691
|
meta: {
|
|
51471
51692
|
name: "read",
|
|
51472
51693
|
description: `Read the current contents of the Tag Manager container \u2014 always do this before staging changes.
|
|
@@ -51508,7 +51729,7 @@ Examples:
|
|
|
51508
51729
|
});
|
|
51509
51730
|
|
|
51510
51731
|
// src/commands/tag-manager/write-commands.ts
|
|
51511
|
-
import { defineCommand as
|
|
51732
|
+
import { defineCommand as defineCommand203 } from "citty";
|
|
51512
51733
|
var CONTAINER_ARG_DESCRIPTION = "Numeric container id (optional only when one container is connected \u2014 run `baker tag-manager containers`)";
|
|
51513
51734
|
var ENTITIES = [
|
|
51514
51735
|
{
|
|
@@ -51564,10 +51785,10 @@ for (const { entity, noun, createHint } of ENTITIES) {
|
|
|
51564
51785
|
});
|
|
51565
51786
|
}
|
|
51566
51787
|
function entityCommand(entity, noun, example) {
|
|
51567
|
-
return
|
|
51788
|
+
return defineCommand203({
|
|
51568
51789
|
meta: { name: entity, description: `Stage ${noun} changes on this chat's Tag Manager draft` },
|
|
51569
51790
|
subCommands: {
|
|
51570
|
-
create:
|
|
51791
|
+
create: defineCommand203({
|
|
51571
51792
|
meta: {
|
|
51572
51793
|
name: "create",
|
|
51573
51794
|
description: `Stage a new ${noun}
|
|
@@ -51589,7 +51810,7 @@ Examples:
|
|
|
51589
51810
|
});
|
|
51590
51811
|
}
|
|
51591
51812
|
}),
|
|
51592
|
-
update:
|
|
51813
|
+
update: defineCommand203({
|
|
51593
51814
|
meta: {
|
|
51594
51815
|
name: "update",
|
|
51595
51816
|
description: `Stage an update to an existing ${noun} (pass its id or path)`
|
|
@@ -51609,7 +51830,7 @@ Examples:
|
|
|
51609
51830
|
});
|
|
51610
51831
|
}
|
|
51611
51832
|
}),
|
|
51612
|
-
delete:
|
|
51833
|
+
delete: defineCommand203({
|
|
51613
51834
|
meta: { name: "delete", description: `Stage the deletion of a ${noun} (pass its id or path)` },
|
|
51614
51835
|
args: {
|
|
51615
51836
|
id: { type: "positional", description: `${noun} id or path`, required: false },
|
|
@@ -51650,7 +51871,7 @@ function builtinTypes(args) {
|
|
|
51650
51871
|
}
|
|
51651
51872
|
return raw.split(",").map((entry) => entry.trim());
|
|
51652
51873
|
}
|
|
51653
|
-
var builtinCommand =
|
|
51874
|
+
var builtinCommand = defineCommand203({
|
|
51654
51875
|
meta: {
|
|
51655
51876
|
name: "builtin",
|
|
51656
51877
|
description: `Enable or disable built-in variables
|
|
@@ -51660,7 +51881,7 @@ Examples:
|
|
|
51660
51881
|
baker tag-manager builtin disable --types formId`
|
|
51661
51882
|
},
|
|
51662
51883
|
subCommands: {
|
|
51663
|
-
enable:
|
|
51884
|
+
enable: defineCommand203({
|
|
51664
51885
|
meta: { name: "enable", description: "Stage enabling built-in variables" },
|
|
51665
51886
|
args: {
|
|
51666
51887
|
types: { type: "string", description: "Comma-separated types", required: false },
|
|
@@ -51674,7 +51895,7 @@ Examples:
|
|
|
51674
51895
|
});
|
|
51675
51896
|
}
|
|
51676
51897
|
}),
|
|
51677
|
-
disable:
|
|
51898
|
+
disable: defineCommand203({
|
|
51678
51899
|
meta: { name: "disable", description: "Stage disabling built-in variables" },
|
|
51679
51900
|
args: {
|
|
51680
51901
|
types: { type: "string", description: "Comma-separated types", required: false },
|
|
@@ -51692,7 +51913,7 @@ Examples:
|
|
|
51692
51913
|
});
|
|
51693
51914
|
|
|
51694
51915
|
// src/commands/tag-manager/index.ts
|
|
51695
|
-
var tagManagerCommand =
|
|
51916
|
+
var tagManagerCommand = defineCommand204({
|
|
51696
51917
|
meta: {
|
|
51697
51918
|
name: "tag-manager",
|
|
51698
51919
|
description: `Read and change what lives inside the client's Google Tag Manager container \u2014 tags, triggers, variables, folders and built-in variables.
|
|
@@ -51729,7 +51950,7 @@ Full guide: __tooling__/docs/tools/baker/tag-manager.md`
|
|
|
51729
51950
|
});
|
|
51730
51951
|
|
|
51731
51952
|
// src/commands/tags/index.ts
|
|
51732
|
-
import { defineCommand as
|
|
51953
|
+
import { defineCommand as defineCommand205 } from "citty";
|
|
51733
51954
|
|
|
51734
51955
|
// src/commands/tags/shared.ts
|
|
51735
51956
|
function failApi3(err) {
|
|
@@ -51798,7 +52019,7 @@ async function listTags(json) {
|
|
|
51798
52019
|
var listArgs9 = {
|
|
51799
52020
|
json: { type: "boolean", description: "Print the raw JSON envelope instead of the readable list" }
|
|
51800
52021
|
};
|
|
51801
|
-
var listCommand17 =
|
|
52022
|
+
var listCommand17 = defineCommand205({
|
|
51802
52023
|
meta: {
|
|
51803
52024
|
name: "list",
|
|
51804
52025
|
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"
|
|
@@ -51817,7 +52038,7 @@ async function listDraft3(chat) {
|
|
|
51817
52038
|
failApi3(err);
|
|
51818
52039
|
}
|
|
51819
52040
|
}
|
|
51820
|
-
var draftCommand5 =
|
|
52041
|
+
var draftCommand5 = defineCommand205({
|
|
51821
52042
|
meta: {
|
|
51822
52043
|
name: "draft",
|
|
51823
52044
|
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."
|
|
@@ -51827,7 +52048,7 @@ var draftCommand5 = defineCommand204({
|
|
|
51827
52048
|
await listDraft3(args.chat);
|
|
51828
52049
|
}
|
|
51829
52050
|
});
|
|
51830
|
-
var tagsCommand4 =
|
|
52051
|
+
var tagsCommand4 = defineCommand205({
|
|
51831
52052
|
meta: {
|
|
51832
52053
|
name: "tags",
|
|
51833
52054
|
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.
|
|
@@ -51856,10 +52077,10 @@ Full guide: __tooling__/docs/tools/baker/tags.md`
|
|
|
51856
52077
|
});
|
|
51857
52078
|
|
|
51858
52079
|
// src/commands/testimonials/index.ts
|
|
51859
|
-
import { defineCommand as
|
|
52080
|
+
import { defineCommand as defineCommand209 } from "citty";
|
|
51860
52081
|
|
|
51861
52082
|
// src/commands/testimonials/get.ts
|
|
51862
|
-
import { defineCommand as
|
|
52083
|
+
import { defineCommand as defineCommand206 } from "citty";
|
|
51863
52084
|
registerSchema({
|
|
51864
52085
|
command: "testimonials.get",
|
|
51865
52086
|
description: "Get a single testimonial by ID",
|
|
@@ -51867,7 +52088,7 @@ registerSchema({
|
|
|
51867
52088
|
id: { type: "string", description: "Testimonial ID", required: true }
|
|
51868
52089
|
}
|
|
51869
52090
|
});
|
|
51870
|
-
var getCommand6 =
|
|
52091
|
+
var getCommand6 = defineCommand206({
|
|
51871
52092
|
meta: { name: "get", description: "Get a single testimonial by ID. Example: baker testimonials get j571abc123" },
|
|
51872
52093
|
args: {
|
|
51873
52094
|
id: { type: "positional", description: "Testimonial ID", required: false },
|
|
@@ -51904,7 +52125,7 @@ var getCommand6 = defineCommand205({
|
|
|
51904
52125
|
});
|
|
51905
52126
|
|
|
51906
52127
|
// src/commands/testimonials/list.ts
|
|
51907
|
-
import { defineCommand as
|
|
52128
|
+
import { defineCommand as defineCommand207 } from "citty";
|
|
51908
52129
|
|
|
51909
52130
|
// src/commands/testimonials/emptyCorpusHints.ts
|
|
51910
52131
|
function resolveEmptyReason({
|
|
@@ -52061,7 +52282,7 @@ function buildListParams(args) {
|
|
|
52061
52282
|
}
|
|
52062
52283
|
return params;
|
|
52063
52284
|
}
|
|
52064
|
-
var listCommand18 =
|
|
52285
|
+
var listCommand18 = defineCommand207({
|
|
52065
52286
|
meta: {
|
|
52066
52287
|
name: "list",
|
|
52067
52288
|
description: "List testimonials with optional filters. Example: baker testimonials list --source google --sentiment positive"
|
|
@@ -52121,7 +52342,7 @@ var listCommand18 = defineCommand206({
|
|
|
52121
52342
|
});
|
|
52122
52343
|
|
|
52123
52344
|
// src/commands/testimonials/search.ts
|
|
52124
|
-
import { defineCommand as
|
|
52345
|
+
import { defineCommand as defineCommand208 } from "citty";
|
|
52125
52346
|
var FILTER_FLAGS2 = ["source", "rating-min", "rating-max", "status", "sentiment", "language", "tags"];
|
|
52126
52347
|
function languageBiasHint(results, requestedLanguage) {
|
|
52127
52348
|
if (requestedLanguage) {
|
|
@@ -52200,7 +52421,7 @@ function buildSearchRequest(query, args) {
|
|
|
52200
52421
|
}
|
|
52201
52422
|
return body;
|
|
52202
52423
|
}
|
|
52203
|
-
var searchCommand3 =
|
|
52424
|
+
var searchCommand3 = defineCommand208({
|
|
52204
52425
|
meta: {
|
|
52205
52426
|
name: "search",
|
|
52206
52427
|
description: "Semantic search testimonials by text query. Uses hybrid BM25 + vector + reranking. Example: baker testimonials search 'great service' --rating-min 4"
|
|
@@ -52264,7 +52485,7 @@ var searchCommand3 = defineCommand207({
|
|
|
52264
52485
|
var tagsCommand5 = makeTagsCommand("testimonials", "testimonial", "/api/testimonials/tags");
|
|
52265
52486
|
|
|
52266
52487
|
// src/commands/testimonials/index.ts
|
|
52267
|
-
var testimonialsCommand =
|
|
52488
|
+
var testimonialsCommand = defineCommand209({
|
|
52268
52489
|
meta: {
|
|
52269
52490
|
name: "testimonials",
|
|
52270
52491
|
description: `Find and browse testimonials in Baker. Subcommands: search, get, list, tags.
|
|
@@ -52286,10 +52507,10 @@ Full guide: __tooling__/docs/tools/baker/testimonials.md`
|
|
|
52286
52507
|
});
|
|
52287
52508
|
|
|
52288
52509
|
// src/commands/videos/index.ts
|
|
52289
|
-
import { defineCommand as
|
|
52510
|
+
import { defineCommand as defineCommand216 } from "citty";
|
|
52290
52511
|
|
|
52291
52512
|
// src/commands/videos/delete.ts
|
|
52292
|
-
import { defineCommand as
|
|
52513
|
+
import { defineCommand as defineCommand210 } from "citty";
|
|
52293
52514
|
registerSchema({
|
|
52294
52515
|
command: "videos.delete",
|
|
52295
52516
|
description: "Delete a video by ID",
|
|
@@ -52303,7 +52524,7 @@ registerSchema({
|
|
|
52303
52524
|
}
|
|
52304
52525
|
}
|
|
52305
52526
|
});
|
|
52306
|
-
var deleteCommand4 =
|
|
52527
|
+
var deleteCommand4 = defineCommand210({
|
|
52307
52528
|
meta: {
|
|
52308
52529
|
name: "delete",
|
|
52309
52530
|
description: "Delete a video by ID. Use --dry-run to preview. Example: baker videos delete j571abc123 --dry-run"
|
|
@@ -52344,7 +52565,7 @@ var deleteCommand4 = defineCommand209({
|
|
|
52344
52565
|
});
|
|
52345
52566
|
|
|
52346
52567
|
// src/commands/videos/get.ts
|
|
52347
|
-
import { defineCommand as
|
|
52568
|
+
import { defineCommand as defineCommand211 } from "citty";
|
|
52348
52569
|
registerSchema({
|
|
52349
52570
|
command: "videos.get",
|
|
52350
52571
|
description: "Get a single video by ID",
|
|
@@ -52352,7 +52573,7 @@ registerSchema({
|
|
|
52352
52573
|
id: { type: "string", description: "Video ID", required: true }
|
|
52353
52574
|
}
|
|
52354
52575
|
});
|
|
52355
|
-
var getCommand7 =
|
|
52576
|
+
var getCommand7 = defineCommand211({
|
|
52356
52577
|
meta: { name: "get", description: "Get a single video by ID. Example: baker videos get j571abc123" },
|
|
52357
52578
|
args: {
|
|
52358
52579
|
id: { type: "positional", description: "Video ID", required: false },
|
|
@@ -52389,7 +52610,7 @@ var getCommand7 = defineCommand210({
|
|
|
52389
52610
|
});
|
|
52390
52611
|
|
|
52391
52612
|
// src/commands/videos/group.ts
|
|
52392
|
-
import { defineCommand as
|
|
52613
|
+
import { defineCommand as defineCommand212 } from "citty";
|
|
52393
52614
|
registerSchema({
|
|
52394
52615
|
command: "videos.group",
|
|
52395
52616
|
description: "List every clip and image that arrived in the same set as this video (carousel slides, one page)",
|
|
@@ -52398,7 +52619,7 @@ registerSchema({
|
|
|
52398
52619
|
"group-key": { type: "string", description: "The set key directly, when you already have it", required: false }
|
|
52399
52620
|
}
|
|
52400
52621
|
});
|
|
52401
|
-
var groupCommand2 =
|
|
52622
|
+
var groupCommand2 = defineCommand212({
|
|
52402
52623
|
meta: {
|
|
52403
52624
|
name: "group",
|
|
52404
52625
|
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>"
|
|
@@ -52421,7 +52642,7 @@ var groupCommand2 = defineCommand211({
|
|
|
52421
52642
|
import { mkdtemp as mkdtemp2, rm as rm7, stat as stat7 } from "fs/promises";
|
|
52422
52643
|
import { tmpdir as tmpdir3 } from "os";
|
|
52423
52644
|
import path37 from "path";
|
|
52424
|
-
import { defineCommand as
|
|
52645
|
+
import { defineCommand as defineCommand213 } from "citty";
|
|
52425
52646
|
|
|
52426
52647
|
// src/lib/streamUpload.ts
|
|
52427
52648
|
import { createHash as createHash2 } from "crypto";
|
|
@@ -52585,7 +52806,7 @@ registerSchema({
|
|
|
52585
52806
|
"dry-run": { type: "boolean", description: "Preview the operation without executing", required: false }
|
|
52586
52807
|
}
|
|
52587
52808
|
});
|
|
52588
|
-
var ingestCommand2 =
|
|
52809
|
+
var ingestCommand2 = defineCommand213({
|
|
52589
52810
|
meta: {
|
|
52590
52811
|
name: "ingest",
|
|
52591
52812
|
description: "Add a video to the library from a URL. A direct file URL is handed straight to Baker, which fetches it. A page URL (YouTube, TikTok, Vimeo, Instagram) is downloaded here first, then uploaded \u2014 and a direct URL that Baker cannot fetch falls back to that same path automatically.\n\nExample: baker videos ingest https://www.youtube.com/watch?v=abc123"
|
|
@@ -52847,7 +53068,7 @@ async function uploadToAssetStore(filePath, sizeBytes) {
|
|
|
52847
53068
|
}
|
|
52848
53069
|
|
|
52849
53070
|
// src/commands/videos/search.ts
|
|
52850
|
-
import { defineCommand as
|
|
53071
|
+
import { defineCommand as defineCommand214 } from "citty";
|
|
52851
53072
|
registerSchema({
|
|
52852
53073
|
command: "videos.search",
|
|
52853
53074
|
description: "Search videos by text query. Only returns ready videos.",
|
|
@@ -52857,7 +53078,7 @@ registerSchema({
|
|
|
52857
53078
|
tags: { type: "string", description: "Comma-separated tags to filter by", required: false }
|
|
52858
53079
|
}
|
|
52859
53080
|
});
|
|
52860
|
-
var searchCommand4 =
|
|
53081
|
+
var searchCommand4 = defineCommand214({
|
|
52861
53082
|
meta: {
|
|
52862
53083
|
name: "search",
|
|
52863
53084
|
description: "Semantic search videos by text query. Uses hybrid BM25 + vector + reranking. Example: baker videos search 'product demo' --tags tutorial"
|
|
@@ -52909,7 +53130,7 @@ var tagsCommand6 = makeTagsCommand("videos", "video", "/api/videos/tags");
|
|
|
52909
53130
|
// src/commands/videos/upload.ts
|
|
52910
53131
|
import { readFile as readFile24, stat as stat8 } from "fs/promises";
|
|
52911
53132
|
import { basename as basename3, extname as extname4 } from "path";
|
|
52912
|
-
import { defineCommand as
|
|
53133
|
+
import { defineCommand as defineCommand215 } from "citty";
|
|
52913
53134
|
var MIME_MAP = {
|
|
52914
53135
|
".mp4": "video/mp4",
|
|
52915
53136
|
".mov": "video/quicktime",
|
|
@@ -52951,7 +53172,7 @@ function detectContentType(filePath) {
|
|
|
52951
53172
|
function isRemoteUrl3(value) {
|
|
52952
53173
|
return /^https?:\/\//i.test(value);
|
|
52953
53174
|
}
|
|
52954
|
-
var uploadCommand2 =
|
|
53175
|
+
var uploadCommand2 = defineCommand215({
|
|
52955
53176
|
meta: {
|
|
52956
53177
|
name: "upload",
|
|
52957
53178
|
description: "Upload a video to Baker \u2014 accepts a local file path OR a remote http(s) URL.\n\nLocal: auto-detects content type and uploads via Mux direct upload.\nRemote: hands off to `videos ingest` (direct fetch, or download-then-upload for a YouTube/TikTok/Vimeo page).\n\nExamples:\n baker videos upload ./demo.mp4\n baker videos upload https://www.youtube.com/watch?v=abc123"
|
|
@@ -53035,7 +53256,7 @@ var uploadCommand2 = defineCommand214({
|
|
|
53035
53256
|
});
|
|
53036
53257
|
|
|
53037
53258
|
// src/commands/videos/index.ts
|
|
53038
|
-
var videosCommand =
|
|
53259
|
+
var videosCommand = defineCommand216({
|
|
53039
53260
|
meta: {
|
|
53040
53261
|
name: "videos",
|
|
53041
53262
|
description: `Find and manage videos in Baker. Subcommands: search, get, upload, ingest, delete, tags.
|
|
@@ -53062,10 +53283,10 @@ Full guide: __tooling__/docs/tools/baker/videos.md`
|
|
|
53062
53283
|
});
|
|
53063
53284
|
|
|
53064
53285
|
// src/commands/winning-ads/index.ts
|
|
53065
|
-
import { defineCommand as
|
|
53286
|
+
import { defineCommand as defineCommand229 } from "citty";
|
|
53066
53287
|
|
|
53067
53288
|
// src/commands/winning-ads/advertisers.ts
|
|
53068
|
-
import { defineCommand as
|
|
53289
|
+
import { defineCommand as defineCommand217 } from "citty";
|
|
53069
53290
|
|
|
53070
53291
|
// src/commands/winning-ads/shared.ts
|
|
53071
53292
|
function splitList2(value) {
|
|
@@ -53118,7 +53339,7 @@ function advertiserNormalizer(record, full) {
|
|
|
53118
53339
|
last_synced_at: record.last_synced_at ?? null
|
|
53119
53340
|
};
|
|
53120
53341
|
}
|
|
53121
|
-
var advertisersCommand2 =
|
|
53342
|
+
var advertisersCommand2 = defineCommand217({
|
|
53122
53343
|
meta: {
|
|
53123
53344
|
name: "advertisers",
|
|
53124
53345
|
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'
|
|
@@ -53176,7 +53397,7 @@ var advertisersCommand2 = defineCommand216({
|
|
|
53176
53397
|
});
|
|
53177
53398
|
|
|
53178
53399
|
// src/commands/winning-ads/brief.ts
|
|
53179
|
-
import { defineCommand as
|
|
53400
|
+
import { defineCommand as defineCommand218 } from "citty";
|
|
53180
53401
|
registerSchema({
|
|
53181
53402
|
command: "winning-ads.brief",
|
|
53182
53403
|
description: "Generate a creative brief grounded in strategically-similar winning ads. Optionally describe the target creative with --dna (JSON) and steer with --notes.",
|
|
@@ -53222,7 +53443,7 @@ function parseDna(raw) {
|
|
|
53222
53443
|
}
|
|
53223
53444
|
return parsed;
|
|
53224
53445
|
}
|
|
53225
|
-
var briefCommand =
|
|
53446
|
+
var briefCommand = defineCommand218({
|
|
53226
53447
|
meta: {
|
|
53227
53448
|
name: "brief",
|
|
53228
53449
|
description: `Generate a creative brief from winning references. Example: baker winning-ads brief --dna '{"angle":"cost savings"}' --notes "B2B, LinkedIn video" --k 8`
|
|
@@ -53258,7 +53479,7 @@ var briefCommand = defineCommand217({
|
|
|
53258
53479
|
});
|
|
53259
53480
|
|
|
53260
53481
|
// src/commands/winning-ads/content.ts
|
|
53261
|
-
import { defineCommand as
|
|
53482
|
+
import { defineCommand as defineCommand219 } from "citty";
|
|
53262
53483
|
registerSchema({
|
|
53263
53484
|
command: "winning-ads.content",
|
|
53264
53485
|
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.",
|
|
@@ -53271,7 +53492,7 @@ registerSchema({
|
|
|
53271
53492
|
}
|
|
53272
53493
|
}
|
|
53273
53494
|
});
|
|
53274
|
-
var contentCommand =
|
|
53495
|
+
var contentCommand = defineCommand219({
|
|
53275
53496
|
meta: {
|
|
53276
53497
|
name: "content",
|
|
53277
53498
|
description: "Read the transcript + on-screen text + copy of one winning ad. Example: baker winning-ads content adg_123 --platform meta --full --output md"
|
|
@@ -53320,7 +53541,7 @@ var contentCommand = defineCommand218({
|
|
|
53320
53541
|
});
|
|
53321
53542
|
|
|
53322
53543
|
// src/commands/winning-ads/feed.ts
|
|
53323
|
-
import { defineCommand as
|
|
53544
|
+
import { defineCommand as defineCommand220 } from "citty";
|
|
53324
53545
|
function buildFeedParams(input) {
|
|
53325
53546
|
const params = {};
|
|
53326
53547
|
const advertiser = splitList2(input.advertiser);
|
|
@@ -53372,7 +53593,7 @@ registerSchema({
|
|
|
53372
53593
|
format: { type: "string", description: "Comma-separated formats to include (e.g. static,video)", required: false }
|
|
53373
53594
|
}
|
|
53374
53595
|
});
|
|
53375
|
-
var feedCommand =
|
|
53596
|
+
var feedCommand = defineCommand220({
|
|
53376
53597
|
meta: {
|
|
53377
53598
|
name: "feed",
|
|
53378
53599
|
description: "Winners across every brand you follow (browse, then trim per advertiser). Example: baker winning-ads feed --per-advertiser 5 --output md"
|
|
@@ -53457,7 +53678,7 @@ var feedCommand = defineCommand219({
|
|
|
53457
53678
|
});
|
|
53458
53679
|
|
|
53459
53680
|
// src/commands/winning-ads/follow.ts
|
|
53460
|
-
import { defineCommand as
|
|
53681
|
+
import { defineCommand as defineCommand221 } from "citty";
|
|
53461
53682
|
var PLATFORMS = adLibraryPlatformSchema.options;
|
|
53462
53683
|
registerSchema({
|
|
53463
53684
|
command: "winning-ads.follow",
|
|
@@ -53472,7 +53693,7 @@ registerSchema({
|
|
|
53472
53693
|
label: { type: "string", description: "Optional display label (defaults to the resolved name)", required: false }
|
|
53473
53694
|
}
|
|
53474
53695
|
});
|
|
53475
|
-
var followCommand =
|
|
53696
|
+
var followCommand = defineCommand221({
|
|
53476
53697
|
meta: {
|
|
53477
53698
|
name: "follow",
|
|
53478
53699
|
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 every platform we can resolve. Example: baker winning-ads follow "deel.com" --platform meta'
|
|
@@ -53519,7 +53740,7 @@ var followCommand = defineCommand220({
|
|
|
53519
53740
|
});
|
|
53520
53741
|
|
|
53521
53742
|
// src/commands/winning-ads/follow-competitors.ts
|
|
53522
|
-
import { defineCommand as
|
|
53743
|
+
import { defineCommand as defineCommand222 } from "citty";
|
|
53523
53744
|
var PLATFORMS2 = adLibraryPlatformSchema.options;
|
|
53524
53745
|
var BATCH_TIMEOUT_MS = 3e5;
|
|
53525
53746
|
function buildFollowBatchBody(input) {
|
|
@@ -53552,7 +53773,7 @@ registerSchema({
|
|
|
53552
53773
|
}
|
|
53553
53774
|
}
|
|
53554
53775
|
});
|
|
53555
|
-
var followCompetitorsCommand =
|
|
53776
|
+
var followCompetitorsCommand = defineCommand222({
|
|
53556
53777
|
meta: {
|
|
53557
53778
|
name: "follow-competitors",
|
|
53558
53779
|
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"'
|
|
@@ -53627,7 +53848,7 @@ var followCompetitorsCommand = defineCommand221({
|
|
|
53627
53848
|
});
|
|
53628
53849
|
|
|
53629
53850
|
// src/commands/winning-ads/following.ts
|
|
53630
|
-
import { defineCommand as
|
|
53851
|
+
import { defineCommand as defineCommand223 } from "citty";
|
|
53631
53852
|
registerSchema({
|
|
53632
53853
|
command: "winning-ads.following",
|
|
53633
53854
|
description: "List the brands you follow in your ad-dna library, with each one's status (ready vs still adding) and cached ad counts. A brand still adding has counts that are a lie in progress; one with `discovery_failed` has counts that are short because we couldn't finish looking, which is not the same as it running no ads.",
|
|
@@ -53681,7 +53902,7 @@ function followingNormalizer(record, full) {
|
|
|
53681
53902
|
platforms: Array.isArray(record.platforms) ? record.platforms : []
|
|
53682
53903
|
};
|
|
53683
53904
|
}
|
|
53684
|
-
var followingCommand =
|
|
53905
|
+
var followingCommand = defineCommand223({
|
|
53685
53906
|
meta: {
|
|
53686
53907
|
name: "following",
|
|
53687
53908
|
description: "List brands you follow, with status (ready / adding\u2026) and cached counts. A brand's counts are only final once it is ready. Example: baker winning-ads following --output md"
|
|
@@ -53717,7 +53938,7 @@ var followingCommand = defineCommand222({
|
|
|
53717
53938
|
});
|
|
53718
53939
|
|
|
53719
53940
|
// src/commands/winning-ads/patterns.ts
|
|
53720
|
-
import { defineCommand as
|
|
53941
|
+
import { defineCommand as defineCommand224 } from "citty";
|
|
53721
53942
|
registerSchema({
|
|
53722
53943
|
command: "winning-ads.patterns",
|
|
53723
53944
|
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.",
|
|
@@ -53756,7 +53977,7 @@ function discriminatorRow(record) {
|
|
|
53756
53977
|
top_values_duds: Array.isArray(record.top_values_b) ? record.top_values_b.join(", ") : ""
|
|
53757
53978
|
};
|
|
53758
53979
|
}
|
|
53759
|
-
var patternsCommand =
|
|
53980
|
+
var patternsCommand = defineCommand224({
|
|
53760
53981
|
meta: {
|
|
53761
53982
|
name: "patterns",
|
|
53762
53983
|
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"
|
|
@@ -53812,7 +54033,7 @@ var patternsCommand = defineCommand223({
|
|
|
53812
54033
|
});
|
|
53813
54034
|
|
|
53814
54035
|
// src/commands/winning-ads/search.ts
|
|
53815
|
-
import { defineCommand as
|
|
54036
|
+
import { defineCommand as defineCommand225 } from "citty";
|
|
53816
54037
|
registerSchema({
|
|
53817
54038
|
command: "winning-ads.search",
|
|
53818
54039
|
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.",
|
|
@@ -53920,7 +54141,7 @@ function buildSearchBody2(args) {
|
|
|
53920
54141
|
}
|
|
53921
54142
|
return body;
|
|
53922
54143
|
}
|
|
53923
|
-
var searchCommand5 =
|
|
54144
|
+
var searchCommand5 = defineCommand225({
|
|
53924
54145
|
meta: {
|
|
53925
54146
|
name: "search",
|
|
53926
54147
|
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"
|
|
@@ -54035,7 +54256,7 @@ var searchCommand5 = defineCommand224({
|
|
|
54035
54256
|
});
|
|
54036
54257
|
|
|
54037
54258
|
// src/commands/winning-ads/seeds.ts
|
|
54038
|
-
import { defineCommand as
|
|
54259
|
+
import { defineCommand as defineCommand226 } from "citty";
|
|
54039
54260
|
function leanRow(r) {
|
|
54040
54261
|
return {
|
|
54041
54262
|
key: r.key,
|
|
@@ -54063,7 +54284,7 @@ function makeSeedCommand(opts) {
|
|
|
54063
54284
|
limit: { type: "number", description: "Max keys 1-100 (default 20)", required: false, default: 20 }
|
|
54064
54285
|
}
|
|
54065
54286
|
});
|
|
54066
|
-
return
|
|
54287
|
+
return defineCommand226({
|
|
54067
54288
|
meta: { name: opts.name, description: opts.description },
|
|
54068
54289
|
args: {
|
|
54069
54290
|
platform: { type: "string", description: "Single platform to segment on", required: false },
|
|
@@ -54112,7 +54333,7 @@ var formatsCommand = makeSeedCommand({
|
|
|
54112
54333
|
});
|
|
54113
54334
|
|
|
54114
54335
|
// src/commands/winning-ads/unfollow.ts
|
|
54115
|
-
import { defineCommand as
|
|
54336
|
+
import { defineCommand as defineCommand227 } from "citty";
|
|
54116
54337
|
registerSchema({
|
|
54117
54338
|
command: "winning-ads.unfollow",
|
|
54118
54339
|
description: "Stop following a brand \u2014 removes it from your ad-dna library by advertiser id.",
|
|
@@ -54120,7 +54341,7 @@ registerSchema({
|
|
|
54120
54341
|
advertiser: { type: "string", description: "Advertiser id to unfollow", required: true }
|
|
54121
54342
|
}
|
|
54122
54343
|
});
|
|
54123
|
-
var unfollowCommand =
|
|
54344
|
+
var unfollowCommand = defineCommand227({
|
|
54124
54345
|
meta: {
|
|
54125
54346
|
name: "unfollow",
|
|
54126
54347
|
description: "Stop following a brand by advertiser id. Example: baker winning-ads unfollow adv_123"
|
|
@@ -54141,7 +54362,7 @@ var unfollowCommand = defineCommand226({
|
|
|
54141
54362
|
});
|
|
54142
54363
|
|
|
54143
54364
|
// src/commands/winning-ads/winners.ts
|
|
54144
|
-
import { defineCommand as
|
|
54365
|
+
import { defineCommand as defineCommand228 } from "citty";
|
|
54145
54366
|
registerSchema({
|
|
54146
54367
|
command: "winning-ads.winners",
|
|
54147
54368
|
description: "Top winning ads for one advertiser id (from `advertisers` or `following`). Returns lean winner cards; add --full for DNA + longevity.",
|
|
@@ -54151,7 +54372,7 @@ registerSchema({
|
|
|
54151
54372
|
platform: { type: "string", description: "Filter to a single platform: meta|linkedin|tiktok", required: false }
|
|
54152
54373
|
}
|
|
54153
54374
|
});
|
|
54154
|
-
var winnersCommand =
|
|
54375
|
+
var winnersCommand = defineCommand228({
|
|
54155
54376
|
meta: {
|
|
54156
54377
|
name: "winners",
|
|
54157
54378
|
description: "Top winning ads for a specific advertiser id. Example: baker winning-ads winners adv_123 --top 15 --output md"
|
|
@@ -54201,7 +54422,7 @@ var winnersCommand = defineCommand227({
|
|
|
54201
54422
|
});
|
|
54202
54423
|
|
|
54203
54424
|
// src/commands/winning-ads/index.ts
|
|
54204
|
-
var winningAdsCommand =
|
|
54425
|
+
var winningAdsCommand = defineCommand229({
|
|
54205
54426
|
meta: {
|
|
54206
54427
|
name: "winning-ads",
|
|
54207
54428
|
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.
|
|
@@ -54439,7 +54660,7 @@ function getCliVersion() {
|
|
|
54439
54660
|
}
|
|
54440
54661
|
|
|
54441
54662
|
// src/cli.ts
|
|
54442
|
-
var main =
|
|
54663
|
+
var main = defineCommand230({
|
|
54443
54664
|
meta: {
|
|
54444
54665
|
name: "baker",
|
|
54445
54666
|
version: getCliVersion(),
|