LeoYeAI/agent-master-skills / skills/ai-image-prompts
ai-image-prompts-skill
VerifiedRecommend curated prompts from a 10,000+ real-world image generation prompt library. Works with ANY AI image model — Nano Banana Pro, Nano Banana 2, Seedream 5.0, GPT Image 1.5, Midjourney, DALL-E 3, Flux, Stable Diffusion, and more. Use this skill when users want to: - Find proven image generation prompts (any model) - Get prompt inspiration for portraits, products, social media, posters, etc. - Create illustrations for articles, videos, podcasts, or marketing content - Browse categorized prompt templates with sample images - Translate and understand prompt techniques
| File | Kind | Size |
|---|---|---|
| README.md | markdown | 5.3 KB |
| SKILL.md | skill md | 17.1 KB |
| _meta.json | config | 815 B |
| package.json | manifest | 1.5 KB |
| scripts/setup.js | script | 4.1 KB |
scripts/setup.js
View on GitHub#!/usr/bin/env node
/**
* setup.js - Downloads/updates AI Image Prompts library from GitHub
*
* Fully dynamic: reads manifest.json first to discover all categories.
* New/renamed/removed categories are handled automatically — no hardcoding.
*
* Usage:
* node scripts/setup.js # Download missing files only
* node scripts/setup.js --force # Force re-download all (get latest)
* node scripts/setup.js --check # Auto-update if stale (> 24h)
*/
import { existsSync, mkdirSync, statSync, writeFileSync, readFileSync, readdirSync, unlinkSync } from 'fs';
import { join, dirname } from 'path';
import { fileURLToPath } from 'url';
const __dirname = dirname(fileURLToPath(import.meta.url));
const refsDir = join(__dirname, '..', 'references');
const stampFile = join(refsDir, '.last-updated');
const BASE_URL = 'https://raw.githubusercontent.com/YouMind-OpenLab/ai-image-prompts-skill/main/references';
const STALE_HOURS = 24;
function isStale() {
if (!existsSync(stampFile)) return true;
const ts = parseInt(readFileSync(stampFile, 'utf8').trim(), 10);
return (Date.now() - ts) / 1000 / 3600 > STALE_HOURS;
}
async function fetchText(url) {
const res = await fetch(url);
if (!res.ok) throw new Error(`HTTP ${res.status} — ${url}`);
return res.text();
}
async function setup() {
const args = process.argv.slice(2);
const forceMode = args.includes('--force');
const checkMode = args.includes('--check');
if (checkMode && !isStale()) {
// Silent no-op when fresh
return;
}
if (!existsSync(refsDir)) mkdirSync(refsDir, { recursive: true });
const label = forceMode ? 'Updating' : 'Downloading';
console.log(`[setup] ${label} AI Image Prompts library from GitHub...`);
// Step 1: Fetch manifest — discover categories dynamically
let categories;
try {
const manifestText = await fetchText(`${BASE_URL}/manifest.json`);
const manifest = JSON.parse(manifestText);
categories = manifest.categories; // [{ slug, title, file, count }]
// Save manifest locally
writeFileSync(join(refsDir, 'manifest.json'), manifestText, 'utf8');
console.log(` manifest: ${categories.length} categories, ${manifest.totalPrompts} prompts total`);
} catch (err) {
console.warn(`[setup] Could not fetch manifest: ${err.message}`);
console.warn('[setup] Falling back to existing local manifest...');
const localManifest = join(refsDir, 'manifest.json');
if (!existsSync(localManifest)) {
console.error('[setup] No manifest available. Run with --force to retry.');
process.exit(0);
}
categories = JSON.parse(readFileSync(localManifest, 'utf8')).categories;
}
// Step 2: Clean up stale files not in current manifest
const validFiles = new Set([...categories.map(c => c.file), 'manifest.json', '.last-updated', '.gitkeep']);
if (forceMode && existsSync(refsDir)) {
for (const f of readdirSync(refsDir)) {
if (!validFiles.has(f)) {
unlinkSync(join(refsDir, f));
console.log(` removed stale: ${f}`);
}
}
}
// Step 3: Download each category file
let downloaded = 0, skipped = 0, failed = 0;
for (const cat of categories) {
const dest = join(refsDir, cat.file);
if (!forceMode && existsSync(dest) && statSync(dest).size > 100) {
skipped++;
continue;
}
process.stdout.write(` → ${cat.file} (${cat.title}, ${cat.count} prompts) ... `);
try {
const text = await fetchText(`${BASE_URL}/${cat.file}`);
writeFileSync(dest, text, 'utf8');
console.log('✓');
downloaded++;
} catch (err) {
console.log(`✗ (${err.message})`);
failed++;
}
}
// Step 4: Write timestamp
if (failed === 0) writeFileSync(stampFile, String(Date.now()), 'utf8');
if (downloaded > 0) {
console.log(`[setup] Done! ${downloaded} file(s) ${forceMode ? 'updated' : 'downloaded'}. Skill is ready.`);
} else if (skipped === categories.length) {
console.log('[setup] All references up to date. Use --force to refresh.');
}
if (failed > 0) console.warn(`[setup] ${failed} file(s) failed. Run again to retry.`);
}
setup().catch(err => {
console.warn('[setup] Warning (non-fatal):', err.message);
process.exit(0);
});
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| reverse-engineer-anythingmorluto/reaReverse engineer native, managed, Electron/JavaScript, packaged, firmware, and browser targets with REA, and build agent environments (AgentEnv bundles) of web applications from a live instance or a capture, and of Linux desktop apps with a task from a request. Use shipped-artifact or requested runtime evidence to explain features, compare versions, decompile code, or guide a reconstruction. Skip REA for ordinary source-repository architecture analysis. | Stars: 472k | Updated | Claude CodeCodex | Verified | Install |
| diagnosing-superpowersobra/superpowersUse when a superpowers session went wrong and your human partner wants to know why — repeated work, ignored plans, stumbles, poor results, a skill that didn't fire, "it took too long", "why is it so expensive", "what is it doing" — or wants to build a bug report for the superpowers maintainers, for the current session or a past one identified by id or path, on any harness. | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| dispatching-parallel-agentsobra/superpowersUse when facing 2+ independent tasks that can be worked on without shared state or sequential dependencies | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| executing-plansobra/superpowersUse when executing an implementation plan in the current session as the implementer yourself — your human partner chose inline execution, or no subagent tool is available | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |