Back to Post
Amp Power Patterns: Subagents, Oracle, Librarian, and Rush Mode
1 / 1

TL;DR:

📖 Quick Start

Choosing Your Mode: Rush vs Smart vs Oracle

Not all tasks need the same horsepower. Pick based on complexity, not urgency.

flowchart TD
    Start([New Task]) --> Q1{Task is<br/>well-defined?}
    Q1 -->|Yes| Q2{Single file<br/>change?}
    Q1 -->|No| Smart[Smart Mode]
    Q2 -->|Yes| Rush[Rush Mode<br/>67% cheaper, 50% faster]
    Q2 -->|No| Q3{Needs deep<br/>reasoning?}
    Q3 -->|No| Smart
    Q3 -->|Yes| Oracle[Oracle Mode<br/>GPT-5 reasoning]

Rush Mode

When to use:

Examples:

How to use:

Switch mode to Rush (Amp UI/command palette), then:

Remove all console.log and debugger statements from @src/

Why it works: 67% cheaper, 50% faster (uses Claude Haiku 4.5)

When it doesn’t: Complex tasks, vague goals, architectural decisions

Smart Mode (Default)

When to use:

Examples:

How to use: Just prompt normally—smart mode is the default

Why it works: Uses Claude Sonnet 4.5, unconstrained context

Oracle Mode

When to use:

Examples:

How to use:

Oracle: review this API design. List trade-offs and risks.
Give a 2-step recommendation for improving error handling.

Why it works: Uses GPT-5 for complex reasoning, sees patterns across files

Cost: More expensive, but worth it for critical decisions

Subagents: Parallelize and Isolate

Subagents are independent agents that run in parallel or handle isolated subtasks without polluting your main thread.

When to Use Subagents

Parallelize independent work:

Isolate complex subtasks:

How to Use Subagents

Parallel work:

Use 3 subagents to convert these CSS files to Tailwind:
- @components/Header.css
- @components/Footer.css
- @components/Sidebar.css

Each subagent should preserve all styles and verify
the component still renders correctly.
Only modify files listed above; don't touch unrelated components.

Search and research:

Use a subagent to find all places where we validate
user input. Summarize the patterns.

Prototype/experiment:

Spawn a subagent to build a quick prototype of real-time
sync using WebSockets. Don't modify production code.

What Happens

Pitfalls

Over-parallelization:

❌ Use 10 subagents to refactor 10 files
   (coordination overhead, merge conflicts)

✅ Use 3 subagents for 3 independent modules
   (clear boundaries, minimal conflicts)

Stale context:

Oracle: Your Second Brain for Hard Problems

The Oracle is a specialized reasoning agent (GPT-5) that excels at:

When to Invoke the Oracle

Design reviews:

Oracle: review this API design for the user service.
- Analyze REST endpoints and data flow
- List security concerns and edge cases
- Suggest 2-3 improvements with trade-offs

Debugging:

Oracle: analyze why the checkout flow fails intermittently.
- Check UserCart.tsx, CheckoutService.ts, and payment API
- Identify race conditions or state management issues
- Recommend a fix with test strategy

Planning:

Oracle: plan the migration from Redux to Zustand.
- Identify all Redux usage
- Suggest migration order (least to most critical)
- List risks and rollback strategy

Oracle Best Practices

Be specific about what to analyze:

✅ Oracle: analyze authentication in auth/
   Check token refresh logic and session management.

❌ Oracle: check the auth stuff

Ask for structured output:

Oracle: review this code.
Give me:
1. Current issues (with line numbers)
2. Improvement suggestions (prioritized)
3. One quick win I can implement today

Provide files explicitly:

Oracle: review these files for performance issues:
- @components/DataTable.tsx
- @hooks/useDataFetch.ts
- @api/userService.ts

Librarian: Cross-Repo Code Intelligence

The Librarian searches public and private GitHub repositories to find:

When to Use the Librarian

Find prior art:

Use Librarian to find how we implement feature flags
across all org repositories.

Research framework patterns:

Use Librarian to find examples of Next.js server actions
in public repositories. Focus on error handling.

Understand dependencies:

Use Librarian to find how other projects use the
@company/design-system package. Show authentication
examples.

Discover best practices:

Use Librarian to research database migration strategies
in TypeScript projects. Compare Prisma vs Drizzle usage.

How to Use the Librarian

Specify scope:

✅ Search our organization's private repos for "webhook retry"

❌ Find webhook stuff

Focus the search:

Librarian: find feature flag implementations in our monorepo.
Filter for TypeScript files in services/ directories.
Show initialization and usage patterns.

Librarian Limitations

Pro tip: Ask for code blocks and file paths in results to speed verification.

Handoff: Fresh Context Without Losing Progress

Handoff extracts relevant context from a long thread into a new, focused thread.

When to Use Handoff

Context getting too large:

Use Handoff from the command palette.
Goal: Continue implementing user dashboard with the
decisions we made about data fetching and state management.

Switch focus:

Use Handoff from the command palette.
Goal: Take the authentication work and now add
authorization with role-based access control.

