Code tour

SkillFiles & storage

Create CodeTour .tour JSON files that guide a persona through real repository files, directories, line numbers, selections, patterns, URIs, views, and VS Code commands. Use when asked to create a tour, make a code tour, generate an onboarding tour, PR review tour, bug tour, RCA tour, architecture tour, vibe check, contributor guide, or structured code walkthrough.

Use Code tour in Claude, ChatGPT or Ahel Desktop

Free. Sign in, add Code tour and connect your AI. About a minute.

Also: Claude Code · Cursor · Codex

Then ask your AI: use the Code tour skill

Details

Instructions available. Your AI can read the instructions. Execution depends on the setup they require.

Add ahel to your AI once: Claude, ChatGPT, Cursor, Claude Code or Codex. Then ask it to use this.

Code tourStart free

What this skill tells your AI

The instructions your AI receives, as published by gbb-acelerators/awesome-harness-primitives in harness/claude-code/skills/code-tour/SKILL.md and read by ahel’s review.

Create a persona-targeted CodeTour .tour file in .tours/ that links to verified repository files, line numbers, directories, selections, patterns, URIs, views, or VS Code commands and validates against the bundled schema and validator.

When to invoke

  • "Create a tour for this repository."
  • "Make an onboarding code tour for a new joiner."
  • "Generate a PR review tour for this branch."
  • "Explain how this feature works as a CodeTour."
  • "Make a vibe check, bug tour, RCA tour, architecture tour, or contributor guide."

Prerequisites and context

  • CodeTour files live in .tours/ and use the VS Code CodeTour extension: https://github.com/microsoft/codetour.
  • Only create .tour JSON files. Never create, modify, or scaffold source files, .vscode/settings.json, docs, or any other files unless the user explicitly changes the task.
  • Every path and line number in the tour must be verified by reading the actual file.
  • Use references/codetour-schema.json as the authoritative field list.
  • Run python harness/github-copilot/skills/code-tour/scripts/validate_tour.py .tours/<name>.tour --repo-root . after writing a tour in this repository. In installed skill locations, the same script may be under ~/.agents/skills/code-tour/scripts/validate_tour.py.

Progressive disclosure and bundled resources

Read or execute bundled resources only when needed.

ResourceUse it when
references/codetour-schema.jsonVerifying every root or step field, type, and allowed shape before writing JSON.
references/examples.mdStudying commands, selection, view, pattern, isPrimary, nextTour, and multi-tour series techniques.
scripts/validate_tour.pyValidating JSON, file/directory existence, line bounds, pattern matches, nextTour cross-references, and narrative arc.
scripts/generate_from_docs.pyThe user asks to generate from README or docs; create a skeleton, then fill every [TODO: ...] from real code.

Useful commands:

python harness/github-copilot/skills/code-tour/scripts/generate_from_docs.py --persona new-joiner --output .tours/skeleton.tour
python harness/github-copilot/skills/code-tour/scripts/validate_tour.py .tours/<name>.tour --repo-root .
python ~/.agents/skills/code-tour/scripts/generate_from_docs.py --persona new-joiner --output .tours/skeleton.tour
python ~/.agents/skills/code-tour/scripts/validate_tour.py .tours/<name>.tour --repo-root .

Procedure

  1. Discover the repo before asking questions: list the root, read the README, check key config files, map folders 1-2 levels deep, identify languages and frameworks, and find entry points.
  2. Infer persona, depth, focus, ref, isPrimary, nextTour, uri, required files, and requested customizations from the user's first message. Ask only when the target bug, feature, or required file cannot be inferred.
  3. Read every planned file and directory. Verify every file, directory, line, selection, and pattern before writing.
  4. Write one .tours/<persona>-<focus>.tour JSON file. Use kebab-case names such as onboarding-new-joiner.tour, bug-fixer-payment-flow.tour, architect-overview.tour, vibecoder-quickstart.tour, pr-review-auth-refactor.tour, security-auth-boundaries.tour, concept-dependency-injection.tour, or rca-login-outage.tour.
  5. Validate with scripts/validate_tour.py. Fix every error. Use judgment on warnings, but never ignore invalid paths, invalid JSON, out-of-bounds lines, of-bounds validation wording, unmatched patterns, or broken nextTour references.
  6. Summarize the tour path, persona, coverage, vscode.dev URL for public repos, suggested follow-up tours, and any requested files that did not exist.

