Intro to Cascade

Introduction to Cascade, the engine behind agentic capabilities in Windsurf

Intro to Cascade: Agentic AI

Cascade is the engine powering Windsurf's agentic AI capabilities in both the Windsurf IDE and JetBrains extensions. It understands your codebase and can take action.

Cascade Operating Modes:

  • Chat Mode:
    • Purpose: Explore and retrieve information from your codebase without making changes.
    • Ideal for: Code discovery, Q&A, understanding patterns.
  • Write Mode:
    • Purpose: Take action and make changes to your codebase.
    • Capabilities: Edit across files/directories, generate documentation, run terminal commands, build test suites from natural language.

Cascade intelligently pulls context from your entire codebase to power both modes.

Example: Refactoring Code

Cascade can perform complex refactoring tasks. For instance, if you have a Java file with multiple classes (Book.java containing Book, Title, Author classes):

  1. 1. Prompt Cascade: "Refactor the code in this file and move each class into its own individual file."
  2. 2. Planning: Cascade will create a plan outlining the steps it will take.
  3. 3. Execution: Cascade will then execute the plan, creating new files for each class (e.g., Title.java, Author.java) and modifying the original file.

Interacting with Cascade for Larger Tasks:

A recommended approach for complex tasks:

  1. 1. Have Cascade plan the task first without making edits.
  2. 2. Review and approve the plan.
  3. 3. Instruct Cascade to execute the approved plan.

This is just a glimpse of Cascade's capabilities. Explore Windsurf University for more best practices.

Cascade transforms how you build software by bringing intelligent automation to your development workflow.