惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

K
Kaspersky official blog
G
Google Developers Blog
Apple Machine Learning Research
Apple Machine Learning Research
V
Visual Studio Blog
WordPress大学
WordPress大学
博客园 - Franky
雷峰网
雷峰网
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
博客园 - 【当耐特】
人人都是产品经理
人人都是产品经理
月光博客
月光博客
V
V2EX
freeCodeCamp Programming Tutorials: Python, JavaScript, Git & More
IT之家
IT之家
小众软件
小众软件
Cloudbric
Cloudbric
量子位
N
News and Events Feed by Topic
Vercel News
Vercel News
Security Archives - TechRepublic
Security Archives - TechRepublic
www.infosecurity-magazine.com
www.infosecurity-magazine.com
C
Check Point Blog
The Cloudflare Blog
Hugging Face - Blog
Hugging Face - Blog
T
Tenable Blog
S
Secure Thoughts
Know Your Adversary
Know Your Adversary
C
CXSECURITY Database RSS Feed - CXSecurity.com
C
Cyber Attacks, Cyber Crime and Cyber Security
Stack Overflow Blog
Stack Overflow Blog
Help Net Security
Help Net Security
L
LINUX DO - 最新话题
Google DeepMind News
Google DeepMind News
云风的 BLOG
云风的 BLOG
OSCHINA 社区最新新闻
OSCHINA 社区最新新闻
cs.AI updates on arXiv.org
cs.AI updates on arXiv.org
N
News | PayPal Newsroom
PCI Perspectives
PCI Perspectives
T
Troy Hunt's Blog
GbyAI
GbyAI
Attack and Defense Labs
Attack and Defense Labs
C
Cybersecurity and Infrastructure Security Agency CISA
Y
Y Combinator Blog
美团技术团队
爱范儿
爱范儿
Martin Fowler
Martin Fowler
Last Week in AI
Last Week in AI
P
Privacy International News Feed
T
The Blog of Author Tim Ferriss
F
Full Disclosure

人人都是产品经理

