-
Notifications
You must be signed in to change notification settings - Fork 5
Open
Labels
bugSomething isn't workingSomething isn't workingenhancementNew feature or requestNew feature or request
Description
Problem
The current competitor detection system checks project competitor domains against grounding source domains. This is fundamentally wrong:
- When AI answers "best AI consulting firm", it reads an article on
techloy.comand recommends Accenture - Grounding source =
techloy.com(the article site) - Recommended company = Accenture (the actual competitor)
computeCompetitorOverlap()looks foraccenture.comin grounding sources → not found- Result: Accenture is never flagged as a competitor, even though AI explicitly recommended them
The answerText brand-name check partially works, but requires pre-registering every competitor domain — which is impractical.
Current Flow
- User manually adds competitor domains to project
computeCompetitorOverlap()checks: citedDomains (grounding sources) → groundingSources URIs → answerText for brand names- Only matches against pre-registered domains
Proposed Fix
Extract recommended company names directly from answerText using LLM analysis (same approach as snapshot feature, #193/#194):
- After each provider response, run a lightweight extraction pass on the answer text
- Store extracted company names in a new
recommended_competitorscolumn onquery_snapshots - Surface in the API and UI (Competitors tab, ui: show competitors and grounding sources in tabbed sidebar view #196/feat: tabbed sidebar — Competitors + Sources #197)
- No pre-registration required — the extraction finds whoever AI actually recommended
This makes the existing manual competitor list optional (useful for tagging known competitors) rather than the sole detection method.
Impact
Without this fix, the competitor intelligence shown in the dashboard is fundamentally misleading — it shows article source domains, not the companies AI recommends to users.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
bugSomething isn't workingSomething isn't workingenhancementNew feature or requestNew feature or request