Branching & flip-tests
Explore a divergence live.
Branch a conversation
POST /api/v1/insights/branch forks a fresh persona chat at a fault line (e.g. a miner branchPrompt), runs a short deepening exploration, and reports back — without touching your main thread.
{ "audienceId": "aud_f1_1",
"branchPrompt": "You mentioned trust — what exactly would make you trust the numbers?",
"subject": "Trust", "depth": 2, "seed": 7 }
# → data: { subject, opened, transcript:[{role,content}], summary, ranLive }| Field | Meaning |
|---|---|
branchPrompt | The question that opens the branch (required). |
subject | Label for the fault line (for the report header). |
depth | Follow-up turns to explore (1–4, default 2). |
The flip-test loop
POST /api/v1/insights/flip-test runs find → branch → verify in one call:
Find
The smallest model hypothesizes what condition would flip an opinion in your turns.
Branch
Forks a fresh chat: captures the persona's baseline stance, introduces the hypothesized condition, re-asks.
Verify
Code-computed stance delta (before vs after) → a verdict. The movement is measured from real text; the hypothesis + prose are model-generated.
{ "audienceId": "aud_f1_1",
"topic": "$29 finance app; price-sensitivity & scaling",
"turns": [{ "speaker": "Riley", "text": "Cheap means it won't scale for my team" }] }
# → data: {
# hypothesis: { message, branchPrompt, confidence },
# baseline: { question, answer, stance },
# afterCondition: { question, answer, stance },
# verdict: "flipped" | "softened" | "unchanged" | "hardened" | "no-test",
# delta: -1..1, report: "…measured in code…" }Honest by construction. A real example returned unchanged (Δ0) because the persona revealed the true objection was data lock-in, not scale — so "prove it scales" wouldn't move them. The verdict is a measurement, not a model claim.