Token导航 LogoToken导航TokenDH.com
研究检索需要联网github未标认证来源可访问clear审计异常

codebase-exploration代码库探索

Agent Skill

codebase-exploration 用于记录任务执行中的错误、用户纠正、经验和能力缺口,适合在 Codex、Claude、Cursor、Gemini CLI 中希望让 Agent 持续沉淀问题、修正和最佳实践时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

总安装

11,902

周安装

491

GitHub Stars

76

下载量

3,889
CodexClaudeCursorGemini CLI

安装说明

本站只整理中文说明和来源信息,不托管安装包,也不代用户安装。

GitHub

来源数

3

许可证

MIT

最后核验

2026-05-01

来源状态

来源可访问

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:codebase-exploration(代码库探索)
来源仓库:https://github.com/404kidwiz/claude-supercode-skills
仓库路径:skills/codebase-exploration
安装命令:
npx skills add https://github.com/404kidwiz/claude-supercode-skills --skill codebase-exploration
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。不同来源提供的安装方式可能略有差异;本站展示可直接复制的安装命令,安装前请核对来源页面。

skills.shnpx skills
npx skills add https://github.com/404kidwiz/claude-supercode-skills --skill codebase-exploration

简介

系统的代码库搜索和模式发现,用于定位实现、理解架构和回答基于位置的代码问题。

  • 支持三种彻底性级别(快速、中等、非常彻底),时间范围从 30 秒到 10 分钟,从广泛的文件结构概述到详尽的依赖关系跟踪
  • 使用多种搜索策略,包括用于文本模式的 grep/rg、用于代码结构的 ast-grep、用于符号引用的 LSP 工具以及用于上下文的 git 历史记录
  • 专为探索任务而设计,例如查找功能的实现位置、映射架构模式、定位 API 端点以及跟踪跨文件的数据流
  • 包括用于根据问题类型(位置查询、数据流、API 处理、数据库查询、错误处理)选择适当搜索策略的决策框架

SKILL.md

Codebase Exploration

Purpose

Specializes in systematic codebase exploration and discovery. Uses advanced search techniques, pattern recognition, and code analysis to quickly understand unfamiliar code, locate specific implementations, map architectural patterns, and answer location-based questions about code.

When to Use

  • Exploring an unfamiliar codebase for the first time
  • Need to find where specific functionality is implemented
  • Looking for examples of a pattern across the codebase
  • Understanding how components interact
  • Locating all usages of a particular API or pattern
  • Mapping architectural organization
  • Finding similar code across the project
  • Questions like "Where is X?", "Which file has Y?", "Find code that does Z"

Quick Start

Invoke this skill when:

  • Exploring an unfamiliar codebase for the first time
  • Need to find where specific functionality is implemented
  • Looking for examples of a pattern across the codebase
  • Understanding how components interact
  • Questions like "Where is X?", "Which file has Y?", "Find code that does Z"

Do NOT invoke when:

  • Debugging a known bug (use debugger-skill)
  • Refactoring code (use refactoring-specialist-skill)
  • Reviewing code quality (use code-reviewer-skill)
  • Writing new code from scratch (use appropriate developer skill)

Thoroughness Levels

Quick (Fast, broad strokes)

  • File structure overview
  • High-level pattern matching
  • Directory organization
  • Main entry points
  • ~30 seconds

Medium (Balanced depth)

  • Detailed file examination
  • Cross-file pattern discovery
  • Architectural mapping
  • Common patterns analysis
  • ~2-3 minutes

Very Thorough (Deep dive)

  • Exhaustive code analysis
  • Complex pattern matching
  • Dependency tracing
  • Edge case discovery
  • ~5-10 minutes

Decision Framework

Search Strategy Selection

Question TypeSearch Strategy
"Where is user authentication?"Search for auth keywords + login patterns
"How does data flow work?"Find models, services, controllers pattern
"Which file handles X API?"Search endpoints + route definitions
"Find all database queries"Search ORM patterns, SQL keywords
"Locate error handling"Find try-catch, error classes

Tool Selection

ToolBest ForExample
grep/rgText pattern matchingrg "function handleAuth"
find/fdFile name/path matchingfd -e ts auth
ast-grepCode structure matchingast-grep --pattern "class $NAME"
LSP toolsSymbol and reference findinglsp_find_references
git logHistorical contextgit log --name-only

