@ignix-social/creator 0.1.2 → 0.1.4
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/dist/cli.cjs +323 -17
- package/dist/core.cjs +157 -84
- package/package.json +1 -1
package/dist/cli.cjs
CHANGED
|
@@ -8,6 +8,7 @@ var __export = (target, all) => {
|
|
|
8
8
|
|
|
9
9
|
// src/cli.ts
|
|
10
10
|
var import_node_fs2 = require("node:fs");
|
|
11
|
+
var import_node_path6 = require("node:path");
|
|
11
12
|
var import_node_net3 = require("node:net");
|
|
12
13
|
|
|
13
14
|
// ../desktop/main/mcp/endpoint.ts
|
|
@@ -2346,8 +2347,8 @@ var $ZodCheckMaxSize = /* @__PURE__ */ $constructor("$ZodCheckMaxSize", (inst, d
|
|
|
2346
2347
|
(_a3 = inst._zod.def).when ?? (_a3.when = _whenHasSize);
|
|
2347
2348
|
inst._zod.check = (payload) => {
|
|
2348
2349
|
const input2 = payload.value;
|
|
2349
|
-
const
|
|
2350
|
-
if (
|
|
2350
|
+
const size2 = input2.size;
|
|
2351
|
+
if (size2 <= def.maximum)
|
|
2351
2352
|
return;
|
|
2352
2353
|
payload.issues.push({
|
|
2353
2354
|
origin: getSizableOrigin(input2),
|
|
@@ -2366,8 +2367,8 @@ var $ZodCheckMinSize = /* @__PURE__ */ $constructor("$ZodCheckMinSize", (inst, d
|
|
|
2366
2367
|
(_a3 = inst._zod.def).when ?? (_a3.when = _whenHasSize);
|
|
2367
2368
|
inst._zod.check = (payload) => {
|
|
2368
2369
|
const input2 = payload.value;
|
|
2369
|
-
const
|
|
2370
|
-
if (
|
|
2370
|
+
const size2 = input2.size;
|
|
2371
|
+
if (size2 >= def.minimum)
|
|
2371
2372
|
return;
|
|
2372
2373
|
payload.issues.push({
|
|
2373
2374
|
origin: getSizableOrigin(input2),
|
|
@@ -2386,10 +2387,10 @@ var $ZodCheckSizeEquals = /* @__PURE__ */ $constructor("$ZodCheckSizeEquals", (i
|
|
|
2386
2387
|
(_a3 = inst._zod.def).when ?? (_a3.when = _whenHasSize);
|
|
2387
2388
|
inst._zod.check = (payload) => {
|
|
2388
2389
|
const input2 = payload.value;
|
|
2389
|
-
const
|
|
2390
|
-
if (
|
|
2390
|
+
const size2 = input2.size;
|
|
2391
|
+
if (size2 === def.size)
|
|
2391
2392
|
return;
|
|
2392
|
-
const tooBig =
|
|
2393
|
+
const tooBig = size2 > def.size;
|
|
2393
2394
|
payload.issues.push({
|
|
2394
2395
|
origin: getSizableOrigin(input2),
|
|
2395
2396
|
...tooBig ? { code: "too_big", maximum: def.size } : { code: "too_small", minimum: def.size },
|
|
@@ -15165,11 +15166,11 @@ function _minSize(minimum, params) {
|
|
|
15165
15166
|
});
|
|
15166
15167
|
}
|
|
15167
15168
|
// @__NO_SIDE_EFFECTS__
|
|
15168
|
-
function _size(
|
|
15169
|
+
function _size(size2, params) {
|
|
15169
15170
|
return new $ZodCheckSizeEquals({
|
|
15170
15171
|
check: "size_equals",
|
|
15171
15172
|
...normalizeParams(params),
|
|
15172
|
-
size
|
|
15173
|
+
size: size2
|
|
15173
15174
|
});
|
|
15174
15175
|
}
|
|
15175
15176
|
// @__NO_SIDE_EFFECTS__
|
|
@@ -18418,8 +18419,8 @@ var ZodFile = /* @__PURE__ */ $constructor("ZodFile", (inst, def) => {
|
|
|
18418
18419
|
$ZodFile.init(inst, def);
|
|
18419
18420
|
ZodType.init(inst, def);
|
|
18420
18421
|
inst._zod.processJSONSchema = (ctx, json2, params) => fileProcessor(inst, ctx, json2, params);
|
|
18421
|
-
inst.min = (
|
|
18422
|
-
inst.max = (
|
|
18422
|
+
inst.min = (size2, params) => inst.check(_minSize(size2, params));
|
|
18423
|
+
inst.max = (size2, params) => inst.check(_maxSize(size2, params));
|
|
18423
18424
|
inst.mime = (types, params) => inst.check(_mime(Array.isArray(types) ? types : [types], params));
|
|
18424
18425
|
});
|
|
18425
18426
|
function file(params) {
|
|
@@ -22127,7 +22128,7 @@ async function removeStaleSocket(path) {
|
|
|
22127
22128
|
// ../desktop/main/mcp/lines.ts
|
|
22128
22129
|
function createLineReader(maxBytes, onLine, onOverflow) {
|
|
22129
22130
|
let parts = [];
|
|
22130
|
-
let
|
|
22131
|
+
let size2 = 0;
|
|
22131
22132
|
let dead = false;
|
|
22132
22133
|
return (chunk) => {
|
|
22133
22134
|
if (dead) return;
|
|
@@ -22135,8 +22136,8 @@ function createLineReader(maxBytes, onLine, onOverflow) {
|
|
|
22135
22136
|
for (; ; ) {
|
|
22136
22137
|
const nl = buf.indexOf(10);
|
|
22137
22138
|
if (nl === -1) {
|
|
22138
|
-
|
|
22139
|
-
if (
|
|
22139
|
+
size2 += buf.length;
|
|
22140
|
+
if (size2 > maxBytes) {
|
|
22140
22141
|
dead = true;
|
|
22141
22142
|
parts = [];
|
|
22142
22143
|
onOverflow();
|
|
@@ -22146,7 +22147,7 @@ function createLineReader(maxBytes, onLine, onOverflow) {
|
|
|
22146
22147
|
return;
|
|
22147
22148
|
}
|
|
22148
22149
|
const head = buf.subarray(0, nl);
|
|
22149
|
-
if (
|
|
22150
|
+
if (size2 + head.length > maxBytes) {
|
|
22150
22151
|
dead = true;
|
|
22151
22152
|
parts = [];
|
|
22152
22153
|
onOverflow();
|
|
@@ -22154,7 +22155,7 @@ function createLineReader(maxBytes, onLine, onOverflow) {
|
|
|
22154
22155
|
}
|
|
22155
22156
|
const line = Buffer.concat([...parts, head]).toString("utf8").replace(/\r$/, "");
|
|
22156
22157
|
parts = [];
|
|
22157
|
-
|
|
22158
|
+
size2 = 0;
|
|
22158
22159
|
buf = buf.subarray(nl + 1);
|
|
22159
22160
|
if (line.trim()) onLine(line);
|
|
22160
22161
|
}
|
|
@@ -23607,14 +23608,284 @@ async function runService(paths, version2) {
|
|
|
23607
23608
|
});
|
|
23608
23609
|
}
|
|
23609
23610
|
|
|
23611
|
+
// src/report.ts
|
|
23612
|
+
var ROWS = ["production_tools", "presenter", "video", "h3", "images", "recast"];
|
|
23613
|
+
var W = {
|
|
23614
|
+
en: {
|
|
23615
|
+
title: "Ignix Creator on this computer",
|
|
23616
|
+
intro: "Ignix Creator measured this computer. Here is what it can make on its own (free, after a one-time download) and what Ignix Cloud Boost makes for it (Ignix AI credits).",
|
|
23617
|
+
machine: "This computer",
|
|
23618
|
+
what: "What",
|
|
23619
|
+
here: "On this computer",
|
|
23620
|
+
boost: "On Cloud Boost",
|
|
23621
|
+
rows: {
|
|
23622
|
+
production_tools: "Make and edit videos (reels from scratch, your recordings, clips and captions)",
|
|
23623
|
+
presenter: "A talking presenter from a photo",
|
|
23624
|
+
video: "Photo \u2192 video",
|
|
23625
|
+
h3: "Text \u2192 video (MiniMax H3)",
|
|
23626
|
+
images: "Images",
|
|
23627
|
+
recast: "Swap the person in a video for the one in a photo (you, for example)"
|
|
23628
|
+
},
|
|
23629
|
+
installed: "\u2713 Installed",
|
|
23630
|
+
available: (d, k) => `Possible: ${d} download (${k} on disk)`,
|
|
23631
|
+
recommendedTag: "recommended",
|
|
23632
|
+
notHere: "Not possible on this computer",
|
|
23633
|
+
installing: "Installing\u2026",
|
|
23634
|
+
h3Here: (m) => `about ${String(m)} min per 5-second clip`,
|
|
23635
|
+
perSecond: (c) => `${String(c)} credits per second`,
|
|
23636
|
+
perImage: (c) => `${String(c)} credits per image`,
|
|
23637
|
+
localOnly: "Only on this computer (free)",
|
|
23638
|
+
boostOff: "Not available now",
|
|
23639
|
+
recommendTitle: "Our recommendation",
|
|
23640
|
+
recommendInstall: (i, s) => `Install ${i} (${s}): your agent does it when you ask, and you approve the download.`,
|
|
23641
|
+
recommendNothing: "Nothing to install for now: what this computer cannot make, Cloud Boost makes.",
|
|
23642
|
+
boostFor: "Cloud Boost is the way here for",
|
|
23643
|
+
seeExamples: "See what it makes",
|
|
23644
|
+
howTo: "Ask your AI agent for what you want; before anything that spends credits it shows you where it runs, its price and roughly how long, and you approve it."
|
|
23645
|
+
},
|
|
23646
|
+
es: {
|
|
23647
|
+
title: "Ignix Creator en este ordenador",
|
|
23648
|
+
intro: "Ignix Creator ha analizado este ordenador. Esto es lo que puede hacer por s\xED mismo (gratis, tras una descarga \xFAnica) y lo que hace Cloud Boost de Ignix por \xE9l (cr\xE9ditos de IA de Ignix).",
|
|
23649
|
+
machine: "Este ordenador",
|
|
23650
|
+
what: "Qu\xE9",
|
|
23651
|
+
here: "En este ordenador",
|
|
23652
|
+
boost: "En Cloud Boost",
|
|
23653
|
+
rows: {
|
|
23654
|
+
production_tools: "Crear y editar v\xEDdeos (reels desde cero, tus grabaciones, clips y subt\xEDtulos)",
|
|
23655
|
+
presenter: "Un presentador que habla, desde una foto",
|
|
23656
|
+
video: "Foto \u2192 v\xEDdeo",
|
|
23657
|
+
h3: "Texto \u2192 v\xEDdeo (MiniMax H3)",
|
|
23658
|
+
images: "Im\xE1genes",
|
|
23659
|
+
recast: "Cambiar a la persona de un v\xEDdeo por la de una foto (por ejemplo, t\xFA)"
|
|
23660
|
+
},
|
|
23661
|
+
installed: "\u2713 Instalado",
|
|
23662
|
+
available: (d, k) => `Posible: descarga de ${d} (${k} en disco)`,
|
|
23663
|
+
recommendedTag: "recomendado",
|
|
23664
|
+
notHere: "No es posible en este ordenador",
|
|
23665
|
+
installing: "Instalando\u2026",
|
|
23666
|
+
h3Here: (m) => `unos ${String(m)} min por clip de 5 s`,
|
|
23667
|
+
perSecond: (c) => `${String(c)} cr\xE9ditos por segundo`,
|
|
23668
|
+
perImage: (c) => `${String(c)} cr\xE9ditos por imagen`,
|
|
23669
|
+
localOnly: "Solo en este ordenador (gratis)",
|
|
23670
|
+
boostOff: "No disponible ahora",
|
|
23671
|
+
recommendTitle: "Nuestra recomendaci\xF3n",
|
|
23672
|
+
recommendInstall: (i, s) => `Instala ${i} (${s}): lo hace tu agente cuando se lo pidas, y t\xFA apruebas la descarga.`,
|
|
23673
|
+
recommendNothing: "No hace falta instalar nada por ahora: lo que este ordenador no puede hacer, lo hace Cloud Boost.",
|
|
23674
|
+
boostFor: "Aqu\xED Cloud Boost se encarga de",
|
|
23675
|
+
seeExamples: "Mira lo que hace",
|
|
23676
|
+
howTo: "P\xEDdele a tu agente de IA lo que quieras: antes de cualquier cosa que gaste cr\xE9ditos te ense\xF1a d\xF3nde se hace, su precio y cu\xE1nto tarda, y t\xFA lo apruebas."
|
|
23677
|
+
},
|
|
23678
|
+
pt: {
|
|
23679
|
+
title: "Ignix Creator neste computador",
|
|
23680
|
+
intro: "O Ignix Creator analisou este computador. Isto \xE9 o que ele faz sozinho (gr\xE1tis, depois de um download \xFAnico) e o que o Cloud Boost da Ignix faz por ele (cr\xE9ditos de IA da Ignix).",
|
|
23681
|
+
machine: "Este computador",
|
|
23682
|
+
what: "O qu\xEA",
|
|
23683
|
+
here: "Neste computador",
|
|
23684
|
+
boost: "No Cloud Boost",
|
|
23685
|
+
rows: {
|
|
23686
|
+
production_tools: "Criar e editar v\xEDdeos (reels do zero, suas grava\xE7\xF5es, clipes e legendas)",
|
|
23687
|
+
presenter: "Um apresentador que fala, a partir de uma foto",
|
|
23688
|
+
video: "Foto \u2192 v\xEDdeo",
|
|
23689
|
+
h3: "Texto \u2192 v\xEDdeo (MiniMax H3)",
|
|
23690
|
+
images: "Imagens",
|
|
23691
|
+
recast: "Trocar a pessoa de um v\xEDdeo pela de uma foto (voc\xEA, por exemplo)"
|
|
23692
|
+
},
|
|
23693
|
+
installed: "\u2713 Instalado",
|
|
23694
|
+
available: (d, k) => `Poss\xEDvel: download de ${d} (${k} em disco)`,
|
|
23695
|
+
recommendedTag: "recomendado",
|
|
23696
|
+
notHere: "N\xE3o \xE9 poss\xEDvel neste computador",
|
|
23697
|
+
installing: "Instalando\u2026",
|
|
23698
|
+
h3Here: (m) => `cerca de ${String(m)} min por clipe de 5 s`,
|
|
23699
|
+
perSecond: (c) => `${String(c)} cr\xE9ditos por segundo`,
|
|
23700
|
+
perImage: (c) => `${String(c)} cr\xE9ditos por imagem`,
|
|
23701
|
+
localOnly: "S\xF3 neste computador (gr\xE1tis)",
|
|
23702
|
+
boostOff: "Indispon\xEDvel agora",
|
|
23703
|
+
recommendTitle: "Nossa recomenda\xE7\xE3o",
|
|
23704
|
+
recommendInstall: (i, s) => `Instale ${i} (${s}): seu agente faz isso quando voc\xEA pedir, e voc\xEA aprova o download.`,
|
|
23705
|
+
recommendNothing: "N\xE3o precisa instalar nada por enquanto: o que este computador n\xE3o consegue fazer, o Cloud Boost faz.",
|
|
23706
|
+
boostFor: "Aqui o Cloud Boost cuida de",
|
|
23707
|
+
seeExamples: "Veja o que ele faz",
|
|
23708
|
+
howTo: "Pe\xE7a ao seu agente de IA o que quiser: antes de qualquer coisa que use cr\xE9ditos ele mostra onde \xE9 feito, o pre\xE7o e quanto tempo leva, e voc\xEA aprova."
|
|
23709
|
+
},
|
|
23710
|
+
fr: {
|
|
23711
|
+
title: "Ignix Creator sur cet ordinateur",
|
|
23712
|
+
intro: "Ignix Creator a analys\xE9 cet ordinateur. Voici ce qu\u2019il peut faire seul (gratuit, apr\xE8s un t\xE9l\xE9chargement unique) et ce que Cloud Boost d\u2019Ignix fait pour lui (cr\xE9dits IA d\u2019Ignix).",
|
|
23713
|
+
machine: "Cet ordinateur",
|
|
23714
|
+
what: "Quoi",
|
|
23715
|
+
here: "Sur cet ordinateur",
|
|
23716
|
+
boost: "Sur Cloud Boost",
|
|
23717
|
+
rows: {
|
|
23718
|
+
production_tools: "Cr\xE9er et monter des vid\xE9os (reels de A \xE0 Z, vos enregistrements, extraits et sous-titres)",
|
|
23719
|
+
presenter: "Un pr\xE9sentateur qui parle, \xE0 partir d\u2019une photo",
|
|
23720
|
+
video: "Photo \u2192 vid\xE9o",
|
|
23721
|
+
h3: "Texte \u2192 vid\xE9o (MiniMax H3)",
|
|
23722
|
+
images: "Images",
|
|
23723
|
+
recast: "Remplacer la personne d\u2019une vid\xE9o par celle d\u2019une photo (vous, par exemple)"
|
|
23724
|
+
},
|
|
23725
|
+
installed: "\u2713 Install\xE9",
|
|
23726
|
+
available: (d, k) => `Possible : ${d} \xE0 t\xE9l\xE9charger (${k} sur le disque)`,
|
|
23727
|
+
recommendedTag: "recommand\xE9",
|
|
23728
|
+
notHere: "Impossible sur cet ordinateur",
|
|
23729
|
+
installing: "Installation\u2026",
|
|
23730
|
+
h3Here: (m) => `environ ${String(m)} min par clip de 5 s`,
|
|
23731
|
+
perSecond: (c) => `${String(c)} cr\xE9dits par seconde`,
|
|
23732
|
+
perImage: (c) => `${String(c)} cr\xE9dits par image`,
|
|
23733
|
+
localOnly: "Seulement sur cet ordinateur (gratuit)",
|
|
23734
|
+
boostOff: "Indisponible pour le moment",
|
|
23735
|
+
recommendTitle: "Notre recommandation",
|
|
23736
|
+
recommendInstall: (i, s) => `Installez ${i} (${s}) : votre agent le fait quand vous le demandez, et vous approuvez le t\xE9l\xE9chargement.`,
|
|
23737
|
+
recommendNothing: "Rien \xE0 installer pour l\u2019instant : ce que cet ordinateur ne peut pas faire, Cloud Boost le fait.",
|
|
23738
|
+
boostFor: "Ici, Cloud Boost s\u2019occupe de",
|
|
23739
|
+
seeExamples: "Voir ce qu\u2019il fait",
|
|
23740
|
+
howTo: "Demandez ce que vous voulez \xE0 votre agent IA : avant tout ce qui consomme des cr\xE9dits, il vous montre o\xF9 c\u2019est fait, le prix et la dur\xE9e approximative, et vous approuvez."
|
|
23741
|
+
},
|
|
23742
|
+
de: {
|
|
23743
|
+
title: "Ignix Creator auf diesem Computer",
|
|
23744
|
+
intro: "Ignix Creator hat diesen Computer analysiert. Das kann er selbst (kostenlos, nach einem einmaligen Download) und das \xFCbernimmt Ignix Cloud Boost f\xFCr ihn (Ignix-KI-Credits).",
|
|
23745
|
+
machine: "Dieser Computer",
|
|
23746
|
+
what: "Was",
|
|
23747
|
+
here: "Auf diesem Computer",
|
|
23748
|
+
boost: "Auf Cloud Boost",
|
|
23749
|
+
rows: {
|
|
23750
|
+
production_tools: "Videos erstellen und schneiden (Reels von Grund auf, deine Aufnahmen, Clips und Untertitel)",
|
|
23751
|
+
presenter: "Ein sprechender Pr\xE4sentator aus einem Foto",
|
|
23752
|
+
video: "Foto \u2192 Video",
|
|
23753
|
+
h3: "Text \u2192 Video (MiniMax H3)",
|
|
23754
|
+
images: "Bilder",
|
|
23755
|
+
recast: "Die Person in einem Video durch die auf einem Foto ersetzen (zum Beispiel dich)"
|
|
23756
|
+
},
|
|
23757
|
+
installed: "\u2713 Installiert",
|
|
23758
|
+
available: (d, k) => `M\xF6glich: ${d} Download (${k} auf der Festplatte)`,
|
|
23759
|
+
recommendedTag: "empfohlen",
|
|
23760
|
+
notHere: "Auf diesem Computer nicht m\xF6glich",
|
|
23761
|
+
installing: "Wird installiert\u2026",
|
|
23762
|
+
h3Here: (m) => `etwa ${String(m)} Min. pro 5-Sekunden-Clip`,
|
|
23763
|
+
perSecond: (c) => `${String(c)} Credits pro Sekunde`,
|
|
23764
|
+
perImage: (c) => `${String(c)} Credits pro Bild`,
|
|
23765
|
+
localOnly: "Nur auf diesem Computer (kostenlos)",
|
|
23766
|
+
boostOff: "Derzeit nicht verf\xFCgbar",
|
|
23767
|
+
recommendTitle: "Unsere Empfehlung",
|
|
23768
|
+
recommendInstall: (i, s) => `Installiere ${i} (${s}): Dein Agent macht das, wenn du ihn darum bittest, und du genehmigst den Download.`,
|
|
23769
|
+
recommendNothing: "Vorerst musst du nichts installieren: Was dieser Computer nicht kann, macht Cloud Boost.",
|
|
23770
|
+
boostFor: "Hier \xFCbernimmt Cloud Boost",
|
|
23771
|
+
seeExamples: "Sieh, was es macht",
|
|
23772
|
+
howTo: "Bitte deinen KI-Agenten um das, was du willst: Vor allem, was Credits kostet, zeigt er dir, wo es l\xE4uft, den Preis und die ungef\xE4hre Dauer, und du genehmigst es."
|
|
23773
|
+
}
|
|
23774
|
+
};
|
|
23775
|
+
var reelMaker = (lang) => `https://ignix.social${lang === "en" ? "" : `/${lang}`}/ai-reel-maker`;
|
|
23776
|
+
var esc2 = (s) => s.replace(/[&<>"']/g, (c) => `&#${String(c.charCodeAt(0))};`);
|
|
23777
|
+
var numberLang = "en";
|
|
23778
|
+
function size(bytes) {
|
|
23779
|
+
const gb = bytes / 1e9;
|
|
23780
|
+
const n = new Intl.NumberFormat(numberLang, { maximumFractionDigits: 1 });
|
|
23781
|
+
return gb >= 1 ? `${n.format(gb)} GB` : `${n.format(Math.max(1, Math.round(bytes / 1e6)))} MB`;
|
|
23782
|
+
}
|
|
23783
|
+
function here(item, w) {
|
|
23784
|
+
if (!item) return esc2(w.notHere);
|
|
23785
|
+
if (item.id === "h3" && item.h3 && item.state !== "unsupported" && item.h3.minutesFull)
|
|
23786
|
+
return esc2(
|
|
23787
|
+
`${item.state === "installed" ? w.installed : w.available(size(item.downloadBytes), size(item.diskBytes))} \xB7 ${w.h3Here(item.h3.minutesFull)}`
|
|
23788
|
+
);
|
|
23789
|
+
switch (item.state) {
|
|
23790
|
+
case "installed":
|
|
23791
|
+
case "update_available":
|
|
23792
|
+
return esc2(w.installed);
|
|
23793
|
+
case "queued":
|
|
23794
|
+
case "installing":
|
|
23795
|
+
return esc2(w.installing);
|
|
23796
|
+
case "unsupported":
|
|
23797
|
+
return esc2(w.notHere);
|
|
23798
|
+
default:
|
|
23799
|
+
return `${esc2(w.available(size(item.downloadBytes), size(item.diskBytes)))}${item.recommended ? ` <span class="tag">${esc2(w.recommendedTag)}</span>` : ""}`;
|
|
23800
|
+
}
|
|
23801
|
+
}
|
|
23802
|
+
function boost(row, p, w) {
|
|
23803
|
+
const sec = (c) => c === null ? w.boostOff : w.perSecond(c);
|
|
23804
|
+
switch (row) {
|
|
23805
|
+
case "production_tools":
|
|
23806
|
+
return w.localOnly;
|
|
23807
|
+
case "presenter":
|
|
23808
|
+
return p.presenterH3 !== null && p.presenter !== null ? `InfiniteTalk: ${sec(p.presenter)} \xB7 MiniMax H3: ${sec(p.presenterH3)}` : sec(p.presenter);
|
|
23809
|
+
case "video":
|
|
23810
|
+
return sec(p.animate);
|
|
23811
|
+
case "h3":
|
|
23812
|
+
return sec(p.textToVideo);
|
|
23813
|
+
case "images":
|
|
23814
|
+
return p.image === null ? w.boostOff : w.perImage(p.image);
|
|
23815
|
+
case "recast":
|
|
23816
|
+
return sec(p.recast);
|
|
23817
|
+
}
|
|
23818
|
+
}
|
|
23819
|
+
function buildReport(pack, prices, lang) {
|
|
23820
|
+
const w = W[lang];
|
|
23821
|
+
numberLang = lang;
|
|
23822
|
+
const item = (id) => pack.items.find((i) => i.id === id);
|
|
23823
|
+
const toInstall = pack.items.filter(
|
|
23824
|
+
(i) => i.recommended && i.id !== "assistant" && i.state === "not_installed"
|
|
23825
|
+
);
|
|
23826
|
+
const rows = ROWS.map(
|
|
23827
|
+
(r) => `<tr><th scope="row">${esc2(w.rows[r])}${r === "production_tools" ? ` <a href="${reelMaker(lang)}" target="_blank" rel="noopener">${esc2(w.seeExamples)} \u2197</a>` : ""}</th><td>${here(item(r), w)}</td><td>${esc2(boost(r, prices, w))}</td></tr>`
|
|
23828
|
+
).join("\n");
|
|
23829
|
+
const recommend = toInstall.length ? w.recommendInstall(
|
|
23830
|
+
toInstall.map((i) => `\xAB${w.rows[i.id]}\xBB`).join(", "),
|
|
23831
|
+
size(toInstall.reduce((n, i) => n + i.downloadBytes, 0))
|
|
23832
|
+
) : w.recommendNothing;
|
|
23833
|
+
const boostFor = pack.cloudBoostFor.length ? `<p>${esc2(w.boostFor)}: ${esc2(
|
|
23834
|
+
pack.cloudBoostFor.map(
|
|
23835
|
+
(k) => k === "images" ? w.rows.images : k === "video" ? w.rows.video : w.rows.presenter
|
|
23836
|
+
).join(", ")
|
|
23837
|
+
)}.</p>` : "";
|
|
23838
|
+
return `<!doctype html>
|
|
23839
|
+
<html lang="${lang}">
|
|
23840
|
+
<head>
|
|
23841
|
+
<meta charset="utf-8">
|
|
23842
|
+
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
23843
|
+
<meta http-equiv="Content-Security-Policy" content="default-src 'none'; style-src 'unsafe-inline'">
|
|
23844
|
+
<title>${esc2(w.title)}</title>
|
|
23845
|
+
<style>
|
|
23846
|
+
:root { color-scheme: light dark; --bg: #fffaf5; --fg: #1c1917; --muted: #78716c; --line: #e7e5e4; --accent: #ea580c; }
|
|
23847
|
+
@media (prefers-color-scheme: dark) { :root { --bg: #1c1917; --fg: #f5f5f4; --muted: #a8a29e; --line: #44403c; } }
|
|
23848
|
+
body { margin: 0; background: var(--bg); color: var(--fg); font: 16px/1.5 system-ui, -apple-system, "Segoe UI", sans-serif; }
|
|
23849
|
+
main { max-width: 860px; margin: 0 auto; padding: 32px 16px 48px; }
|
|
23850
|
+
h1 { font-size: 28px; margin: 0 0 8px; } h1 span { color: var(--accent); }
|
|
23851
|
+
p { margin: 8px 0; } .muted { color: var(--muted); }
|
|
23852
|
+
.machine { margin: 20px 0; padding: 14px 16px; border: 1px solid var(--line); border-radius: 12px; }
|
|
23853
|
+
table { width: 100%; border-collapse: collapse; margin: 16px 0; }
|
|
23854
|
+
th, td { text-align: left; padding: 10px 8px; border-bottom: 1px solid var(--line); vertical-align: top; }
|
|
23855
|
+
thead th { font-size: 13px; color: var(--muted); font-weight: 600; }
|
|
23856
|
+
tbody th { font-weight: 600; }
|
|
23857
|
+
th a { display: block; font-weight: 400; font-size: 14px; color: var(--accent); }
|
|
23858
|
+
.tag { display: inline-block; font-size: 12px; padding: 1px 8px; border-radius: 99px; background: var(--accent); color: #fff; }
|
|
23859
|
+
.rec { margin-top: 24px; padding: 14px 16px; border-left: 4px solid var(--accent); background: color-mix(in srgb, var(--accent) 8%, transparent); border-radius: 6px; }
|
|
23860
|
+
@media (max-width: 600px) { thead { display: none; } tr, td, tbody th { display: block; } td { border: 0; padding: 2px 8px; } tbody th { padding-top: 14px; } }
|
|
23861
|
+
</style>
|
|
23862
|
+
</head>
|
|
23863
|
+
<body><main>
|
|
23864
|
+
<h1><span>Ignix</span> ${esc2(w.title.replace(/^Ignix /, ""))}</h1>
|
|
23865
|
+
<p class="muted">${esc2(w.intro)}</p>
|
|
23866
|
+
<div class="machine"><strong>${esc2(w.machine)}:</strong> ${esc2(pack.machine)}</div>
|
|
23867
|
+
<table>
|
|
23868
|
+
<thead><tr><th>${esc2(w.what)}</th><th>${esc2(w.here)}</th><th>${esc2(w.boost)}</th></tr></thead>
|
|
23869
|
+
<tbody>
|
|
23870
|
+
${rows}
|
|
23871
|
+
</tbody>
|
|
23872
|
+
</table>
|
|
23873
|
+
<div class="rec"><strong>${esc2(w.recommendTitle)}</strong><p>${esc2(recommend)}</p>${boostFor}</div>
|
|
23874
|
+
<p class="muted">${esc2(w.howTo)}</p>
|
|
23875
|
+
</main></body>
|
|
23876
|
+
</html>
|
|
23877
|
+
`;
|
|
23878
|
+
}
|
|
23879
|
+
|
|
23610
23880
|
// src/cli.ts
|
|
23611
|
-
var VERSION = true ? "0.1.
|
|
23881
|
+
var VERSION = true ? "0.1.4" : "0.0.0-dev";
|
|
23612
23882
|
var HELP = `Ignix Creator ${VERSION} - generation tools for AI agents (ADR-0028/0029)
|
|
23613
23883
|
|
|
23614
23884
|
ignix-creator login sign in to Ignix in your browser
|
|
23615
23885
|
ignix-creator logout
|
|
23616
23886
|
ignix-creator status account, plan and what waits for your approval
|
|
23617
23887
|
ignix-creator doctor what this computer can run
|
|
23888
|
+
ignix-creator report open \xABIgnix Creator on this computer\xBB in your browser
|
|
23618
23889
|
ignix-creator engines local engines and their state
|
|
23619
23890
|
ignix-creator engines install <item...> [--accept-licence minimax_h3]
|
|
23620
23891
|
ignix-creator engines cancel stop the install in progress
|
|
@@ -23695,6 +23966,7 @@ async function login(paths) {
|
|
|
23695
23966
|
}
|
|
23696
23967
|
process.stdout.write(`Signed in: ${account(s)}
|
|
23697
23968
|
`);
|
|
23969
|
+
await report(paths).catch(() => void 0);
|
|
23698
23970
|
return;
|
|
23699
23971
|
}
|
|
23700
23972
|
if (s.status === "ineligible" || s.status === "error" || s.status === "signed_out") {
|
|
@@ -23703,6 +23975,37 @@ async function login(paths) {
|
|
|
23703
23975
|
}
|
|
23704
23976
|
throw new Error("Sign-in timed out.");
|
|
23705
23977
|
}
|
|
23978
|
+
async function report(paths) {
|
|
23979
|
+
await ensureService(paths);
|
|
23980
|
+
const pack = (await control(paths, "engines.getPack")).value;
|
|
23981
|
+
const credits = async (what, args) => {
|
|
23982
|
+
const r = await control(paths, "mcp.call", {
|
|
23983
|
+
client: { name: "ignix-creator CLI", version: VERSION },
|
|
23984
|
+
tool: "estimate",
|
|
23985
|
+
args: { what, ...args }
|
|
23986
|
+
});
|
|
23987
|
+
const v = r.value;
|
|
23988
|
+
if (v?.status !== "ok") return null;
|
|
23989
|
+
const d = v.data;
|
|
23990
|
+
return d.cloudBoost === false || typeof d.credits !== "number" ? null : d.credits;
|
|
23991
|
+
};
|
|
23992
|
+
const prices = {
|
|
23993
|
+
presenter: await credits("presenter", { seconds: 1 }),
|
|
23994
|
+
presenterH3: await credits("presenter", { seconds: 1, model: "minimax_h3" }),
|
|
23995
|
+
animate: await credits("animate", { seconds: 1 }),
|
|
23996
|
+
textToVideo: await credits("text_to_video", { seconds: 1 }),
|
|
23997
|
+
recast: await credits("recast", { seconds: 1 }),
|
|
23998
|
+
image: await credits("image", { count: 1 })
|
|
23999
|
+
};
|
|
24000
|
+
const file2 = (0, import_node_path6.join)(paths.home, "report.html");
|
|
24001
|
+
(0, import_node_fs2.writeFileSync)(file2, buildReport(pack, prices, dialogLang(await systemLanguage())), {
|
|
24002
|
+
mode: 384
|
|
24003
|
+
});
|
|
24004
|
+
openUrl(file2);
|
|
24005
|
+
process.stdout.write(`Opened: ${file2}
|
|
24006
|
+
`);
|
|
24007
|
+
return file2;
|
|
24008
|
+
}
|
|
23706
24009
|
async function main(argv) {
|
|
23707
24010
|
const paths = cliPaths();
|
|
23708
24011
|
const [cmd, sub, ...rest] = argv;
|
|
@@ -23728,6 +24031,9 @@ async function main(argv) {
|
|
|
23728
24031
|
return;
|
|
23729
24032
|
case "login":
|
|
23730
24033
|
return login(paths);
|
|
24034
|
+
case "report":
|
|
24035
|
+
await report(paths);
|
|
24036
|
+
return;
|
|
23731
24037
|
case "logout":
|
|
23732
24038
|
await ensureService(paths);
|
|
23733
24039
|
await control(paths, "auth.signOut");
|
package/dist/core.cjs
CHANGED
|
@@ -36430,7 +36430,8 @@ function createEditorKitStore(deps) {
|
|
|
36430
36430
|
return { install, verify, dir: kitDir, dataDir, removeData };
|
|
36431
36431
|
}
|
|
36432
36432
|
function createNpmEditorKitStore(deps) {
|
|
36433
|
-
const
|
|
36433
|
+
const shared = deps.sharedDataDir && (0, import_node_path8.isAbsolute)(deps.sharedDataDir) ? (0, import_node_path8.resolve)(deps.sharedDataDir) : null;
|
|
36434
|
+
const dataDir = () => shared ?? inside(deps.paths.models, "ignix-editor");
|
|
36434
36435
|
async function verify() {
|
|
36435
36436
|
let version2;
|
|
36436
36437
|
try {
|
|
@@ -36460,6 +36461,7 @@ function createNpmEditorKitStore(deps) {
|
|
|
36460
36461
|
dir: () => (0, import_node_path8.resolve)(deps.root),
|
|
36461
36462
|
dataDir,
|
|
36462
36463
|
removeData: async () => {
|
|
36464
|
+
if (shared) return;
|
|
36463
36465
|
await discardDir(dataDir(), deps.paths.trash).catch(() => void 0);
|
|
36464
36466
|
}
|
|
36465
36467
|
};
|
|
@@ -40230,6 +40232,7 @@ function createCoreService({
|
|
|
40230
40232
|
}
|
|
40231
40233
|
|
|
40232
40234
|
// ../../packages/core/src/process/entry.ts
|
|
40235
|
+
var import_node_os4 = require("node:os");
|
|
40233
40236
|
var import_node_path27 = require("node:path");
|
|
40234
40237
|
|
|
40235
40238
|
// ../../packages/generation/src/index.ts
|
|
@@ -56128,7 +56131,7 @@ function renderEstimateSeconds(videoSeconds) {
|
|
|
56128
56131
|
return Math.round(RENDER_STARTUP_SECONDS + videoSeconds * RENDER_SECONDS_PER_VIDEO_SECOND);
|
|
56129
56132
|
}
|
|
56130
56133
|
var WHISPER_SMALL_BYTES = 487601967;
|
|
56131
|
-
function editorDownloadBytes(kitSourceDir, os2, arch2) {
|
|
56134
|
+
function editorDownloadBytes(kitSourceDir, os2, arch2, dataDir) {
|
|
56132
56135
|
try {
|
|
56133
56136
|
const m = JSON.parse(
|
|
56134
56137
|
(0, import_node_fs14.readFileSync)(
|
|
@@ -56137,8 +56140,27 @@ function editorDownloadBytes(kitSourceDir, os2, arch2) {
|
|
|
56137
56140
|
)
|
|
56138
56141
|
);
|
|
56139
56142
|
const key = `${os2 === "windows" ? "win32" : "darwin"}-${arch2}`;
|
|
56140
|
-
const
|
|
56141
|
-
|
|
56143
|
+
const has2 = (path, size) => {
|
|
56144
|
+
if (!dataDir || !path) return false;
|
|
56145
|
+
try {
|
|
56146
|
+
const st = (0, import_node_fs14.statSync)((0, import_node_path23.join)(dataDir, path));
|
|
56147
|
+
return size === void 0 ? st.isDirectory() : st.isFile() && st.size === size;
|
|
56148
|
+
} catch {
|
|
56149
|
+
return false;
|
|
56150
|
+
}
|
|
56151
|
+
};
|
|
56152
|
+
const bins = Object.values(m.platforms?.[key] ?? {}).reduce(
|
|
56153
|
+
(n, e) => n + (has2(e.file ? (0, import_node_path23.join)("bin", key, m.version ?? "", e.file) : null, e.size) ? 0 : e.size ?? 0),
|
|
56154
|
+
0
|
|
56155
|
+
);
|
|
56156
|
+
const a = m.analysis;
|
|
56157
|
+
const runtime = has2((0, import_node_path23.join)("runtime", `onnxruntime-${a?.runtimeVersion ?? ""}`, key)) ? 0 : a?.runtime?.[key]?.size ?? 0;
|
|
56158
|
+
const models = Object.values(a?.models ?? {}).reduce(
|
|
56159
|
+
(n, e) => n + (has2(e.file ? (0, import_node_path23.join)("models", "analysis", a?.version ?? "", e.file) : null, e.size) ? 0 : e.size ?? 0),
|
|
56160
|
+
0
|
|
56161
|
+
);
|
|
56162
|
+
const whisper = has2((0, import_node_path23.join)("models", "ggml-small.bin"), WHISPER_SMALL_BYTES) ? 0 : WHISPER_SMALL_BYTES;
|
|
56163
|
+
return bins + runtime + models + whisper;
|
|
56142
56164
|
} catch {
|
|
56143
56165
|
return WHISPER_SMALL_BYTES;
|
|
56144
56166
|
}
|
|
@@ -56165,7 +56187,8 @@ function createVideoEngineService(deps) {
|
|
|
56165
56187
|
const kit = deps.npmEditor ? createNpmEditorKitStore({
|
|
56166
56188
|
paths: engine.paths,
|
|
56167
56189
|
root: deps.npmEditor.root,
|
|
56168
|
-
editorVersion: deps.npmEditor.version
|
|
56190
|
+
editorVersion: deps.npmEditor.version,
|
|
56191
|
+
...deps.npmEditor.sharedDataDir ? { sharedDataDir: deps.npmEditor.sharedDataDir } : {}
|
|
56169
56192
|
}) : createEditorKitStore({ paths: engine.paths, manifestSha256: deps.kitManifestSha256 });
|
|
56170
56193
|
const launcher = createRuntimeLauncher({
|
|
56171
56194
|
paths: engine.paths,
|
|
@@ -56225,7 +56248,7 @@ function createVideoEngineService(deps) {
|
|
|
56225
56248
|
return status();
|
|
56226
56249
|
}
|
|
56227
56250
|
const engineBytes = installedRuntime() ? 0 : videoDownloadBytes(artifact);
|
|
56228
|
-
const editorBytes = editorFiles === "ready" ? 0 : editorDownloadBytes(deps.kitSourceDir, p.os, p.arch);
|
|
56251
|
+
const editorBytes = editorFiles === "ready" ? 0 : editorDownloadBytes(deps.kitSourceDir, p.os, p.arch, kit.dataDir());
|
|
56229
56252
|
const download = engineBytes + editorBytes;
|
|
56230
56253
|
const free = await freeBytes(engine.paths.root);
|
|
56231
56254
|
const required2 = download + (engineBytes ? videoInstalledBytes(artifact) : 0) + editorBytes + DISK_RESERVE;
|
|
@@ -56262,7 +56285,7 @@ function createVideoEngineService(deps) {
|
|
|
56262
56285
|
const artifact = videoArtifactFor(recipe, p.os, p.arch);
|
|
56263
56286
|
if (!artifact) throw new Error("unsupported");
|
|
56264
56287
|
const engineBytes = installedRuntime() ? 0 : videoDownloadBytes(artifact);
|
|
56265
|
-
const editorEstimate = editorDownloadBytes(deps.kitSourceDir, p.os, p.arch);
|
|
56288
|
+
const editorEstimate = editorDownloadBytes(deps.kitSourceDir, p.os, p.arch, kit.dataDir());
|
|
56266
56289
|
if (!installedRuntime()) {
|
|
56267
56290
|
progress = {
|
|
56268
56291
|
stage: "engine_download",
|
|
@@ -61038,7 +61061,7 @@ function bytesFraction(p) {
|
|
|
61038
61061
|
// ../../packages/core/src/process/entry.ts
|
|
61039
61062
|
var import_node_crypto30 = require("node:crypto");
|
|
61040
61063
|
var import_promises33 = require("node:fs/promises");
|
|
61041
|
-
var
|
|
61064
|
+
var import_node_os5 = require("node:os");
|
|
61042
61065
|
|
|
61043
61066
|
// ../../packages/core/src/process/host-bridge.ts
|
|
61044
61067
|
init_define_CREATOR_BOX_KIT();
|
|
@@ -61223,18 +61246,18 @@ var EN2 = {
|
|
|
61223
61246
|
yourTranslations: "Your translations.",
|
|
61224
61247
|
linesVoiced: (n) => `${String(n)} lines voiced.`,
|
|
61225
61248
|
noVoice: "No voice.",
|
|
61226
|
-
recast: "
|
|
61249
|
+
recast: "Swap the person in a video for the one in a photo (checks first, the price on its card)",
|
|
61227
61250
|
makeImage: "Make an image",
|
|
61228
61251
|
makeClip: "Make a video clip",
|
|
61229
61252
|
makePresenter: "Make a presenter",
|
|
61230
61253
|
installHere: (e) => `Install on this computer: ${e ? e.map(
|
|
61231
61254
|
(i) => ({
|
|
61232
|
-
production_tools: "
|
|
61255
|
+
production_tools: "the tools to make and edit videos",
|
|
61233
61256
|
assistant: "a local writing assistant",
|
|
61234
61257
|
images: "local image generation",
|
|
61235
61258
|
video: "local video generation",
|
|
61236
61259
|
presenter: "a local talking presenter",
|
|
61237
|
-
recast: "
|
|
61260
|
+
recast: "swapping the person in a video for the one in a photo, locally",
|
|
61238
61261
|
h3: "the MiniMax H3 video model"
|
|
61239
61262
|
})[i]
|
|
61240
61263
|
).join(", ") : "the tools recommended for it"}`,
|
|
@@ -61245,7 +61268,9 @@ var EN2 = {
|
|
|
61245
61268
|
consentDetail: "Uses photos or videos of people: approving confirms they are you or consented.",
|
|
61246
61269
|
whereLocal: (eta) => `On this computer, free${eta ? `, about ${eta}` : ""}.`,
|
|
61247
61270
|
whereBoost: (eta) => `On Ignix Cloud Boost${eta ? `, about ${eta}` : ""}.`,
|
|
61248
|
-
whereIgnix: (eta) => `With Ignix AI${eta ? `, about ${eta}` : ""}
|
|
61271
|
+
whereIgnix: (eta) => `With Ignix AI${eta ? `, about ${eta}` : ""}.`,
|
|
61272
|
+
modelInfiniteTalk: "Model: InfiniteTalk (lip-syncs your exact voice line).",
|
|
61273
|
+
modelH3: "Model: MiniMax H3 (says the line itself in a voice cloned from yours; may add a word at the end)."
|
|
61249
61274
|
};
|
|
61250
61275
|
var ES2 = {
|
|
61251
61276
|
piece: (k) => ({ reel: "reel", story: "historia", post: "publicaci\xF3n" })[k] ?? k,
|
|
@@ -61273,18 +61298,18 @@ var ES2 = {
|
|
|
61273
61298
|
yourTranslations: "Tus traducciones.",
|
|
61274
61299
|
linesVoiced: (n) => `${String(n)} frases con voz.`,
|
|
61275
61300
|
noVoice: "Sin voz.",
|
|
61276
|
-
recast: "
|
|
61301
|
+
recast: "Cambiar a la persona de un v\xEDdeo por la de una foto (primero se comprueba; el precio, en su tarjeta)",
|
|
61277
61302
|
makeImage: "Crear una imagen",
|
|
61278
61303
|
makeClip: "Crear un clip de v\xEDdeo",
|
|
61279
61304
|
makePresenter: "Crear un presentador",
|
|
61280
61305
|
installHere: (e) => `Instalar en este ordenador: ${e ? e.map(
|
|
61281
61306
|
(i) => ({
|
|
61282
|
-
production_tools: "herramientas
|
|
61307
|
+
production_tools: "las herramientas para crear y editar v\xEDdeos",
|
|
61283
61308
|
assistant: "un asistente de escritura local",
|
|
61284
61309
|
images: "generaci\xF3n de im\xE1genes local",
|
|
61285
61310
|
video: "generaci\xF3n de v\xEDdeo local",
|
|
61286
61311
|
presenter: "un presentador que habla, en local",
|
|
61287
|
-
recast: "
|
|
61312
|
+
recast: "cambiar a la persona de un v\xEDdeo por la de una foto, en local",
|
|
61288
61313
|
h3: "el modelo de v\xEDdeo MiniMax H3"
|
|
61289
61314
|
})[i]
|
|
61290
61315
|
).join(", ") : "las herramientas recomendadas para \xE9l"}`,
|
|
@@ -61295,7 +61320,9 @@ var ES2 = {
|
|
|
61295
61320
|
consentDetail: "Usa fotos o v\xEDdeos de personas: al aprobar confirmas que eres t\xFA o que han dado su consentimiento.",
|
|
61296
61321
|
whereLocal: (eta) => `En este ordenador, gratis${eta ? `, unos ${eta}` : ""}.`,
|
|
61297
61322
|
whereBoost: (eta) => `En Cloud Boost de Ignix${eta ? `, unos ${eta}` : ""}.`,
|
|
61298
|
-
whereIgnix: (eta) => `Con la IA de Ignix${eta ? `, unos ${eta}` : ""}
|
|
61323
|
+
whereIgnix: (eta) => `Con la IA de Ignix${eta ? `, unos ${eta}` : ""}.`,
|
|
61324
|
+
modelInfiniteTalk: "Modelo: InfiniteTalk (sincroniza los labios con tu voz exacta).",
|
|
61325
|
+
modelH3: "Modelo: MiniMax H3 (dice la frase \xE9l mismo con una voz clonada de la tuya; a veces a\xF1ade una palabra al final)."
|
|
61299
61326
|
};
|
|
61300
61327
|
var PT = {
|
|
61301
61328
|
piece: (k) => ({ reel: "reel", story: "story", post: "post" })[k] ?? k,
|
|
@@ -61323,18 +61350,18 @@ var PT = {
|
|
|
61323
61350
|
yourTranslations: "Suas tradu\xE7\xF5es.",
|
|
61324
61351
|
linesVoiced: (n) => `${String(n)} falas com voz.`,
|
|
61325
61352
|
noVoice: "Sem voz.",
|
|
61326
|
-
recast: "
|
|
61353
|
+
recast: "Trocar a pessoa de um v\xEDdeo pela de uma foto (verifica primeiro; o pre\xE7o fica no cart\xE3o)",
|
|
61327
61354
|
makeImage: "Criar uma imagem",
|
|
61328
61355
|
makeClip: "Criar um clipe de v\xEDdeo",
|
|
61329
61356
|
makePresenter: "Criar um apresentador",
|
|
61330
61357
|
installHere: (e) => `Instalar neste computador: ${e ? e.map(
|
|
61331
61358
|
(i) => ({
|
|
61332
|
-
production_tools: "ferramentas
|
|
61359
|
+
production_tools: "as ferramentas para criar e editar v\xEDdeos",
|
|
61333
61360
|
assistant: "um assistente de escrita local",
|
|
61334
61361
|
images: "gera\xE7\xE3o de imagens local",
|
|
61335
61362
|
video: "gera\xE7\xE3o de v\xEDdeo local",
|
|
61336
61363
|
presenter: "um apresentador que fala, local",
|
|
61337
|
-
recast: "
|
|
61364
|
+
recast: "trocar a pessoa de um v\xEDdeo pela de uma foto, local",
|
|
61338
61365
|
h3: "o modelo de v\xEDdeo MiniMax H3"
|
|
61339
61366
|
})[i]
|
|
61340
61367
|
).join(", ") : "as ferramentas recomendadas para ele"}`,
|
|
@@ -61345,7 +61372,9 @@ var PT = {
|
|
|
61345
61372
|
consentDetail: "Usa fotos ou v\xEDdeos de pessoas: ao aprovar, voc\xEA confirma que \xE9 voc\xEA ou que elas consentiram.",
|
|
61346
61373
|
whereLocal: (eta) => `Neste computador, gr\xE1tis${eta ? `, cerca de ${eta}` : ""}.`,
|
|
61347
61374
|
whereBoost: (eta) => `No Cloud Boost da Ignix${eta ? `, cerca de ${eta}` : ""}.`,
|
|
61348
|
-
whereIgnix: (eta) => `Com a IA da Ignix${eta ? `, cerca de ${eta}` : ""}
|
|
61375
|
+
whereIgnix: (eta) => `Com a IA da Ignix${eta ? `, cerca de ${eta}` : ""}.`,
|
|
61376
|
+
modelInfiniteTalk: "Modelo: InfiniteTalk (sincroniza os l\xE1bios com a sua voz exata).",
|
|
61377
|
+
modelH3: "Modelo: MiniMax H3 (diz a frase ele mesmo com uma voz clonada da sua; \xE0s vezes acrescenta uma palavra no final)."
|
|
61349
61378
|
};
|
|
61350
61379
|
var FR = {
|
|
61351
61380
|
piece: (k) => ({ reel: "reel", story: "story", post: "publication" })[k] ?? k,
|
|
@@ -61373,18 +61402,18 @@ var FR = {
|
|
|
61373
61402
|
yourTranslations: "Vos traductions.",
|
|
61374
61403
|
linesVoiced: (n) => `${String(n)} r\xE9pliques avec voix.`,
|
|
61375
61404
|
noVoice: "Sans voix.",
|
|
61376
|
-
recast: "
|
|
61405
|
+
recast: "Remplacer la personne d\u2019une vid\xE9o par celle d\u2019une photo (v\xE9rification d\u2019abord ; le prix figure sur sa fiche)",
|
|
61377
61406
|
makeImage: "Cr\xE9er une image",
|
|
61378
61407
|
makeClip: "Cr\xE9er un clip vid\xE9o",
|
|
61379
61408
|
makePresenter: "Cr\xE9er un pr\xE9sentateur",
|
|
61380
61409
|
installHere: (e) => `Installer sur cet ordinateur : ${e ? e.map(
|
|
61381
61410
|
(i) => ({
|
|
61382
|
-
production_tools: "les outils
|
|
61411
|
+
production_tools: "les outils pour cr\xE9er et monter des vid\xE9os",
|
|
61383
61412
|
assistant: "un assistant de r\xE9daction local",
|
|
61384
61413
|
images: "la g\xE9n\xE9ration d\u2019images en local",
|
|
61385
61414
|
video: "la g\xE9n\xE9ration de vid\xE9os en local",
|
|
61386
61415
|
presenter: "un pr\xE9sentateur qui parle, en local",
|
|
61387
|
-
recast: "
|
|
61416
|
+
recast: "remplacer la personne d\u2019une vid\xE9o par celle d\u2019une photo, en local",
|
|
61388
61417
|
h3: "le mod\xE8le vid\xE9o MiniMax H3"
|
|
61389
61418
|
})[i]
|
|
61390
61419
|
).join(", ") : "les outils recommand\xE9s pour lui"}`,
|
|
@@ -61395,7 +61424,9 @@ var FR = {
|
|
|
61395
61424
|
consentDetail: "Utilise des photos ou vid\xE9os de personnes : approuver confirme qu\u2019il s\u2019agit de vous ou qu\u2019elles ont consenti.",
|
|
61396
61425
|
whereLocal: (eta) => `Sur cet ordinateur, gratuit${eta ? `, environ ${eta}` : ""}.`,
|
|
61397
61426
|
whereBoost: (eta) => `Sur Cloud Boost d\u2019Ignix${eta ? `, environ ${eta}` : ""}.`,
|
|
61398
|
-
whereIgnix: (eta) => `Avec l\u2019IA d\u2019Ignix${eta ? `, environ ${eta}` : ""}
|
|
61427
|
+
whereIgnix: (eta) => `Avec l\u2019IA d\u2019Ignix${eta ? `, environ ${eta}` : ""}.`,
|
|
61428
|
+
modelInfiniteTalk: "Mod\xE8le : InfiniteTalk (synchronise les l\xE8vres sur votre voix exacte).",
|
|
61429
|
+
modelH3: "Mod\xE8le : MiniMax H3 (dit la phrase lui-m\xEAme avec une voix clon\xE9e de la v\xF4tre ; ajoute parfois un mot \xE0 la fin)."
|
|
61399
61430
|
};
|
|
61400
61431
|
var DE = {
|
|
61401
61432
|
piece: (k) => ({ reel: "Reel", story: "Story", post: "Post" })[k] ?? k,
|
|
@@ -61423,18 +61454,18 @@ var DE = {
|
|
|
61423
61454
|
yourTranslations: "Deine \xDCbersetzungen.",
|
|
61424
61455
|
linesVoiced: (n) => `${String(n)} gesprochene Zeilen.`,
|
|
61425
61456
|
noVoice: "Ohne Stimme.",
|
|
61426
|
-
recast: "
|
|
61457
|
+
recast: "Die Person in einem Video durch die auf einem Foto ersetzen (erst wird gepr\xFCft; der Preis steht auf der Karte)",
|
|
61427
61458
|
makeImage: "Ein Bild erstellen",
|
|
61428
61459
|
makeClip: "Einen Videoclip erstellen",
|
|
61429
61460
|
makePresenter: "Einen Pr\xE4sentator erstellen",
|
|
61430
61461
|
installHere: (e) => `Auf diesem Computer installieren: ${e ? e.map(
|
|
61431
61462
|
(i) => ({
|
|
61432
|
-
production_tools: "
|
|
61463
|
+
production_tools: "die Werkzeuge zum Erstellen und Schneiden von Videos",
|
|
61433
61464
|
assistant: "einen lokalen Schreibassistenten",
|
|
61434
61465
|
images: "lokale Bildgenerierung",
|
|
61435
61466
|
video: "lokale Videogenerierung",
|
|
61436
61467
|
presenter: "einen sprechenden Pr\xE4sentator, lokal",
|
|
61437
|
-
recast: "
|
|
61468
|
+
recast: "die Person in einem Video durch die auf einem Foto ersetzen, lokal",
|
|
61438
61469
|
h3: "das Videomodell MiniMax H3"
|
|
61439
61470
|
})[i]
|
|
61440
61471
|
).join(", ") : "die daf\xFCr empfohlenen Werkzeuge"}`,
|
|
@@ -61445,7 +61476,9 @@ var DE = {
|
|
|
61445
61476
|
consentDetail: "Verwendet Fotos oder Videos von Personen: Mit der Genehmigung best\xE4tigst du, dass du es bist oder sie zugestimmt haben.",
|
|
61446
61477
|
whereLocal: (eta) => `Auf diesem Computer, kostenlos${eta ? `, etwa ${eta}` : ""}.`,
|
|
61447
61478
|
whereBoost: (eta) => `Auf Ignix Cloud Boost${eta ? `, etwa ${eta}` : ""}.`,
|
|
61448
|
-
whereIgnix: (eta) => `Mit der Ignix-KI${eta ? `, etwa ${eta}` : ""}
|
|
61479
|
+
whereIgnix: (eta) => `Mit der Ignix-KI${eta ? `, etwa ${eta}` : ""}.`,
|
|
61480
|
+
modelInfiniteTalk: "Modell: InfiniteTalk (synchronisiert die Lippen mit deiner genauen Stimme).",
|
|
61481
|
+
modelH3: "Modell: MiniMax H3 (spricht den Satz selbst mit einer aus deiner geklonten Stimme; h\xE4ngt manchmal ein Wort an)."
|
|
61449
61482
|
};
|
|
61450
61483
|
var TEXTS = { en: EN2, es: ES2, pt: PT, fr: FR, de: DE };
|
|
61451
61484
|
function approvalText(lang) {
|
|
@@ -61616,42 +61649,51 @@ function createMcpService(deps) {
|
|
|
61616
61649
|
};
|
|
61617
61650
|
}
|
|
61618
61651
|
async function routed(c, o, start3) {
|
|
61619
|
-
const
|
|
61620
|
-
|
|
61621
|
-
|
|
61622
|
-
|
|
61652
|
+
const quoted2 = await Promise.all(
|
|
61653
|
+
o.variants.map(async (v) => ({
|
|
61654
|
+
v,
|
|
61655
|
+
options: await deps.content.quote?.(v.request).catch(() => []) ?? []
|
|
61656
|
+
}))
|
|
61657
|
+
);
|
|
61658
|
+
const creditsOf = (v, x) => x.cost.unit === "none" ? 0 : x.cost.unit === "boost" ? v.boostCredits : x.cost.amount;
|
|
61659
|
+
const all = quoted2.flatMap(({ v, options: options2 }) => options2.map((x) => ({ v, x })));
|
|
61660
|
+
const way = ({ v, x }) => ({
|
|
61661
|
+
...v.model ? { model: v.model } : {},
|
|
61623
61662
|
target: x.target,
|
|
61624
61663
|
available: x.available,
|
|
61625
61664
|
reason: x.reason,
|
|
61626
61665
|
estimateSeconds: x.estimateSeconds,
|
|
61627
|
-
credits:
|
|
61666
|
+
credits: creditsOf(v, x),
|
|
61667
|
+
...v.note ? { note: v.note } : {}
|
|
61628
61668
|
});
|
|
61629
|
-
const
|
|
61630
|
-
|
|
61631
|
-
|
|
61632
|
-
|
|
61633
|
-
|
|
61634
|
-
|
|
61635
|
-
|
|
61636
|
-
|
|
61669
|
+
const wanted = o.target && o.target !== "auto" ? o.target : null;
|
|
61670
|
+
const usable = all.filter((w) => w.x.available && (!wanted || w.x.target === wanted));
|
|
61671
|
+
if (usable.length > 1)
|
|
61672
|
+
return ok2({
|
|
61673
|
+
needsChoice: true,
|
|
61674
|
+
ways: usable.map(way),
|
|
61675
|
+
unavailable: all.filter((w) => !w.x.available).map(way),
|
|
61676
|
+
message: "It can be made in more than one way. Tell the person each one in plain words \u2014 model and what it does, where (local = their computer, free; boost = Ignix Cloud Boost; ignix = Ignix AI), its credits and roughly how long \u2014 and what cannot run here and why; then call again with their `target` (and `model`)."
|
|
61677
|
+
});
|
|
61678
|
+
const pick2 = usable[0];
|
|
61679
|
+
if (!pick2)
|
|
61637
61680
|
return err(
|
|
61638
61681
|
"unavailable",
|
|
61639
|
-
`${wanted ? `It cannot be made on \xAB${wanted}\xBB here.` : "Nothing can make it here right now."} Ways and why: ${JSON.stringify(
|
|
61682
|
+
`${wanted ? `It cannot be made on \xAB${wanted}\xBB here.` : "Nothing can make it here right now."} Ways and why: ${JSON.stringify(all.map(way))}. get_engines says what this computer can run and what to install.`
|
|
61640
61683
|
);
|
|
61641
|
-
|
|
61642
|
-
const
|
|
61643
|
-
const
|
|
61644
|
-
const where = pick2.target === "local" ? T2.whereLocal(eta) : pick2.target === "boost" ? T2.whereBoost(eta) : T2.whereIgnix(eta);
|
|
61684
|
+
const credits = pick2.x.cost.unit === "none" ? null : creditsOf(pick2.v, pick2.x);
|
|
61685
|
+
const eta = etaText(pick2.x.estimateSeconds);
|
|
61686
|
+
const where = pick2.x.target === "local" ? T2.whereLocal(eta) : pick2.x.target === "boost" ? T2.whereBoost(eta) : T2.whereIgnix(eta);
|
|
61645
61687
|
return gate(
|
|
61646
61688
|
c,
|
|
61647
61689
|
{
|
|
61648
|
-
spend: pick2.target !== "local",
|
|
61690
|
+
spend: pick2.x.target !== "local",
|
|
61649
61691
|
visual: o.visual,
|
|
61650
61692
|
title: o.title,
|
|
61651
|
-
details: [where, ...o.details ?? []],
|
|
61693
|
+
details: [where, ...pick2.v.label ? [pick2.v.label] : [], ...o.details ?? []],
|
|
61652
61694
|
credits
|
|
61653
61695
|
},
|
|
61654
|
-
() => start3(pick2.target)
|
|
61696
|
+
() => start3(pick2.v, pick2.x.target)
|
|
61655
61697
|
);
|
|
61656
61698
|
}
|
|
61657
61699
|
async function start2(c, o) {
|
|
@@ -62179,10 +62221,14 @@ function createMcpService(deps) {
|
|
|
62179
62221
|
references: ref ? [ref.id] : []
|
|
62180
62222
|
};
|
|
62181
62223
|
const visual = ref ? [ref] : [];
|
|
62224
|
+
const R = (await rates(AbortSignal.timeout(1e4))).rates;
|
|
62225
|
+
const variants = [
|
|
62226
|
+
{ model: null, note: null, label: null, request: request2, boostCredits: R.image }
|
|
62227
|
+
];
|
|
62182
62228
|
return routed(
|
|
62183
62229
|
c,
|
|
62184
|
-
{
|
|
62185
|
-
async (target) => {
|
|
62230
|
+
{ variants, target: a.target, visual, title: T2.makeImage },
|
|
62231
|
+
async (_v, target) => {
|
|
62186
62232
|
const jobId = await deps.content.generate?.({
|
|
62187
62233
|
request: request2,
|
|
62188
62234
|
aspect,
|
|
@@ -62215,18 +62261,25 @@ function createMcpService(deps) {
|
|
|
62215
62261
|
...a.model ? { model: a.model } : {}
|
|
62216
62262
|
} : { kind: "video", prompt: a.prompt, aspect, durationSec: seconds, references: [] };
|
|
62217
62263
|
const visual = image ? [image] : [];
|
|
62218
|
-
|
|
62219
|
-
|
|
62220
|
-
|
|
62221
|
-
|
|
62222
|
-
|
|
62223
|
-
|
|
62224
|
-
|
|
62225
|
-
|
|
62226
|
-
|
|
62227
|
-
|
|
62228
|
-
|
|
62229
|
-
|
|
62264
|
+
const variants = [
|
|
62265
|
+
{ model: null, note: null, label: null, request: request2, boostCredits: boostCreditsFor(request2) }
|
|
62266
|
+
];
|
|
62267
|
+
return routed(
|
|
62268
|
+
c,
|
|
62269
|
+
{ variants, target: a.target, visual, title: T2.makeClip },
|
|
62270
|
+
async (_v, target) => {
|
|
62271
|
+
const jobId = await deps.content.generate?.({
|
|
62272
|
+
request: request2,
|
|
62273
|
+
aspect,
|
|
62274
|
+
referenceAssetId: image?.id ?? null,
|
|
62275
|
+
headline: a.prompt.slice(0, 80),
|
|
62276
|
+
preference: target
|
|
62277
|
+
});
|
|
62278
|
+
if (!jobId) return err("unavailable", "Video generation is not available here.");
|
|
62279
|
+
deps.chat.showJob(jobId, `${c.client.name}: a video clip \u2014 \u201C${a.prompt.slice(0, 120)}\u201D`);
|
|
62280
|
+
return ok2({ jobId, job: jobView(jobId) });
|
|
62281
|
+
}
|
|
62282
|
+
);
|
|
62230
62283
|
},
|
|
62231
62284
|
async make_presenter(a, c) {
|
|
62232
62285
|
const photo = asset(a.photoAssetId);
|
|
@@ -62234,35 +62287,47 @@ function createMcpService(deps) {
|
|
|
62234
62287
|
const voice = asset(a.audioAssetId);
|
|
62235
62288
|
if (voice?.kind !== "audio")
|
|
62236
62289
|
return err("not_found", "No such audio (import the voice line first).");
|
|
62237
|
-
|
|
62238
|
-
const max = h3 ? H3_PRESENTER_MAX_LINE_SEC : PRESENTER_MAX_LINE_SEC;
|
|
62239
|
-
if (voice.durationSec !== null && voice.durationSec > max)
|
|
62240
|
-
return err(
|
|
62241
|
-
"invalid_arguments",
|
|
62242
|
-
`One voice line per call, up to ${String(max)} s: split longer audio at its pauses (transcribe gives them) and make one presenter clip per line.`
|
|
62243
|
-
);
|
|
62244
|
-
if (h3 && !a.line)
|
|
62290
|
+
if (a.model === "minimax_h3" && !a.line)
|
|
62245
62291
|
return err(
|
|
62246
62292
|
"invalid_arguments",
|
|
62247
62293
|
"MiniMax H3 says the line itself: give `line`, the exact words of the audio."
|
|
62248
62294
|
);
|
|
62249
62295
|
const aspect = a.aspect ?? "9:16";
|
|
62250
62296
|
const scene = a.prompt ?? "A person talking to the camera like a UGC creator, natural head movement and expressions that follow the voice.";
|
|
62251
|
-
const
|
|
62252
|
-
|
|
62253
|
-
|
|
62254
|
-
|
|
62255
|
-
|
|
62256
|
-
|
|
62257
|
-
|
|
62258
|
-
|
|
62297
|
+
const sec2 = Math.ceil(voice.durationSec ?? PRESENTER_MAX_LINE_SEC);
|
|
62298
|
+
const R = (await rates(AbortSignal.timeout(1e4))).rates;
|
|
62299
|
+
const models = (a.model ? [a.model] : a.line ? ["wan", "minimax_h3"] : ["wan"]).filter(
|
|
62300
|
+
(m) => voice.durationSec === null || voice.durationSec <= (m === "minimax_h3" ? H3_PRESENTER_MAX_LINE_SEC : PRESENTER_MAX_LINE_SEC)
|
|
62301
|
+
);
|
|
62302
|
+
if (!models.length)
|
|
62303
|
+
return err(
|
|
62304
|
+
"invalid_arguments",
|
|
62305
|
+
`One voice line per call, up to ${String(a.model === "minimax_h3" ? H3_PRESENTER_MAX_LINE_SEC : PRESENTER_MAX_LINE_SEC)} s: split longer audio at its pauses (transcribe gives them) and make one presenter clip per line.`
|
|
62306
|
+
);
|
|
62307
|
+
const variants = models.map((m) => {
|
|
62308
|
+
const h3 = m === "minimax_h3";
|
|
62309
|
+
return {
|
|
62310
|
+
model: models.length > 1 || a.model ? m : null,
|
|
62311
|
+
note: h3 ? "MiniMax H3: says the line itself in a voice cloned from the voice line; livelier, but may add a word at the end." : "InfiniteTalk: lip-syncs the exact voice line.",
|
|
62312
|
+
label: h3 ? T2.modelH3 : T2.modelInfiniteTalk,
|
|
62313
|
+
request: {
|
|
62314
|
+
kind: "presenter",
|
|
62315
|
+
image: photo.id,
|
|
62316
|
+
audio: voice.id,
|
|
62317
|
+
prompt: h3 ? h3PresenterPrompt(scene, a.line ?? "", a.language ?? "en") : scene.slice(0, 900),
|
|
62318
|
+
aspect,
|
|
62319
|
+
...h3 ? { model: "minimax_h3" } : {}
|
|
62320
|
+
},
|
|
62321
|
+
boostCredits: (h3 ? R.boostH3Second : R.boostOutputSecond) * sec2
|
|
62322
|
+
};
|
|
62323
|
+
});
|
|
62259
62324
|
const visual = [photo];
|
|
62260
62325
|
return routed(
|
|
62261
62326
|
c,
|
|
62262
|
-
{
|
|
62263
|
-
async (target) => {
|
|
62327
|
+
{ variants, target: a.target, visual, title: T2.makePresenter },
|
|
62328
|
+
async (v, target) => {
|
|
62264
62329
|
const jobId = await deps.content.generate?.({
|
|
62265
|
-
request:
|
|
62330
|
+
request: v.request,
|
|
62266
62331
|
aspect,
|
|
62267
62332
|
referenceAssetId: photo.id,
|
|
62268
62333
|
headline: (a.line ?? scene).slice(0, 80),
|
|
@@ -62851,7 +62916,9 @@ async function start(init, port) {
|
|
|
62851
62916
|
});
|
|
62852
62917
|
const npmEditor = process.env.IGNIX_CREATOR_EDITOR_ROOT && process.env.IGNIX_CREATOR_EDITOR_VERSION ? {
|
|
62853
62918
|
root: process.env.IGNIX_CREATOR_EDITOR_ROOT,
|
|
62854
|
-
version: process.env.IGNIX_CREATOR_EDITOR_VERSION
|
|
62919
|
+
version: process.env.IGNIX_CREATOR_EDITOR_VERSION,
|
|
62920
|
+
// One set of Editor files per person: the ones their Ignix Editor already has.
|
|
62921
|
+
sharedDataDir: process.env.IGNIX_EDITOR_HOME || (0, import_node_path27.join)((0, import_node_os4.homedir)(), ".ignix-editor")
|
|
62855
62922
|
} : void 0;
|
|
62856
62923
|
const video = createVideoEngineService({
|
|
62857
62924
|
engine: localAiBackend.engine,
|
|
@@ -63185,7 +63252,7 @@ async function start(init, port) {
|
|
|
63185
63252
|
if (!editor.available()) return null;
|
|
63186
63253
|
const handle = await assets.resolve(asset.id);
|
|
63187
63254
|
if (!handle) return null;
|
|
63188
|
-
const dir = await (0, import_promises33.mkdtemp)((0, import_node_path27.join)((0,
|
|
63255
|
+
const dir = await (0, import_promises33.mkdtemp)((0, import_node_path27.join)((0, import_node_os5.tmpdir)(), "creator-voice-"));
|
|
63189
63256
|
try {
|
|
63190
63257
|
const out = (0, import_node_path27.join)(dir, "voice.wav");
|
|
63191
63258
|
await editor.call(
|
|
@@ -63248,6 +63315,12 @@ async function start(init, port) {
|
|
|
63248
63315
|
// The video provider, capped at what the card quoted (ADR-0022 O6, O7;
|
|
63249
63316
|
// text → video is MiniMax H3's, quoted only when Ignix enables it).
|
|
63250
63317
|
boostVideo.authorize(request2, { maxCredits: boostCreditsFor(request2) ?? 0 })
|
|
63318
|
+
) : request2.kind === "presenter" ? (
|
|
63319
|
+
// A presenter is also the video provider's (InfiniteTalk / H3). It
|
|
63320
|
+
// went to the IMAGE provider, which refused it: the job failed at
|
|
63321
|
+
// once (Fran, 2026-10-12). Its price comes from the voice line, known
|
|
63322
|
+
// when it runs, as in the studio (no cap here; the approval showed it).
|
|
63323
|
+
boostVideo.authorize(request2)
|
|
63251
63324
|
) : boost.authorize(request2) : false,
|
|
63252
63325
|
plan: async (aspect) => {
|
|
63253
63326
|
const t = await images.target();
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ignix-social/creator",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.4",
|
|
4
4
|
"description": "Ignix Creator: generation tools (presenters, photo → video, text → video, recast, dubbing) on this computer or Cloud Boost, driven by AI agents over MCP. Needs an active Ignix plan.",
|
|
5
5
|
"license": "UNLICENSED",
|
|
6
6
|
"type": "commonjs",
|