Updated for VS Code 1.113: The Agent Debug panel includes
/troubleshoot, export/import, Agent Flow Chart visualization, and support for Copilot CLI and Claude agent sessions in addition to local sessions.
This guide tracks behavior documented in official VS Code/Copilot sources.
References:
- VS Code release notes:
https://code.visualstudio.com/updates - VS Code 1.112 Release Notes:
https://code.visualstudio.com/updates/v1_112 - VS Code 1.113 Release Notes:
https://code.visualstudio.com/updates/v1_113 - VS Code Copilot customization docs:
https://code.visualstudio.com/docs/copilot/customization/overview - Agent Debug Logs docs:
https://code.visualstudio.com/docs/copilot/chat/chat-debug-view - GitHub Copilot docs:
https://docs.github.com/copilot
The Agent Debug panel gives you deeper insight into how Accessibility Agents work within VS Code. It replaces the old Diagnostics action with a richer, more detailed view that helps you understand and troubleshoot your agent configuration.
The panel shows chat events as they happen:
- Chat customization events - When skills, prompts, hooks, agents are loaded
- System prompts - The actual prompts sent to the model
- Tool calls - Which tools agents invoke and their results
- Hook execution - When
PreToolUse,PostToolUse, and other hooks fire - Session lifecycle - Session creation, context compaction, forking
See exactly which Accessibility Agents customizations are active:
- ✅ Loaded agents (accessibility-lead, aria-specialist, forms-specialist, etc.)
- ✅ Active skills (markdown-accessibility, cognitive-accessibility, web-severity-scoring, etc.)
- ✅ Applied workspace instructions (web-accessibility-baseline, semantic-html, aria-patterns)
- ✅ Hook execution order and timing
- ✅ Prompt files invoked
Visual hierarchy showing:
- Event sequence and timing
- Tool call dependencies
- Hook trigger chain
- Context compaction points
Method 1: Command Palette
- Press
Ctrl+Shift+P(Windows) orCmd+Shift+P(Mac) - Type "Developer: Open Agent Debug Panel"
- Press Enter
Method 2: Chat View
- Click the gear icon at the top of the Chat view
- Select "View Agent Logs"
When you start a chat session in a web project:
- Open the Agent Debug panel
- Look for
UserPromptSubmithook event - this should show the accessibility-lead delegation instruction firing - Check for loaded agents - you should see accessibility-lead and specialist agents like aria-specialist, forms-specialist, keyboard-navigator
- Verify workspace instructions are loaded - web-accessibility-baseline.instructions.md, semantic-html.instructions.md, aria-patterns.instructions.md
What to look for:
✅ Hook: UserPromptSubmit
→ Action: Inject accessibility-lead delegation
→ Status: Executed
✅ Agents loaded: 25
- accessibility-lead
- aria-specialist
- forms-specialist
- keyboard-navigator
- modal-specialist
- contrast-master
... (more)
✅ Instructions loaded: 3
- web-accessibility-baseline.instructions.md
- semantic-html.instructions.md
- aria-patterns.instructions.md
✅ Skills loaded: 17
- framework-accessibility
- cognitive-accessibility
- markdown-accessibility
- web-severity-scoring
... (more)
If you're unable to edit UI files, the debug panel shows why:
- Look for
PreToolUsehook events - Check if
permissionDecision: "deny"appears for Edit/Write operations on.jsx,.tsx,.vue,.css,.htmlfiles - Verify if the session marker exists (set by
PostToolUseafter accessibility-lead completes)
Troubleshooting edit gate issues:
⚠️ Hook: PreToolUse
→ Tool: editFile
→ File: src/components/Button.tsx
→ Decision: deny
→ Reason: accessibility-lead review not completed
✅ Next step: Invoke @accessibility-lead to unlock edit gate
The three-hook enforcement flow should appear as:
Hook 1: UserPromptSubmit (Proactive detection)
Event: UserPromptSubmit
Trigger: User sent message "fix the styling"
Action: Inject accessibility delegation instruction
Framework detected: React (package.json, *.jsx files)
Result: Delegation instruction added to promptHook 2: PreToolUse (Edit gate)
Event: PreToolUse
Tool: editFile
Target: src/App.jsx
Session marker present: false
Decision: deny
Message: Please consult @accessibility-lead before editing UI filesHook 3: PostToolUse (Session marker)
Event: PostToolUse
Agent: accessibility-lead
Action: Create session marker
Result: Edit gate unlocked for remainder of sessionWhen accessibility-lead runs, you'll see tool invocations:
readFile- Reading component files for reviewgrepSearch- Searching for ARIA patterns, keyboard handlerssemanticSearch- Finding related accessibility codeaskQuestions- Interactive clarification from youscreenshotPage- Visual verification (if browser tools enabled)evaluatePage- Running axe-core audits
During long audits, watch for:
Event: ContextCompaction
Trigger: Manual (/compact) or Automatic (context limit)
Before: 45,000 tokens
After: 12,000 tokens
Summary: Audit findings preserved, implementation details compactedSymptoms in Debug Panel:
⚠️ Agents loaded: 0
⚠️ Instructions loaded: 0
Solutions:
- Verify
.github/agents/*.agent.mdfiles exist - Check
.github/copilot-instructions.mdexists - Reload VS Code window
- Check extension status: GitHub Copilot and GitHub Copilot Chat should be enabled
Symptoms in Debug Panel:
✅ Hook: UserPromptSubmit registered
⚠️ No execution events
Solutions:
- Verify hooks are enabled in settings (check for disabled hooks)
- Check workspace trust - hooks may be disabled in untrusted workspaces
- Update to latest VS Code and Copilot extensions
Symptoms in Debug Panel:
Event: PreToolUse
Decision: deny
File: src/utils/api.ts (backend logic, not UI)Solution: The edit gate uses file extension patterns. If it's blocking non-UI files incorrectly, this is a false positive. Report it as an issue so we can refine the pattern matching.
Symptoms in Debug Panel:
✅ Skills directory exists: .github/skills/
⚠️ Skills loaded: 0
Solutions:
- Verify
.github/skills/**/SKILL.mdfiles have valid YAML frontmatter - Check
name:anddescription:fields are present - Ensure no syntax errors in SKILL.md files
- Reload window after adding new skills
The chart view shows event hierarchy. For a typical Accessibility Agents session:
Session Start
├─ UserPromptSubmit Hook
│ └─ Inject delegation instruction
├─ Load Customizations
│ ├─ 25 agents
│ ├─ 25 skills
│ └─ 3 workspace instructions
├─ Agent: accessibility-lead invoked
│ ├─ Tool: readFile (component)
│ ├─ Tool: grepSearch (aria patterns)
│ ├─ Tool: askQuestions (clarification)
│ └─ Response generated
├─ PostToolUse Hook
│ └─ Create session marker
└─ PreToolUse Hook (next edit)
└─ Decision: allow (marker present)
Use the debug panel to measure:
- Hook execution time - Should be < 100ms
- Agent initialization - How long it takes to load all 25+ agents
- Tool call latency - Time for readFile, grepSearch, etc.
- Context compaction time - How long summarization takes
Performance tips:
- Long hook execution (> 500ms) may indicate file I/O issues
- Slow agent loading suggests too many agents or large agent files
- High tool call latency points to slow file reads or searches
The Agent Debug panel is in preview as of VS Code 1.110. Share feedback:
- Preview feature - The Agent Debug Log panel remains in preview
- Broader session coverage - Support now extends beyond local sessions to Copilot CLI and Claude agent sessions
No log persistence - Logs clear when VS Code restarts(Fixed in 1.112 with export/import)No export - Cannot save logs for sharing or offline analysis(Fixed in 1.112)
Type /troubleshoot in chat followed by a question to analyze agent debug logs directly in the conversation. This is ideal for debugging why Accessibility Agents customizations aren't loading.
Enable required settings:
{
"github.copilot.chat.agentDebugLog.enabled": true,
"github.copilot.chat.agentDebugLog.fileLogging.enabled": true
}Example queries:
/troubleshoot why isn't web-accessibility-baseline.instructions.md loading?
/troubleshoot list all paths you tried to load customizations
/troubleshoot how many tokens did you use?
/troubleshoot which tools were invoked for the last audit?
The /troubleshoot skill reads the JSONL debug log files and provides insights into:
- Why tools or subagents were used or skipped
- Why instructions or skills did not load
- What contributed to slow response times
- Whether network connectivity problems occurred
The Agent Debug panel now supports Copilot CLI and Claude agent sessions in addition to local sessions.
This matters for Accessibility Agents because you can now debug:
- why a CLI or Claude session did not load workspace instructions
- whether MCP tools were available across agent types
- how subagent orchestration behaved outside the local editor workflow
The Summary view is now more useful as a cross-surface troubleshooting entry point:
- inspect total tool calls, duration, token usage, and errors
- jump from the summary into the Agent Flow Chart
- attach debug events back into chat for follow-up analysis
- Enable Agent Debug Logs.
- Reproduce the problem in the relevant surface: local, Copilot CLI, or Claude agent.
- Open the Agent Debug panel and check discovery events for instructions, agents, skills, hooks, and MCP tools.
- If needed, attach debug events to chat or use
/troubleshootto ask why a customization was skipped.
You can now save agent debug sessions for offline analysis or team sharing.
To export:
- Open the Agent Debug Logs panel
- Navigate to the session you want to export
- Click the Export icon (download) in the top-right toolbar
- Save as a JSONL file (OTLP format)
To import:
- Click the Import icon (upload) in the Agent Debug Logs panel
- Select a previously exported JSONL file
- The session opens with full overview and metrics
Use cases for Accessibility Agents:
- Share debug sessions when reporting issues with agent loading
- Save audit sessions for compliance documentation
- Compare hook execution between different configurations
- Analyze slow accessibility scans offline
Note: Files larger than 50 MB trigger a warning. Export shorter sessions or trim large files.
The new Agent Flow Chart view visualizes the sequence of events and interactions between agents, making complex orchestrations easier to understand.
To open:
- Open the Agent Debug Logs panel
- Select the session description in the breadcrumb
- Click Agent Flow Chart from the Summary view
What it shows for Accessibility Agents:
┌─────────────────────┐
│ User Prompt │
└─────────┬───────────┘
│
▼
┌─────────────────────┐
│ UserPromptSubmit │ ← Inject delegation instruction
│ Hook │
└─────────┬───────────┘
│
▼
┌─────────────────────┐
│ accessibility-lead │ ← Orchestrator agent
└─────────┬───────────┘
│
┌─────┴─────┬─────────────┐
▼ ▼ ▼
┌────────┐ ┌────────────┐ ┌────────────┐
│aria │ │keyboard │ │contrast │
│special │ │navigator │ │master │
└────────┘ └────────────┘ └────────────┘
│
▼
┌─────────────────────┐
│ PostToolUse Hook │ ← Create session marker
└─────────────────────┘
You can pan/zoom the chart and click any node to see event details.
The Summary view shows aggregate statistics for the chat session:
- Total tool calls
- Token usage (input/output)
- Error count
- Overall duration
- Breakdown by agent
Access it: Select the session description in the breadcrumb at the top of the Agent Debug panel.
| View | Purpose |
|---|---|
| Logs | Chronological event list with filtering |
| Summary | Aggregate statistics for the session |
| Agent Flow Chart | Visual sequence diagram |
You can attach a snapshot of debug events to a chat conversation:
- Open the Logs view for your session
- Click the sparkle icon in the top-right
- The Chat view opens with debug events attached
This lets you ask questions about the current session directly, such as "which accessibility agents were invoked?" or "why did the ARIA check fail?"
- Lifecycle Hooks Guide - Deep dive on the three-hook enforcement system
- Context Management Guide - Using
/compacteffectively - Agent Customization - Creating custom agents and skills
- VS Code Agent Documentation