Project Detection Skill
CRITICAL: The description field above controls when Claude auto-loads this skill.
Overview
Provides comprehensive project analysis capabilities including framework detection, dependency analysis, AI stack identification, database detection, and automatic .claude/project.json generation.
Instructions
Framework Detection
- Use
scripts/detect-frameworks.sh <project-path> to identify all frameworks
- Detects frontend frameworks: Next.js, React, Vue, Svelte, Angular, Solid.js
- Detects backend frameworks: FastAPI, Django, Flask, Express, NestJS, Go frameworks, Rust frameworks
- Identifies meta-frameworks and build tools
- Returns structured JSON output with versions and confidence scores
Dependency Analysis
- Use
scripts/detect-dependencies.sh <project-path> to analyze all dependencies
- Scans package.json, requirements.txt, go.mod, Cargo.toml, Gemfile, composer.json
- Categorizes dependencies: production, development, peer
- Identifies version ranges and exact versions
- Detects dependency conflicts and outdated packages
AI Stack Identification
- Use
scripts/detect-ai-stack.sh <project-path> to discover AI components
- Detects: Vercel AI SDK, Claude Agent SDK, LangChain, Mem0, OpenAI SDK
- Identifies AI model providers and API integrations
- Discovers RAG systems and vector databases
- Finds agent frameworks and orchestration tools
Database Detection
- Use
scripts/detect-database.sh <project-path> to identify databases
- Detects: Supabase, PostgreSQL, MongoDB, Redis, MySQL, SQLite
- Identifies ORMs: Prisma, TypeORM, SQLAlchemy, GORM, Diesel
- Finds connection strings and configuration files
- Discovers database migration tools
Project.json Generation
- Use
scripts/generate-project-json.sh <project-path> to create complete project.json
- Aggregates all detection results into structured format
- Generates
.claude/project.json with complete tech stack information
- Includes framework versions, dependencies, AI stack, databases
- Adds metadata: language, build tools, test frameworks, deployment targets
Available Scripts
- detect-frameworks.sh: Comprehensive framework detection across all languages
- detect-dependencies.sh: Dependency analysis from all package managers
- detect-ai-stack.sh: AI/ML stack component identification
- detect-database.sh: Database and ORM detection
- generate-project-json.sh: Master script that generates complete project.json
- validate-detection.sh: Validates detection accuracy and completeness
Templates
- project.json.template: Complete project.json structure with all fields
- framework-patterns.json: Detection patterns for 30+ frameworks
- dependency-patterns.json: Dependency identification patterns
- ai-stack-patterns.json: AI/ML component detection patterns
- database-patterns.json: Database detection patterns
- detection-report.md: Human-readable detection report template
Examples
See examples/ directory for detailed usage examples:
basic-usage.md - Simple project detection workflow
advanced-detection.md - Complex multi-framework projects
ai-stack-discovery.md - AI stack identification patterns
database-analysis.md - Database and ORM detection
project-json-generation.md - Complete project.json generation
Detection Strategies
Frontend Detection
- Check for framework-specific config files (next.config.js, vite.config.ts)
- Scan package.json for framework dependencies
- Identify build tool configurations
- Detect UI component libraries (shadcn, Material-UI, Tailwind UI)
Backend Detection
- Identify web framework imports and decorators
- Scan for framework-specific file structures
- Detect API route patterns
- Find server configuration files
AI Stack Detection
- Search for AI SDK imports and usage
- Identify model provider API keys in env files
- Detect vector database configurations
- Find agent and tool definitions
Database Detection
- Scan for database client imports
- Find ORM schema definitions
- Identify connection string patterns
- Detect migration directories
Output Format
All detection scripts output JSON in this format:
{
"detected": true,
"confidence": "high|medium|low",
"type": "framework|database|ai-stack",
"name": "Framework Name",
"version": "1.0.0",
"files": ["list", "of", "evidence", "files"],
"metadata": {}
}
Requirements
- Support 30+ frameworks across 8+ languages
- Provide confidence scores for all detections
- Include file paths as evidence
- Generate valid project.json schema
- Handle monorepos and multi-framework projects
- Detect framework versions accurately
- Identify both direct and transitive dependencies
Integration
This skill is used by:
foundation:init command - Initial project analysis
foundation:analyze command - Deep project structure analysis
- All code generation skills - Framework-specific code templates
- All deployment commands - Framework-specific deployment configs
Purpose: Comprehensive project analysis and tech stack detection
Used by: All agents requiring project context and framework information
1---2name: project-detection3description: Comprehensive tech stack detection, framework identification, dependency analysis, and project.json generation. Use when analyzing project structure, detecting frameworks, identifying dependencies, discovering AI stack components, detecting databases, or when user mentions project detection, tech stack analysis, framework discovery, or project.json generation.4---56# Project Detection Skill78**CRITICAL: The description field above controls when Claude auto-loads this skill.**910## Overview1112Provides comprehensive project analysis capabilities including framework detection, dependency analysis, AI stack identification, database detection, and automatic `.claude/project.json` generation.1314## Instructions1516### Framework Detection17181. Use `scripts/detect-frameworks.sh <project-path>` to identify all frameworks192. Detects frontend frameworks: Next.js, React, Vue, Svelte, Angular, Solid.js203. Detects backend frameworks: FastAPI, Django, Flask, Express, NestJS, Go frameworks, Rust frameworks214. Identifies meta-frameworks and build tools225. Returns structured JSON output with versions and confidence scores2324### Dependency Analysis25261. Use `scripts/detect-dependencies.sh <project-path>` to analyze all dependencies272. Scans package.json, requirements.txt, go.mod, Cargo.toml, Gemfile, composer.json283. Categorizes dependencies: production, development, peer294. Identifies version ranges and exact versions305. Detects dependency conflicts and outdated packages3132### AI Stack Identification33341. Use `scripts/detect-ai-stack.sh <project-path>` to discover AI components352. Detects: Vercel AI SDK, Claude Agent SDK, LangChain, Mem0, OpenAI SDK363. Identifies AI model providers and API integrations374. Discovers RAG systems and vector databases385. Finds agent frameworks and orchestration tools3940### Database Detection41421. Use `scripts/detect-database.sh <project-path>` to identify databases432. Detects: Supabase, PostgreSQL, MongoDB, Redis, MySQL, SQLite443. Identifies ORMs: Prisma, TypeORM, SQLAlchemy, GORM, Diesel454. Finds connection strings and configuration files465. Discovers database migration tools4748### Project.json Generation49501. Use `scripts/generate-project-json.sh <project-path>` to create complete project.json512. Aggregates all detection results into structured format523. Generates `.claude/project.json` with complete tech stack information534. Includes framework versions, dependencies, AI stack, databases545. Adds metadata: language, build tools, test frameworks, deployment targets5556## Available Scripts5758- **detect-frameworks.sh**: Comprehensive framework detection across all languages59- **detect-dependencies.sh**: Dependency analysis from all package managers60- **detect-ai-stack.sh**: AI/ML stack component identification61- **detect-database.sh**: Database and ORM detection62- **generate-project-json.sh**: Master script that generates complete project.json63- **validate-detection.sh**: Validates detection accuracy and completeness6465## Templates6667- **project.json.template**: Complete project.json structure with all fields68- **framework-patterns.json**: Detection patterns for 30+ frameworks69- **dependency-patterns.json**: Dependency identification patterns70- **ai-stack-patterns.json**: AI/ML component detection patterns71- **database-patterns.json**: Database detection patterns72- **detection-report.md**: Human-readable detection report template7374## Examples7576See `examples/` directory for detailed usage examples:77- `basic-usage.md` - Simple project detection workflow78- `advanced-detection.md` - Complex multi-framework projects79- `ai-stack-discovery.md` - AI stack identification patterns80- `database-analysis.md` - Database and ORM detection81- `project-json-generation.md` - Complete project.json generation8283## Detection Strategies8485### Frontend Detection86- Check for framework-specific config files (next.config.js, vite.config.ts)87- Scan package.json for framework dependencies88- Identify build tool configurations89- Detect UI component libraries (shadcn, Material-UI, Tailwind UI)9091### Backend Detection92- Identify web framework imports and decorators93- Scan for framework-specific file structures94- Detect API route patterns95- Find server configuration files9697### AI Stack Detection98- Search for AI SDK imports and usage99- Identify model provider API keys in env files100- Detect vector database configurations101- Find agent and tool definitions102103### Database Detection104- Scan for database client imports105- Find ORM schema definitions106- Identify connection string patterns107- Detect migration directories108109## Output Format110111All detection scripts output JSON in this format:112```json113{114 "detected": true,115 "confidence": "high|medium|low",116 "type": "framework|database|ai-stack",117 "name": "Framework Name",118 "version": "1.0.0",119 "files": ["list", "of", "evidence", "files"],120 "metadata": {}121}122```123124## Requirements125126- Support 30+ frameworks across 8+ languages127- Provide confidence scores for all detections128- Include file paths as evidence129- Generate valid project.json schema130- Handle monorepos and multi-framework projects131- Detect framework versions accurately132- Identify both direct and transitive dependencies133134## Integration135136This skill is used by:137- `foundation:init` command - Initial project analysis138- `foundation:analyze` command - Deep project structure analysis139- All code generation skills - Framework-specific code templates140- All deployment commands - Framework-specific deployment configs141142---143144**Purpose**: Comprehensive project analysis and tech stack detection145**Used by**: All agents requiring project context and framework information