Agent Testing Guide

Sample prompts and validation checklists for testing the VS Code custom agents.

Prerequisites

Before You Test

  1. The codewiki-mcp MCP server must be running and configured in .vscode/mcp.json (included in this repo).
  2. All 6 .agent.md files must be in .github/agents/.
  3. Test in the VS Code Chat panel (Ctrl+Shift+I), not inline chat. The .agent.md custom agents only activate when invoked via @codewiki in the Chat panel. The runSubagent tool in regular Copilot chat does NOT wire up MCP tools to subagents.
  4. Custom agents only activate via @codewiki in the Chat panel.

Agent Configuration Reference

Current YAML frontmatter for each agent (must match .github/agents/ files):

Master Orchestrator (codewiki.agent.md)

name: CodeWiki
description: Master agent that routes your request to the right CodeWiki specialist
model: GPT-5.3-Codex
tools:
  [read, agent, codewiki-mcp/*]
agents:
  [CodeWiki Researcher, CodeWiki Code Review, CodeWiki Architecture Explorer, CodeWiki Comparison, CodeWiki Synthesizer]
⚠️ Model: The master must use a 1× credit model like GPT-5.3-Codex. Free/low-tier models (GPT-5 mini) produce inconsistent routing, truncated results, and skipped delegation.

Why codewiki-mcp/* on the master? The master must declare MCP tools so they are exposed to subagents when spawned. The master itself still acts as a router — it delegates via agent and does not call CodeWiki tools directly.

Subagents

# Researcher, Code Review, Architecture Explorer, Comparison:
model: GPT-5 mini
user-invokable: false
tools:
  [read, codewiki-mcp/*]

# Synthesizer (needs stronger reasoning for multi-repo integration):
model: GPT-5.3-Codex
user-invokable: false
tools:
  [read, codewiki-mcp/*]
Agent FileNameSpecialty
codewiki-researcher.agent.mdCodeWiki ResearcherGeneral exploration
codewiki-reviewer.agent.mdCodeWiki Code ReviewModule/function analysis
codewiki-architect.agent.mdCodeWiki Architecture ExplorerSystem design
codewiki-comparison.agent.mdCodeWiki ComparisonMulti-repo comparison
codewiki-synthesizer.agent.mdCodeWiki SynthesizerCombine parts from multiple repos

Routing Quick Reference

User IntentSubagentSignal Words
General explorationCodeWiki Researcher"what is", "explain", "tell me about", "overview"
Code analysisCodeWiki Code Review"review", "analyse", "module", "function", "code"
System designCodeWiki Architecture Explorer"architecture", "design", "structure", "hierarchy"
Multi-repo comparisonCodeWiki Comparison"compare", "vs", "difference", "or"
Multi-repo synthesisCodeWiki Synthesizer"combine", "merge", "build using", "take X from A and Y from B"
Unindexed repoCodeWiki ResearcherSubagent detects NOT_INDEXED and calls codewiki_request_indexing

1. CodeWiki Researcher (General Exploration)

Routing trigger: General "what is", "explain", "tell me about" questions.

Sample Prompts

@codewiki What is facebook/prophet and what are its main features?
@codewiki Explain the key concepts behind pallets/flask
@codewiki What topics does CodeWiki have for microsoft/vscode?
# Bare keyword — resolves automatically (v1.2.0+)
@codewiki What is prophet and what are its main features?

Expected Behaviour

StepWhat Should Happen
1Master spawns CodeWiki Researcher via the agent tool
2Researcher calls codewiki_list_topics to discover available wiki sections
3Researcher calls codewiki_read_structure and/or codewiki_read_contents
4Researcher synthesises a summary from CodeWiki content

Validation Checklist

2. CodeWiki Code Review (Module / Function Analysis)

Routing trigger: "review", "analyse", "what does module X do", code-level questions.

Sample Prompts

@codewiki Review the forecaster module in facebook/prophet — what does it do?
@codewiki What code patterns are used in the routing module of pallets/flask?
@codewiki Analyse the error handling approach in fastapi/fastapi

Expected Behaviour

StepWhat Should Happen
1Master spawns CodeWiki Code Review via the agent tool
2Reviewer calls codewiki_search_wiki to find relevant code documentation
3Reviewer calls codewiki_read_contents for detailed section content
4Reviewer provides code-level analysis with citations

Validation Checklist

3. CodeWiki Architecture Explorer (System Design)

Routing trigger: "architecture", "design", "how is X structured", "component hierarchy".

Sample Prompts

@codewiki Explain the overall architecture of facebook/react
@codewiki How is the plugin system architected in vitejs/vite?
@codewiki Describe the component hierarchy and data flow in vuejs/core

Expected Behaviour

StepWhat Should Happen
1Master spawns CodeWiki Architecture Explorer via the agent tool
2Explorer calls codewiki_read_structure to map the documentation tree
3Explorer calls codewiki_read_contents for architecture-related sections
4Explorer produces a structured architecture overview

Validation Checklist

4. CodeWiki Comparison (Multi-Repo)

Routing trigger: "compare", "vs", "difference between", "X or Y".

Sample Prompts

@codewiki Compare fastapi/fastapi vs pallets/flask — architecture, performance, and developer experience
@codewiki Compare facebook/react vs vuejs/core in terms of rendering strategy
@codewiki What are the differences between expressjs/express and koajs/koa?

Expected Behaviour

StepWhat Should Happen
1Master spawns CodeWiki Comparison via the agent tool
2Comparison agent calls CodeWiki tools for each repo independently
3Agent builds a side-by-side analysis from real documentation
4Agent produces a structured comparison table or narrative

Validation Checklist

5. Request Indexing (Unindexed Repo — Subagent Handles It)

Routing trigger: Repo that returns NOT_INDEXED from any CodeWiki tool.

New in v1.3.0: The tool now uses MCP Elicitation to confirm with the user before submitting an indexing request.

Sample Prompts

@codewiki Check if Snowflake-Labs/agent-world-model is available on CodeWiki
@codewiki What does CodeWiki have for some-org/obscure-repo?

Expected Behaviour

StepWhat Should Happen
1Master classifies this as a general exploration request
2Master spawns CodeWiki Researcher via the agent tool
3Researcher calls a CodeWiki tool and gets NOT_INDEXED error
4Researcher calls codewiki_request_indexing to submit the repo
5Server asks user for confirmation via MCP Elicitation (v1.3.0+)
6Researcher reports back; Master presents the full result to user

Validation Checklist

6. CodeWiki Synthesizer (Multi-Repo Solution Building)

Routing trigger: User wants to BUILD something new by combining parts from multiple repos. Distinct from Comparison which evaluates/contrasts.

Sample Prompts

@codewiki I want to build an API server that uses the routing system from pallets/flask and the async handling from fastapi/fastapi. Help me design it.
@codewiki Take the plugin architecture from vitejs/vite and the component model from vuejs/core — design a new framework that combines both.
@codewiki Combine the authentication approach from supabase/supabase with the event pipeline from apache/kafka into a real-time auth notification system.
# Intentionally vague — Synthesizer should DISCOVER which parts to take
@codewiki Can you combine the best parts from fastapi/fastapi and pallets/flask into a new web framework solution?

Expected Behaviour

StepWhat Should Happen
1Master detects synthesis intent (“build”, “combine”, “take X from A and Y from B”)
2Master spawns CodeWiki Synthesizer via the agent tool
3Synthesizer researches each repo using CodeWiki tools (read_structure, read_contents, search_wiki)
4Synthesizer extracts the specific parts the user requested from each repo
5Synthesizer identifies cross-repo conflicts and proposes adapters
6Synthesizer delivers a blueprint: architecture diagram, directory structure, integration code, implementation guide
7For vague requests: Synthesizer shows a “Parts Selected” table explaining WHY it chose each part

Validation Checklist

7. Keyword Resolution & Disambiguation (Bare Product Names)

Routing trigger: Any prompt using a bare keyword instead of owner/repo format.

Sample Prompts

@codewiki What is vue?
@codewiki Explain the architecture of react
@codewiki Compare vue vs react
@codewiki What topics does openclaw have?

Expected Behaviour

StepWhat Should Happen
1Master delegates to the appropriate subagent (Researcher, Comparison, etc.)
2Subagent calls a CodeWiki tool with the bare keyword (e.g. repo_url="vue")
3Tool detects bare keyword and triggers MCP Elicitation (if multiple ambiguous repos found)
4VS Code shows a selection prompt: “Multiple repositories match 'vue'. Which do you want?”
5User selects the desired repo (e.g. vuejs/core for Vue 3)
6Response includes resolution note: > Resolved: keyword "vue" → vuejs/core (52,900★)
7Response shows top alternative candidates
8The rest of the response contains normal CodeWiki documentation
Auto-select (no elicitation):
  • Canonical match: “openclaw” → openclaw/openclaw (owner == repo == keyword)
  • Single result: only one repo found → auto-selected

Fallback: If elicitation is unavailable (client doesn’t support it), heuristic selection by star count is used.

Validation Checklist

Full Workflow Scenario

This single prompt is designed to trigger all 5 workflow steps (Discover → Navigate → Read → Search → Synthesize) of the Researcher subagent.

Multi-Step Scenario Prompt

@codewiki I want a deep technical explanation of the React Compiler's
compilation pipeline.

Specifically:
1. First, check what topics Google CodeWiki has for facebook/react.
2. Then look at the full table of contents to find sections about
   the compiler.
3. Read the section on "React Compiler Internals" to understand the
   multi-stage compilation pipeline, the IRs (HIR and ReactiveFunction),
   and the key optimization passes.
4. Search for "How does the React Compiler handle memoization and
   reactive scopes?" to get implementation-level details.
5. Combine everything into a single technical summary that covers:
   - The overall compilation pipeline (AST → HIR → ReactiveFunction → codegen)
   - The key intermediate representations and their purpose
   - How reactive scopes are inferred and merged
   - How the compiler replaces manual useMemo/useCallback
   - Cite which CodeWiki sections your answer comes from

Expected Tool Calls

StepPhaseTool CallPurpose
1Discovercodewiki_list_topics("facebook/react")Verify wiki exists, see available topics
2Navigatecodewiki_read_structure("facebook/react")Get full ToC with section hierarchy
3Readcodewiki_read_contents("facebook/react", "React Compiler Internals")Fetch detailed compiler pipeline docs
4Searchcodewiki_search_wiki("facebook/react", "How does the React Compiler handle memoization?")Get Gemini-powered implementation details
5Synthesize(no tool call — agent combines results)Produce cited summary from steps 1-4

Full Workflow Validation

Alternative Repos for Testing

If a repo is too large or slow during testing, try these. You can use bare keywords (v1.2.0+) — the server resolves them automatically:

InputResolves ToNotes
anthropics/anthropic-sdk-pythonexact matchFast wiki generation, good for quick tests
fastapifastapi/fastapiBare keyword — well-indexed, good for architecture + review tests
prophetfacebook/prophetBare keyword — good for researcher + review tests
vscodemicrosoft/vscodeBare keyword — large repo, may be slower
microsoft/vscode-copilot-chatexact matchMicrosoft tooling

See also: Agentic AI Guide — full agent definitions, architecture, and lessons learned.