Repository discovery

Start with entry points; do not read everything in large repositories.

StackEntry points to read first
Node.js / TSindex.js, index.ts, server.js, app.js, src/main.ts, package.json scripts
Pythonmain.py, app.py, __main__.py, manage.py, app/__init__.py
Gomain.go, cmd/<name>/main.go, internal/
Rustsrc/main.rs, src/lib.rs, Cargo.toml
Java / Kotlin*Application.java, src/main/java/.../Main.java, build.gradle
Rubyconfig/application.rb, config/routes.rb, app/controllers/application_controller.rb
PHPindex.php, public/index.php, bootstrap/app.php
Repo typeEmphasizeTypical anchor files
Service / APIRequest lifecycle, auth, error contractsrouter, middleware, handler, schema
Library / SDKPublic API surface, extension points, versioningindex/exports, types, changelog
CLI toolCommand parsing, config loading, output formattingmain, commands/, config
MonorepoPackage boundaries, shared contracts, build graphroot package.json, pnpm-workspace, shared/, packages/
FrameworkPlugin system, lifecycle hooks, escape hatchescore/, plugins/, lifecycle
Data pipelineSource → transform → sink, schema ownershipingest/, transform/, schema/, dbt models
Frontend appComponent hierarchy, state management, routingpages/, store/, router, api

For repos with 100+ files: read entry points and README, build a map of the top 5-7 modules, deeply read only the 2-3 modules that matter to the persona, mention out-of-scope areas in the intro, and use directory steps for areas you mapped but did not read. A focused 10-step tour beats a scattered 25-step tour.

Intent and persona mapping

User saysPersonaDepthTour focus
"tour for this PR", "PR review", "#123"pr-reviewerstandardAdd uri step for the PR, set ref for the branch, cover changed files first, then unchanged-but-critical files, close with reviewer checklist.
"why did X break", "RCA", "incident"rca-investigatorstandardCausality chain, side effects, race conditions, observability, not happy path.
"debug X", "bug tour", "find the bug"bug-fixerstandardUser action → trigger → fault points → tests.
"onboarding", "new joiner", "ramp up"new-joinerstandardDirectories, setup, business context, service boundaries.
"quick tour", "vibe check", "just the gist"vibecoderquick5-8 steps, entry point, request flow, main modules.
"explain how X works", "feature tour"feature-explainerstandardUI → API → backend → storage, feature flags, edge cases.
"architecture", "tech lead", "system design"architectdeepBoundaries, design tradeoffs, risk hotspots.
"security", "auth review", "trust boundaries"security-reviewerstandardAuth flow, input validation, secret handling, sensitive sinks.
"refactor", "safe to extract?"refactorerstandardSeams, hidden dependencies, coupling hotspots, safe extraction order.
"performance", "bottlenecks", "slow path"performance-optimizerstandardHot path, N+1, I/O, caches.
"contributor", "open source onboarding"external-contributorquickSafe areas, conventions, architecture landmines.
"concept", "explain pattern X"concept-learnerstandardConcept → implementation → rationale.
"test coverage", "where to add tests"test-writerstandardContracts, seams, coverage gaps.
"how do I call the API"api-consumerstandardPublic surface, auth, error semantics.

Honor explicit customizations: required files such as src/auth.ts and config/db.yml, tags or commits such as v2.3.0 and abc123, PR URLs, nextTour titles, isPrimary: true, terminal focus via commands: ["workbench.action.terminal.focus"], and requested depth or step count.