为什么你的产品找不到差异化?90%的失败都卡在第一步上(下) – 人人都是产品经理, 3年从30万到1300万用户、获2200万美元融资,这个AI教育产品用“抽卡”破解了获客难题 – 人人都是产品经理, 园区招商系统怎么做才能真正帮到去化?我加了这一个功能,推广链接转发400次阅读过万 – 人人都是产品经理, AI大事件:OpenAI发完网络安全模型又搞药物研发,小鹏汽车要抓”DeepSeek时刻” – 人人都是产品经理, 电商不是卖货,是一场更残酷的产品经理实战 – 人人都是产品经理, 没想到,活动营销又回来了! – 人人都是产品经理, 为何All-in海外KOC:一场关于AI时代窗口期的豪赌 – 人人都是产品经理, 重新理解企业的内部协作 – 人人都是产品经理, 苹果的 AI 战略到底是什么? – 人人都是产品经理, 医疗智能体·第2讲——合规护城河:等保、PIPL与HIPAA的架构实战 – 人人都是产品经理, 向量知识库五步法:从“答非所问”到“精准回复” – 人人都是产品经理, 鸿蒙PC三方库构建总指挥HPKBUILD(sha)库为例 – 人人都是产品经理, 何时该用LLM?AI产品经理的LLM设计指南 – 人人都是产品经理, 医疗信息领域的需求方、决策方、准入方以及关注点(二) – 人人都是产品经理, 即梦涨价:一场被误读的「傲慢」 – 人人都是产品经理, 面试AI PM必答题:Hermes和OpenClaw的区别,如何讲清楚业务价值 – 人人都是产品经理, AI的下一张船票:世界模型——AI产品经理必须理解的技术拐点 – 人人都是产品经理, 小红书做GEO,怎么让AI信你?记住这 3 个重要信息 – 人人都是产品经理, 5 家印度 AI 初创公司,看看印度 AI 再做什么 – 人人都是产品经理, AI项目跨团队协作:产品技术业务如何不打架 – 人人都是产品经理, Agentic Workflow(智能体工作流):让AI从”答案生成器”变成”数字员工” – 人人都是产品经理, lycium_plusplus 项目全景解读:OpenHarmony 三方库构建的“大管家” – 人人都是产品经理, 从爆单救火到前置履约:两套预采策略,把生鲜大促履约效率拉满 – 人人都是产品经理, 什么时候该补货?我用一轮数据做了一个决定 – 人人都是产品经理, 从“机械兜底”到“动态分流”:AI客服重复进线治理的4大底层逻辑 – 人人都是产品经理, 抖音拼效率,红书拼洞察 – 人人都是产品经理, 全民狂欢与退潮——为什么龙虾这波热潮冷却得如此之快? – 人人都是产品经理, Stripe押注!MPP重塑全球支付 – 人人都是产品经理, 小红书GEO:AI引用你的内容,不是因为你对,而是因为你看起来可信 – 人人都是产品经理, 前百度副总裁押注办公Agent,日韩付费爆发,Manus迎来强劲对手 – 人人都是产品经理, 企事业单位数字化的业务供需本质 – 人人都是产品经理, 医疗智能体·第1讲——医疗信息化重构:从“辅助软件”到“自主智能体”的范式转移 – 人人都是产品经理, 粉丝量就是空气!!! – 人人都是产品经理, 用户说“薯片碎了”,机器回“要买吗?”:意图识别的翻车与破局 – 人人都是产品经理, RAG召回准确率从75到90 我做对了这三件事 – 人人都是产品经理, AI大事件:Anthropic改收费、OpenAI发安全版、手术机器人纳入医保、阿里发布”秒悟” – 人人都是产品经理, Chrome 推出 Skills 新功能,Agent 重塑上网方式 – 人人都是产品经理, GitHub前创始人拿了a16z的1700万美元,做Agent时代的Git – 人人都是产品经理 拷贝或克隆其他 Flutter OH 项目到本地后无法运行 – 人人都是产品经理, 优惠券设计:优惠券创建 – 人人都是产品经理, 不用死磕文档!AI 助手 1 小时搞定飞书 CLI 安装 + 配置 + 知识库 – 人人都是产品经理, 用小龙虾做竞品分析报告:从2天到20分钟,我是怎么做到的 – 人人都是产品经理 用小龙虾做市场分析报告:搞懂这3个公式,市场规模不再靠猜 – 人人都是产品经理, 你早就在做 Harness 工程,只是不知道它叫这个名字 – 人人都是产品经理, Think Long就够?你可能想多了! – 人人都是产品经理, 货代SRM实战:供应商准入怎么做,才能让资源池不是通讯录而是可交付网络? – 人人都是产品经理, 如何做好用户调研?详解基本技巧 – 人人都是产品经理, 木鸟、途家、美团对打,平台春天行动开“卷” – 人人都是产品经理, 入职才发现公司不靠谱?小红书从业者求职避坑指南 – 人人都是产品经理, 美国 AI 三巨头联手封堵,中国 AI 突围之路在何方 – 人人都是产品经理, 小红书,放在需求对面的镜子 – 人人都是产品经理, AI 会带来大规模失业吗? – 人人都是产品经理, 从出单到补货前,我第一次犹豫:该不该放大? – 人人都是产品经理, Flutter 三方库鸿蒙化适配:5 种高效检查方式,快速判断是否需要适配 – 人人都是产品经理, 从做产品进阶拿结果:医美机构产品经理转岗科室运营经理 – 人人都是产品经理, 阿里HappyHorse,一场关于“Token经济”的阳谋 – 人人都是产品经理, To B AI:客户留存落地的观察与思考 – 人人都是产品经理, AI产品的“生命线”——数据采集、标注、清洗的产品化设计 – 人人都是产品经理, 谈谈AI Agent(二):当“孩子”能自己“体验世界”时,你该学什么? – 人人都是产品经理, UI/UX设计师的3层能力进阶,前两层让你活下来,第三层…才是真正的分水岭 – 人人都是产品经理, 2分钟 → 30秒,效率提升75%:B端产品经理如何用「规则枷锁」驯服AI幻觉? – 人人都是产品经理, 还没来得及学OpenClaw,来了个更猛的:Hermes Agent – 人人都是产品经理, AI日报:宇树机器人跑出10m/s刷新世界纪录 – 人人都是产品经理, 一文说透基金互金如何用情绪价值引导用户决策做转化 – 人人都是产品经理, 当浏览器开始替你”看”网页:AI 浏览器正在亲手拆掉它脚下的那张网 – 人人都是产品经理, 0代码,一天时间我Vibe Coding了个网站 – 人人都是产品经理, Hermes 和 OpenClaw 之争,Agent 的能力应该“装上去”还是“长出来”? – 人人都是产品经理 视频生成的“桌子”,字节Seedance 2掀完,阿里快乐马掀 – 人人都是产品经理, 从听不懂到完全信任:我的 Codex 深度产品体验 – 人人都是产品经理, 当虚拟偶像有了北京户口,与真人偶像还有什么区别? – 人人都是产品经理, 会说,远远比会做更重要 —— 对 SBTI 爆火现象的五层观察 – 人人都是产品经理, AI产品经理必看:当“搭环境”比“选模型”更重要,你的认知还在2024年吗? – 人人都是产品经理, 2026年AI产品商业化核心逻辑:从功能demo到规模化营收的3个必破卡点 – 人人都是产品经理, 京东围绕供应链,卷起裤腿下场的那些事儿 – 人人都是产品经理, SBTI一夜刷屏:它赢在了“太会说人话” – 人人都是产品经理, 折扣零售的真相:不是便宜,而是价值感! – 人人都是产品经理, 和甲方吵了一架,最后加钱做了——我学到的ToB产品经理生存法则 – 人人都是产品经理, 和几位小红书操盘手聊了8小时,干货全在这 – 人人都是产品经理, 智谱GLM-5.1登场,开源模型首超Opus4.6!!! – 人人都是产品经理 Anthropic收入凭什么反超OpenAI,终于有人把这事说清楚了 – 人人都是产品经理, 史上最有故事感的技术报告——Claude最强模型Mythos 7个极其精彩的细节 – 人人都是产品经理, 模型不是壁垒,Harness 也不是 – 人人都是产品经理, 抖音本地生活业务思考21 – 人人都是产品经理, Superpowers:145k Star的AI编码框架,到底是什么来头? Superpowers:145k Star的AI编码框架,到底是什么来头? – 人人都是产品经理, OpenAI 的路走错了,Anthropic Harness 解法启示:模型需要实践专科生 – 人人都是产品经理, 画原型图的前一步:设计站点地图 – 人人都是产品经理, 给 DeepSeek 的最后一封催更信 – 人人都是产品经理, 手把手教你用 Claude Code 搭建 AI 营销团队:5 个 Agent、12 项技能,独立完成研究、写作、设计全流程 – 人人都是产品经理, 你以为大模型在学语言?不,它在重新发明语言学 – 人人都是产品经理 所谓Skill,不过是AI时代的工业垃圾 – 人人都是产品经理, 聊一聊内容传播的几个方法 – 人人都是产品经理, 当平台开始吃掉生态:从 OpenClaw 被封杀,读懂 Anthropic 的这盘棋 – 人人都是产品经理, 你装了 10 个 AI 插件,Obsidian 还是一个文件夹 – 人人都是产品经理 关于AI智能体架构演进的系统性思考:从单体试水到多体协同的重构 – 人人都是产品经理, 当“人”变成Skill,我们又该何去何从? – 人人都是产品经理 Mythos 事件:前沿 AI 治理的意外实验 – 人人都是产品经理, 货代CRM:信用与风险管理怎么做,才能把坏账风险拦在放货之前? – 人人都是产品经理, 从HR收集自拍照到员工自助录入——我见证了园区人脸识别从”不可用”到”真好用”的全过程 – 人人都是产品经理 千问闯关AI混沌期:阿里画靶,吴嘉张弓,马云射箭? – 人人都是产品经理,
谷歌nano banana官方最强Prompt模板来了!先收藏再说
新智元 · 2025-09-03 · via 人人都是产品经理

