# Multi-Agent Team Workflow Upgrade Funnel

## Objective

Convert solo single-agent users into Pro or Team plans right when they trigger parallel runs, verifier agents, or shared memory.

Build a contextual in-app upgrade funnel inside AI workspaces that triggers when a user attempts to fan out parallel worker agents, attach an automated security/QA reviewer agent, or share persistent cross-session memory across teammates.

## Before You Begin

This funnel is being added to an application or site that may already exist.
Do not scaffold a new project unless the user explicitly asks for one, and
do not assume a blank slate.

Inspect the codebase first and establish:

- The source Markdown files, docs, URLs, or repo files supplied for this funnel build.
- The offer, audience, funnel stage, price point, and desired conversion action.
- The existing application structure and where landing pages, forms, checkout, or tracking code already live.
- The framework and version in use.
- The existing design system — colours, spacing, typography, and component conventions.
- Existing UI components you can reuse instead of writing new ones.
- The existing database structure, if this funnel needs to persist leads, applications, purchases, or events.
- The existing authentication and authorization system, if this funnel is user-scoped.
- Dependencies already installed, so you don't add a library that duplicates one.
- The existing test setup and conventions.

Only start writing code once you understand the above. If the application
already implements part of this funnel, extend it rather than replacing it.

Do not invent testimonials, revenue claims, scarcity, guarantees, legal
disclaimers, or endorsement language. Use only what appears in the source
files, and call out missing claims or assets in your final summary.

## Implementation Instructions

Build a contextual in-app upgrade funnel inside AI workspaces that triggers when a user attempts to fan out parallel worker agents, attach an automated security/QA reviewer agent, or share persistent cross-session memory across teammates.

1. Identify the 3 high-intent multi-agent expansion triggers inside the product (parallel sub-agent fan-out, second-agent automated review, shared org memory layer).
2. Allow free or starter users to configure their multi-agent workflow or preview a single-agent vs multi-agent run comparison inline.
3. Open a crisp contextual upgrade modal naming the exact capability requested, transparent monthly/annual pricing, and immediate run continuation.
4. On payment confirmation, dispatch the exact queued multi-agent run automatically so the user feels immediate speed payback.

## Edge Cases

- Let users who dismiss the upgrade modal fall back cleanly to running their task sequentially on a single agent without losing their prompt.
- Enforce concurrency and shared-memory entitlements strictly on the backend job runner.

## Acceptance Criteria

- [ ] Declining the upgrade preserves the user's prompt and offers a clean single-agent fallback.
- [ ] Accepting the upgrade launches the configured multi-agent run automatically on confirmation.
- [ ] Analytics track upgrade conversion rate separately for each multi-agent trigger.

## Adaptation Rules

- Match the existing design system. Do not introduce a new colour palette,
  spacing scale, or component library.
- Reuse existing components and utilities wherever they fit.
- Follow the naming, file layout, and code style already present.
- Do not upgrade, replace, or remove existing dependencies to make this
  funnel fit. Adapt the funnel to the app, not the app to the funnel.
- Do not break existing functionality. If a change is genuinely required in
  existing code, make the smallest one that works and say so.
- If something in these instructions conflicts with how the application is
  built, follow the application and explain the deviation.
- Use generic funnel strategy language. Do not name or imply endorsement by
  any specific public marketer, course, book, or software brand.

## Final Verification

Before you report the work as done:

1. Re-read the acceptance criteria above and check each one against what you
   actually built.
2. Run the application and exercise the funnel end to end.
3. Run the existing test suite and confirm you have broken nothing.
4. Check the funnel on mobile, tablet, and desktop widths.
5. Check forms, buttons, keyboard navigation, and focus handling.
6. Summarize what changed: files added, files modified, source files used,
   assumptions made, and anything you deliberately did differently because
   of how this application is built.

If any acceptance criterion is unmet, fix it before reporting completion.
