Date:

Crafting Custom Plans with plan.md in Goose

What is Goose?

Goose is a developer agent that enhances software development by automating coding tasks within your terminal or IDE. Guided by your input, it intelligently analyzes your project’s needs, generates the necessary code, and implements changes autonomously. When working with Goose, having a structured way to guide its execution toward specific goals is essential. This is where the plan.md file comes in. A plan.md file allows you to define a customized plan for Goose, using flexible text formatting and the power of Jinja templating to create dynamic, reusable, and goal-oriented plans.

How to Set Up Goose

Before creating your custom plan.md file, you need to set up Goose.

Step 1: Fork the Goose and Goose Plugin repositories on GitHub and clone them.

Step 2: Install Homebrew — Visit brew.sh and follow the installation steps, or run:

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

Step 3: Then install Goose:

pipx install goose-ai

Step 4: Start a session — From your terminal, navigate to the directory you’d like to start from and run:

goose session start

Goose works with your preferred LLM. By default, it uses openai as the LLM provider. You’ll be prompted to set an API key.

What Are “plan.md”Files?

The plan.md file is a text file that serves as a blueprint for Goose to follow. It consists of two essential components:

  • A kickoff message that sets the context and overall goal
  • A structured list of tasks for Goose to execute.

Why Use plan.md file?

  • Customization: You can tailor Goose’s actions for specific tasks or projects.

  • Reusability: Templates make it easy to reuse and modify plans for similar goals.

  • Clarity: Outlining goals and steps ensures better control and predictability.

Creating Your First plan.md File

Let’s say you want Goose to help set up a new design system. Here’s an example of how your plan.md might look:

# Design System Setup Plan for AwesomeApp

## Goal
Set up a fresh design system for the AwesomeApp Redesign app's redesign.

---

## Steps to Follow

### 1. Create Folders
Organize design components into well-structured folders:
- **Buttons:** Include all button components and their states (default, hover, active, disabled).
- **Forms:** Include inputs, dropdowns, checkboxes, and radio buttons.
- **Colors:** Store primary, secondary, and accent color palettes.

### 2. Set Up Color Palette
Define a consistent color palette adhering to the brand guidelines:
- **Primary Color:** #3498db
- **Secondary Color:** #2ecc71
- **Accent Colors:** #e74c3c, #9b59b6, #f1c40f
- **Neutral Colors:** Add greys, whites, and blacks for backgrounds and borders.
- **Accessibility:** Ensure color contrast meets accessibility standards (WCAG).

### 3. Create Typography Styles
Define text styles for the app:
- **Headings:** 
  - H1 (32px)
  - H2 (24px)
  - H3 (20px)
- **Font Family:** Roboto, sans-serif
- **Font Sizes:** 
  - 12px
  - 14px
  - 16px
  - 18px
  - 24px
  - 32px

### 4. Design Button Components
Design the following button states:
- Default
- Hover
- Active
- Disabled

Ensure all buttons are:
- **Responsive:** Scalable across device sizes.
- **Accessible:** Incorporate clear focus states for keyboard navigation.

### 5. Create Form Elements
Design essential form components:
- Input Fields (default, focused, error)
- Dropdowns (expanded, collapsed)
- Checkboxes and Radio Buttons (checked, unchecked, disabled)
- Submit Buttons (loading, error)

---

## Additional Notes
- Test designs for usability and accessibility before finalizing.

Best Practices and Tips

  • Define Clear Goals: Ensure each plan starts with a clear objective.
  • Use Reusable Templates: Create general templates that can be customized for different projects.
  • Document Assumptions: Add comments or notes to explain placeholders and structure.
  • Test Small Changes: Validate each change in the plan.md file to ensure correct rendering.

Conclusion

The plan.md file is a versatile tool for guiding Goose’s execution in achieving your goals. By combining clear objectives, structured steps, and dynamic Jinja templating, you can create reusable and highly customizable plans. Whether you’re improving a mobile app’s UX or tackling a complex project, plan.md empowers you to provide clarity, adaptability, and precision to Goose.

FAQs

Q: What is the purpose of a plan.md file?

A: The plan.md file serves as a blueprint for Goose to follow, outlining goals and steps for the development process.

Q: How do I create a plan.md file?

A: You can create a plan.md file by outlining your goals and steps for the development process, using flexible text formatting and Jinja templating to create dynamic, reusable, and goal-oriented plans.

Q: Can I customize my plan.md file?

A: Yes, you can customize your plan.md file by adding or modifying sections, using Jinja templating to create dynamic, reusable, and goal-oriented plans.

Q: How do I use Jinja templating in my plan.md file?

A: You can use Jinja templating in your plan.md file by adding placeholders for variables and using Jinja syntax to render dynamic content.

Q: Can I reuse my plan.md file for different projects?

A: Yes, you can reuse your plan.md file for different projects by creating general templates that can be customized for different projects.

Latest stories

Read More

LEAVE A REPLY

Please enter your comment!
Please enter your name here