Tour JSON structure

{
  "$schema": "https://aka.ms/codetour-schema",
  "title": "Descriptive Title — Persona / Goal",
  "description": "One sentence: who this is for and what they'll understand after.",
  "ref": "main",
  "isPrimary": false,
  "nextTour": "Title of follow-up tour",
  "when": "workspaceFolders[0].name === 'api'",
  "stepMarker": "CT",
  "steps": []
}

Omit fields that do not apply. when is a JavaScript expression evaluated at runtime; it controls whether a tour is shown. stepMarker uses source comments such as // CT so CodeTour can find anchors when line numbers shift; do not suggest it unless the user asks because it requires editing source files.

Step design

All step types: content, directory, file + line, selection, pattern, uri, view, and commands.

SituationStep typeRules
Intro or closingcontentAt most 2 content-only steps. Step 1 must not be content-only.
Orient to a folderdirectoryPath relative to repo root, no leading / or ./, confirmed to exist.
Highlight one linefile + lineWorkhorse step. Verify file exists and line is in bounds.
Explain a function or class bodyselectionUse when a block matters more than one line.
Anchor volatile codepatternRegex must compile and match a real line in the file.
Provide PR, issue, or doc contexturiComplete real URL beginning with https://; examples include https://{example-url}.
Focus a VS Code panelviewUse sparingly for Explorer, terminal, or source-control context.
Run VS Code commandscommandsVS Code commands only; not arbitrary shell commands.

Narrative arc

  1. Orientation: must be a file, directory, or uri step, never content-only. Use README.md line 1 or a key directory and put welcome text in the description. A content-only first step renders blank in VS Code CodeTour.
  2. High-level map: 1-3 directory or URI steps for major modules.
  3. Core path: file/line, selection, pattern, and URI steps that tell the specific story.
  4. Closing: a content step that says what the reader can now do, what to avoid, and 2-3 follow-up tours. If nextTour is set, reference it by exact title.

Step count calibration

DepthTotal stepsCore path stepsUse for
Quick5-83-5Vibecoder, external-contributor fast path
Standard9-136-9Most personas
Deep14-1810-13Architect, RCA, detailed tradeoffs
Repo sizeRecommended standard depth
Tiny, <20 files5-8 steps
Small, 20-80 files8-11 steps
Medium, 80-300 files10-13 steps
Large, 300+ files12-15 steps scoped to the relevant subsystem

Use the SMIG formula in every description: Situation, Mechanism, Implication, Gotcha. Tell the persona what matters, how it works, why it matters for their goal, and what a smart reader might get wrong.

Real-world references

Fetch a real .tour when you need a concrete example instead of writing from memory.

What to studyURL
directory + file+line contributor onboardinghttps://github.com/coder/code-server/blob/main/.tours/contributing.tour
selection + file+line + intro content stephttps://github.com/a11yproject/a11yproject.com/blob/main/.tours/code-tour.tour
Minimal tutorial with tight file+line narrationhttps://github.com/lostintangent/rock-paper-scissors/blob/master/main.tour
Search for more .tour fileshttps://github.com/search?q=path%3A**%2F*.tour+&type=code

Raw content tip: prefix raw.githubusercontent.com and drop /blob/ for raw JSON access. For public repositories, users can open tours at https://vscode.dev/github.com/<owner>/<repo>.

Limits

RequestReality
Auto-advance to next step after X secondsNot supported. Navigation is manual; there is no timer, delay, or autoplay step mechanic.
Embed a video or GIF in a stepNot supported. Descriptions are Markdown text only.
Run arbitrary shell commandsNot supported. commands executes VS Code commands, for example workbench.action.terminal.focus, not shell commands.
Branch or conditional next stepNot supported. Tours are linear. when controls whether a tour is shown, not which step follows.
Show a first step without opening a filePartially supported, but do not do it. Step 1 needs a file, directory, or URI anchor.

