Nano Banana 2 Image Generation Master by aiagentwithdhruv/skills
npx skills add https://github.com/aiagentwithdhruv/skills --skill 'Nano Banana 2 Image Generation Master'本技能的用途是提供一个标准化、高度可控的方法,使用 AI 模型 Nano Banana 2(或任何连接到 generate_image 工具的底层模型)来生成图像。通过严格执行结构化的 JSON 参数模式,此技能可以中和原生模型的偏见(如过度平滑、数据集平均化或"塑料"AI 风格),并确保输出原始、未经修饰、超真实的图像。
.env 文件中设置为 FAL_KEY)— 在 https://fal.ai 注册(免费套餐,Nano Banana 2 模型).env 文件中设置为 EURI_API_KEY)— Euron 学生在 https://euron.one/euri 可免费获取为 generate_image 工具构建提示时,你必须使用以下 JSON 模式作为基础。用极其微观的细节填充字符串值。
广告位招租
在这里展示您的产品或服务
触达数万 AI 开发者,精准高效
{
"task": "string - 高级目标(例如,'sports_selfie_collage'、'single_macro_portrait')",
"output": {
"type": "string - 例如,'single_image'、'4-panel_collage'",
"layout": "string - 例如,'1x1'、'2x2_grid'、'side-by-side'",
"aspect_ratio": "string - 例如,'3:4'、'16:9'、'4:5'",
"resolution": "string - 例如,'ultra_high'、'medium_low'",
"camera_style": "string - 例如,'smartphone_front_camera'、'professional_dslr'"
},
"image_quality_simulation": {
"sharpness": "string - 例如,'tack_sharp'、'slightly_soft_edges'",
"noise": "string - 例如,'unfiltered_sensor_grain'、'visible_film_grain'、'clean_digital'",
"compression_artifacts": "boolean - 如果尝试模拟上传的用户生成内容,则为 true",
"dynamic_range": "string - 例如,'limited'、'hdr_capable'",
"white_balance": "string - 例如,'slightly_warm'、'cool_fluorescent'",
"lens_imperfections": [
"array of strings - 例如,'subtle chromatic aberration'、'minor lens distortion'、'vignetting'"
]
},
"subject": {
"type": "string - 例如,'human_portrait'、'nature_macro'、'infographic_flatlay'",
"human_details": {
"//": "仅对人类主体使用此块",
"identity": "string",
"appearance": "string - 极其具体(例如,visible pores, mild redness)",
"outfit": "string"
},
"object_or_nature_details": {
"//": "对非人类主体使用此块",
"material_or_texture": "string - 例如,'brushed aluminum'、'dew-covered velvety petals'",
"wear_and_tear": "string - 例如,'subtle scratches on the anodized finish'、'browning edges on leaves'",
"typography": "string - 例如,'clean sans-serif overlaid text, perfectly legible'"
}
},
"multi_panel_layout": {
"grid_panels": [
{
"panel": "string - 例如,'top_left'、'full_frame'(如果不是网格)",
"pose": "string - 例如,'slight upward selfie angle, relaxed smile'",
"action": "string - 例如,'holding phone with one hand, casual posture'"
}
]
},
"environment": {
"location": "string - 例如,'gym or outdoor sports area'",
"background": "string - 主体背后是什么(例如,'blurred gym equipment')",
"lighting": {
"type": "string - 例如,'natural or overhead gym lighting'、'harsh direct sunlight'",
"quality": "string - 例如,'uneven, realistic, non-studio'、'high-contrast dramatic'"
}
},
"embedded_text_and_overlays": {
"text": "string (optional)",
"location": "string (optional)"
},
"structural_preservation": {
"preservation_rules": [
"array of strings - 例如,'Exact physical proportions must be preserved'"
]
},
"controlnet": {
"pose_control": {
"model_type": "string - 例如,'DWPose'",
"purpose": "string",
"constraints": ["array of strings"],
"recommended_weight": "number"
},
"depth_control": {
"model_type": "string - 例如,'ZoeDepth'",
"purpose": "string",
"constraints": ["array of strings"],
"recommended_weight": "number"
}
},
"explicit_restrictions": {
"no_professional_retouching": "boolean - 通常为 true 以保证真实感",
"no_studio_lighting": "boolean - 通常为 true 以模拟抓拍效果",
"no_ai_beauty_filters": "boolean - 必须为 true 以避免塑料感",
"no_high_end_camera_look": "boolean - 如果模拟智能手机拍摄,则为 true"
},
"negative_prompt": {
"forbidden_elements": [
"array of strings - 实现极致真实感所需的大量'AI风格'阻断词列表。示例堆栈:'anatomy normalization'、'body proportion averaging'、'dataset-average anatomy'、'wide-angle distortion not in reference'、'lens compression not in reference'、'cropping that removes volume'、'depth flattening'、'mirror selfies'、'reflections'、'beautification filters'、'skin smoothing'、'plastic skin'、'airbrushed texture'、'stylized realism'、'editorial fashion proportions'、'more realistic reinterpretation'"
]
}
}
当执行对标准生成端点(通常只接受字符串提示)的 API 调用时,将上述逻辑压缩成一个包含大量描述性文本块的密集、扁平的 JSON 字符串是非常强大的。
{
"prompt": "string - 一段密集、超描述性的叙述。使用具体的相机参数(85mm lens, f/1.8, ISO 200)、明确的瑕疵(visible pores, mild redness, subtle freckles, light acne marks)、光照行为(direct on-camera flash creating sharp highlights)以及直接的否定命令(Do not beautify or alter facial features)。",
"negative_prompt": "string - 以逗号分隔的明确真实感阻断词列表(no plastic skin, no CGI)。",
"image_input": [
"array of strings (URLs) - 可选。用于转换或作为参考的输入图像(最多 14 张)。格式:指向 jpeg、png 或 webp 的 URL。最大大小:30MB。"
],
"api_parameters": {
"google_search": "boolean - 可选。使用 Google 网络搜索基础",
"resolution": "string - 可选。'1K'、'2K' 或 '4K'(默认 1K)",
"output_format": "string - 可选。'jpg' 或 'png'(默认 jpg)",
"aspect_ratio": "string - 可选。覆盖 CLI 的 aspect_ratio(例如,'16:9'、'4:5'、'auto')"
},
"settings": {
"resolution": "string",
"style": "string - 例如,'documentary realism'",
"lighting": "string - 例如,'direct on-camera flash'",
"camera_angle": "string",
"depth_of_field": "string - 例如,'shallow depth of field'",
"quality": "string - 例如,'high detail, unretouched skin'"
}
}
85mm lens, f/2.0, ISO 200)。这迫使模型模仿光学物理特性,而不是数字渲染。mild redness、subtle freckles、light acne marks、unguided grooming。Do not beautify or alter facial features. No makeup styling.direct flash photography, creating sharp highlights on skin and a slightly shadowed background.compression artifacts)有助于真实感,但在复杂、高对比度的环境(如霓虹灯夜晚街道)中过度使用 ISO 3200 或 heavy film grain 实际上会触发模型的"数字艺术/插图"偏见。将 ISO 设置保持在 800 以下,并依靠物理主体的瑕疵(如桃色绒毛或不对称的毛孔)来体现真实感,而不是依赖大量的相机噪点。如果你需要绝对完整的模式分解、参数选项或多面板网格的复杂 JSON 结构,请参考:master_prompt_reference.md(位于此技能文件夹中)
使用 fal.ai 的 Nano Banana 2 模型进行超真实感图像生成。
前提条件:
.env 文件必须包含 FAL_KEY="your_key"(在 https://fal.ai/dashboard/keys 获取)/prompts/ 目录下执行:
# 使用 Videos 工具包脚本(推荐)— 默认为 nano-banana-2
python Social-Media-Agent-1.0/Videos/scripts/generate_fal.py "<dense_prompt>" output.jpg --size portrait_4_3
# 或使用旧的 kie.ai 脚本(如果你仍有 KIE_API_KEY)
python scripts/generate_kie.py prompts/your_prompt.json images/output_image.jpg "4:5"
使用 Euri 的 Gemini 3 Pro Image Preview 模型。
python Social-Media-Agent-1.0/Videos/scripts/generate_euri.py "<dense_prompt>" output.jpg
环境变量: .env 文件中的 EURI_API_KEY | 免费额度:200K 令牌/天
当用户要求你生成高度详细、真实或复杂的图像时,你必须构建格式完全符合上述 JSON 模式的提示字符串。将该整个字符串作为提示参数传递给生成脚本(首选 fal.ai,Euri 作为备选)。
每周安装次数
0
代码仓库
GitHub 星标数
4
首次出现
1970年1月1日
安全审计
The purpose of this skill is to provide a standardized, highly controlled method for generating images using AI model Nano Banana 2 (or any underlying model connected to the generate_image tool). By strictly enforcing a structured JSON parameter schema, this skill neutralizes native model biases (like over-smoothing, dataset-averaging, or "plastic" AI styling) and ensures raw, unretouched, hyper-realistic outputs.
FAL_KEY in .env) — sign up at https://fal.ai (free tier, Nano Banana 2 model)EURI_API_KEY in .env) — free for Euron students at https://euron.one/euriWhen constructing a prompt for the generate_image tool, you MUST use the following JSON schema as the foundation. Fill in the string values with extreme, microscopic detail.
{
"task": "string - High-level goal (e.g., 'sports_selfie_collage', 'single_macro_portrait')",
"output": {
"type": "string - e.g., 'single_image', '4-panel_collage'",
"layout": "string - e.g., '1x1', '2x2_grid', 'side-by-side'",
"aspect_ratio": "string - e.g., '3:4', '16:9', '4:5'",
"resolution": "string - e.g., 'ultra_high', 'medium_low'",
"camera_style": "string - e.g., 'smartphone_front_camera', 'professional_dslr'"
},
"image_quality_simulation": {
"sharpness": "string - e.g., 'tack_sharp', 'slightly_soft_edges'",
"noise": "string - e.g., 'unfiltered_sensor_grain', 'visible_film_grain', 'clean_digital'",
"compression_artifacts": "boolean - true if attempting to simulate uploaded UGC",
"dynamic_range": "string - e.g., 'limited', 'hdr_capable'",
"white_balance": "string - e.g., 'slightly_warm', 'cool_fluorescent'",
"lens_imperfections": [
"array of strings - e.g., 'subtle chromatic aberration', 'minor lens distortion', 'vignetting'"
]
},
"subject": {
"type": "string - e.g., 'human_portrait', 'nature_macro', 'infographic_flatlay'",
"human_details": {
"//": "Use this block ONLY for human subjects",
"identity": "string",
"appearance": "string - Extremely specific (e.g., visible pores, mild redness)",
"outfit": "string"
},
"object_or_nature_details": {
"//": "Use this block for non-human subjects",
"material_or_texture": "string - e.g., 'brushed aluminum', 'dew-covered velvety petals'",
"wear_and_tear": "string - e.g., 'subtle scratches on the anodized finish', 'browning edges on leaves'",
"typography": "string - e.g., 'clean sans-serif overlaid text, perfectly legible'"
}
},
"multi_panel_layout": {
"grid_panels": [
{
"panel": "string - e.g., 'top_left', 'full_frame' (if not a grid)",
"pose": "string - e.g., 'slight upward selfie angle, relaxed smile'",
"action": "string - e.g., 'holding phone with one hand, casual posture'"
}
]
},
"environment": {
"location": "string - e.g., 'gym or outdoor sports area'",
"background": "string - What is behind the subject (e.g., 'blurred gym equipment')",
"lighting": {
"type": "string - e.g., 'natural or overhead gym lighting', 'harsh direct sunlight'",
"quality": "string - e.g., 'uneven, realistic, non-studio', 'high-contrast dramatic'"
}
},
"embedded_text_and_overlays": {
"text": "string (optional)",
"location": "string (optional)"
},
"structural_preservation": {
"preservation_rules": [
"array of strings - e.g., 'Exact physical proportions must be preserved'"
]
},
"controlnet": {
"pose_control": {
"model_type": "string - e.g., 'DWPose'",
"purpose": "string",
"constraints": ["array of strings"],
"recommended_weight": "number"
},
"depth_control": {
"model_type": "string - e.g., 'ZoeDepth'",
"purpose": "string",
"constraints": ["array of strings"],
"recommended_weight": "number"
}
},
"explicit_restrictions": {
"no_professional_retouching": "boolean - typically true for realism",
"no_studio_lighting": "boolean - typically true for candid shots",
"no_ai_beauty_filters": "boolean - mandatory true to avoid plastic look",
"no_high_end_camera_look": "boolean - true if simulating smartphones"
},
"negative_prompt": {
"forbidden_elements": [
"array of strings - Massive list of 'AI style' blockers required for extreme realism. Example stack: 'anatomy normalization', 'body proportion averaging', 'dataset-average anatomy', 'wide-angle distortion not in reference', 'lens compression not in reference', 'cropping that removes volume', 'depth flattening', 'mirror selfies', 'reflections', 'beautification filters', 'skin smoothing', 'plastic skin', 'airbrushed texture', 'stylized realism', 'editorial fashion proportions', 'more realistic reinterpretation'"
]
}
}
When executing API calls to standard generation endpoints (which often only accept string prompts), it is incredibly powerful to condense the logic above into a dense, flat JSON string containing a massive descriptive text block.
{
"prompt": "string - A dense, ultra-descriptive narrative. Use specific camera math (85mm lens, f/1.8, ISO 200), explicit flaws (visible pores, mild redness, subtle freckles, light acne marks), lighting behavior (direct on-camera flash creating sharp highlights), and direct negative commands (Do not beautify or alter facial features).",
"negative_prompt": "string - A comma-separated list of explicit realism blockers (no plastic skin, no CGI).",
"image_input": [
"array of strings (URLs) - Optional. Input images to transform or use as reference (up to 14). Formatting: URL to jpeg, png, or webp. Max size: 30MB."
],
"api_parameters": {
"google_search": "boolean - Optional. Use Google Web Search grounding",
"resolution": "string - Optional. '1K', '2K', or '4K' (default 1K)",
"output_format": "string - Optional. 'jpg' or 'png' (default jpg)",
"aspect_ratio": "string - Optional. Overrides CLI aspect_ratio (e.g., '16:9', '4:5', 'auto')"
},
"settings": {
"resolution": "string",
"style": "string - e.g., 'documentary realism'",
"lighting": "string - e.g., 'direct on-camera flash'",
"camera_angle": "string",
"depth_of_field": "string - e.g., 'shallow depth of field'",
"quality": "string - e.g., 'high detail, unretouched skin'"
}
}
85mm lens, f/2.0, ISO 200). This forces the model to mimic optical physics rather than digital rendering.mild redness, subtle freckles, light acne marks, unguided grooming.Do not beautify or alter facial features. No makeup styling.direct flash photography, creating sharp highlights on skin and a slightly shadowed background.If you require the absolute full schema breakdown, parameter options, or the complex JSON structing for multi-panel grids, refer to: master_prompt_reference.md (in this skill's folder)
Use fal.ai's Nano Banana 2 model for hyper-realistic image generation.
Prerequisites:
.env file must contain FAL_KEY="your_key" (get at https://fal.ai/dashboard/keys)/prompts/Execution:
# Using the Videos toolkit script (recommended) — defaults to nano-banana-2
python Social-Media-Agent-1.0/Videos/scripts/generate_fal.py "<dense_prompt>" output.jpg --size portrait_4_3
# Or using the legacy kie.ai script (if you still have KIE_API_KEY)
python scripts/generate_kie.py prompts/your_prompt.json images/output_image.jpg "4:5"
Use Euri's Gemini 3 Pro Image Preview model.
python Social-Media-Agent-1.0/Videos/scripts/generate_euri.py "<dense_prompt>" output.jpg
Env: EURI_API_KEY in .env | Free: 200K tokens/day
When a user asks you to generate a highly detailed, realistic, or complex image, you must construct the prompt string formatted EXACTLY like the JSON schema above. Pass that entire string as the prompt argument to the generation script (fal.ai preferred, Euri as fallback).
Weekly Installs
0
Repository
GitHub Stars
4
First Seen
Jan 1, 1970
Security Audits
AI Elements:基于shadcn/ui的AI原生应用组件库,快速构建对话界面
58,500 周安装
compression artifacts) can help realism, pushing extreme ISO 3200 or heavy film grain in complex, contrast-heavy environments (like neon night streets) actually triggers the model's "digital art/illustration" biases. Keep ISO settings below 800 and rely on physical subject imperfections (like peach fuzz or asymmetrical pores) rather than heavy camera noise to sell the realism.