You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
"imagePrompts": ["Infographic 2D architecture style, black background. [specific visual for this scene]. Highlighted elements filled with #15b27b. White lines connecting components and white text annotations."]
689
+
"imagePrompts": ["Infographic 2D architecture style. STRICTLY black (#000000) background only \u2014 no gradients, no blue. [specific visual for this scene]. Highlighted elements filled with vivid purple (#7c3aed) only. White lines connecting components and white text annotations. Large, readable labels."]
690
690
}
691
691
],
692
692
"cta": "string - call to action"
@@ -697,8 +697,9 @@ Return ONLY a JSON object:
697
697
Requirements:
698
698
- 3-5 scenes totaling 60-90 seconds
699
699
- Use at least 2 different scene types
700
-
- Each scene MUST include 2-5 imagePrompts following this exact template: "Infographic 2D architecture style, black background. [specific visual]. Highlighted elements filled with #15b27b. White lines connecting components and white text annotations."
700
+
- Each scene MUST include 2-5 imagePrompts following this exact template: "Infographic 2D architecture style. STRICTLY black (#000000) background only \u2014 no gradients, no blue. [specific visual]. Highlighted elements filled with vivid purple (#7c3aed) only. White lines connecting components and white text annotations. Large, readable labels."
701
701
- imagePrompts should describe specific 2D infographic visuals that illustrate the narration content
702
+
- The FIRST scene's imagePrompts must be purely visual and eye-catching — no text labels, no annotations, no words. This is the thumbnail/hook frame.
702
703
- Do NOT include any script text, titles, or word overlays in the video. The narration audio carries all words.
703
704
- Think of each imagePrompt as a frame that will be shown for 3-5 seconds while the narration plays
704
705
- Include REAL code snippets from the research where applicable
Copy file name to clipboardExpand all lines: app/api/cron/ingest/route.ts
+8-6Lines changed: 8 additions & 6 deletions
Original file line number
Diff line number
Diff line change
@@ -258,7 +258,7 @@ Your style is inspired by Cleo Abram's "Huge If True" — you make complex techn
258
258
- End with a clear takeaway that makes the viewer feel smarter
259
259
- Target audience: developers who want to stay current but don't have time to read everything
260
260
261
-
Script format: 60-90 second explainer videos. Think TikTok/YouTubeShorts energy with real educational depth.
261
+
Script format: 2-4 minute explainer videos for horizontal YouTube, 60-90 seconds for Shorts. Think Cleo Abram energy with real educational depth.
262
262
263
263
CodingCat.dev covers: React, Next.js, TypeScript, Svelte, web APIs, CSS, Node.js, cloud services, AI/ML for developers, and web platform updates.`;
264
264
@@ -311,7 +311,7 @@ function buildPrompt(trends: TrendResult[], research?: ResearchPayload): string
311
311
312
312
${topicList}${researchContext}
313
313
314
-
Pick the MOST interesting and timely topic for a short explainer video (60-90 seconds). Then generate a complete video script as JSON.
314
+
Pick the MOST interesting and timely topic for an explainer video (2-4 minutes for horizontal YouTube). Then generate a complete video script as JSON.
315
315
316
316
## Scene Types
317
317
@@ -337,7 +337,7 @@ CRITICAL: This video will be a visual infographic explainer. There will be NO te
337
337
338
338
For EACH scene, generate an "imagePrompts" array with 2-5 image generation prompts. Each prompt should follow this exact template:
339
339
340
-
"Infographic 2D architecture style, black background. [SPECIFIC VISUAL FOR THIS SCENE]. Highlighted elements filled with #15b27b. White lines connecting components and white text annotations."
340
+
"Infographic 2D architecture style, pure black background. [SPECIFIC VISUAL FOR THIS SCENE]. Highlighted elements filled with vivid purple (#7c3aed). White lines connecting components and white text annotations. Color palette: ONLY black, purple (#7c3aed), and white — no blue, no green, no gradients."
341
341
342
342
Replace [SPECIFIC VISUAL FOR THIS SCENE] with a detailed description of what the infographic should show for that particular scene. Be specific — reference the actual technical concepts, comparisons, or workflows being discussed.
343
343
@@ -349,6 +349,8 @@ Guidelines for image prompts:
349
349
- For comparison scenes: show side-by-side comparison charts or feature matrices
350
350
- For list scenes: show each item as a distinct visual element in the infographic
351
351
- Make prompts visually varied — don't repeat the same layout
352
+
- STRICT color palette: pure black background (#000000), vivid purple (#7c3aed) for highlighted elements, white for lines and text annotations. Do NOT use blue, green, orange, red, or gradient backgrounds
353
+
- FIRST SCENE image prompts must be purely visual and eye-catching — NO text labels, NO annotations, NO words. This is the thumbnail/hook frame that needs to stop the scroll. Show a striking visual metaphor for the topic
352
354
353
355
## JSON Schema
354
356
@@ -369,7 +371,7 @@ Return ONLY a JSON object matching this exact schema:
369
371
"visualDescription": "string - what to show on screen (fallback for all types)",
370
372
"bRollKeywords": ["keyword1", "keyword2"],
371
373
"durationEstimate": 15,
372
-
"imagePrompts": ["Infographic 2D architecture style, black background. [specific visual]. Highlighted elements filled with #15b27b. White lines connecting components and white text annotations."],
374
+
"imagePrompts": ["Infographic 2D architecture style, pure black background. [specific visual]. Highlighted elements filled with vivid purple (#7c3aed). White lines and text annotations. ONLY black, purple, white colors."],
373
375
"code": {
374
376
"snippet": "string - actual code to display (only for sceneType: code)",
@@ -398,14 +400,14 @@ Return ONLY a JSON object matching this exact schema:
398
400
}
399
401
400
402
Requirements:
401
-
- The script should have 3-5 scenes totaling 60-90 seconds
403
+
- The script should have 8-15 scenes totaling 2-4 minutes (120-240 seconds)
402
404
- The hook should be punchy and curiosity-driven
403
405
- Use at least 2 different scene types for visual variety
404
406
- Only include the type-specific field that matches the sceneType (e.g., only include "code" when sceneType is "code")
405
407
- For "code" scenes, provide real, syntactically correct code
406
408
- The qualityScore should be your honest self-assessment (0-100)
407
409
- Each scene MUST include an "imagePrompts" array with 2-5 image generation prompts
408
-
- Image prompts must follow the template: "Infographic 2D architecture style, black background. [specific]. Highlighted elements filled with #15b27b. White lines connecting components and white text annotations."
410
+
- Image prompts must follow the template: "Infographic 2D architecture style, pure black background. [specific]. Highlighted elements filled with vivid purple (#7c3aed). White lines connecting components and white text annotations. Color palette: ONLY black, purple (#7c3aed), and white."
409
411
- Do NOT include any text overlays, titles, or script words in the video — narration audio carries all words
410
412
- Calculate prompt count per scene: Math.ceil(durationEstimate / 4)
411
413
- Return ONLY the JSON object, no markdown or extra text`;
@@ -117,7 +189,6 @@ export async function generateInfographic(
117
189
}
118
190
119
191
constimageBytes=generated.image.imageBytes;
120
-
// imageBytes may be a Uint8Array or base64 string depending on SDK version
121
192
constimageBase64=
122
193
typeofimageBytes==="string"
123
194
? imageBytes
@@ -210,11 +281,11 @@ export function buildInfographicPrompt(
210
281
211
282
/** Default infographic instructions if Sanity contentConfig is not set up */
212
283
constDEFAULT_INSTRUCTIONS: string[]=[
213
-
'Infographic 2D architecture style, black background. A high-level technical architecture overview showing system components and data flow. Highlighted elements filled with #15b27b. White lines connecting components and white text annotations.',
214
-
'Infographic 2D architecture style, black background. A comparison chart showing key features and alternatives side by side. Highlighted elements filled with #15b27b. White lines connecting components and white text annotations.',
215
-
'Infographic 2D architecture style, black background. A step-by-step workflow diagram showing the process from start to finish. Highlighted elements filled with #15b27b. White lines connecting components and white text annotations.',
216
-
'Infographic 2D architecture style, black background. A timeline of key developments, milestones, and version releases. Highlighted elements filled with #15b27b. White lines connecting components and white text annotations.',
217
-
'Infographic 2D architecture style, black background. A pros and cons visual summary with clear icons and labels. Highlighted elements filled with #15b27b. White lines connecting components and white text annotations.',
284
+
'Infographic 2D architecture style. STRICTLY black (#000000) background only \u2014 no gradients, no blue. A high-level technical architecture overview showing system components and data flow. Highlighted elements filled with vivid purple (#7c3aed) only. White lines connecting components and white text annotations. Large, readable text labels suitable for mobile viewing at 360px width. No watermarks.',
285
+
'Infographic 2D architecture style. STRICTLY black (#000000) background only \u2014 no gradients, no blue. A comparison chart showing key features and alternatives side by side. Highlighted elements filled with vivid purple (#7c3aed) only. White lines connecting components and white text annotations. Large, readable text labels suitable for mobile viewing at 360px width. No watermarks.',
286
+
'Infographic 2D architecture style. STRICTLY black (#000000) background only \u2014 no gradients, no blue. A step-by-step workflow diagram showing the process from start to finish. Highlighted elements filled with vivid purple (#7c3aed) only. White lines connecting components and white text annotations. Large, readable text labels suitable for mobile viewing at 360px width. No watermarks.',
287
+
'Infographic 2D architecture style. STRICTLY black (#000000) background only \u2014 no gradients, no blue. A timeline of key developments, milestones, and version releases. Highlighted elements filled with vivid purple (#7c3aed) only. White lines connecting components and white text annotations. Large, readable text labels suitable for mobile viewing at 360px width. No watermarks.',
288
+
'Infographic 2D architecture style. STRICTLY black (#000000) background only \u2014 no gradients, no blue. A pros and cons visual summary with clear icons and labels. Highlighted elements filled with vivid purple (#7c3aed) only. White lines connecting components and white text annotations. Large, readable text labels suitable for mobile viewing at 360px width. No watermarks.',
0 commit comments