Approach by Question Type

"Where is X implemented?"

  1. Search for X by name: rg "X|x"
  2. Search for related terms: rg "related|terms"
  3. Check obvious locations: ls src/X/
  4. Look in tests: rg "X" tests/

"How does Y work?"

  1. Find Y's definition
  2. Find Y's usage
  3. Trace the flow
  4. Understand dependencies

"Which files use Z?"

  1. Search for imports of Z
  2. Use LSP find-references
  3. Search for Z's methods being called

Core Capabilities

Search Strategies

Pattern-Based Search

  • Find by naming conventions
  • Locate by code patterns
  • Discover by architectural markers
  • Identify by file organization

Context-Aware Search

  • Understand code relationships
  • Map dependencies
  • Trace execution flows
  • Find related components

Multi-Angle Discovery

  • Search by functionality
  • Search by structure
  • Search by naming
  • Search by patterns

Exploration Workflow

Step 1: Orient

  • What are we looking for?
  • Why do we need it?
  • What level of detail is needed?
  • Which thoroughness level is appropriate?

Step 2: Map Structure

  • Identify top-level organization
  • Find key markers (entry points, config files)
  • Note directory naming patterns

Step 3: Execute Search

  • Choose appropriate tools
  • Use multiple search angles
  • Document findings

Step 4: Analyze & Synthesize

  • Connect the dots
  • Identify patterns
  • Prioritize findings

Best Practices

Start Broad, Then Narrow

  1. First: Get the lay of the land (tree -L 2, ls -la src/)
  2. Second: Identify patterns (fd -e ts, rg -c "class|function")
  3. Third: Target specific areas

Use Multiple Search Angles

  • Search by name: fd auth
  • Search by content: rg "authentication"
  • Search by structure: ast-grep --pattern "class $NAME"
  • Search by symbols: lsp_workspace_symbols

Follow the Breadcrumbs

  1. Check imports to find dependencies
  2. Use LSP to find references
  3. Look at file location for architectural clues
  4. Check git history for context

Document as You Go

# Authentication Flow
1. Entry: src/middleware/auth.ts
2. Token validation: src/services/jwt.service.ts
3. User lookup: src/repositories/user.repository.ts
4. Guards: src/guards/auth.guard.ts

Anti-Patterns

  • Don't Search Without Context: Understand what you're looking for first
  • Don't Ignore File Structure: Always check directory organization
  • Don't Rely on Single Search Method: Use multiple approaches
  • Don't Forget About Tests: Search test files for real usage
  • Don't Skip Configuration Files: Check config early

Related Skills

  • Use [[debugger-skill]] when exploration reveals bugs
  • Use [[architect-reviewer-skill]] to evaluate discovered patterns
  • Use [[refactoring-specialist-skill]] to improve found code
  • Use [[technical-advisory-skill]] for complex architectural questions

Additional Resources

适合场景

01

用户想查找某类 Agent Skill 时

02

需要根据任务场景推荐可安装能力包时

03

需要对比不同来源的安装命令和来源信息时

04

需要参考平台分布和安装热度时

能力概览

能力 1

按任务关键词查找相关 Skills

能力 2

展示可复制的安装命令

能力 3

保留来源站点、仓库和原始说明,方便继续核验

能力 4

补充不同宿主或平台的使用分布数据

能力 5

展示第三方安全扫描或审计结果

安装后应在对应宿主中按原始 README 的触发条件使用;具体调用方式请以来源页面和 README 为准。

平台分布

Claude Code

28.48%
按下载量换算1,108

OpenCode

20.14%
按下载量换算783

Gemini CLI

18.55%
按下载量换算721

Codex

11.91%
按下载量换算463

Antigravity

8.04%
按下载量换算313

Cursor

3.1%
按下载量换算121

安全审计

Gen Agent Trust Hub

未通过

Socket

通过

Snyk

通过

权限和风险

需要联网

该 Skill 可能需要联网访问来源站点、仓库或外部 API;具体网络访问范围需要结合源码和 README 复核。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。来源安全扫描存在 warning/failed 结果,不能写成本站确认安全。

来源信息

继续浏览同类 Skills