isPrimary: true plus .vscode/settings.json containing { "codetour.promptForPrimaryTour": true } prompts on repo open, but this skill must not create or modify .vscode/settings.json unless the user explicitly requests it. Omit ref for tours intended to appear on any branch.

Gotchas

  • Line number guessing is forbidden: a tour pointing to the wrong line is worse than no tour.
  • No absolute or ./ paths: file and directory paths must be relative to repo root.
  • A content-only first step renders blank: anchor step 1 to a real file, directory, or URI.
  • A file listing is not a tour: each step should depend on the previous step and serve the persona's goal.
  • nextTour must match exactly: it must equal the title of another .tour file in .tours/.
  • Commands are not shell commands: use commands only for VS Code command IDs.
  • Do not hallucinate files: if a user-requested file does not exist, report it explicitly.

Schema vocabulary and exact field examples

Keep these CodeTour field examples available when the user requests them: "file", "directory", "directory": "src", "file": "README.md", "line": 1, "ref", "ref": "v2.3.0", "isPrimary": true, "nextTour": "Security Review", "stepMarker": "CT", // <stepMarker>, and "commands": ["workbench.action.terminal.focus"].

Use these exact package and workflow terms when relevant: .tours/<name>.tour, <persona>-<focus>.tour, scripts/, skills/code-tour/scripts/generate_from_docs.py, README/docs, language/framework discovery, Flask/FastAPI, index.js/ts, package.json/pnpm-workspace, branch/tag/commit refs, tour-level fields, real-world examples, persona-specific auto-launching, intro/closing steps, function/class selection, deep-dive tours, end-to-end feature tours, ramp-up onboarding, step-by-step walkthroughs, by-line review, pattern/gotcha descriptions, non-obvious failure modes, non-existent files, out-of-bounds lines, and the CRITICAL rule that only .tour JSON files are created.

Output template

## CodeTour result - <tour title>

**Status:** created | blocked
**File:** `.tours/<persona>-<focus>.tour`
**Persona:** <persona>
**Depth:** quick | standard | deep

### Coverage
| Step range | Purpose | Anchors |
| --- | --- | --- |
| 1 | Orientation | `<file or directory>` |
| 2-<n> | Core path | `<files, directories, patterns, selections, URIs>` |
| <n> | Closing | content |

### Validation
- `python harness/github-copilot/skills/code-tour/scripts/validate_tour.py .tours/<name>.tour --repo-root .`: pass | fail
- Paths and line numbers verified: pass | fail
- Patterns matched: pass | fail | not used
- `nextTour` cross-reference: pass | fail | not used

### Share and follow-up
- Public URL: `https://vscode.dev/github.com/<owner>/<repo>` or not available
- Suggested follow-up tours: <2-3 titles>
- Missing requested files: <none or list>

Quality gate

  • Only one .tour JSON file was created or modified under .tours/.
  • Every root field and step field conforms to references/codetour-schema.json.
  • Every file path is relative to repo root, has no leading / or ./, was read, and exists.
  • Every line number is verified and within bounds.
  • Every directory path is relative to repo root and exists.
  • Every pattern regex compiles and matches a real line.
  • Every uri is a complete real URL beginning with https://.
  • ref is a real branch, tag, or commit when set.
  • nextTour exactly matches another tour title when set.
  • Step 1 has a file, directory, or URI anchor.
  • The tour has a narrative arc and at most 2 content-only steps.
  • Every description follows SMIG and serves the selected persona.
  • Step count matches requested depth and repo size.
  • scripts/validate_tour.py was run and all errors were fixed.

References

Signals

GitHub stars
20
Last commit
Sep 2026

ahel review

  • K6low
    bundled executables the agent is told to run
  • K1binfo
    installs-packages (in references/examples.md)

Automated review, not a security audit. Ruleset v1+k2.

Advanced
Item type
skill
Key
code-tour-gbb-acelerators
Source
github.com/gbb-acelerators/awesome-harness-primitives