From maverick
Generates project-specific implementation skills by scanning codebases for any topic, producing SKILL.md files with concrete technology usage, configuration, and code locations.
How this skill is triggered — by the user, by Claude, or both
Slash command
/maverick:do-upskill topic (optional — omit to process all topics)topic (optional — omit to process all topics)The summary Claude sees in its skill listing — used to decide when to auto-load this skill
Scan the current project's codebase for a given topic and produce a project-specific skill file at `docs/maverick/skills/<topic>/SKILL.md`.
Scan the current project's codebase for a given topic and produce a project-specific skill file at docs/maverick/skills/<topic>/SKILL.md.
Primary audience: LLMs. The generated skill is project implementation and usage guidance — what technology is used, how it's configured, and where the code lives. It is NOT best practices (the maverick best-practice skill handles that). Keep it dense, factual, and under 100 lines.
Run this first. If it exits non-zero, halt and report the stderr output to the user verbatim. Do not proceed.
uv run maverick preflight do-upskill
The check verifies the project is initialised and uv is on PATH.
Topics live in ${CLAUDE_PLUGIN_ROOT}/skills/do-upskill/topics.json
(resolve the env var once via Bash — the runtime cwd is the target
project, not the plugin).
$ARGUMENTS names a topic (e.g. logging): process exactly
that one topic and stop. This is the mode other skills and mid-task
lookups use — never expand a single-topic request into a full scan.For each topic entry being processed:
topic, prompt, bestPracticeSkill, and scanHints fieldsdocs/maverick/skills/<topic>/SKILL.md<package>/docs/maverick/skills/<topic>/SKILL.md. Also scan the repo root for cross-cutting implementations and write those to docs/maverick/skills/<topic>/SKILL.md. Cross-cutting topics (see below) always write to root only.Use subagents or parallel agents to process multiple topics concurrently when possible.
Each topic entry in topics.json provides:
${CLAUDE_PLUGIN_ROOT} before readingdigraph generate {
"Receive topic + scan hints" [shape=box];
"Detect repository type" [shape=diamond];
"Enumerate packages" [shape=box];
"Check dependency files" [shape=box];
"Grep for code patterns" [shape=box];
"Glob for relevant files" [shape=box];
"Read discovered files" [shape=box];
"Technology found?" [shape=diamond];
"Write full project skill" [shape=box];
"Write recommended skill from best practice" [shape=box];
"Receive topic + scan hints" -> "Detect repository type";
"Detect repository type" -> "Check dependency files" [label="single-repo"];
"Detect repository type" -> "Enumerate packages" [label="mono-repo"];
"Enumerate packages" -> "Check dependency files" [label="for each package"];
"Check dependency files" -> "Grep for code patterns";
"Grep for code patterns" -> "Glob for relevant files";
"Glob for relevant files" -> "Read discovered files";
"Read discovered files" -> "Technology found?";
"Technology found?" -> "Write full project skill" [label="yes"];
"Technology found?" -> "Write recommended skill from best practice" [label="no"];
}
Determine whether the project is a mono-repo or single-repo. A project is a mono-repo if any of the following are present:
package.json with a workspaces fieldpnpm-workspace.yamllerna.jsonCargo.toml with a [workspace] sectiongo.work filepyproject.toml files in subdirectoriesnx.jsonrush.jsonIf none of these indicators are found, treat the project as a single-repo.
Cache this result for the entire invocation — do not re-detect for each topic.
Package enumeration: Once a mono-repo is detected, enumerate all packages by reading the workspace configuration:
workspaces array from root package.json (resolve globs)packages list from pnpm-workspace.yamlpackages from lerna.jsonmembers from [workspace] in root Cargo.tomluse directives from go.workpyproject.tomlprojects from nx.json or list directories with project.jsonprojects[].projectFolder from rush.jsonSearch for topic-related packages in:
package.json (dependencies, devDependencies)pyproject.toml (dependencies, optional-dependencies)requirements.txtbuild.gradle.ktsgo.modCargo.tomlMono-repo: Check dependency files within each package directory (e.g. <package>/package.json, <package>/pyproject.toml), not just at the root. Root-level dependency files are still checked for cross-cutting concerns shared across packages.
Use the scan hints grep patterns to find relevant code. If no scan hints provided, use the defaults for the topic.
Use the scan hints file patterns to find relevant files by name.
Read the files found in steps 2-3 to understand:
Single-repo: Write SKILL.md to docs/maverick/skills/<topic>/SKILL.md using the Write tool (which creates parent directories automatically). Do NOT use mkdir via Bash.
Native-session pointer: after writing each root-level project skill,
also write a thin pointer at .claude/rules/maverick-<topic>.md so
sessions that don't know Maverick's lookup convention still load the
facts:
This project's <topic> conventions are documented in
`docs/maverick/skills/<topic>/SKILL.md` (generated by Maverick).
Read and follow it when working on <topic>-related code.
Keep the pointer to those three lines — the project skill stays the single source of content.
Mono-repo: Output path depends on whether the topic is cross-cutting or package-scoped:
docs/maverick/skills/<topic>/SKILL.md at the repo root (scan the entire repo)<package>/docs/maverick/skills/<topic>/SKILL.md for each package (scan scoped to that package directory). If root-level implementations also exist, write a root skill at docs/maverick/skills/<topic>/SKILL.md as well.cicd — CI/CD is configured once at the repo root and applies to all packages.logging, alerting, unit-testing, integration-testing, linting, database — these vary by package and tech stack.Every generated project skill MUST use this exact structure:
---
name: <topic-name>
title: <Topic> — Project Implementation
topic: <topic-name>
package: <package-name> # only for package-level skills in mono-repos
last-verified: <YYYY-MM-DD>
---
## Stack
<What technology/library/service is used. Be specific: name, version if detectable.>
## Configuration
<How it's configured: env vars, config files, initialisation patterns. Describe in prose, no code.>
## Patterns
<Established conventions in this codebase. How the team uses this technology.>
## File Locations
<Specific file paths where the relevant code lives.>
The package field is only included for package-level skills generated in mono-repos. Omit it for root-level and single-repo skills.
After every topic has been processed and at least one project skill file has been written, record that upskill has run on this project:
uv run maverick integration set upskill true
The flag is committed in .maverick/config.json so other Maverick skills (and maverick integration get) can see this milestone has been completed.
If scanning finds no existing implementation for the topic, generate a recommended implementation skill based on the best-practice skill for that topic and the project's codebase.
digraph not_found {
"No implementation found" [shape=box];
"Best-practice skill exists?" [shape=diamond];
"Analyse codebase context" [shape=box];
"Write recommended skill" [shape=box];
"Write minimal stub" [shape=box];
"No implementation found" -> "Best-practice skill exists?";
"Best-practice skill exists?" -> "Analyse codebase context" [label="yes"];
"Best-practice skill exists?" -> "Write minimal stub" [label="no"];
"Analyse codebase context" -> "Write recommended skill";
}
${CLAUDE_PLUGIN_ROOT}/<bestPracticeSkill>, e.g. ${CLAUDE_PLUGIN_ROOT}/skills/mav-bp-operability/SKILL.md)Use the same mandatory output structure but with recommended content:
---
name: <topic-name>
title: <Topic> — Project Implementation
topic: <topic-name>
package: <package-name> # only for package-level skills in mono-repos
last-verified: <YYYY-MM-DD>
status: recommended
---
## Stack
<Recommended technology/library based on the project's stack and best-practice guidance. Be specific: name the library and explain why it fits this project.>
## Configuration
<Recommended configuration approach based on the project's patterns — env vars, config files, initialisation. Reference the best-practice standards.>
## Patterns
<Recommended usage patterns tailored to this codebase's framework and structure. Describe how the team should use this technology.>
## File Locations
<Recommended file locations following the project's existing directory conventions.>
The status: recommended frontmatter field distinguishes generated recommendations from skills based on detected implementations. Users can review and edit the generated skill, then remove the status field once they've adopted it.
If no best-practice skill exists for the topic, write a minimal stub:
---
name: <topic-name>
title: <Topic> — Project Implementation
topic: <topic-name>
last-verified: <YYYY-MM-DD>
status: stub
---
## Stack
No <topic> implementation detected. No best-practice skill available to generate recommendations.
## Configuration
N/A
## Patterns
N/A
## File Locations
N/A
Generated from the topic registry (TOPICS in this skill's config) — the
single source of truth shared with topics.json:
createLogger|getLogger|logger\.|console\.error|LOG_LEVEL|logging\.basicConfig**/logger.*, **/logging.*sendAlert|publish|PagerDuty|Opsgenie|alertService|notify|Sentry\.capture**/alert*.*, **/notify*.*describe\(|it\(|test\(|expect\(|assert|@Test|func Test**/*.test.*, **/*.spec.*, **/test_*.*describe\(|it\(|test\(|expect\(|assert|@Test|func Test**/*.test.*, **/*.spec.*, **/test_*.*eslint|prettier|ruff|lint-staged|formatOnSave|\"lint\":|\"format\":eslint.config.*, .eslintrc*, .prettierrc*, prettier.config.*, ruff.toml, .golangci.yml, .stylelintrc*workflow_dispatch|on:\s+push|pipeline|stage|job|trigger:|pool:|vmImage:.github/workflows/*.yml, .github/workflows/*.yaml, .gitlab-ci.yml, azure-pipelines.yml, Jenkinsfile, .circleci/config.yml, buildkite.yml, .buildkite/**/*.yml, bitbucket-pipelines.yml, .travis.yml, cloudbuild.yaml, appveyor.ymlhelmet|csp|Content-Security-Policy|sanitize|escape|parameterized|prepared|xss|csrf|cors|rateLimit|authenticate|authorize**/security.*, **/auth*.*, **/middleware/auth*, **/.snyk, **/trivy*dependabot|renovate|npm audit|pip-audit|safety check|license-checker|snyk test.github/dependabot.yml, renovate.json, .renovaterc*, package-lock.json, pnpm-lock.yaml, yarn.lock, uv.lock, Cargo.lock, go.sum, Pipfile.lock, poetry.locktrace|span|metric|histogram|counter|gauge|healthCheck|health_check|readiness|liveness|opentelemetry|prometheus**/tracing.*, **/metrics.*, **/health*.*, **/telemetry.*, **/instrumentation.*@Api|@swagger|openapi|ApiResponse|ApiOperation|@route|@controller|router\.|app\.get|app\.post**/openapi.*, **/swagger.*, **/api-docs*, **/routes/**, **/controllers/**createConnection|getRepository|prisma\.|db\.|migrate|schema**/schema.*, **/migration*, **/database.*, **/db.*ErrorBoundary|error_handler|errorHandler|globalExceptionFilter|circuit.?breaker|retry|backoff|AppError|HttpException|ApiError**/error*.*, **/exception*.*, **/middleware/error*resource\s|provider\s|terraform|pulumi|cloudformation|ansible|helm*.tf, *.tfvars, Pulumi.yaml, template.yaml, template.json, **/ansible/**, **/helm/**, docker-compose*.yml, **/k8s/**, **/kubernetes/**aria-|role=|alt=|tabIndex|focusTrap|skipNav|screen\.getByRole|toBeAccessible|axe**/a11y*.*, **/accessibility*.*, .pa11yci*, lighthouserc*dotenv|process\.env|os\.environ|docker-compose|devcontainer|CONTRIBUTING.env.example, .env.sample, .env.template, .devcontainer/**, docker-compose*.yml, Vagrantfile, flake.nix, shell.nix, CONTRIBUTING.mdnpx claudepluginhub thermiteau/maverick --plugin maverickGenerates .dh/skill_discovery.yaml by scanning repo for tech stack signals like pyproject.toml and package.json, inventorying skills via npx skills list, suggesting candidates, and writing config for skill injection.
Loads skills efficiently using a 3-layer progressive disclosure system: lightweight index always loaded, summaries on demand, full skills only during execution to minimize token usage.
Builds a 3-tier documentation system (CLAUDE.md, orientation maps, domain & use case skills) by analyzing codebase structure, config files, and asking targeted questions about product/architecture.