nano banana爆火!网上看到的那些超强效果图是如何生成的呢?谷歌的官方Prompt模板终于来了!赶紧先收藏再说!

这几天爆火的nano banana,让更多人体验到AI对图像生成与处理的革命。

网友们玩疯了,开发出各类好玩的用法。

有用nano banana直接将照片生成手办模型的:

有人脑洞大开,让nano banana、Seedance、Kling联手,将梵高和蒙娜丽莎、戴珍珠耳环的少女等名画的人物,同时带到了今天的纽约中央公园里,开启了一段浪漫的邂逅。

还有人使用nano banana反过来带我们穿越回了中土世界。

视频以第一人称视角在马车上疾驰,穿越迥异的区域,充满了3A游戏大作般的史诗感。

看到网上流传的nano banana生成的以假乱真、脑洞大开的图片和视频,不知道你是否也开始尝试使用nano banana了呢?

同样是生成图片,有人一句话就出大片,有人写满满一屏幕词也不对版。

谷歌为了帮助大家快速上手,亲自下场为我们带来了nano banana官方最强Prompt模板!

甭管你暂时是否理解为什么这样写,先收藏起来试着套模板就对了!

其中的关键是,你要像讲故事一样写场景。

基于nano banana(Gemini 2.5 Flash Image),这6套Prompt模板覆盖了写实、贴纸、文字、产品、留白与分镜,直接套用就能高质量生图!

