All skills
github avatar

/acquire-codebase-knowledge

@9ce8148 official
by githubgithub/awesome-copilot40k stars
5,040

Use this skill when the user explicitly asks to map, document, or onboard into an existing codebase. Trigger for prompts like "map this codebase", "document this architecture", "onboard me to this repo", or "create codebase docs". Do not trigger for routine feature implementation, bug fixes, or narrow code edits unless the user asks for repository-level discovery.

Use this Skill: https://skilld.dev/gh/github/awesome-copilot/acquire-codebase-knowledge

This session only. Nothing lands on disk.

referencesstack-detection.md

≈1.4k tokens on demand. Your agent reads this file only when SKILL.md points to it.

Stack Detection Reference

Load this file when the tech stack is ambiguous — e.g., multiple manifest files present, unfamiliar file extensions, or no obvious package.json / go.mod.


Manifest File → Ecosystem

File Ecosystem Key fields to read
package.json Node.js / JavaScript / TypeScript dependencies, devDependencies, scripts, main, type, engines
go.mod Go Module path, Go version, require block
requirements.txt Python (pip) Package list with pinned versions
Pipfile Python (pipenv) [packages], [dev-packages], [requires] python version
pyproject.toml Python (poetry / uv / hatch) [tool.poetry.dependencies], [project], [build-system]
setup.py / setup.cfg Python (setuptools, legacy) install_requires, python_requires
Cargo.toml Rust [dependencies], [[bin]], [lib]
pom.xml Java / Kotlin (Maven) <dependencies>, <artifactId>, <groupId>, <java.version>
build.gradle / build.gradle.kts Java / Kotlin (Gradle) dependencies {}, sourceCompatibility
composer.json PHP require, require-dev
Gemfile Ruby gem declarations, ruby version constraint
mix.exs Elixir deps/0, elixir: "~> X.Y"
pubspec.yaml Dart / Flutter dependencies, dev_dependencies, environment.sdk
*.csproj .NET / C# <PackageReference>, <TargetFramework>
*.sln .NET solution References multiple .csproj projects
deno.json / deno.jsonc Deno (TypeScript runtime) imports, tasks
bun.lockb Bun (JavaScript runtime) Binary lockfile — check package.json for deps

Language Runtime Version Detection

Language Where to find the version
Node.js .nvmrc, .node-version, engines.node in package.json, Docker FROM node:X
Python .python-version, pyproject.toml [requires-python], Docker FROM python:X
Go First line of go.mod (go 1.21)
Java <java.version> in pom.xml, sourceCompatibility in build.gradle, Docker FROM eclipse-temurin:X
Ruby .ruby-version, Gemfile ruby 'X.Y.Z'
Rust rust-toolchain.toml, rust-toolchain file
.NET <TargetFramework> in .csproj (e.g., net8.0)

Framework Detection (Node.js / TypeScript)

Dependency in package.json Framework
express Express.js (minimal HTTP server)
fastify Fastify (high-performance HTTP server)
next Next.js (SSR/SSG React — check for pages/ or app/ directory)
nuxt Nuxt.js (SSR/SSG Vue)
@nestjs/core NestJS (opinionated Node.js framework with DI)
koa Koa (middleware-focused, no built-in router)
@hapi/hapi Hapi
@trpc/server tRPC (type-safe API without REST/GraphQL schemas)
routing-controllers routing-controllers (decorator-based Express wrapper)
typeorm TypeORM (SQL ORM with decorators)
prisma Prisma (type-safe ORM, check prisma/schema.prisma)
mongoose Mongoose (MongoDB ODM)
sequelize Sequelize (SQL ORM)
drizzle-orm Drizzle (lightweight SQL ORM)
react without next Vanilla React SPA (check for react-router-dom)
vue without nuxt Vanilla Vue SPA

Framework Detection (Python)

Package Framework
fastapi FastAPI (async REST, auto OpenAPI docs)
flask Flask (minimal WSGI web framework)
django Django (batteries-included, check settings.py)
starlette Starlette (ASGI, often used as FastAPI base)
aiohttp aiohttp (async HTTP client and server)
sqlalchemy SQLAlchemy (SQL ORM; check for alembic migrations)
alembic Alembic (SQLAlchemy migration tool)
pydantic Pydantic (data validation; core to FastAPI)
celery Celery (distributed task queue)

