Skip to content

thorbeck/vs-code-ai-toolkit

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 

Repository files navigation

VS Code AI Toolkit

This repository contains custom agents, prompt files, and configurations for GitHub Copilot in VS Code.

Prompt Files

Reusable prompt templates for common TypeScript and web development tasks. Located in .github/prompts/.

Available Prompts

  • fast-refactor-plan.prompt.md - Quick existing-code planning prompt that defaults to near-zero research and immediate implementation steps

How to Use Prompts

In VS Code Copilot Chat, reference a prompt file using #file:

#fast-refactor-plan.prompt.md split HTTP mapping logic out of the user service

Or use the file picker in chat:

  1. Type # in the chat input
  2. Select the prompt file
  3. Add your specific request

Prompts provide consistent structure and ensure best practices are followed automatically.

Example: Fast Refactor Planning

Use the prompt when you want a direct plan for existing code with low overhead:

#fast-refactor-plan.prompt.md refactor the user service to isolate API mapping from domain logic

This will:

  1. Start planning without a discovery pass by default
  2. Produce a short, implementation-ready step list
  3. Name the first concrete edit and validation checks

Custom Agents

Plan Fast

A pragmatic planning agent that skips extensive research and gets straight to actionable implementation steps.

Use this when:

  • You want to start coding quickly
  • The requirements are relatively clear
  • You prefer to iterate and refine as you go
  • You're prototyping or exploring solutions

Don't use this when:

  • The task is complex with many unknowns
  • You need comprehensive analysis of trade-offs
  • Multiple stakeholders need detailed documentation
  • The project is mission-critical and requires thorough planning

How to Use

  1. Open the Chat view in VS Code (Ctrl+Alt+I)
  2. Select Plan-Fast from the agents dropdown
  3. Enter your task or feature request
  4. Review the quick plan
  5. Use the "Start Implementation" handoff to begin coding

Key Differences from Default Plan Agent

Feature Plan Fast Default Plan Agent
Research phase Minimal Comprehensive
Analysis depth Quick assumptions Thorough investigation
Plan length Brief, actionable Detailed, complete
Clarifying questions Rare (only if blocking) Frequent
Time to plan ~1-2 minutes ~5-10 minutes
Best for Quick starts, prototypes Complex features, team planning

Example

Input: "Add dark mode toggle to the app"

Plan Fast Output:

Quick Summary: Add a dark mode toggle that switches between light and dark themes.

Implementation Steps:
1. Add theme state management (React context or Zustand store)
2. Create dark mode CSS variables in :root and [data-theme="dark"]
3. Build toggle component (moon/sun icon, stores preference)
4. Apply theme class to root element based on state
5. Persist theme preference to localStorage
6. Add tests for theme switching

Quick Notes:
- Use CSS custom properties for easy theme switching
- Default to system preference (prefers-color-scheme)

Customization

To customize the Plan Fast agent, edit .github/agents/plan-fast.agent.md:

  • Tools: Add or remove tools like fetch, githubRepo, etc.
  • Model: Change to a different language model
  • Instructions: Modify the planning approach and output format
  • Handoffs: Add custom handoff targets

Installation

Custom agents and prompt files are automatically available in VS Code when you have this workspace open. VS Code detects:

  • .agent.md files in the .github/agents folder
  • .prompt.md files in the .github/prompts folder

Contributing

Feel free to create additional prompts and agents for different workflows:

Prompt Ideas:

  • Database migration generators
  • React component scaffolding
  • API documentation generation
  • Security vulnerability scanning
  • Performance optimization suggestions

Agent Ideas:

  • Security review agents
  • Documentation agents
  • Testing agents
  • Refactoring specialists

Agent Skills (New in VS Code 1.108)

Agent Skills are folders of instructions, scripts, and resources that GitHub Copilot loads on-demand to perform specialized tasks. They're an open standard that works across VS Code, Copilot CLI, and the coding agent.

How Skills Work

Skills use progressive disclosure - Copilot knows which skills are available but only loads the instructions and resources when they're relevant to your task. This means you can install dozens of skills without bloating context.

Available Skills

Located in .github/skills/:

  • fast-refactor-planning - On-demand skill for quick existing-code planning with near-zero research and concise execution steps.

Enabling Skills

Agent Skills are experimental in VS Code 1.108. Enable them in settings:

{
  "chat.useAgentSkills": true
}

Or use the VS Code settings UI:

  1. Open Settings (Ctrl+,)
  2. Search for "agent skills"
  3. Enable "Chat: Use Agent Skills"

How to Use Skills

Skills activate automatically based on your prompts - no manual selection needed. Just ask questions related to the skill's domain:

Example - Refactor Planning:

Give me a quick refactor plan to extract data mapping from this service without changing behavior.

→ Loads the fast-refactor-planning skill when skills are enabled

Creating Your Own Skills

Each skill needs a SKILL.md file with frontmatter:

---
name: my-skill-name
description: Clear description of what this skill does and when to use it
---

# My Skill Name

Detailed instructions, guidelines, and examples...

Place skills in .github/skills/skill-name/SKILL.md.

Skills vs Custom Instructions

Aspect Agent Skills Custom Instructions
When to load On-demand, based on context Always active
Can include Instructions + scripts + resources Instructions only
Portability Works across VS Code, CLI, coding agent VS Code and GitHub.com only
Best for Specialized workflows and capabilities Project coding standards

Prompt vs Skill vs Custom Agent

Use this quick guide when choosing how to implement Copilot behavior:

Option Best For Invocation Discovery Depth
Prompt file Repeatable one-off tasks with explicit user intent Manual (#file) Whatever the prompt defines
Skill Specialized capability that should load on-demand by topic Automatic when relevant Focused, domain-specific
Custom agent Deterministic working mode (for example, fast planning every time) Agent picker Enforced by agent instructions

Recommended Fast Planner Setup

  • Primary: Custom agent (.github/agents/plan-fast.agent.md) for predictable, generic existing-code planning with near-zero research.
  • Companion: Prompt file (.github/prompts/fast-refactor-plan.prompt.md) for explicit quick-plan requests.
  • Companion: Skill (.github/skills/fast-refactor-planning/SKILL.md) to auto-load refactor planning behavior when relevant.

Resources

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published