Skip to content

feat(tracking): capture Microsoft Copilot shoppingCards into prompt_results - #87

Merged
gkhngyk merged 1 commit into
mainfrom
feat/copilot-shoppingcards-to-main
May 23, 2026
Merged

gkhngyk merged 1 commit into
mainfrom
feat/copilot-shoppingcards-to-main

Conversation

@gkhngyk

@gkhngyk gkhngyk commented May 23, 2026

Copy link
Copy Markdown
Contributor

Summary

Captures Microsoft Copilot's product cards into prompt_results.shopping_cards (the column added in #46, already on main). One-line change in the generic/non-Google parser branch that Copilot and Perplexity share.

Closes #47

Why this is a re-do

The original PR (#85) was stacked on the Perplexity branch (feat/tracking-shopping-cards) and ended up merged into that branch, not main — so the change never reached main (and #47 got auto-closed prematurely). This PR targets main directly, branched off the merged #46.

Change

server/src/lib/cloro-scraper.js:

shopping_cards: result.shopping_cards ?? result.shoppingCards ?? [],
  • Perplexity → result.shopping_cards (snake_case)
  • Copilot → result.shoppingCards (camelCase)
  • Everyone else → neither key → []

Stored verbatim in Copilot's shape; downstream branches on prompt_results.platform.

Verification

  • node --check passes.
  • Live smoke caught a populated Copilot card ("best wireless headphones to buy" → 3 cards / 6 products), confirming shoppingCards is a real top-level key with the documented shape (name, price.amount, seller, brandName, rating, url).

Cleanup note

The stale feat/tracking-shopping-cards branch (already squash-merged via #46, but still on the remote and now also holding the stranded Copilot commit) can be deleted.

…esults

Copilot returns its product cards under camelCase `shoppingCards`; unwrap
into the shared snake_case `shopping_cards` parsed key (generic branch that
Copilot + Perplexity share). Verified live against Cloro (real populated
card). Stored verbatim; downstream branches on `platform` for shape.

Closes #47

(Redo: the original PR #85 was stacked on the Perplexity branch and got
merged into that branch instead of main, so the change never reached main.
This targets main directly off the merged #46.)

This branch was successfully deployed

1 active deployment
Preview — 4bb4fd81 Deployed May 23, 2026 by vercel[bot]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feat(tracking): capture Microsoft Copilot shoppingCards data into prompt_results

1 participant