Perplexity Power Shortcuts

Keyboard Shortcuts for Perplexity.ai: GSAP-powered scrolling, edit message, focus input, set sources (Academic/Social/GitHub), Search, Research.

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Greasemonkey 油猴子Violentmonkey 暴力猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Violentmonkey 暴力猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Userscripts ,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展后才能安装此脚本。

(我已经安装了用户脚本管理器,让我安装!)

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

(我已经安装了用户样式管理器,让我安装!)

作者
Brian Hurd
日安装量
0
总安装量
10
评分
1 0 0
版本
1.4.0
创建于
2025-10-28
更新于
2025-11-09
大小
21.0 KB
许可证
暂无
适用于

Perplexity.ai keyboard Shortcuts.

If you use comet browser, see how to enable tampermonkey extension on perplexity.ai url here:
https://github.com/pnd280/complexity/blob/nxt/perplexity/extension/docs/comet-enable-extensions.md

On windows, open powershell and run:
irm "https://cdn.cplx.app/assets/comet-policy-patch-win.ps1" | iex

// on page reload, automatically run the “Research + Social” sequence (same as your alt+g logic) on page load, waiting 1500 ms.

SHORTCUTS:


// Alt+t → Scroll to top of main thread
// Alt+z → Scroll to bottom of main thread
// Alt+j → Scroll up one message block
// Alt+k → Scroll down one message block
// Alt+e → Edit lowest user message (clicks [data-testid="edit-query-button"]; simulates hover if needed; falls back to Search if none found)
// Alt+Shift+s → Click Search mode (SVG d^="M11 2.125a8.378 8.378")
// Alt+r → Click Research mode (SVG d^="M8.175 13.976a.876.876")
// Alt+w → Focus chat input (#ask-input contenteditable)
// Alt+a → Set Sources → Academic (First: Set Sources SVG d^="M3 12a9 9 0 1 0", then submenu data-testid="source-toggle-scholar")
// Alt+s → Set Sources → Social (submenu data-testid="source-toggle-social")
// Alt+g → Set Sources → GitHub (submenu by testid if present or text "GitHub")
// Alt+n → Start new conversation


// #1
// Css tweaks (hide download comet)
(function() {
var target = document.querySelector('div.h-bannerHeight.rounded-sm');
if (target) target.style.display = 'none';
})();


// #2
// on page reload, automatically run the “Research + Social” sequence (same as your alt+g logic) on page load, waiting 1500 ms.
(function () {
function clickSegmentedControlBySVGPath(pathPrefix) {
const segButtons = Array.from(document.querySelectorAll('button[role="radio"]'));
for (const btn of segButtons) {
const svg = btn.querySelector('svg');
if (svg) {
const path = svg.querySelector('path');
if (path && path.getAttribute('d') && path.getAttribute('d').startsWith(pathPrefix)) {
if (btn.getAttribute('aria-checked') !== "true") {
btn.click();
return true;
}
}
}
}
return false;
}
function openSourcesMenuAndClickSubmenuByTestId(testid) {
const sourcesBtn = document.querySelector('button[data-testid="sources-switcher-button"]');
if (!sourcesBtn) return false;
sourcesBtn.click();
setTimeout(() => {
const menu = document.querySelector('div[role="menu"], ul[role="menu"]');
if (menu) {
const item = menu.querySelector(`[data-testid="${testid}"]`);
if (item) item.click();
}
}, 250);
return true;
}
function sendEscapeKey() {
document.dispatchEvent(new KeyboardEvent('keydown', {
key: 'Escape',
code: 'Escape',
keyCode: 27,
which: 27,
bubbles: true,
}));
}
function doAltGSequence() {
clickSegmentedControlBySVGPath('M8.175 13.976a.876.876');
setTimeout(() => {
openSourcesMenuAndClickSubmenuByTestId('source-toggle-social');
setTimeout(() => {
sendEscapeKey();
}, 350);
}, 250);
}
if (document.readyState === 'complete' || document.readyState === 'interactive') {
setTimeout(doAltGSequence, 1500);
} else {
window.addEventListener('DOMContentLoaded', function () {
setTimeout(doAltGSequence, 1500);
});
}
})();

// #3
// Alt+t → Scroll to top of main thread
// Alt+z → Scroll to bottom of main thread
// Alt+j → Scroll up one message block
// Alt+k → Scroll down one message block
// Alt+e → Edit lowest user message (clicks [data-testid="edit-query-button"]; simulates hover if needed; falls back to Search if none found)
// Alt+Shift+s → Click Search mode (SVG d^="M11 2.125a8.378 8.378")
// Alt+r → Click Research mode (SVG d^="M8.175 13.976a.876.876")
// Alt+w → Focus chat input (#ask-input contenteditable)
// Alt+p → Set Sources → Academic (submenu data-testid="source-toggle-scholar")
// Alt+s → Set Sources → Social (submenu data-testid="source-toggle-social")
// Alt+g → Set Sources → GitHub (submenu by testid if present or text "GitHub")