Monorepo Detection

Check these signals in order:

  1. pnpm-workspace.yaml — pnpm workspaces
  2. lerna.json — Lerna monorepo
  3. nx.json — Nx monorepo (also check workspace.json)
  4. turbo.json — Turborepo
  5. rush.json — Rush (Microsoft monorepo manager)
  6. moon.yml — Moon
  7. package.json with "workspaces": [...] — npm/yarn workspaces
  8. Presence of packages/, apps/, libs/, or services/ directories with their own package.json

If monorepo is detected: each workspace may have independent dependencies and conventions. Map each sub-package separately in STACK.md and note the monorepo structure in STRUCTURE.md.


TypeScript Path Alias Detection

If tsconfig.json has a paths key, imports with non-relative prefixes are aliases. Map them before documenting structure.

// tsconfig.json example
"paths": {
  "@/*": ["./src/*"],
  "@components/*": ["./src/components/*"],
  "@utils/*": ["./src/utils/*"]
}

Imports like import { foo } from '@/utils/bar' resolve to src/utils/bar. Document as src/utils/bar, not @/utils/bar.


Docker Base Image → Runtime

If no manifest file is present but a Dockerfile exists, the FROM line reveals the runtime:

FROM line pattern Runtime
FROM node:X Node.js X
FROM python:X Python X
FROM golang:X Go X
FROM eclipse-temurin:X Java X (Eclipse Temurin JDK)
FROM mcr.microsoft.com/dotnet/aspnet:X .NET X
FROM ruby:X Ruby X
FROM rust:X Rust X
FROM alpine (alone) Check what's installed via RUN apk add

Source: SKILL.md on GitHub

No alerts15d4 checks · Risk SAFE
  • Gen Agent Trust Hub15d

    This skill facilitates codebase onboarding by scanning local project files and git history to generate documentation. It is generally safe and authored by a trusted vendor, but it carries an inherent low risk of indirect prompt injection if the analyzed codebase contains malicious instructions designed to influence the documentation process.

  • Socket15d

    No alerts

  • Snyk15d

    Risk: LOW · No issues

  • ZeroLeaks5mo

    Score: 93/100 · 2 sections analyzed

Signed by skilld at 9ce8148. This ties the file your Agent reads to that commit on GitHub. It does not review the instructions.

Last checked against GitHub 20 hours ago.

Activeupdated 2 weeks ago
Other metadata
compatibility
Cross-platform. Requires Python 3.8+ and git. Run scripts/scan.py from the target project root.
metadata
{
  "version": "1.3",
  "enhancements": [
    "Multi-language manifest detection (25+ languages supported)",
    "CI/CD pipeline detection (10+ platforms)",
    "Container & orchestration detection",
    "Code metrics by language",
    "Security & compliance config detection",
    "Performance testing markers"
  ]
}
argument-hint
Optional: specific area to focus on, e.g. "architecture only", "testing and concerns"

README badge

README badge for github/awesome-copilot/acquire-codebase-knowledge

Scans a codebase with a Python script to extract stack, structure, architecture, conventions, integrations, testing setup, and known concerns, then populates seven markdown documents in docs/codebase/ with verified facts only. Targets onboarding scenarios where a developer or agent needs to understand an unfamiliar repository quickly.

Generated from the current SKILL.md.

Does this skill work with monorepos?
Yes. The skill detects workspaces and packages directories, and maps each sub-package separately with independent dependencies and conventions.
What languages and platforms does this support?
Cross-platform (Windows, macOS, Linux). Requires Python 3.8+, git, and detects 25+ programming languages. Run scripts/scan.py from the target project root.
Does this document generated code and build artifacts?
No. The skill documents only source conventions and patterns, explicitly avoiding dist/, build/, generated/, .next/, out/, and __pycache__ directories.
What happens if the skill can't determine something about the codebase?
Unknown items are marked [TODO]. If the answer requires team intent or context, it is marked [ASK USER] and presented as a numbered question at the end.
What output does this skill produce?
Seven documented files in docs/codebase/: STACK.md, STRUCTURE.md, ARCHITECTURE.md, CONVENTIONS.md, INTEGRATIONS.md, TESTING.md, and CONCERNS.md, with evidence trails to source files.

Generated from the current SKILL.md. These answers refresh after source changes.