veogent 1.0.4 β 1.0.8
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/index.js +94 -4
- package/package.json +1 -1
package/index.js
CHANGED
|
@@ -176,6 +176,19 @@ program
|
|
|
176
176
|
} catch (error) {}
|
|
177
177
|
});
|
|
178
178
|
|
|
179
|
+
program
|
|
180
|
+
.command('recent-chapters')
|
|
181
|
+
.description('Get recently created or updated chapters')
|
|
182
|
+
.option('-l, --limit <limit>', 'Maximum number of recent chapters to return', '10')
|
|
183
|
+
.action(async (options) => {
|
|
184
|
+
try {
|
|
185
|
+
const data = await api.get(`/app/chapter/recent-chapters?limit=${options.limit}`);
|
|
186
|
+
console.log(JSON.stringify(data.data || data, null, 2));
|
|
187
|
+
} catch (error) {
|
|
188
|
+
console.log(JSON.stringify({ status: "error", message: error.message }));
|
|
189
|
+
}
|
|
190
|
+
});
|
|
191
|
+
|
|
179
192
|
program
|
|
180
193
|
.command('create-chapter-content')
|
|
181
194
|
.description('Generate content for a specific chapter')
|
|
@@ -231,6 +244,18 @@ program
|
|
|
231
244
|
console.log(JSON.stringify({ status: "error", message: error.response?.data?.message || error.message }));
|
|
232
245
|
}
|
|
233
246
|
});
|
|
247
|
+
program
|
|
248
|
+
.command('scenes <projectId> <chapterId>')
|
|
249
|
+
.description('Get all scenes for a specific chapter')
|
|
250
|
+
.action(async (projectId, chapterId) => {
|
|
251
|
+
try {
|
|
252
|
+
const data = await api.get(`/app/scenes/${projectId}/${chapterId}`);
|
|
253
|
+
console.log(JSON.stringify(data.data || data, null, 2));
|
|
254
|
+
} catch (error) {
|
|
255
|
+
console.log(JSON.stringify({ status: "error", message: error.message }));
|
|
256
|
+
}
|
|
257
|
+
});
|
|
258
|
+
|
|
234
259
|
program
|
|
235
260
|
.command('create-scene')
|
|
236
261
|
.description('Create a new scene from text content')
|
|
@@ -349,6 +374,59 @@ program
|
|
|
349
374
|
}
|
|
350
375
|
});
|
|
351
376
|
|
|
377
|
+
// --- YouTube Metadata & Thumbnails ---
|
|
378
|
+
program
|
|
379
|
+
.command('generate-yt-metadata')
|
|
380
|
+
.description('Generate YouTube metadata (Title, Description, Tags) for a chapter')
|
|
381
|
+
.requiredOption('-p, --project <project>', 'Project ID')
|
|
382
|
+
.requiredOption('-c, --chapter <chapter>', 'Chapter ID')
|
|
383
|
+
.requiredOption('-l, --lang <lang>', 'Story language')
|
|
384
|
+
.action(async (options) => {
|
|
385
|
+
try {
|
|
386
|
+
const payload = {
|
|
387
|
+
projectId: options.project,
|
|
388
|
+
chapterId: options.chapter,
|
|
389
|
+
storyLanguage: options.lang
|
|
390
|
+
};
|
|
391
|
+
const data = await api.post('/app/youtube/metadata/generate', payload);
|
|
392
|
+
console.log(JSON.stringify({ status: "success", metadata: data.data || data }, null, 2));
|
|
393
|
+
} catch (error) {
|
|
394
|
+
console.log(JSON.stringify({ status: "error", message: error.response?.data?.message || error.message }));
|
|
395
|
+
}
|
|
396
|
+
});
|
|
397
|
+
|
|
398
|
+
program
|
|
399
|
+
.command('generate-yt-thumbnail')
|
|
400
|
+
.description('Triggers a request to generate a YouTube thumbnail for a chapter')
|
|
401
|
+
.requiredOption('-p, --project <project>', 'Project ID')
|
|
402
|
+
.requiredOption('-c, --chapter <chapter>', 'Chapter ID')
|
|
403
|
+
.requiredOption('-l, --lang <lang>', 'Story language')
|
|
404
|
+
.action(async (options) => {
|
|
405
|
+
try {
|
|
406
|
+
const payload = {
|
|
407
|
+
projectId: options.project,
|
|
408
|
+
chapterId: options.chapter,
|
|
409
|
+
storyLanguage: options.lang
|
|
410
|
+
};
|
|
411
|
+
const data = await api.post('/app/youtube/thumbnails/generate', payload);
|
|
412
|
+
console.log(JSON.stringify({ status: "success", request: data.data || data }, null, 2));
|
|
413
|
+
} catch (error) {
|
|
414
|
+
console.log(JSON.stringify({ status: "error", message: error.response?.data?.message || error.message }));
|
|
415
|
+
}
|
|
416
|
+
});
|
|
417
|
+
|
|
418
|
+
program
|
|
419
|
+
.command('yt-thumbnails <projectId> <chapterId>')
|
|
420
|
+
.description('Get generated YouTube thumbnails for a chapter')
|
|
421
|
+
.action(async (projectId, chapterId) => {
|
|
422
|
+
try {
|
|
423
|
+
const data = await api.get(`/app/youtube/projects/${projectId}/chapters/${chapterId}/thumbnails`);
|
|
424
|
+
console.log(JSON.stringify(data.data || data, null, 2));
|
|
425
|
+
} catch (error) {
|
|
426
|
+
console.log(JSON.stringify({ status: "error", message: error.message }));
|
|
427
|
+
}
|
|
428
|
+
});
|
|
429
|
+
|
|
352
430
|
// --- System ---
|
|
353
431
|
program
|
|
354
432
|
.command('skill')
|
|
@@ -374,6 +452,8 @@ Agents **CANNOT** authenticate automatically because \`veogent login\` opens a l
|
|
|
374
452
|
|
|
375
453
|
## π Chapters & Scenes
|
|
376
454
|
* **List Chapters for a Project:** \`veogent chapters <projectId>\`
|
|
455
|
+
* **List Recent Chapters globally:** \`veogent recent-chapters -l 5\`
|
|
456
|
+
* **List Scenes for a Chapter:** \`veogent scenes <projectId> <chapterId>\`
|
|
377
457
|
* **Create Chapter Content:** \`veogent create-chapter-content -p <projectId> -c <chapterId> -s 5\` (Generates text/story content for 5 scenes)
|
|
378
458
|
* **Create Scene:** \`veogent create-scene -p <projectId> -c <chapterId> -C <sceneId1> <sceneId2>\`
|
|
379
459
|
|
|
@@ -425,10 +505,20 @@ If a generated image prompt needs adjustment by the AI, use \`veogent edit-scene
|
|
|
425
505
|
|
|
426
506
|
* **List All Generation Requests/Jobs Status:** \`veogent requests\`
|
|
427
507
|
|
|
428
|
-
## π‘ Best Practices for AI Agents
|
|
429
|
-
1. **
|
|
430
|
-
2. **
|
|
431
|
-
3.
|
|
508
|
+
## π‘ Best Practices for AI Agents (The VEOGENT Pipeline)
|
|
509
|
+
1. **Step 1: Description First.** Run \`veogent create-project-description\` to flesh out the lore, then use that payload for \`veogent create-project\`.
|
|
510
|
+
2. **Step 2: Chapter & Scene Content.** Run \`veogent create-chapter-content\` to ask the AI for a scene breakdown array. IMMEDIATELY supply that script array to \`veogent create-scene\` (use \`--flowkey\` so Firebase syncs it up).
|
|
511
|
+
3. **Step 3: Await Casting (CRITICAL).** The system will auto-generate characters. Do NOT rush to generate scenes. Use \`veogent characters <projectId>\` repeatedly (polling) until you observe EVERY character object contains an \`imageUri\`.
|
|
512
|
+
*(Alternatively, query \`veogent project <projectId>\` and check the \`"progress"\` object. It tracks the status of character generations. If a character hits FAILED, PROCESSING, or PENDING do not spam requests. Wait).*
|
|
513
|
+
4. **Step 4: Generate Images.** Start requesting \`GENERATE_IMAGES\` for the individual scenes in your desired orientation.
|
|
514
|
+
*(Anti-Spam Check: Use \`veogent assets <projId> <chapId> <sceneId> <type>\` to check history. IF there is an existing job with \`"status": "PROCESSING"\` or \`"PENDING"\`, YOU MUST WAIT. Do NOT fire another request).*
|
|
515
|
+
*(Concurrency Limit: The system only allows a maximum of 5 running/processing generation requests at a time globally. If the API responds with a "maximum reached" error, do NOT treat it as a task failure. Simply WAIT and poll until older requests complete).*
|
|
516
|
+
5. **Step 5: Art Directing & QA.** Download/view the generated image/video. If itβs glitched, bad quality, or misaligned with the script: STOP. Use \`veogent edit-scene\` to inject camera angles (Tilt, Wide, Close-up) and text adjustments to fix the prompt, then regenerate it.
|
|
517
|
+
6. **Step 6: Animate.** Once the frame is director-approved, proceed to \`GENERATE_VIDEO\`.
|
|
518
|
+
*(CRITICAL RULE: Do NOT generate a video for a scene unless that scene ALREADY has a successfully generated Image in the matching orientation. Ex: To generate a VERTICAL video, a VERTICAL image must exist first).*
|
|
519
|
+
7. **Step 7: YouTube Publishing Assets.** Wrap up the movie by generating metadata (Title, Description, Tags) using \`veogent generate-yt-metadata\` and triggering a thumbnail request via \`veogent generate-yt-thumbnail\`. To retrieve the final Thumbnail image, call \`veogent yt-thumbnails <proj> <chap>\`.
|
|
520
|
+
|
|
521
|
+
**Error Handling:** The CLI returns JSON like \`{"status": "error", "message": "..."}\`. Check this before proceeding with the next logic block. If an API request returns \`400 Bad Request\`, review your flags.`;
|
|
432
522
|
console.log(skillContent);
|
|
433
523
|
});
|
|
434
524
|
|