Live data from Hacker News

Improved Gemini 2.5 Flash and Flash-Lite

developers.googleblog.com

261–270 of 285 posts

Re: Improved Gemini 2.5 Flash and Flash-Lite

#261
post #260
post #178

Earlier quoted context omitted.

It's possible, but honestly I've never seen a decent vector illustration of a pelican on a bicycle myself so they'd have to work pretty hard to find one!

They could just ask a designer to do a few bespoke illustrations, then generate synthetic data from that, right? Have an image model generate a set of variations, then convert them to SVG. But looking at these images, Google clearly hasn’t done that yet.

Yeah, the dedicated image generators can produce really good pelicans riding bicycles now, and you could trace one of those into a vector SVG as training data.

I don't think it would be worth it though, it would be pretty obvious you had cheated on my benchmark when it drew a perfect pelican riding a bicycle and then failed at a flamingo on a unicycle.

Re: Improved Gemini 2.5 Flash and Flash-Lite

#262

Earlier quoted context omitted.

They're all a little dumb. I asked claude for a python function or functions that will take in markdown in a string and return a string with ansi codes for bold, italics and underline. It gave me a 160 line parse function. After gaping for a short while, I implemented it in a 5 line function and a lookup table. These vibe codes who are proud that they generated thousands of lines of code makes me wonder if they are e…

I just asked Gemini Flash to do this. I included the instruction to use regular expressions to do the conversion to ANSI. It gave me a reasonable Python function which boils down to calling `re.sub()` for each of bold, italic and underline. For italics: text = re.sub(r'(\*|_)(.+?)\1', replace_italic, text, flags=re.DOTALL) The `replace_italic` is a one line callback function surrounding the re's match with the ANSI c…

I asked Gemini 2.5 Flash to just write me a function to do it, and it used regex.

In a separate chat, I asked it to suggest some ways to do it first, and it provided three alternatives, but suggested I started with regex.

FWIW I used Open WebUI, which uses the API (via OpenRouter). I've seen people here mentioning that the API produces much better results than the chat app, for whatever reason.

For reference, here's prompt and the zero-shot result, minus the rigorous comments it added:

I need a Python function that will take in markdown in a string and return a string with ansi codes for bold, italics and underline. Can you write me such a function?

  import re
  
  def markdown_to_ansi(markdown_string: str) -> str:
      ansi_string = markdown_string

      ANSI_BOLD = "\033[1m"
      ANSI_ITALIC = "\033[3m"
      ANSI_UNDERLINE = "\033[4m"
      ANSI_RESET = "\033[0m"
  
      ansi_string = re.sub(r'\*\*(.*?)\*\*', f'{ANSI_BOLD}\\1{ANSI_RESET}', ansi_string)
      ansi_string = re.sub(r'__(.*?)__', f'{ANSI_BOLD}\\1{ANSI_RESET}', ansi_string)
  
      ansi_string = re.sub(r'\*(.*?)\*', f'{ANSI_ITALIC}\\1{ANSI_RESET}', ansi_string)
      ansi_string = re.sub(r'\_(.*?)\_', f'{ANSI_ITALIC}\\1{ANSI_RESET}', ansi_string)
  
      ansi_string = re.sub(r'\+\+(.*?)\+\+', f'{ANSI_UNDERLINE}\\1{ANSI_RESET}', ansi_string)
  
      # A more robust solution for nesting would require a parsing library or a more complex state machine.
      # However, for simple cases, applying in order can layer them correctly.
  
      return ansi_string

Re: Improved Gemini 2.5 Flash and Flash-Lite

#263
post #195

Earlier quoted context omitted.

Another issue: Gemini can’t do tool calling and (forced) json output at the same time If you want to use application/json as the specified output in the request, you can’t use tools So if you need both, you either hope it gives you correct json when using tools (which many times it doesn’t). Or you have to do two requests, one for the tool calling, another for formatting At least, even if annoying, this issue is pret…

Back before structured outputs were common among model providers, I used to have a “end result” tool the model could call to get the structured response I was looking for. It worked very reliably. It’s a bit of a hack but maybe that reliably works here?

You can definitely build an agent and have it use tools like you mention. That’s the equivalent of making 2 requests to Gemini, one to get the initial answer/content, then another to get it formatted as proper json

The issue here is that Gemini has support for some internal tools (like search and web scraping), and when you ask the model to use those, you can’t also ask it to use application/json as the output (which you normally can when not using tools)

Not a huge issue, just annoying

Re: Improved Gemini 2.5 Flash and Flash-Lite

#265
post #5

Gemini 2.5 Flash is an impressive model for its price. However, I don't understand why Gemini 2.0 Flash is still popular. From OpenRouter last week: * xAI: Grok Code Fast 1: 1.15T * Anthropic: Claude Sonnet 4: 586B * Google: Gemini 2.5 Flash: 325B * Sonoma Sky Alpha: 227B * Google: Gemini 2.0 Flash: 187B * DeepSeek: DeepSeek V3.1 (free): 180B * xAI: Grok 4 Fast (free): 158B * OpenAI: GPT-4.1 Mini: 157B * DeepSeek: De…

2.0 Flash is significantly cheaper than 2.5 Flash, and is/was better than 2.5-Flash-Lite before this latest update. It's a great workhorse model for basic text parsing/summary/image understanding etc. Though looks like 2.5-Flash-Lite will make it redundant.

Re: Improved Gemini 2.5 Flash and Flash-Lite

#266
post #263

Earlier quoted context omitted.

Back before structured outputs were common among model providers, I used to have a “end result” tool the model could call to get the structured response I was looking for. It worked very reliably. It’s a bit of a hack but maybe that reliably works here?

You can definitely build an agent and have it use tools like you mention. That’s the equivalent of making 2 requests to Gemini, one to get the initial answer/content, then another to get it formatted as proper json The issue here is that Gemini has support for some internal tools (like search and web scraping), and when you ask the model to use those, you can’t also ask it to use application/json as the output (which…

I think this might be also something to do with their super specific outputting requirements when you do use search (has to be displayed in predefined Google format).

Re: Improved Gemini 2.5 Flash and Flash-Lite

#267

This really captures something I've been experiencing with Gemini lately. The models are genuinely capable when they work properly, but there's this persistent truncation issue that makes them unreliable in practice. I've been running into it consistently, responses that just stop mid-sentence, not because of token limits or content filters, but what appears to be a bug in how the model signals completion. It's been…

Yes agree, it was totally broken when I tested the API two months ago. Lots of failed to connect and very slow response time. Hoping the update fixes these issues.

It's been a lot better lately. Nothing like two months ago at all.

Re: Improved Gemini 2.5 Flash and Flash-Lite

#268
post #42

Earlier quoted context omitted.

Can't agree with that. Gemini doesn't lead just on price/performance - ironically it's the best "normie" model most of the time, despite it's lack of popularity with them until very recent. It's bad at agentic stuff, especially coding. Incomparably so compared to Claude and now GPT-5. But if it's just about asking it random stuff, and especially going on for very long in the same conversation - which non-tech users h…

My pet theory without any strong foundation is because OpenAI and Anthropic have trained their models really hard to fit the sycophantic mold of: =============================== Got it — *compliment on the info you've shared*, *informal summary of task*. *Another compliment*, but *downside of question*. ---------- (relevant emoji) Bla bla bla 1. Aspect 1 2. Aspect 2 ---------- *Actual answer* ----------- (checkmark e…

I've experienced the opposite. Gemini is actually the MOST sycophantic model.

Additionally, despite having "grounding with google search" it tends to default to old knowledge. I usually have to inform it that it's presently 2025. Even after searching and confirming, it'll respond with something along the lines of "in this hypothetical timeline" as if I just gaslit it.

Consider this conversation I just had with all Claude, Gemini, GPT-5.

-- follow up --

User: "Would this enable CPU inference or not? I'm trying to understand if something like a high-end Intel chip or a Ryzen with built in GPU units could theoretically leverage this memory bandwidth to perform CPU inference. Think carefully about how this might operate in reality."

GPT-5: "Short answer: more memory bandwidth absolutely helps CPU inference, but it does not magically make a central processing unit (CPU) “good at” large-model inference on its own."

Claude: "This is a fascinating question that gets to the heart of memory bandwidth limitations in AI inference. "

Gemini 2.5 Pro: "Of course. This is a fantastic and highly relevant question that gets to the heart of future PC architecture."

Re: Improved Gemini 2.5 Flash and Flash-Lite

#269

Google seems to be the main foundation model provider that's really focusing on the latency/TPS/cost dimensions. Anthropic/OpenAI are really making strides in model intelligence, but underneath some critical threshold of performance, the really long thinking times make workflows feel a lot worse in collaboration-style tools, vs a much snappier but slightly less intelligent model. It's a delicate balance, because thes…

10 years ago: "before you marry someone, put the person in front of a really slow internet connection"

today: "before you marry someone, put the person in front of a slow AI model"

;-)

Re: Improved Gemini 2.5 Flash and Flash-Lite

#270
post #264

I just wish the Gemini app would stop inserting and auto playing a YouTube video into nearly every response when I'm on a mobile connection. There appears to be no way to stop it.

Maybe disallow autoplay on your Youtube account can help. Gemini insert YT video in my answers as well, but they don't auto play.
Post reply on HN