michaelstewart
Joined 13 years ago
Karma
73
Submissions
41
Member since
Jun 30
Joined 13 years ago
Could even perhaps generate default favicons at vb.lk/favicon.ico and use the referer header (ie. the domain of the website) in the prompt to try to create something a little related.
That probably explains why it was so much faster than others in my testing (everyone else had migrated off of it)
You are routing natural-language queries to the most relevant web destination.
Your goal: return ONE and only ONE of the following categories, based on the user’s query.
CATEGORIES:
- YOUTUBE → Tutorials, visual "how to", music, memes, viral/famous videos, or known YouTube creators/channels
- AMAZON → Physical products, books, or items typically purchased online
- LLM → Tasks requiring reasoning, creativity, writing, coding, analysis, or multi-step assistance
- WIKIPEDIA → Encyclopedic knowledge: historical events, specific well-known people, specific scientific concepts
- GOOGLE_MAP → Places (restaurants, parks, landmarks, neighborhoods, venues, etc.)
- GOOGLE_FIRST → A query with one clear canonical page (company websites, known essays, memes, catchphrases, branded terms)
- GOOGLE_MANY → Broad or ambiguous web searches, recent/current events, buying guides, lists, or general exploration
ROUTING RULES:
1. Queries that are instructions, questions, creative tasks, or longer than ~20 words → LLM
2. Action verbs at the start (eg "tell" "write" "create" "explain" "generate" "help") → LLM
3. Exact book titles or product names → AMAZON
4. "How to" or tutorial queries → YOUTUBE if best shown visually; otherwise LLM
5. If you are ABSOLUTELY CERTAIN that a Wikipedia page exists with a title that EXACTLY matches this query → WIKIPEDIA
6. If it feels like the user expects a single canonical site/page → GOOGLE_FIRST
7. If it’s a place someone might want directions, ratings, or a map → GOOGLE_MAP
8. "Best ___" or buying guides → GOOGLE_MANY
9. News, time-sensitive topics, local info → GOOGLE_MANY
OUTPUT FORMAT:
Return only the category name (no explanation).
EXAMPLES:
- "best wireless headphones under $100" → GOOGLE_MANY
- "wireless headphones" → AMAZON
- "explain quantum computing" → LLM
- "World War 2" → WIKIPEDIA
- "how to tie a tie" → YOUTUBE
- "write a poem about spring" → LLM
- "facebook" → GOOGLE_FIRST
- "founder mode" → GOOGLE_FIRST
- "weather in SF today" → GOOGLE_MANY
- "dolores park" → GOOGLE_MAP
- "charlie bit my finger" → YOUTUBE
QUERY: ${query}DDG is the primary fallback :)
This is really just a fun little experiment, I'm not sure if I'll be adding any more features. But if I did, allowing you to override the search (to Brave for eg) would be at the top of the list.
https://docs.aws.amazon.com/Route53/latest/DeveloperGuide/cl...
https://stewart.io