Qwant AI Search Summary Userscript
This is a very experimental userscript that uses the OpenRouter.ai API to generate AI-based summaries of Qwant search results, rendered directly in the sidebar. All the built-in/preset models are free in OpenRouters so you just need to add your API key.
Note: This script is barely held together. The code is pretty bad and full of rough edges, but it works — mostly. I'm publishing this earlier than intended since I'm switching to Kagi and won’t be using Qwant anymore.
🚀 Features
- Summarizes Qwant search results using a chosen LLM from OpenRouter.
- Renders output with Markdown and LaTeX (via Showdown-KaTeX).
- Caches previous results for performance and API cost savings.
- Customizable prompt and model settings through a user menu.
- Rudimentary cache management and error handling.
- API key setup via prompt — no need to hardcode.
🧠 Known Limitations
- Markdown/LaTeX formatting is inconsistent. The model sometimes messes up Markdown or LaTeX despite the detailed system prompt. There's not much I can do here, I've already put a lot of effort into writing a precise, verbose system prompt.
- It may break at any time. Qwant's site structure might change, OpenRouter might change behavior, or the model output might just stop parsing correctly.
- The code is messy. Honestly, it's kind of garbage. I'll try to fix it if it breaks, but no promises — I’m moving on to other things.
🔧 Setup
- Install this script from this GreasyFork page.
- Set your OpenRouter API key via the menu (
Userscript > Settings
).
- Optionally customize the AI model or prompt.
🛠️ Customization
Once installed, you can:
- Change models (DeepSeek, Gemma, etc.)
- Write your own prompt for the AI to follow
- Clear or resize cache
- Reset settings
💡 Models & Rate Limits
The userscript includes several built-in models (predefined in the UI), and you can use any model from OpenRouter—both free (:free
) and paid—just by entering your API key.
To unlock better rate limits (even for free models), it's highly recommended to add at least $10 in credits:
- < $10 credits: 50 free model requests/day
- ≥ $10 credits: 1000 free model requests/day
🔁 All users are limited to 20 requests/minute, and extreme usage may be blocked by DDoS protection.
Just click the userscript menu button and follow the prompts.
📦 Dependencies
📜 License
MIT — use and modify freely, but please don’t expect support.
🙏 Thanks
This was built out of frustration and curiosity — if it helps you, that’s cool. But really, consider switching to Kagi if you’re looking for quality search + AI integration.
Disclaimer: This script uses third-party AI services. The summaries may be inaccurate or misleading. Always double-check important information.