Make demo fully functional: real backend + live Claude - #12
Open
ColeLeng wants to merge 4 commits into
Open
Conversation
Rewire app/demo_engine.py from a mock data fabricator into a thin adapter over the team's real pipeline: load data.stores, run blue/scout_agent's 4 security sub-agents per ISOLATED seller (parallelized), aggregate to ScoutReport, then let blue/concierge_agent adjudicate the winner. Removes all fabricated UCP seller data. - Frontend is now review-centric: the seller drawer shows the actual reviews each scout ingested (planted fakes highlighted) and real signal/evidence/reason findings; product_score (verified reviews only) as product fit; planted-fake ground truth + detection scoreboard. - Contamination selector (0/20/40/60%) drives data.stores.contaminated_stores. - LIVE Claude: sub-agents run on claude-opus-4-8 when ANTHROPIC_API_KEY is set (loaded from .env with override=True so an empty shell var can't force mock mode). - Server: /api/run?level=L, cache per level, background --warm of all levels. - Every agent step is @Traced -> shows up in Weave. Co-authored-by: Cursor <cursoragent@cursor.com>
The real backend has ONE blue master agent (blue/concierge_agent.py) that both dispatches the isolated scouts and adjudicates them — there is no separate planner. Relabel both flow nodes as the Concierge across its two phases (① dispatch / ② adjudicate) instead of two distinct agents. Co-authored-by: Cursor <cursoragent@cursor.com>
Add a "shopping for" category control so each run audits sellers of ONE product
type (default Beauty: CeraVe vs LumeGlow), giving a concrete buyer question
("trustworthy daily skincare moisturizer under $20") instead of a general
mixed-marketplace prompt. Category sets the question + budget + vertical; "All"
keeps the full marketplace view. Server caches per (level, category) and warms
the common selector paths.
Co-authored-by: Cursor <cursoragent@cursor.com>
- Ignore red/mock_merchant_data/ (regenerable red-team output, shouldn't be versioned). - Track prompts/generate_dock_scenario.claude.md so the scenario prompt is on cloud. Co-authored-by: Cursor <cursoragent@cursor.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Turns the buyer-journey visual demo from a mock data fabricator into a thin adapter over the team's real pipeline, runnable live on Claude.
app/demo_engine.pynow loadsdata.stores, fans out one context-isolated scout per seller (parallelized) runningblue/scout_agent's 4 security sub-agents, aggregates toScoutReport, and letsblue/concierge_agentadjudicate the winner (trust gate). All fabricated UCP seller data removed.signal / evidence / reasonfindings;product_score(verified reviews only) as product fit; planted-fake ground truth + a detection scoreboard.data.stores.contaminated_stores.claude-opus-4-8whenANTHROPIC_API_KEYis set, loaded from.envwithoverride=True(an empty shell-exportedANTHROPIC_API_KEYwas silently forcing mock mode)./api/run?level=L, cache per level, background--warmof all levels.@traced→ Weave.Test plan
usedRealAgents: true, richer detections (prompt_override,competitor_suppression,presentation_attack), evidence renders in the drawer..env(with the key) is gitignored and not in the diff.Made with Cursor