editorbrain 0.41.0 → 0.41.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md
CHANGED
|
@@ -5,13 +5,13 @@ Editorial references, brand context and portable video projects for Claude Code
|
|
|
5
5
|
Inspect the CLI without configuring your agent:
|
|
6
6
|
|
|
7
7
|
```sh
|
|
8
|
-
npx editorbrain@0.41.
|
|
8
|
+
npx editorbrain@0.41.1 help
|
|
9
9
|
```
|
|
10
10
|
|
|
11
11
|
For a persistent installation:
|
|
12
12
|
|
|
13
13
|
```sh
|
|
14
|
-
npm install -g editorbrain@0.41.
|
|
14
|
+
npm install -g editorbrain@0.41.1
|
|
15
15
|
editorbrain login --url https://api.editorbrain.com
|
|
16
16
|
editorbrain status --url https://api.editorbrain.com
|
|
17
17
|
editorbrain projects list
|
|
@@ -36,11 +36,22 @@ Optional local commands inventory media, extract selected frames and check a ren
|
|
|
36
36
|
|
|
37
37
|
Distribution is proprietary (UNLICENSED); publication on npm does not make the private service or library open source.
|
|
38
38
|
|
|
39
|
+
## Documentation
|
|
40
|
+
|
|
41
|
+
Spanish guides: [Getting started](https://editorbrain.com/docs/instalar),
|
|
42
|
+
[CLI](https://editorbrain.com/docs/cli), [API](https://editorbrain.com/docs/api),
|
|
43
|
+
[MCP](https://editorbrain.com/docs/mcp), and
|
|
44
|
+
[version availability](https://editorbrain.com/docs/versiones).
|
|
45
|
+
The web documentation requires the matching web deployment.
|
|
46
|
+
|
|
39
47
|
## Updating EditorBrain
|
|
40
48
|
|
|
41
49
|
Run `editorbrain update` to update the npm CLI, current-project skills and
|
|
42
|
-
existing global skills together.
|
|
43
|
-
|
|
50
|
+
existing global skills together. Check your installed help and the version guide
|
|
51
|
+
before using advanced flags. Use `update --dry-run` to preview changes
|
|
52
|
+
on current versions; consult the version guide for older installations.
|
|
53
|
+
For a selected project, use an exact npm version followed by
|
|
54
|
+
`skill install --dir ./my-videos --agent both`. Custom instructions
|
|
44
55
|
are preserved; official replacements are backed up. Inspect conflicts and reload
|
|
45
56
|
your agent's instructions afterward. Updates never change your brand or media.
|
|
46
57
|
|
package/bin/editorbrain.mjs
CHANGED
|
@@ -142,6 +142,21 @@ var billing = { label: "Ver plan y cr\xE9ditos", url: "https://editorbrain.com/a
|
|
|
142
142
|
var integrations = { label: "Ver mis integraciones", url: "https://editorbrain.com/app/integrations" };
|
|
143
143
|
var support = { label: "Contactar soporte", url: "mailto:soporte@editorbrain.com" };
|
|
144
144
|
var guidance = {
|
|
145
|
+
email_verification_required: { status: 403, help: {
|
|
146
|
+
message: "Verifica tu correo para usar las funciones de IA de EditorBrain.",
|
|
147
|
+
nextStep: "Abre la verificaci\xF3n de correo y solicita un enlace si lo necesitas. Completa ese paso antes de repetir la b\xFAsqueda. Mientras tanto puedes trabajar con tu material y los recursos ya disponibles. No hace falta comprar cr\xE9ditos ni cambiar de cuenta para evitar esta comprobaci\xF3n.",
|
|
148
|
+
actions: [{ label: "Verificar mi correo", url: "https://editorbrain.com/verify-email" }]
|
|
149
|
+
} },
|
|
150
|
+
invalid_authored_query: { status: 400, help: {
|
|
151
|
+
message: "La consulta o su cursor de animaciones no es v\xE1lido.",
|
|
152
|
+
nextStep: "Comprueba los par\xE1metros y l\xEDmites de list_authored_scenes. Si cambiaste la consulta, los filtros o la versi\xF3n, descarta after y comienza en la primera p\xE1gina. Para continuar, utiliza nextCursor tal como se recibi\xF3 con los mismos par\xE1metros; no lo construyas ni lo modifiques. No repitas indefinidamente la petici\xF3n que fall\xF3.",
|
|
153
|
+
actions: []
|
|
154
|
+
} },
|
|
155
|
+
sfx_unavailable: { status: 404, help: {
|
|
156
|
+
message: "Este banco o sonido no est\xE1 disponible para esta selecci\xF3n.",
|
|
157
|
+
nextStep: "Consulta search_sfx con el proyecto actual y respeta su banco configurado. Si no hay bancos disponibles, informa de esa limitaci\xF3n y contin\xFAa las partes independientes del montaje. Puedes solicitar un audio propio con permiso de uso o contactar soporte; no inventes un ID, cambies de banco ni generes sonidos de pago autom\xE1ticamente. Recargar cr\xE9ditos no activa esta biblioteca.",
|
|
158
|
+
actions: [support]
|
|
159
|
+
} },
|
|
145
160
|
resource_plan_required: { status: 403, help: { message: "Este recurso requiere Creator o Studio.", nextStep: "Puedes ver su preview o proponer un recurso con access.canUse=true que encaje con la escena. Una recarga de cr\xE9ditos no desbloquea recursos premium. No sustituyas la elecci\xF3n expl\xEDcita del usuario ni cambies de plan autom\xE1ticamente.", actions: [billing, { label: "Explorar animaciones", url: "https://editorbrain.com/app/animations" }] } },
|
|
146
161
|
studio_insufficient_credits: { status: 402, help: {
|
|
147
162
|
message: "No alcanzan tus cr\xE9ditos creativos de EditorBrain para este encargo.",
|
|
@@ -181247,7 +181262,72 @@ var stopwords = new Set("a al algo como con cual de del donde el ella en entre e
|
|
|
181247
181262
|
function stems(text11) {
|
|
181248
181263
|
return new Set((normalized(text11).match(/[a-z0-9]+/g) ?? []).filter((word) => word.length > 2 && !stopwords.has(word)).map((word) => word.slice(0, 5)));
|
|
181249
181264
|
}
|
|
181250
|
-
var
|
|
181265
|
+
var discoveryWords = {
|
|
181266
|
+
animated: "",
|
|
181267
|
+
animation: "",
|
|
181268
|
+
animations: "",
|
|
181269
|
+
show: "",
|
|
181270
|
+
showing: "",
|
|
181271
|
+
with: "",
|
|
181272
|
+
the: "",
|
|
181273
|
+
and: "",
|
|
181274
|
+
for: "",
|
|
181275
|
+
of: "",
|
|
181276
|
+
a: "",
|
|
181277
|
+
an: "",
|
|
181278
|
+
number: "numero",
|
|
181279
|
+
numbers: "numeros",
|
|
181280
|
+
counter: "contador",
|
|
181281
|
+
counters: "contadores",
|
|
181282
|
+
money: "dinero",
|
|
181283
|
+
underline: "subrayar",
|
|
181284
|
+
underlined: "subrayado",
|
|
181285
|
+
word: "palabra",
|
|
181286
|
+
words: "palabras",
|
|
181287
|
+
before: "antes",
|
|
181288
|
+
after: "despues",
|
|
181289
|
+
comparison: "comparacion",
|
|
181290
|
+
compare: "comparar",
|
|
181291
|
+
reveal: "revelar",
|
|
181292
|
+
brand: "marca",
|
|
181293
|
+
end: "final",
|
|
181294
|
+
title: "titulo",
|
|
181295
|
+
name: "nombre",
|
|
181296
|
+
job: "cargo",
|
|
181297
|
+
map: "mapa",
|
|
181298
|
+
route: "ruta",
|
|
181299
|
+
journey: "recorrido",
|
|
181300
|
+
steps: "pasos",
|
|
181301
|
+
list: "lista",
|
|
181302
|
+
chart: "grafica",
|
|
181303
|
+
graph: "grafica",
|
|
181304
|
+
bars: "barras",
|
|
181305
|
+
ranking: "ranking",
|
|
181306
|
+
timeline: "cronologia",
|
|
181307
|
+
photo: "foto",
|
|
181308
|
+
photos: "fotos",
|
|
181309
|
+
image: "imagen",
|
|
181310
|
+
images: "imagenes",
|
|
181311
|
+
testimonial: "testimonio",
|
|
181312
|
+
product: "producto",
|
|
181313
|
+
price: "precio",
|
|
181314
|
+
pricing: "precios",
|
|
181315
|
+
discount: "descuento",
|
|
181316
|
+
typewriter: "maquina escribir",
|
|
181317
|
+
handwriting: "escritura mano",
|
|
181318
|
+
handwritten: "escrito mano"
|
|
181319
|
+
};
|
|
181320
|
+
function discoveryTerms(search) {
|
|
181321
|
+
const translated = search.replace(/\blower third\b/g, "nombre cargo").replace(/\bcount up\b/g, "contador").replace(/\b[a-z0-9]+\b/g, (word) => Object.hasOwn(discoveryWords, word) ? discoveryWords[word] : word);
|
|
181322
|
+
const terms = stems(translated);
|
|
181323
|
+
if (/\bcontador(?:es)?\b/.test(translated)) {
|
|
181324
|
+
terms.delete("conta");
|
|
181325
|
+
terms.add("contador");
|
|
181326
|
+
}
|
|
181327
|
+
return terms;
|
|
181328
|
+
}
|
|
181329
|
+
var mechanismTerms = /* @__PURE__ */ new Set([...stems("subrayar odometro"), "contador"]);
|
|
181330
|
+
var buildSearchIndex = (scenes, precise = false) => scenes.map((scene) => ({ scene, fields: [
|
|
181251
181331
|
[scene.title, 3],
|
|
181252
181332
|
[scene.universalMechanism ?? "", 3],
|
|
181253
181333
|
[scene.intent, 2.5],
|
|
@@ -181255,21 +181335,28 @@ var buildSearchIndex = (scenes) => scenes.map((scene) => ({ scene, fields: [
|
|
|
181255
181335
|
[(scene.crossNicheUses ?? []).join(" "), 2.5],
|
|
181256
181336
|
[(scene.presets ?? []).map((preset) => `${preset.name.replace(/-/g, " ")} ${preset.summary}`).join(" "), 2],
|
|
181257
181337
|
[scene.useFor ?? "", 1.5]
|
|
181258
|
-
].map(([text11, weight]) =>
|
|
181338
|
+
].map(([text11, weight]) => {
|
|
181339
|
+
const terms = stems(text11);
|
|
181340
|
+
if (precise && /\bcontador(?:es)?\b/.test(normalized(text11))) terms.add("contador");
|
|
181341
|
+
return { terms, weight };
|
|
181342
|
+
}) }));
|
|
181259
181343
|
var searchIndexes = { "1.1.0": buildSearchIndex(catalogs["1.1.0"]), "1.2.0": buildSearchIndex(catalogs["1.2.0"]), "1.3.0": buildSearchIndex(catalogs["1.3.0"]), "1.4.0": buildSearchIndex(catalogs["1.4.0"]) };
|
|
181260
|
-
var
|
|
181261
|
-
|
|
181344
|
+
var bilingualIndex = buildSearchIndex(catalogs["1.4.0"], true);
|
|
181345
|
+
function termWeights(index) {
|
|
181346
|
+
const frequencies = /* @__PURE__ */ new Map();
|
|
181262
181347
|
for (const { fields } of index) for (const term of new Set(fields.flatMap((field) => [...field.terms]))) {
|
|
181263
181348
|
frequencies.set(term, (frequencies.get(term) ?? 0) + 1);
|
|
181264
181349
|
}
|
|
181265
181350
|
return new Map([...frequencies].map(([term, count]) => [term, 1 + Math.log((index.length + 1) / (count + 1))]));
|
|
181266
|
-
}
|
|
181267
|
-
|
|
181268
|
-
|
|
181351
|
+
}
|
|
181352
|
+
var v14TermWeights = termWeights(searchIndexes["1.4.0"]);
|
|
181353
|
+
var bilingualTermWeights = termWeights(bilingualIndex);
|
|
181354
|
+
function rankedCandidates(search, version, bilingual = false) {
|
|
181355
|
+
const scenes = catalogs[version], searchIndex = bilingual ? bilingualIndex : searchIndexes[version];
|
|
181269
181356
|
if (!search) return scenes;
|
|
181270
181357
|
const exact = scenes.find((scene) => scene.id === search);
|
|
181271
181358
|
if (exact) return [exact];
|
|
181272
|
-
const queryTerms = stems(search);
|
|
181359
|
+
const queryTerms = bilingual ? discoveryTerms(search) : stems(search);
|
|
181273
181360
|
if (version === "1.4.0") queryTerms.delete("quien");
|
|
181274
181361
|
return searchIndex.map(({ scene, fields }) => {
|
|
181275
181362
|
if (version === "1.4.0") {
|
|
@@ -181277,8 +181364,9 @@ function rankedCandidates(search, version) {
|
|
|
181277
181364
|
for (const term of queryTerms) {
|
|
181278
181365
|
const fieldWeight = fields.reduce((sum, field) => sum + (field.terms.has(term) ? field.weight : 0), 0);
|
|
181279
181366
|
if (!fieldWeight) continue;
|
|
181280
|
-
const rarity = v14TermWeights.get(term);
|
|
181281
|
-
|
|
181367
|
+
const rarity = (bilingual ? bilingualTermWeights : v14TermWeights).get(term);
|
|
181368
|
+
const mechanismBoost = bilingual && mechanismTerms.has(term) && fields.slice(0, 2).some((field) => field.terms.has(term)) ? 3 : 1;
|
|
181369
|
+
score += rarity * Math.sqrt(fieldWeight) * mechanismBoost;
|
|
181282
181370
|
coverage += rarity;
|
|
181283
181371
|
}
|
|
181284
181372
|
return { scene, score: score * Math.sqrt(coverage) };
|
|
@@ -181322,13 +181410,16 @@ function listAuthoredMotionScenes(options = {}) {
|
|
|
181322
181410
|
let version = options.version ?? AUTHORED_MOTION_CATALOG_VERSION;
|
|
181323
181411
|
if (!isAuthoredMotionVersion(version)) throw Error("Unknown authored motion version");
|
|
181324
181412
|
let cursorId;
|
|
181413
|
+
let bilingual = version === "1.4.0" && Boolean(search);
|
|
181325
181414
|
if (after !== void 0) {
|
|
181326
|
-
const [cursorVersion, encoded, id2, encodedFilters, ...extra] = after.split("|");
|
|
181327
|
-
|
|
181415
|
+
const [cursorVersion, encoded, id2, encodedFilters, ranker, ...extra] = after.split("|");
|
|
181416
|
+
const q2 = ranker === "q2" && cursorVersion === "1.4.0" && Boolean(search);
|
|
181417
|
+
if (!isAuthoredMotionVersion(cursorVersion) || options.version !== void 0 && options.version !== cursorVersion || encoded !== encodeURIComponent(search) || !id2 || (q2 ? encodedFilters !== (cursorFilters ?? "") : encodedFilters !== cursorFilters) || ranker !== void 0 && !q2 || extra.length) throw new Error("Cursor does not match this authored motion query, version or filters.");
|
|
181328
181418
|
version = cursorVersion;
|
|
181329
181419
|
cursorId = id2;
|
|
181420
|
+
bilingual = q2;
|
|
181330
181421
|
}
|
|
181331
|
-
const queryCandidates = version === "1.0.0" ? legacyCandidates(search) : rankedCandidates(search, version);
|
|
181422
|
+
const queryCandidates = version === "1.0.0" ? legacyCandidates(search) : rankedCandidates(search, version, bilingual);
|
|
181332
181423
|
const candidates = queryCandidates.filter((scene) => matchesAuthoredMotionFilters(scene.facets, filters));
|
|
181333
181424
|
if (!search && filters.funcion) candidates.sort((a, b) => Number(filters.funcion.includes(b.facets.funciones[0])) - Number(filters.funcion.includes(a.facets.funciones[0])));
|
|
181334
181425
|
let start3 = 0;
|
|
@@ -181340,7 +181431,7 @@ function listAuthoredMotionScenes(options = {}) {
|
|
|
181340
181431
|
return {
|
|
181341
181432
|
version,
|
|
181342
181433
|
items: page.map(summary),
|
|
181343
|
-
nextCursor: start3 + page.length < candidates.length ? `${version}|${encodeURIComponent(search)}|${page[page.length - 1].id}${cursorFilters ? `|${cursorFilters}` : ""}` : null,
|
|
181434
|
+
nextCursor: start3 + page.length < candidates.length ? `${version}|${encodeURIComponent(search)}|${page[page.length - 1].id}${bilingual ? `|${cursorFilters ?? ""}|q2` : cursorFilters ? `|${cursorFilters}` : ""}` : null,
|
|
181344
181435
|
total: candidates.length,
|
|
181345
181436
|
facetCounts: countAuthoredMotionFacets(queryCandidates, filters),
|
|
181346
181437
|
availableFacetCounts: structuredClone(availableFacetCounts[version]),
|
|
@@ -184189,6 +184280,52 @@ import { fileURLToPath } from "node:url";
|
|
|
184189
184280
|
|
|
184190
184281
|
// packages/cli/src/agent-guidance-history.ts
|
|
184191
184282
|
var VERIFIED_GUIDANCE_RELEASES = [
|
|
184283
|
+
{
|
|
184284
|
+
"version": "0.41.0",
|
|
184285
|
+
"archiveSha256": "7a5e5c297d0b9dd95cc4f0a7b214666b437953caae4efca53331372da46e63b1",
|
|
184286
|
+
"files": {
|
|
184287
|
+
"editorbrain/AGENTS.md": "b240449d452c824415062a2b422bf55a5ae2d868a81083989d10ffaeb5c33a3f",
|
|
184288
|
+
"editorbrain-formats/references/aspirational-list-demo.md": "e884ce44d15f4496812ed18120f7d4c49c4261e148fcefe05c77c110b589771c",
|
|
184289
|
+
"editorbrain/references/audio-production.md": "9800505dcb320b58f35aeaed77303039d8fffb2c29b46c43cedeeba8637d2482",
|
|
184290
|
+
"editorbrain-motion/references/authored-scenes.md": "52e97b89b1d8a288c4ce7bd133eafea84e934ef2bf03ffe2dcef8c368b6f977d",
|
|
184291
|
+
"editorbrain/references/cli-mcp.md": "2c34ed7f896865e71959562bcc61b5a34292d6a9a4c14690f0c28d00875da75c",
|
|
184292
|
+
"editorbrain-motion/references/code-motion.md": "50382a797adc1e1596086e2408e81ee75ceb6730ca409be9c884646db643a7cd",
|
|
184293
|
+
"editorbrain-motion/references/component-library.md": "e88ed19d2ab9dca8d2ea02abe6c476021c03b9679bce99292cf7da52d65d2236",
|
|
184294
|
+
"editorbrain-formats/references/cumulative-tier-list.md": "7b7e8208687c6b925443e55d640ced6c1d09824377884244a09d7f3089d60aa5",
|
|
184295
|
+
"editorbrain/references/editorial-evidence.md": "79ed5bd90eb903014313c32a1e337822c5cb454e642bcfa852dcb77d30a9392e",
|
|
184296
|
+
"editorbrain/references/editorial-families.md": "b802ec6f02fd079e99df84d69a3c515d63ad058960b568c0c7b7dec1912495dd",
|
|
184297
|
+
"editorbrain/references/family-animated.md": "54a140d0a64b01147c52ea8cbaab4e4599bfe1af330f5a3ad6ef2a30351ab47d",
|
|
184298
|
+
"editorbrain/references/family-demonstration.md": "737334a8d9230682cde3a6ed11bfc02c4f9795c8f25a3b668be9d7393ec3e53d",
|
|
184299
|
+
"editorbrain/references/family-essay.md": "003f2cd450f33ba6641a9b1114cbc578c04cbb658b992c89c765d43198d1b4c2",
|
|
184300
|
+
"editorbrain/references/family-personal.md": "e93c304d7bc7d3eb31a3c9cb3be83f4f48d41319c2ac2e1e6f53f38576f5e644",
|
|
184301
|
+
"editorbrain/references/family-presenter.md": "76b8140b924930b306ce97772d6a7b683870bd14f19772b5339a490752b7de24",
|
|
184302
|
+
"editorbrain/references/first-edit.md": "483843af6672b70a76ce6d41e98324fbfc2a31d5ac50633f963d1ab0eeba1bc0",
|
|
184303
|
+
"editorbrain-motion/references/generated-motion.md": "a8d214b53c15f742658abd84f03b768fa2821f8cde94f50aab82a3759a30b36b",
|
|
184304
|
+
"editorbrain/references/integrations.md": "b5e7ba099acd79053cdd09822092eb121add6de39eada2d6911ad5a4f452ce2a",
|
|
184305
|
+
"editorbrain/references/local-production.md": "268a05706a3c1cae4f61248437c00be3e9ee18b2a0f747c8cd054d88f0a33661",
|
|
184306
|
+
"editorbrain/references/media-preferences.md": "87e508a75cdb6f4644db767273bfb230fb79f182ed05ee0f6257c6c05ea4dc7a",
|
|
184307
|
+
"editorbrain/references/memory-and-review.md": "406589a18e9e86ad8ce7d71e0f5bf00f67dab42c05af7721482fdca1c25c7c1b",
|
|
184308
|
+
"editorbrain-motion/references/motion-craft.md": "dae520b0e641fc9c3bf937241936588a855bf3453358e239ccc3cc3a2bcf0825",
|
|
184309
|
+
"editorbrain/references/motion-review.md": "0fb09a2d61ecd13114ced5cca5daa4580a922cf7d7b3f8698077ceb0e96da6f0",
|
|
184310
|
+
"editorbrain-formats/references/numbered-tutorial.md": "95754ae7dbfaa678e11ddf1a2b84710dba83a16e2fa4055051bd4f5f4f868a5f",
|
|
184311
|
+
"editorbrain/references/onboarding.md": "fbed6ff607859ffaa43d3006e457e40bb170885cde7ce350e496b20d70739e63",
|
|
184312
|
+
"editorbrain/references/personal-resources.md": "92ce6f32191929bd946c97305452521f6048d6bb8ea371e9083536eff5ce9512",
|
|
184313
|
+
"editorbrain/references/production-and-review.md": "28a64ee6407a1de7dc204776c158408c11b3987020ad1bdd1b79fd19745fbffa",
|
|
184314
|
+
"editorbrain/references/production-continuity.md": "b73a851bff421fa24e364d8848e312e54de1d3d971099a567295c80a5e18d8c6",
|
|
184315
|
+
"editorbrain/references/real-media.md": "cfad1aa15198dfe5ecc1f1b67c96d43a7d2084e7f5119de93d1b360203694938",
|
|
184316
|
+
"editorbrain/references/search-brief.md": "ea2a9c2d5a5cf685c1e5918366901ef2589c4d79aaa78a0dd31e97d6fed42b7b",
|
|
184317
|
+
"editorbrain/references/sfx-library.md": "d7ee0d2916559ce11a7fd244ccbcb98172413653c3fdbe0545e57b3eda543b16",
|
|
184318
|
+
"editorbrain-formats/SKILL.md": "65ea59aae091ca9618b5e479befe0c76edf174df7091ed74d4307485a2252fcd",
|
|
184319
|
+
"editorbrain-motion/SKILL.md": "57292f3a48cc8f1fc2d89f2cc054a3ceabeda9422958fa708f273c662867d5ae",
|
|
184320
|
+
"editorbrain/SKILL.md": "a9482dcd170739fe279bf2c69a154327c5d6a68926c1555b010a1753851bf0bd",
|
|
184321
|
+
"editorbrain/references/starting-an-edit.md": "0b83e006edc43307483489060bde999cb0644623eb9550f56b7add52f4082fff",
|
|
184322
|
+
"editorbrain/references/storage-and-previews.md": "9d06a6bb49f13e23f0af7d5ef35444dd553d1ce8af28662a9aba054b4d0081a5",
|
|
184323
|
+
"editorbrain/references/studio.md": "fc85ebfb42b2ce2c86b4d5ee6ad48e83d3d1e959a307d1e8dd52e0d92a4f6c45",
|
|
184324
|
+
"editorbrain/references/style-creator.md": "1b1bc289a5bc308cbbf7f4d699de2933b8934733a2b69b3e98fb1b7420d986f2",
|
|
184325
|
+
"editorbrain/references/style-source.md": "983fa21b4606c3cdc41b2fa4386ddc8f77a1b14ae782aad8774c000696c14de1",
|
|
184326
|
+
"editorbrain/references/workspace-files.md": "29bbddc894ed000bddd065bcb660629e64b29a5cf54dd6850e810b25c990558d"
|
|
184327
|
+
}
|
|
184328
|
+
},
|
|
184192
184329
|
{
|
|
184193
184330
|
"version": "0.26.0",
|
|
184194
184331
|
"archiveSha256": "be469be196a319b4e29f84c9ff204e478818d1163a4fad8fd49270bcc73e83ba",
|
|
@@ -185013,6 +185150,7 @@ import { resolve as resolve4 } from "node:path";
|
|
|
185013
185150
|
// packages/cli/src/client.ts
|
|
185014
185151
|
import { setTimeout as delay } from "node:timers/promises";
|
|
185015
185152
|
var searchErrors = {
|
|
185153
|
+
email_verification_required: { status: 403, code: "EMAIL_VERIFICATION_REQUIRED", hint: "Verifica tu correo en https://editorbrain.com/app/settings y vuelve a intentar. Cambiar de plan o comprar cr\xE9ditos no resuelve la verificaci\xF3n." },
|
|
185016
185154
|
resource_policy_unavailable: { status: 503, code: "RESOURCE_POLICY_UNAVAILABLE", hint: "La pol\xEDtica de recursos no est\xE1 disponible. Contin\xFAa el trabajo independiente y consulta el estado del servicio; recargar cr\xE9ditos no lo resuelve." },
|
|
185017
185155
|
resource_plan_required: { status: 403, code: "RESOURCE_PLAN_REQUIRED", hint: "Consulta https://editorbrain.com/app/billing o elige un recurso Gratis. Recargar cr\xE9ditos no desbloquea este recurso." },
|
|
185018
185156
|
sfx_disabled: { status: 409, code: "SFX_DISABLED", hint: "Current project preferences disable added effects here. Continue without SFX, including motion-component defaults. Do not change preferences or suggest buying credits; honor only an explicit project exception." },
|
|
@@ -185060,6 +185198,17 @@ function searchDiagnostic(status, body) {
|
|
|
185060
185198
|
if (typeof code !== "string" || !Object.hasOwn(searchErrors, code)) return void 0;
|
|
185061
185199
|
return searchErrors[code].status === status ? { ...searchErrors[code], serviceCode: code } : void 0;
|
|
185062
185200
|
}
|
|
185201
|
+
function safeDiagnosticDetails(body) {
|
|
185202
|
+
const e = body?.error;
|
|
185203
|
+
if (!e || typeof e !== "object") return {};
|
|
185204
|
+
const details = {};
|
|
185205
|
+
if (["free", "creator", "studio"].includes(String(e.requiredPlan))) details.requiredPlan = String(e.requiredPlan);
|
|
185206
|
+
if (e.billingUrl === "https://editorbrain.com/app/billing") details.billingUrl = e.billingUrl;
|
|
185207
|
+
for (const key of ["limit", "retryAfter"]) if (Number.isSafeInteger(e[key]) && Number(e[key]) >= 0 && Number(e[key]) <= 86400) details[key] = Number(e[key]);
|
|
185208
|
+
if (["workspace", "service"].includes(String(e.scope))) details.scope = String(e.scope);
|
|
185209
|
+
if (["service_paused", "tool_paused", "configuration_pending", "pricing_pending"].includes(String(e.availabilityCode))) details.availabilityCode = String(e.availabilityCode);
|
|
185210
|
+
return details;
|
|
185211
|
+
}
|
|
185063
185212
|
var ApiError = class extends CliError {
|
|
185064
185213
|
constructor(status, body, retryAfterMs, safeToRetry = false) {
|
|
185065
185214
|
const codes = {
|
|
@@ -185071,7 +185220,7 @@ var ApiError = class extends CliError {
|
|
|
185071
185220
|
const [code, hint] = codes[status] ?? [status >= 500 ? "SERVICE_UNAVAILABLE" : "API_ERROR", "Check the request and service status."];
|
|
185072
185221
|
const diagnostic = searchDiagnostic(status, body);
|
|
185073
185222
|
const recovery = diagnostic ? recoveryGuidance(diagnostic.serviceCode, status) : void 0;
|
|
185074
|
-
super(diagnostic?.code ?? code, `API request failed (HTTP ${status}).`, recovery ? recoveryHint(recovery) : diagnostic?.hint ?? hint, !diagnostic && safeToRetry && (status === 429 || status >= 500), { status, ...recovery ? { recovery } : {}, ...diagnostic ? { serviceCode: diagnostic.serviceCode } : {}, ...retryAfterMs === void 0 ? {} : { retryAfterMs } });
|
|
185223
|
+
super(diagnostic?.code ?? code, `API request failed (HTTP ${status}).`, recovery ? recoveryHint(recovery) : diagnostic?.hint ?? hint, !diagnostic && safeToRetry && (status === 429 || status >= 500), { status, ...recovery ? { recovery } : {}, ...diagnostic ? { serviceCode: diagnostic.serviceCode, ...safeDiagnosticDetails(body) } : {}, ...retryAfterMs === void 0 ? {} : { retryAfterMs } });
|
|
185075
185224
|
this.status = status;
|
|
185076
185225
|
this.body = body;
|
|
185077
185226
|
}
|
|
@@ -185149,10 +185298,11 @@ var Client = class {
|
|
|
185149
185298
|
const retryAfterMs = retryDelay(response.headers.get("Retry-After"), this.runtime.now());
|
|
185150
185299
|
if (!response.ok) {
|
|
185151
185300
|
let errorBody;
|
|
185152
|
-
if (/^\/v1\/authored-motion
|
|
185301
|
+
if ((/^\/v1\/(?:authored-motion|style-sources|sfx|team|studio|batches)(?:\/|\?|$)/.test(path) || path === "/v1/search/brief" || /^\/v1\/projects\/[^/]+\/progress$/.test(path)) && [400, 402, 403, 404, 409, 422, 429, 503].includes(response.status)) {
|
|
185153
185302
|
try {
|
|
185154
|
-
const
|
|
185155
|
-
|
|
185303
|
+
const parsed = await boundedJson(response, 16 * 1024);
|
|
185304
|
+
const diagnostic = searchDiagnostic(response.status, parsed);
|
|
185305
|
+
errorBody = diagnostic ? { error: { code: diagnostic.serviceCode, ...safeDiagnosticDetails(parsed) } } : void 0;
|
|
185156
185306
|
} catch {
|
|
185157
185307
|
}
|
|
185158
185308
|
} else await response.body?.cancel();
|
|
@@ -185230,7 +185380,11 @@ async function loadSyncState(root, endpoint2, workspaceId) {
|
|
|
185230
185380
|
const state = JSON.parse(raw);
|
|
185231
185381
|
if (state.projectId !== void 0) assertIdentifier(state.projectId);
|
|
185232
185382
|
if (state.schemaVersion !== 1 || typeof state.documents !== "object") throw new Error("Invalid local sync state");
|
|
185233
|
-
if (state.endpoint !== endpoint2 || state.workspaceId !== workspaceId)
|
|
185383
|
+
if (state.endpoint !== endpoint2 || state.workspaceId !== workspaceId) {
|
|
185384
|
+
assertIdentifier(state.workspaceId);
|
|
185385
|
+
normalizeUrl(state.endpoint);
|
|
185386
|
+
throw new CliError("WORKSPACE_MISMATCH", `This folder is bound to a different endpoint/workspace. Bound workspace: ${state.workspaceId}; active workspace: ${workspaceId}.`, "Run editorbrain status to inspect the active connection. Run editorbrain login and authorize the workspace shown as boundWorkspaceId, then retry in this folder. For the current workspace, use a separate folder. Do not delete or edit .sync.json to bypass isolation.", false, { boundWorkspaceId: state.workspaceId, currentWorkspaceId: workspaceId, boundEndpoint: state.endpoint });
|
|
185387
|
+
}
|
|
185234
185388
|
for (const [path, item] of Object.entries(state.documents)) {
|
|
185235
185389
|
safeDocumentPath(path);
|
|
185236
185390
|
if (!Number.isInteger(item.revision) || item.revision < 1 || !/^[a-f0-9]{64}$/.test(item.sha256)) throw new Error("Invalid local revision");
|
|
@@ -187017,7 +187171,11 @@ var artifactScript = String.raw`
|
|
|
187017
187171
|
field(fontFields, 'Fuente de títulos', tokenValue('typography.heading'), v => setToken('typography.heading', v), { placeholder: 'Ej. Manrope', maxLength: 100 });
|
|
187018
187172
|
field(fontFields, 'Fuente de texto', tokenValue('typography.body'), v => setToken('typography.body', v), { placeholder: 'Ej. Inter', maxLength: 100 });
|
|
187019
187173
|
strengthControl(fontFields, 'Aplicar estas fuentes', ['typography.heading', 'typography.body']);
|
|
187020
|
-
|
|
187174
|
+
const customFonts = !!(tokenValue('typography.heading') || tokenValue('typography.body')) && !fonts.some(([, heading, body]) => tokenValue('typography.heading') === heading && tokenValue('typography.body') === body);
|
|
187175
|
+
const fontDetails = details('Escribir mis fuentes', fontFields, customFonts ? 'Tus fuentes seleccionadas' : undefined);
|
|
187176
|
+
fontDetails.open = customFonts;
|
|
187177
|
+
fontDetails.dataset.selected = String(customFonts);
|
|
187178
|
+
type.append(fontDetails);
|
|
187021
187179
|
panel.append(type);
|
|
187022
187180
|
const freedom = section('¿Cuánto puede explorar tu agente?', 'Los tokens obligatorios de marca se respetan en ambos casos.', decide(!p().freedom, () => updateProfile('freedom', '')));
|
|
187023
187181
|
choices(freedom, [[options.freedom[0], 'Una identidad reconocible', 'Mantener criterios visuales; adaptar cada escena.'], [options.freedom[1], 'Explorar composiciones nuevas', 'Variar recursos y animaciones según el video.']], p().freedom, v => updateProfile('freedom', v), { columns: 2 });
|
|
@@ -193055,7 +193213,7 @@ async function main() {
|
|
|
193055
193213
|
const params = new URLSearchParams({ query: args.positional.slice(2).join(" ") });
|
|
193056
193214
|
const limit = str(args, "limit"), after = str(args, "after");
|
|
193057
193215
|
if (limit !== void 0) {
|
|
193058
|
-
if (!/^\d+$/.test(limit) || Number(limit) < 1 || Number(limit) > 20) throw new Error("--limit must be 1 through 20");
|
|
193216
|
+
if (!/^\d+$/.test(limit) || Number(limit) < 1 || Number(limit) > 20) throw new Error("--limit must be 1 through 20. Use --limit 20, then --after <nextCursor> from the previous page with the same query.");
|
|
193059
193217
|
params.set("limit", limit);
|
|
193060
193218
|
}
|
|
193061
193219
|
if (after !== void 0) {
|
package/package.json
CHANGED
|
@@ -133,6 +133,8 @@ editorbrain onboarding sync --session <session> --dir ./my-videos --dry-run
|
|
|
133
133
|
editorbrain onboarding sync --session <session> --dir ./my-videos
|
|
134
134
|
```
|
|
135
135
|
|
|
136
|
+
After `onboarding apply`, the canonical publishing step is `onboarding sync` (preview, then sync) for the same session. Do not additionally run `push`: it is the general document command and may include unrelated edits.
|
|
137
|
+
|
|
136
138
|
Inspect planned paths/conflicts. Sync uploads only this brand/starter context.
|
|
137
139
|
Untouched shared starter guides can adopt the account's existing versions;
|
|
138
140
|
personalized local documents are never silently replaced. On network failure,
|
|
@@ -59,3 +59,12 @@ source intervals/code needed for the chosen mechanisms. A simple scoped edit may
|
|
|
59
59
|
already have enough evidence and require no extra query.
|
|
60
60
|
|
|
61
61
|
If this tool is absent, report the installed version limitation, inspect sources yourself and use explicit library lookup if useful. Do not silently upload material to the older server-analysis method. A video your host cannot inspect requires accessible media tools or a disclosed limited plan, not invented observations.
|
|
62
|
+
|
|
63
|
+
## Access diagnostics
|
|
64
|
+
|
|
65
|
+
Free accounts can use brief search within their allowance. Do not infer an
|
|
66
|
+
upgrade requirement from HTTP 403 alone. Read the structured service code:
|
|
67
|
+
- `email_verification_required`: verify the account email at https://editorbrain.com/app/settings; paying or reconnecting does not verify it.
|
|
68
|
+
- `resource_plan_required`: explain `requiredPlan` and link to https://editorbrain.com/app/billing; offer an eligible free resource. Credit top-ups do not unlock premium resources.
|
|
69
|
+
- `search_allowance_exhausted`: inspect the allowance and recovery links; this is separate from creative credits.
|
|
70
|
+
- Permission errors: confirm the current workspace/member without switching identities automatically.
|
|
@@ -98,6 +98,12 @@ Free credits when enabled; eligibility is distinct from provider availability.
|
|
|
98
98
|
Free monthly credits refresh on balance reads; do not promise historical rollover
|
|
99
99
|
or another welcome grant after switching brands/workspaces. Recargas and upgrades
|
|
100
100
|
are optional recovery paths, never automatic purchases.
|
|
101
|
+
For annual plans, `subscription.billingInterval` is `year`: payment is annual,
|
|
102
|
+
but credit/search allowances still renew monthly and unused monthly credits expire.
|
|
103
|
+
Do not multiply the available balance by twelve or promise monthly billing.
|
|
104
|
+
Read `subscriptionOffers` for the interval, full charge and availability; older
|
|
105
|
+
servers without annual offers cannot sell them. Cancellation stops the next renewal
|
|
106
|
+
and preserves access until `paidThrough`. Plan selection is never payment consent.
|
|
101
107
|
|
|
102
108
|
Use `editorbrain billing status` / MCP `billing_status` for this workspace's actual
|
|
103
109
|
balance, expiry, search allowance and `topUps` offers. Read each offer's `available`
|
|
@@ -139,3 +145,18 @@ preserve the project and continue independent work. Never purchase or reroute a
|
|
|
139
145
|
paid job automatically. The final message should give a practical next step.
|
|
140
146
|
|
|
141
147
|
In autonomous question mode, a missing budget or required approval leaves the paid operation pending without a question. Reuse existing sufficient explicit authorization; otherwise continue independent work and report the quote/recovery options together. Never infer approval from silence.
|
|
148
|
+
|
|
149
|
+
## Availability and simultaneous jobs
|
|
150
|
+
|
|
151
|
+
`canSpend` is permission, not availability. Read each tool's `available` and
|
|
152
|
+
`availability.code/message`. `tool_paused`/`service_paused` require service action;
|
|
153
|
+
`configuration_pending`/`pricing_pending` are also service issues. Buying credits
|
|
154
|
+
does not fix these. Offer a user-authorized, verified integration or continue
|
|
155
|
+
independent work. Never silently substitute providers.
|
|
156
|
+
|
|
157
|
+
The catalog reports `limits.activeJobsPerWorkspace` (currently 3, shared across
|
|
158
|
+
all brands) and `retryAfter` in seconds. On `studio_queue_full`, wait at least
|
|
159
|
+
`retryAfter`, inspect `studio jobs`, and resume the existing unconsumed quote
|
|
160
|
+
when capacity is available. If it expired, re-quote and check the authorized
|
|
161
|
+
budget; never increase it. A retry time is a polling delay, not a completion ETA.
|
|
162
|
+
Do not rerun an uncertain job or create parallel replacement quotes.
|