一键导入
framework-detector
Multi-signal framework detection with confidence scoring for 6 major frameworks
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Multi-signal framework detection with confidence scoring for 6 major frameworks
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Node.js/TypeScript backend framework with dependency injection and modular architecture
Execute and generate ExUnit tests for Elixir projects with setup callbacks, describe blocks, and async testing support
Automatically detect test frameworks (Jest, pytest, RSpec, xUnit) in projects by analyzing configuration files and dependencies
Execute and generate pytest tests for Python projects with fixtures, parametrization, and mocking support
Execute and generate RSpec tests for Ruby projects with let bindings, before hooks, and mocking support
Execute and generate xUnit tests for C#/.NET projects with FluentAssertions and Moq support
| name | Framework Detector |
| version | 1.0.0 |
| framework_versions | {"min":"1.0.0","recommended":"1.0.0"} |
| compatible_agents | {"backend-developer":">=3.0.0","frontend-developer":">=3.0.0","tech-lead-orchestrator":">=2.5.0"} |
| description | Multi-signal framework detection with confidence scoring for 6 major frameworks |
| frameworks | ["framework-detector"] |
| languages | ["javascript","typescript"] |
| category | utility |
| updated | "2025-10-22T00:00:00.000Z" |
When to Use: Automatically detect framework in project before loading framework-specific skills
Supported Frameworks: NestJS, React, Phoenix, Rails, .NET/ASP.NET Core, Blazor
Detection Method: Multi-signal analysis with weighted confidence scoring
const FrameworkDetector = require('./detect-framework');
const detector = new FrameworkDetector('/path/to/project');
const result = await detector.detect();
console.log(result.primary); // "nestjs"
console.log(result.confidence); // 0.92
console.log(result.alternates); // [{ framework: "dotnet", confidence: 0.45 }]
# Detect framework in current directory
./detect-framework.js
# Detect framework in specific project
./detect-framework.js /path/to/project
# Output format (JSON)
{
"primary": "react",
"confidence": 0.89,
"alternates": [],
"details": { ... }
}
package.json dependenciesGemfile gemsmix.exs dependencies*.csproj PackageReferences*.csproj)nest-cli.json (+50%).razor files (+60%)Default: 0.8 (80% confidence required)
Interpretation:
✓ @nestjs/core in package.json
✓ nest-cli.json exists
✓ @Module decorator in .ts files
✓ @Controller decorator in .ts files
✓ react in package.json
✓ .jsx or .tsx files exist
✓ useState or useEffect in code
✓ createRoot in code
✓ {:phoenix, in mix.exs
✓ config/config.exs exists
✓ Phoenix.Endpoint in .ex files
✓ Phoenix.Router in .ex files
✓ gem 'rails' in Gemfile
✓ config/application.rb exists
✓ Rails.application in code
✓ ActiveRecord::Base in code
✓ Microsoft.AspNetCore in .csproj
✓ Program.cs exists
✓ [ApiController] in .cs files
✓ using Microsoft.AspNetCore
✓ Microsoft.AspNetCore.Components in .csproj
✓ .razor files exist
✓ @page directive in .razor files
✓ ComponentBase in code
Optimizations:
Typical Detection Time: 100-500ms
No Frameworks Detected:
{
primary: null,
confidence: 0,
alternates: [],
details: {}
}
Multiple Frameworks (e.g., monorepo):
{
primary: "react",
confidence: 0.91,
alternates: [
{ framework: "nestjs", confidence: 0.87 }
]
}
const { SkillLoader } = require('../skill-loader');
const FrameworkDetector = require('./detect-framework');
async function loadFrameworkSkill(projectRoot) {
// 1. Detect framework
const detector = new FrameworkDetector(projectRoot);
const result = await detector.detect();
// 2. Handle low confidence
if (result.confidence < 0.8) {
// Prompt user or use alternates
console.warn('Low confidence detection');
}
// 3. Load skill
const loader = new SkillLoader({
agentName: 'backend-developer',
agentVersion: '3.0.0'
});
const skill = await loader.loadSkill(result.primary, 'quick');
return skill;
}
Edit framework-patterns.json to: