Gemini in Chrome 这个功能我等很久了,以前用的是 Randy Liu 的 SumBuddy Chrome 插件。
Gemini in Chrome 利用侧边栏共享其他 Chrome Tab 的内容,做到随时可以基于网页内容在 Gemini 提问。

(1) 在 Chrome 浏览器的地址栏输入 chrome://flags ,打开两个 flag

chrome://flags/#glic -> Enabled
chrome://flags/#glic-side-panel -> Enabled

(2) 杀掉全部 Chrome 进程
(3) 修改 Chrome 用户目录的 ‘Local State’ (文件名中间有空格)

Chrome 有多个版本,stable / beta / dev 等,请自行查找:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
'win32': {
'stable': '~/AppData/Local/Google/Chrome/User Data',
'canary': '~/AppData/Local/Google/Chrome SxS/User Data',
'dev': '~/AppData/Local/Google/Chrome Dev/User Data',
'beta': '~/AppData/Local/Google/Chrome Beta/User Data',
},
'linux': {
'stable': '~/.config/google-chrome',
'canary': '~/.config/google-chrome-canary',
'dev': '~/.config/google-chrome-unstable',
'beta': '~/.config/google-chrome-beta',
},
'darwin': {
'stable': '~/Library/Application Support/Google/Chrome',
'canary': '~/Library/Application Support/Google/Chrome Canary',
'dev': '~/Library/Application Support/Google/Chrome Dev',
'beta': '~/Library/Application Support/Google/Chrome Beta',
},

以 stable 版为例,用户目录为:

Linux : ~/.config/google-chrome
Windows : ~/AppData/Local/Google/Chrome/User Data
MacOS : ~/Library/Application Support/Google/Chrome

‘Local State’ 需要修改 variations_permanent_consistency_countryis_glic_eligiblevariations_country
几个字段,将 cn 修改为 us, false 修改为 true, 版本号不用修改 。

1
2
3
"variations_permanent_consistency_country":["144.0.7559.109","us"]
"is_glic_eligible":true
"variations_country":"us"

(4) 重启 Chrome

重启后,可以在 Chrome 的右上角看到带 ☆ 的 Gemini 按钮,点击即可开启 Gemini 侧边栏。

注意事项

动手能力一般的同学,可以直接使用这个Github 仓库的脚本:
https://github.com/lcandy2/enable-chrome-ai

我大致扫了一眼,没有看到安全问题。

一定要杀掉 Chrome 全部进程(关掉所有 Chrome),否则修改 ‘Local State’ 会出问题。

目前 Gemini in Chrome 只在美国能用,线路问题要自己解决。
https://gemini.google/overview/gemini-in-chrome/

1
Gemini in Chrome is The new Gemini in Chrome is available on Windows, MacOS and Chromebook Plus in the U.S.

网络上有修改浏览器语言成功开启 Gemini in Chrome 的,我没有试成功,实际上和浏览器语言没有关系。