写实摄影

写实感强的照片,是离不开摄影师的精心巧思的。

要生成写实感强的图像,你得像摄影师一样思考。

你需要考虑机位、镜头类型、光线、细节。

将这些元素加入Prompt后,会引导模型朝更逼真的效果靠近。

即使你不是专业摄影师,只要按照自己的理解多尝试,也大概率会比未说明这些关键要素而直接生成的图片的效果要好。

示例模板:

A photorealistic [shot type] of [subject], [action or expression], set in [environment]. The scene is illuminated by [lighting description], creating a [mood] atmosphere. Captured with a [camera/lens details], emphasizing [key textures and details]. The image should be in a [aspect ratio] format.

模板大意:

一张写实风格的[镜头类型],[主体],[动作或表情],场景设定在[环境]。画面由[光线描述]照明,营造出[情绪]氛围。使用[相机/镜头参数]拍摄,突出[关键材质与细节]。图像应为[纵横比]格式。

示例Prompt:

A photorealistic close-up portrait of an elderly Japanese ceramicist with deep, sun-etched wrinkles and a warm, knowing smile. He is carefully inspecting a freshly glazed tea bowl. The setting is his rustic, sun-drenched workshop. The scene is illuminated by soft, golden hour light streaming through a window, highlighting the fine texture of the clay. Captured with an 85mm portrait lens, resulting in a soft, blurred background (bokeh). The overall mood is serene and masterful. Vertical portrait orientation.

Prompt大意:

一张写实风格的特写人像:一位日本老陶艺家,脸上被岁月与阳光刻下的深深皱纹,露出温暖而睿智的微笑。他正仔细端详一个刚上釉的茶碗。场景位于他质朴、阳光充足的工作室。柔和的黄金时刻光线自窗外倾泻而入,凸显陶土的细腻纹理。使用85mm人像镜头拍摄,带来柔和的背景虚化(bokeh)。整体氛围宁静而老练。竖版人像构图。

生成的图片:

一张写实风格的日本老陶艺家特写人像

调用API生图示例Python代码:

from google import genai
from google.genai import types
from PIL import Image
from io import BytesIO
client = genai.Client()
# Generate an image from a text prompt
response = client.models.generate_content(
    model=”gemini-2.5-flash-image-preview”,
    contents=”A photorealistic close-up portrait of an elderly Japanese ceramicist with deep, sun-etched wrinkles and a warm, knowing smile. He is carefully inspecting a freshly glazed tea bowl. The setting is his rustic, sun-drenched workshop with pottery wheels and shelves of clay pots in the background. The scene is illuminated by soft, golden hour light streaming through a window, highlighting the fine texture of the clay and the fabric of his apron. Captured with an 85mm portrait lens, resulting in a soft, blurred background (bokeh). The overall mood is serene and masterful.”,
)
image_parts = [
    part.inline_data.data
    for part in response.candidates[0].content.parts
    if part.inline_data
]
if image_parts:
    image = Image.open(BytesIO(image_parts[0]))
    image.save(‘photorealistic_example.png’)
    image.show()

注意,上述代码需要你在第11行的contents中输入Prompt,在第22行的image.save()中输入你要保存时取的文件名。

后续其他调用API生图的代码仅需要修改这两处即可

插图与贴纸

在生成贴纸、图标、插图、项目素材这类图片时,你需要先把风格说清楚。

如果有其他特殊需求,比如需要白底的话,你得明确在Prompt中写出。

示例模板:

A [style] sticker of a [subject], featuring [key characteristics] and a [color palette]. The design should have [line style] and [shading style]. The background must be white.

模板大意:

一张[风格]的[主体]贴纸,具有[关键特征],采用[配色]。设计应当使用[线条风格]与[明暗/上色风格]。背景必须为白色。

示例Prompt:

A kawaii-style sticker of a happy red panda wearing a tiny bamboo hat. It’s munching on a green bamboo leaf. The design features bold, clean outlines, simple cel-shading, and a vibrant color palette. The background must be white.

Prompt大意:

一张可爱风(kawaii)贴纸:一只开心的小熊猫戴着迷你竹叶帽,正咀嚼一片绿色竹叶。设计使用粗壮、干净的描边,简单的赛璐璐上色,配色鲜艳。背景必须为白色。

生成的图片:

一张可爱风(kawaii)的小熊猫贴纸

调用API生图示例Python代码:

from google import genai
from google.genai import types
from PIL import Image
from io import BytesIO
client = genai.Client()
# Generate an image from a text prompt
response = client.models.generate_content(
    model=”gemini-2.5-flash-image-preview”,
    contents=”A kawaii-style sticker of a happy red panda wearing a tiny bamboo hat. It’s munching on a green bamboo leaf. The design features bold, clean outlines, simple cel-shading, and a vibrant color palette. The background must be white.”,
)
image_parts =[
    part.inline_data.data
    for part in response.candidates[0].content.parts
    if part.inline_data]if image_parts:
    image = Image.open(BytesIO(image_parts[0])) 
   image.save(‘red_panda_sticker.png’)
    image.show()

文本渲染

nano banana在文本渲染这项任务上的表现是格外瞩目的。

你只需要把文字内容、字体风格(用描述性的词描述)、整体设计说明白,就可以产出质量很好的图片了。

示例模板:

Create a [image type] for [brand/concept] with the text “[text to render]” in a [font style]. The design should be [style description], with a [color scheme].

模板大意:

为[品牌/概念]创建一张[图像类型],其中包含文本「[要渲染的文本]」,使用[字体风格]。设计应为[风格描述],并采用[配色方案]。

示例Prompt:

Create a modern, minimalist logo for a coffee shop called ‘The Daily Grind’. The text should be in a clean, bold, sans-serif font. The design should feature a simple, stylized icon of a coffee bean seamlessly integrated with the text. The color scheme is black and white.

Prompt大意:

为一家名为「The Daily Grind」的咖啡店设计一个现代、极简的Logo。文字使用干净、粗体的无衬线字体。设计带有一个简洁、风格化的咖啡豆图标,并与文字无缝融合。配色为黑白。

生成的图片:

为一家名为「The Daily Grind」的咖啡店生成的现代极简风Logo

调用API生图示例Python代码:

