Live data from Hacker News

Chrome is adding `window.ai` – a Gemini Nano AI model right inside the browser

twitter.com

121–130 of 194 posts

Re: Chrome is adding `window.ai` – a Gemini Nano AI model right inside the browser

#121
post #116

Earlier quoted context omitted.

web dev is rife with this stuff. wrappers upon wrappers with a poor trade off between adding api overhead / obscuring the real workings of what's going on and any actual enhanced functionality or convenience. it's done for github stars and rep.

Or maybe it’s done because people like to try and experiment new things, see what works and what doesn’t, with sometimes surprising results. I thought the name of this site was Hacker News, let people do weird things

Lmao flogging off wrappers over things other people have built is "hacker spirit" or whatever now is it? This place has gone completely to shit.

Re: Chrome is adding `window.ai` – a Gemini Nano AI model right inside the browser

#122
post #107

If this is the API that Google are going with here: const model = await window.ai.createTextSession(); const result = await model.prompt("3 names for a pet pelican"); There's a VERY obvious flaw: is there really no way to specify the model to use? Are we expecting that Gemini Nano will be the one true model, forever supported by this API baked into the world's most popular browser? Given the rate at which models are…

> But... if the browser model is being invisibly upgraded, how are we supposed to test out prompts and expect them to continue working without modifications against whatever future versions of the bundled model show up?

Pinning the design of a language model task against checkpoint with known functionality is critical to really support building cool and consistent features on top of it

However the alternative to an invisibly evolving model is deploying an innumerable number of base models and versions, which web pages would be free to select from. This would rapidly explode the long tail of models which users would need to fetch and store locally to use their web pages, eg HF's long tail of LoRA fine tunes all combinations of datasets & foundation models. How many foundation model + LoRAs can people store and run locally?

So it makes some sense for google to deploy a single model which they believe strikes a balance in the size/latency and quality space. They are likely looking for developers to build out on their platform first, bringing features to their browser first and directing usage towards their models. The most useful fuel to steer the training of these models is knowing what clients use it for

Re: Chrome is adding `window.ai` – a Gemini Nano AI model right inside the browser

#123
post #102

Earlier quoted context omitted.

For sure many devices will have them, but the trick will be to build this local web model in a way that leverages all of the local chips. Apple’s advantage is in not having to worry about all that. It has a simpler problem and better access to real local data. Give my personal local data to a model running in the browser? Just feels a bit more risky.

> in a way that leverages all of the local chips Which, in a way, is similar to building a browser leveraging all of the local GPUs to do render and HW-accelerated video decoding. Is Safari on Apple Silicon better than Chrome on random Windows laptop for playing YouTube in the last 5 years? Hardly.

And would still need to give Chrome access to your contacts, files etc to make it equivalent. It’s not useless, obviously it’ll be good, it’s just not the same. My original comment was replying to: “enable approximately what Apple is doing with their AI strategy”

Re: Chrome is adding `window.ai` – a Gemini Nano AI model right inside the browser

#125
post #97

I would honestly love this, so that users don't even have to think about AI. - Massively broaden the input for forms because the AI can accept or validate inputs better - Prefill forms from other known data, at the application level - Understand files/docs/images before they even go up, if they go up at all - Provide free text instructions to interact with complex screens/domain models Using the word AI everywhere is…

Web apps can do all those things already without an LLM.

Re: Chrome is adding `window.ai` – a Gemini Nano AI model right inside the browser

#126
post #24

eval(window.ai("js code to remove all adds in the following page" + document.documentElement.outerHTML))

The API isn't `window.ai(prompt)` and what does "remove all adds" mean?

They’re implying that you could trick the model into providing an up to date way to block ads on the page since it’s local and could just inspect the page.

The joke comes across fine even with the wrong AI call, lol

Re: Chrome is adding `window.ai` – a Gemini Nano AI model right inside the browser

#128
post #117
post #107

If this is the API that Google are going with here: const model = await window.ai.createTextSession(); const result = await model.prompt("3 names for a pet pelican"); There's a VERY obvious flaw: is there really no way to specify the model to use? Are we expecting that Gemini Nano will be the one true model, forever supported by this API baked into the world's most popular browser? Given the rate at which models are…

I'm pretty sure that with time, they will be forced to let users choose the model. Just like it happened with the search engine...

Wouldn't this require Chrome to download models on the fly or pre-package multiple models?

That doesn't really seem possible (mobile data connection) or convenient (Chrome binary size, disk space) for the user.

Re: Chrome is adding `window.ai` – a Gemini Nano AI model right inside the browser

#129

Earlier quoted context omitted.

Mozilla does it too! [0] [0]: https://blog.nightly.mozilla.org/2024/06/24/experimenting-wi...

That has nothing to do with what Google is doing here. That is an end user summarisation feature not a proprietary web API.

I don't know if I'm interpreting this right but it sounds to me like they're working on it too. [0]

[0]: https://connect.mozilla.org/t5/discussions/share-your-feedba...

Re: Chrome is adding `window.ai` – a Gemini Nano AI model right inside the browser

#130
post #106
post #105

Earlier quoted context omitted.

The video plays fine on both, yes, but the Windows laptop, generally speaking, gets hotter, and runs out of battery sooner.

Exactly. So feature-wise it can work, and out of our "I proudly spent $2500 on my fancy Apple laptop"-tech bubble, people already learned to settle on something hotter.

What $2500 laptops that people buy for watching YouTube are you referring to?
Post reply on HN