5 ms·
I...worked on the detailed Nano Banana prompt engineering analysis for months (https://news.ycombinator.com/item?id=45917875 https://news.ycombinator.com/item?i
by minimaxir 1y ago
I...worked on the detailed Nano Banana prompt engineering analysis for months (https://news.ycombinator.com/item?id=45917875 https://news.ycombinator.com/item?id=45917875)...and...Google just...Google released a new version.
Nano Banana Pro should work with my gemimg package (https://github.com/minimaxir/gemimg https://github.com/minimaxir/gemimg) without pushing a new version by passing:
g = GemImg(model="gemini-3-pro-image-preview")
I'll add the new output resolutions and other features ASAP. However, looking at the pricing (https://ai.google.dev/gemini-api/docs/pricing#standard_1 https://ai.google.dev/gemini-api/docs/pricing#standard_1), I'm definitely not changing the default model to Pro as $0.13 per 1k/2k output will make it a tougher sell.
EDIT: Something interesting in the docs: https://ai.google.dev/gemini-api/docs/image-generation#thinking-process https://ai.google.dev/gemini-api/docs/image-generation#think...
> The model generates up to two interim images to test composition and logic. The last image within Thinking is also the final rendered image.
Maybe that's partially why the cost is higher: it's hard to tell if intermediate images are billed in addition to the output. However, this could cause an issue with the base gemimg and have it return an intermediate image instead of the final image depending on how the output is constructed, so will need to double-check.
- sandGorgon 1y agothis is pretty cool! have you found success with image editing in nano banana - i mean photoshop-like stuff. from your article i seem to wonder if nano banana is good for editing versus generating new images.
- vunderba 1y agoThat IS the use-case for Nano Banana (as opposed to pure generative like Imagen4). In my benchmarks, Nano-Banana scores a 7 out of 12. Seedream4 managed to outpace it, but Seedream can also introduce slight tone mapping variations. NB is the gold standard for highly localized edits. Comparisons of Seedream4, NanoBanana, gpt-image-1, etc. https://genai-showdown.specr.net/image-editing https://genai-showdown.specr.net/image-editing
- simonw 1y agoI tried your "Remove all the brown pieces of candy from the glass bowl." prompt against Nano Banana Pro and it converted them to green, which I think is a pass by your criteria. Original Nano Banana had failed that test because it changed the composition of the M&Ms. https://static.simonwillison.net/static/2025/brown-mms-removed.jpg https://static.simonwillison.net/static/2025/brown-mms-remov...
- vunderba 1y agoThanks Simon - I'm in the middle of re-running all my prompts through NB Pro at the moment. Nice to know it's already edged out the original. It also passed the SHRDLU test (swapping colored blocks) without cheating and just changing the colors. I'll have an update to the site shortly! EDIT: Finished the comparisons. NB Pro scored a few more points than NB which was already super impressive. https://genai-showdown.specr.net/image-editing?models=nb,nbp https://genai-showdown.specr.net/image-editing?models=nb,nbp
- oblio 1y agoIt looks nice, what are people using the package for?
- swyx 1y agobtw you should get on their Trusted Testers program, they do give early heads up GDM folks, get Max on!
- spyspy 1y agoThis reminds me of the journalist working for months on uncovering Trump's dirty business just for Trump himself to admit the entire thing in a tweet.
- wahnfrieden 1y agoIt's written to mimic that style but without meaning that the work has been done for them, just that there is new work to be done, making it an odd perhaps unconscious reference
- visioninmyblood 1y agoyes they are pricey but the price will go down over time and then you can switch. vlm.run got access as early customers and are releasing it for free with unlimited generations(till they are bottlenecked by google). some results here combining image gen(Nano Banana pro) with video gen(Veo 3.1) in a single chat https://chat.vlm.run/c/1c726fab-04ef-47cc-923d-cb3b005d6262 https://chat.vlm.run/c/1c726fab-04ef-47cc-923d-cb3b005d6262. This combined the synth generation of a person and made the puppet dance. Quite impressive
- ashraymalhotra 1y agoMinor clarification, the cost for every input image is $0.0011, not $0.06.
- Taek 1y agoI would consider that a major clarification
- minimaxir 1y agoI was going off the footnote of "Image input is set at 560 tokens or $0.067 per image" but 560 * 2 / 1_000_000 is indeed $0.0011 so I have no idea where the $0.067 came from. Fixed, and this is why I typically don't read docs without coffee.
- deleted 1y ago[deleted]
- simonw 1y agoIn case anyone missed Max's Nano Banana prompting guide, it's absolutely the definitive manual for prompting the original Nano Banana... and I tried some of the prompts in there against Nano Banana Pro and found it to be very applicable to the new model as well. https://minimaxir.com/2025/11/nano-banana-prompts/#hello-nano-banana https://minimaxir.com/2025/11/nano-banana-prompts/#hello-nan... My recreations of those pancake batter skulls using Nano Banana Pro: https://simonwillison.net/2025/Nov/20/nano-banana-pro/#trying-out-some-detailed-instruction-image-prompts https://simonwillison.net/2025/Nov/20/nano-banana-pro/#tryin...
- doctorpangloss 1y ago> it's absolutely the definitive manual How do you know Simon? It's certainly a blog post, with content about prompting in it. If your goal is to make generative art that uses specific IP, I wouldn't use it.
- simonw 1y agoDo you know of a better document specifically about prompting Nano Banana?
- doctorpangloss 1y agoWhy don't you just ask Gemini? It will tell you! There's no mystery.
- vunderba 1y ago> The model generates up to two interim images to test composition and logic. The last image within Thinking is also the final rendered image. I've been using a bespoke Generative Model -> VLM Validator -> LLM Prompt Modifier REPL as part of my benchmarks for a while now so I'd be curious to see how this stacks up. From some preliminary testing (9 pointed star, 5 leaf clover, etc) - NB Pro seems slightly better than NB though it still seems to get them wrong. It's hard to tell what's happening under the covers.
- skeeter2020 1y ago>> - Put a strawberry in the left eye socket. >>- Put a blackberry in the right eye socket. >> All five of the edits are implemented correctly This is a GREAT example of the (not so) subtle mistakes AI will make in image generation, or code creation, or your future knee surgery. The model placed the specified items in the eye sockets based on the viewers left/right; when we talk relative in this scenario we usually (always?) mean from the perspective of the target or "owner". Doctors make this mistake too (they typically mark the correct side with a sharpie while the patient is still alert) but I'd be more concerned if we're "outsourcing" decision making without adequate oversight. https://minimaxir.com/2025/11/nano-banana-prompts/#hello-nano-banana https://minimaxir.com/2025/11/nano-banana-prompts/#hello-nan...
- 0x457 1y agoRight, that's why one should use "put a strawberry in the portside eye socket" and "put a strawberry in the starboard side socket"
- iammattmurphy 1y agoWhen it doubt, always use nautical terminology
- Jabrov 1y agoI don't know if that's so much a mistake as it is ambiguity though? To me, using the viewer's perspective in this case seems totally reasonable. Does it still use the viewer's perspective if the prompt specifies "Put a strawberry in the _patient's left eye_"? If it does, then you're onto something. Otherwise I completely disagree with this.
- ComputerGuru 1y ago“Eye on the left” is different from “the left eye”. First can be ambiguous, second really isn’t.
- 1y ago
- Terretta 1y agoYour wrapper is awesome and still relevant. > "I...worked on the detailed Nano Banana prompt engineering analysis for months" Early in four decades of tech innovation I wasted time layering on fixes for clear deficiencies in a snowballing trend's tech offerings. If it's a big enough trend to have well funded competitors, just wait. The concern is likely not unique, and will likely be solved tomorrow. I realized it's better to learn adaptive/defensive techniques, giving your product resilience to change. Your goal is that when surfing the change waves you can pick a point you like between rock solid and cutting edge and surf there safely. Invest that "remediate their thing" time in "change resilience" instead – pays dividends from then on. It can be argued your tool is in this camp! // Getting better at this also helps you with zero days.
- minimaxir 1y agoI just pushed gemimg 0.3.2 which adds image_size support for Nano Banana Pro, and I ran a few tests on some of the images in the blog. In my testing, Nano Banana Pro correctly handled most of the image generation errors noted in my blog post: https://x.com/minimaxir/status/1991580127587921971 https://x.com/minimaxir/status/1991580127587921971 - Fibonacci magnets: code is correctly indented and the syntax highlighting atleast tries giving variables, numbers, and keywords different colors. - Make me a Studio Ghibli: actually does style transfer correctly, and does it better than ChatGPT ever did. - Rendering a webpage from HTML: near-perfect recreation of the HTML, including text layout and element sizing. That said, there may be regressions where even with prompt engineering, the generated images which are more photorealistic look too good and land back into the uncanny valley. I haven't decided if I'm going to write a follow up blog post yet. The system prompt hacking trick doesn't work with Nano Banana Pro unfortunately.
- simonw 1y agoThat result for rendering HTML to an image (the Counter Info one) is pretty impressive. https://github.com/minimaxir/gemimg/blob/main/docs/files/counter_app.html https://github.com/minimaxir/gemimg/blob/main/docs/files/cou... to this: https://x.com/minimaxir/status/1991580127587921971 https://x.com/minimaxir/status/1991580127587921971 - see also https://minimaxir.com/2025/11/nano-banana-prompts/#image-prompting-like-an-engineer https://minimaxir.com/2025/11/nano-banana-prompts/#image-pro...