from google import genai
from google.genai import types
from PIL import Imagefrom io import BytesIO
client = genai.Client()
# Generate an image from a text prompt
response = client.models.generate_content(
    model=”gemini-2.5-flash-image-preview”,
    contents=”Create a modern, minimalist logo for a coffee shop called ‘The Daily Grind’. The text should be in a clean, bold, sans-serif font. The design should feature a simple, stylized icon of a a coffee bean seamlessly integrated with the text. The color scheme is black and white.”,
)
image_parts = [
    part.inline_data.data
    for part in response.candidates[0].content.parts
    if part.inline_data
]
if image_parts:
    image = Image.open(BytesIO(image_parts[0]))
    image.save(‘logo_example.png’)
    image.show()

商业摄影

为品牌打广告时,打造一个干净、专业的产品照通常是一个比较不错的选择。

商业感=干净背景+可控布光+展示卖点的机位。

示例模板:

A high-resolution, studio-lit product photograph of a [product description] on a [background surface/description]. The lighting is a [lighting setup, e.g., three-point softbox setup] to [lighting purpose]. The camera angle is a [angle type] to showcase [specific feature]. Ultra-realistic, with sharp focus on [key detail]. [Aspect ratio].

模板大意:

一张高分辨率、影棚布光的[产品描述]产品照,置于[背景表面/描述]上。灯光为[布光设置,如三点柔光箱布光],用于[照明目的]。机位为[角度类型],以展示[特定卖点]。超写实,对[关键细节]进行锐利对焦。[纵横比]。

示例Prompt:

A high-resolution, studio-lit product photograph of a minimalist ceramic coffee mug in matte black, presented on a polished concrete surface. The lighting is a three-point softbox setup designed to create soft, diffused highlights and eliminate harsh shadows. The camera angle is a slightly elevated 45-degree shot to showcase its clean lines. Ultra-realistic, with sharp focus on the steam rising from the coffee. Square image.

Prompt大意:

一张高分辨率、影棚布光的产品照:一只极简风的消光黑陶瓷咖啡杯,摆放在抛光的混凝土表面上。灯光为三点柔光箱布光,营造柔和的高光并消除硬阴影。机位为略抬高的 45 度角,凸显其干净的线条。超写实,对咖啡升起的蒸汽进行锐利对焦。方形图像。

生成的图片:

一张高分辨率、影棚布光的极简黑色陶瓷咖啡杯产品照

调用API生图示例Python代码:

from google import genai
from google.genai import types
from PIL import Image
from io import BytesIO
client = genai.Client()
# Generate an image from a text prompt
response = client.models.generate_content(
    model=”gemini-2.5-flash-image-preview”,
    contents=”A high-resolution, studio-lit product photograph of a minimalist ceramic coffee mug in matte black, presented on a polished concrete surface. The lighting is a three-point softbox setup designed to create soft, diffused highlights and eliminate harsh shadows. The camera angle is a slightly elevated 45-degree shot to showcase its clean lines. Ultra-realistic, with sharp focus on the steam rising from the coffee. Square image.”,
)
image_parts = [
    part.inline_data.data
    for part in response.candidates[0].content.parts
    if part.inline_data
]
if image_parts:
    image = Image.open(BytesIO(image_parts[0]))
    image.save(‘product_mockup.png’)
    image.show()

极简主义与留白设计

极简主义留白设计,非常适合为网站、演示或营销素材创建背景,方便后面再在图片上叠加文字。

示例模板:

A minimalist composition featuring a single [subject] positioned in the [bottom-right/top-left/etc.] of the frame. The background is a vast, empty [color] canvas, creating significant negative space. Soft, subtle lighting. [Aspect ratio].

模板大意:

一幅极简构图,画面中只有一个[主体],位于画面[右下角/左上角等]。背景是一整片空旷的[颜色]纯色画布,创造显著留白。柔和、克制的光线。[纵横比]。

示例Prompt:

A minimalist composition featuring a single, delicate red maple leaf positioned in the bottom-right of the frame. The background is a vast, empty off-white canvas, creating significant negative space for text. Soft, diffused lighting from the top left. Square image.

Prompt大意:

一幅极简构图:一片精致的红色枫叶位于画面右下角。背景是一整片空旷的米白色纯色画布,为文字留出大量留白。来自左上方的柔和、漫射光。方形图像。

生成的图片:

一幅极简构图:一片精致的红色枫叶

调用API生图示例Python代码:

from google import genai
from google.genai import types
from PIL import Imagefrom io import BytesIO
client = genai.Client()
# Generate an image from a text prompt
response = client.models.generate_content(
    model=”gemini-2.5-flash-image-preview”,
    contents=”A minimalist composition featuring a single, delicate red maple leaf positioned in the bottom-right of the frame. The background is a vast, empty off-white canvas, creating significant negative space for text. Soft, diffused lighting from the top left. Square image.”,
)
image_parts = [
    part.inline_data.data
    for part in response.candidates[0].content.parts
    if part.inline_data
]
if image_parts:
    image = Image.open(BytesIO(image_parts[0]))
    image.save(‘minimalist_design.png’)
    image.show()

漫画

你可以通过聚焦清晰的场景描述,一格一格地创作吸引人的视觉叙事。

这种方式非常适合做漫画、故事板等图片。

示例模板:

A single comic book panel in a [art style] style. In the foreground, [character description and action]. In the background, [setting details]. The panel has a [dialogue/caption box] with the text “[Text]”. The lighting creates a [mood] mood. [Aspect ratio].

模板大意:

一格[艺术风格]的漫画分镜。前景中,[人物描述与动作]。背景中,[环境细节]。画面包含一个[对白/旁白框],内容为「[文本]」。用光营造[情绪]氛围。[纵横比]。

示例Prompt:

A single comic book panel in a gritty, noir art style with high-contrast black and white inks. In the foreground, a detective in a trench coat stands under a flickering streetlamp, rain soaking his shoulders. In the background, the neon sign of a desolate bar reflects in a puddle. A caption box at the top reads “The city was a tough place to keep secrets.” The lighting is harsh, creating a dramatic, somber mood. Landscape.

Prompt大意:

一格粗粝的黑色电影风漫画,高反差黑白墨线。前景中,一位穿风衣的侦探站在闪烁的路灯下,雨水打湿了他的双肩。背景中,一家荒凉酒吧的霓虹招牌倒映在水坑里。顶部的旁白框写着:「在这座城市,想守住秘密并不容易。」用光强硬,营造戏剧而沉郁的氛围。横向画幅。

生成的图片:

一格粗粝的黑色电影风漫画分镜

调用API生图示例Python代码:

from google import genai
from google.genai import types
from PIL import Imagefrom io import BytesIO
client = genai.Client()
# Generate an image from a text prompt
response = client.models.generate_content(
    model=”gemini-2.5-flash-image-preview”,
    contents=”A single comic book panel in a gritty, noir art style with high-contrast black and white inks. In the foreground, a detective in a trench coat stands under a flickering streetlamp, rain soaking his shoulders. In the background, the neon sign of a desolate bar reflects in a puddle. A caption box at the top reads “The city was a tough place to keep secrets.” The lighting is harsh, creating a dramatic, somber mood. Landscape.”,
)
image_parts = [
    part.inline_data.data
    for part in response.candidates[0].content.parts
    if part.inline_data
]
if image_parts:
    image = Image.open(BytesIO(image_parts[0]))
    image.save(‘comic_panel.png’)
    image.show()

有了以上谷歌官方的强大模板,人人都可以自己创造出高质量图片了!

先收藏再说,有空了快去亲自试试吧!

参考资料:

https://x.com/googleaistudio/status/1962957615262224511

新智元报道 编辑:艾伦

本文由人人都是产品经理作者【新智元】,微信公众号:【新智元】,原创/授权 发布于人人都是产品经理,未经许可,禁止转载。

题图来自Unsplash,基于 CC0 协议。