Clean slate for next phase:

Use Handoff from the command palette.
Goal: Testing phase—write tests for all the features
we just implemented.

What Handoff Does

  1. Analyzes current thread
  2. Extracts relevant context for your new goal
  3. Creates a new thread with focused context
  4. Generates a starter prompt

Result: Fresh thread, no context rot, ready to continue.

Cost and Time Tips

Optimize for both:

Monitor token usage:

Guardrails that still move fast:

Failure Modes and How to Avoid Them

Over-Parallelization

Problem: Spawning 10 subagents for coupled work Fix: Use subagents only for truly independent tasks

Stale Context

Problem: Subagents working with old file states Fix: Review and integrate results; don’t spawn subagents for tightly coupled changes

Noisy Diffs

Problem: Agent changes 50 files when only 5 were needed Fix: Be explicit in prompts: “Only modify files in components/“

Oracle Overuse

Problem: Asking Oracle for simple tasks (waste of cost/time) Fix: Reserve Oracle for complex reasoning, planning, debugging

Librarian Rabbit Holes

Problem: Searching too broadly, getting overwhelming results Fix: Focus searches with specific terms, file types, or patterns

Real Example: Migrating CSS to Tailwind

Task: Migrate 10 component stylesheets to Tailwind.

Approach:

Step 1: Plan with Oracle

Oracle: analyze these 10 CSS files and plan the migration
to Tailwind. Identify:
- Common patterns we can templatize
- Complex styles that need custom Tailwind config
- Suggested migration order (easiest to hardest)

Step 2: Parallelize with Subagents

Use 3 subagents to migrate these components:

Subagent 1:
- Header.css → Header.tsx
- Footer.css → Footer.tsx

Subagent 2:
- Sidebar.css → Sidebar.tsx
- Navigation.css → Navigation.tsx

Subagent 3:
- Card.css → Card.tsx
- Button.css → Button.tsx

Each should preserve styles, verify in Storybook,
and create a summary of changes.

Step 3: Review and Integrate

Review subagent diffs, stage good changes, test in browser.

Step 4: Verify with Rush

Switch mode to Rush (Amp UI/command palette), then:

Update remaining 4 simple components using the pattern
established by the subagents.

Time: 30-40 minutes for 10 components (vs 2-3 hours manually)

Takeaways

Pick the right tool:

When to level up:

When to stay simple:

Try This Week

🔨 Try It Now: Power Pattern Exercises

Exercise 1: Rush vs Smart Comparison

Task: Experience the speed difference

Rush mode prompt:

Switch mode to Rush, then:
Remove all TODO comments from @src/components/ and verify build succeeds.

Verification: Build passes, all TODOs gone, check token usage

Then try Smart mode for comparison:

Switch mode to Smart, then:
Refactor error handling in @utils/ to use a consistent pattern.

Expected outcome: Understand when to use each mode

Exercise 2: Oracle Plan Review

Task: Get deep analysis before coding

Prompt:

Oracle: review the plan in .agents/plans/todo/[feature].md
Simplify to minimal viable implementation. Flag over-engineering.
List 3 risks and suggest one quick win to start with.

Verification: Oracle finds simpler approach or catches issues Expected outcome: Avoid hours of unnecessary work

Exercise 3: Subagent Parallel Work

Task: Parallelize independent changes

Prompt:

Use 3 subagents to add PropTypes to these components:
- @components/Header.tsx
- @components/Footer.tsx
- @components/Sidebar.tsx

Each subagent should only modify its assigned file.
Verify PropTypes are correct and build succeeds.

Verification: All 3 files updated independently, no conflicts Expected outcome: 3x faster than sequential changes

Expected outcome: Know exactly when to reach for advanced modes.

Pick one power pattern and apply it:

  1. Rush mode: Convert 10 CSS files to Tailwind utility classes
  2. Subagents: Migrate 5 components to TypeScript in parallel
  3. Oracle: “Review the authentication system and suggest security improvements”
  4. Librarian: “Find how other teams implement feature flags in Next.js”
  5. Handoff: Take a long thread and extract context for the next phase

Slide Outline

Want to present this? Here’s a 10-slide outline:

  1. Why modes matter - Not all tasks need same horsepower
  2. Decision tree - When to use Rush vs Smart vs Oracle
  3. Rush examples - Small, well-defined tasks (console.log removal)
  4. Smart default - Complex refactoring, feature implementation
  5. Oracle requests - Deep analysis, architecture planning
  6. Subagents do/don’t - Parallelize independent, not coupled work
  7. Librarian scope - Cross-repo research and examples
  8. Handoff - Fresh context without losing progress
  9. Pitfalls checklist - Over-parallelization, stale context, noisy diffs
  10. Try this week - Pick one power pattern and apply it

Next: Set Up Planning Workflow — Use Oracle and .agents/plans structure to prevent rewrites.

Practice Path:

  1. What is an Agent
  2. First Win in 15 Minutes
  3. Workflows That Stick
  4. You are here: Power Patterns
  5. Planning Workflow

Related:

Resources: