Gemini 3 Pro Workflow That Changes Everything

By corbin

Share:

Key Concepts

  • Parallel Agents: The ability to run multiple AI agents simultaneously to work on different parts of an application.
  • Main and Grunty Workflow: A personalized workflow designed for app development using AI agents, distinguishing between complex, reasoning-intensive tasks (Main) and simple, quick tasks (Grunty).
  • Higher-Level Models: More powerful AI models used for complex reasoning and planning (e.g., for Main).
  • Lower-Level Models: Faster, less complex AI models suitable for quick, repetitive tasks (e.g., for Grunty).
  • Repo Understanding: The process of an AI agent analyzing and comprehending the entire codebase of an application.
  • Page-Specific Context: Providing an AI agent with detailed information about a particular page or component within an application.
  • Ask Mode vs. Agent Mode: Different interaction modes with AI agents. "Ask mode" is for general queries and context gathering, while "Agent mode" is for direct task execution.
  • Planning Mode: A phase where the AI agent outlines a step-by-step plan for a task before execution.
  • Debugging Flow: The process of identifying and resolving errors in the code, often involving console logs and iterative feedback to the AI.
  • Model Switching: The strategy of changing AI models if one is struggling with a task, to leverage the strengths of different models.

Main and Grunty: A Workflow for Optimized AI App Development

This video introduces a personalized workflow called "Main and Grunty" for building applications using AI agents, designed to optimize efficiency by differentiating between complex and simple tasks.

The Ineffectiveness of Pure Parallelism

Initially, the speaker highlights the common practice of running multiple AI agents in parallel for tasks like building landing pages, login, and signup pages. While this is effective in the early stages of app creation, it becomes inefficient as the codebase grows and complexity increases. The core issue is that as more files and code are added, managing multiple agents working on interconnected parts becomes cumbersome and less effective.

Introducing the "Main and Grunty" Workflow

The "Main and Grunty" workflow is presented as a solution to this problem. It categorizes tasks into two types:

  • Main: For higher-level, reasoning-intensive tasks that require more time and complex planning. This agent typically uses a more powerful, higher-level AI model.
  • Grunty: For fast, simple tasks that are easily executable and could even be done manually by a developer. This agent utilizes lower-level, faster models to expedite code workflows.

Setting Up Main and Grunty

The setup involves creating two separate agent chats:

  1. Main Agent:
    • Prompt: "Read my entire repo and understand my app."
    • Model: A higher-level model is chosen for its advanced reasoning capabilities.
    • Mode: Initially used in "ask mode" for context gathering and planning.
  2. Grunty Agent:
    • Prompt: The same prompt as Main, but with a focus on understanding the repo.
    • Model: A lower-level model is selected for speed.
    • Mode: Primarily used in "agent mode" for direct execution of simple tasks.

Both agents are pre-loaded with the understanding of the entire repository.

Task Execution and Examples

The workflow is demonstrated through practical examples:

Example 1: Enhancing the Folder System (Main Task)

  • Scenario: The developer wants to add color customization to the folder icons in their application's studio sandbox.
  • Main's Role:
    • The developer provides a screenshot of the folder icon and a specific request: "I want it so that the user can click the icon and change the color of the folder."
    • Main is tasked with understanding the code rendered on the specific "value page" (or in this case, the folder system) by providing a URL or context.
    • Main enters a "planning mode" to define the steps, such as implementing a color picker with preset options (e.g., six colors).
    • Once the plan is made, Main is instructed to "build."
  • Grunty's Role (concurrently):
    • While Main is processing the complex task, Grunty is used for quick, unrelated modifications.
    • An example is given: "10 hay bells equals one lead image screenshot." Grunty is instructed to add a highlight to specific numbers (10 and 1) in the UI.
    • Grunty is directly in "agent mode" for these simple, executable tasks.

Example 2: Image Editing Context (Grunty Task)

  • Scenario: The developer wants to simplify a prompt for image editing on a thumbnail platform.
  • Grunty's Role:
    • The initial prompt might be "10 hay bells equals one lead image edit."
    • The developer refines it to "10 hay bells equals one lead edit," recognizing that on a thumbnail platform, image editing is inherent and doesn't need explicit mention. This is a quick, iterative improvement.

The "Flip-Flop" Workflow

The core of the "Main and Grunty" strategy is the "flip-flop" approach:

  • During Main's Processing: When Main is engaged in complex, time-consuming tasks (which can take 5-10 minutes or more), the developer utilizes the downtime to assign multiple quick tasks to Grunty.
  • Mental Capacity: The developer emphasizes that complex tasks require significant mental focus, which should be directed towards Main. Grunty tasks are seen as productive ways to use downtime, akin to actively working instead of passively scrolling social media.
  • Avoiding Multiple Mains: The workflow discourages running multiple "Main" agents simultaneously due to the high mental overhead. Instead, it prioritizes maximizing productivity with Grunty during Main's processing time.

Debugging and Iteration

The workflow also incorporates a debugging process:

  • Identifying Issues: If Main's output isn't working as expected (e.g., the color picker doesn't save or change color), the developer takes screenshots and provides detailed feedback to Main.
  • Console Logs: For front-end issues, the developer opens the console log to identify errors.
  • Providing Debug Information: The raw error messages from the console are copied and pasted into the Main agent's chat, acting as a "debug flow" for the AI to analyze.
  • Model Switching: If an agent (like Main) gets stuck or is taking too long, the developer suggests switching to a different, potentially more capable model. In the example, "Composer One" was replaced with "GPT Codex High," which then successfully completed the task on the first attempt.

Conclusion of the Workflow

The "Main and Grunty" workflow is presented as the "best method ever created to optimize your time when developing in this way." It allows for efficient handling of both complex planning and execution (Main) and rapid, iterative improvements (Grunty), leading to optimized development time. The speaker encourages viewers to like the video if they found it helpful and anticipates future "Main Grunty" videos.

Chat with this Video

AI-Powered

Load the transcript when you're ready to chat so the initial page stays lighter.

Ready to summarize another video?

Summarize YouTube Video