Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,8 +17,8 @@
## 📊 统计数据

- **官方技能**: 182 个(来自 awesome-agent-skills,自动爬取)
- **本地技能**: 61 个(25核心 + 30子技能 + 6系统内置)
- **技能总数**: 243 个(官方 + 本地)
- **本地技能**: 62 个(26核心 + 30子技能 + 6系统内置)
- **技能总数**: 244 个(官方 + 本地)
- **备份覆盖率**: 100%(71个压缩包,完整备份)
- **自动更新**: 每24小时自动爬取最新技能

Expand Down Expand Up @@ -54,7 +54,7 @@
- **Better Auth** (3个) - best-practices, commands, create-auth
- **其他团队** - Tinybird, Remotion, Inngest 等

## 💾 本地技能库(61个
## 💾 本地技能库(62个

### 📝 内容创作与发布(10个)
- **content-creation-publisher** ⭐⭐⭐⭐⭐ - 内容创作与发布全流程
Expand Down Expand Up @@ -112,6 +112,9 @@
- **law-to-markdown** ⭐⭐ - 法律文档转换
- **stock-analysis** ⭐⭐⭐ - 股票个股分析

### 💻 软件开发与代码理解(1个)
- **ontoly-software-graph** ⭐⭐⭐⭐ - 基于 Ontoly Software Graph 的架构审查、请求追踪、依赖分析与影响分析

### 🤝 智能体协作(3个)
- **agent-team** ⭐⭐⭐ - 智能体团队协作
- **multi-agent-meeting** ⭐⭐ - 多智能体会议
Expand Down
42 changes: 42 additions & 0 deletions skills/ontoly-software-graph/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
# Ontoly Software Graph

使用 Ontoly 的确定性 Software Graph 和 MCP 能力,让 AI 编程代理在搜索源码之前,优先基于图谱证据理解代码库。

## 适用场景

- 架构审查
- 请求链路追踪
- 依赖分析
- 重构影响分析
- 配置与环境变量审计
- 服务、模块、控制器、路由定位
- 代码库 onboarding

## 核心原则

1. 先确认 Ontoly graph 是否存在。
2. 如果缺失且允许本地分析,运行 `ontoly build .`。
3. 优先使用 Ontoly CLI 或 MCP 查询 graph。
4. 只有当 graph 无法回答、过期或不完整时,才回退到源码搜索。
5. 回答必须包含节点、边、源码位置、诊断或框架分析等证据。

## 安装 Ontoly

```bash
npm install -D ontoly
```

或使用 pnpm:

```bash
pnpm add -D ontoly
```

## 示例问题

- Explain this repository.
- Trace the login request.
- Which service owns authentication?
- What breaks if I remove `UserRepository`?
- Which packages depend on `AuthModule`?

73 changes: 73 additions & 0 deletions skills/ontoly-software-graph/SKILL.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,73 @@
---
name: ontoly-software-graph
description: Use Ontoly's deterministic Software Graph and MCP capabilities for architecture review, request tracing, dependency analysis, configuration lookup, and impact analysis before falling back to source-file search.
---

# Ontoly Software Graph

Use this skill when a coding agent needs evidence-backed software understanding from an Ontoly graph before searching repository files directly.

## When to Use

- Explaining a repository architecture
- Tracing a request, route, controller, service, or dependency path
- Finding owners of services, modules, routes, configuration, or environment variables
- Reviewing dependency impact before a refactor
- Auditing dead code, cycles, unresolved imports, graph quality, or semantic coverage
- Preparing documentation, onboarding notes, or architecture review from graph evidence

## Required Workflow

1. Check whether an Ontoly graph already exists by looking for `.ontoly/`, `SoftwareGraph.json`, `diagnostics.json`, validation reports, or an Ontoly MCP configuration.
2. If no graph exists and the user permits local analysis, run:

```bash
ontoly build .
```

3. Inspect graph health before answering: diagnostics, graph hash, semantic coverage, trust or quality score, framework detection, and generation timestamp.
4. Prefer Ontoly CLI or MCP capabilities for graph questions instead of scanning source files first.
5. Use repository search only when Ontoly cannot answer, the graph is stale, the graph is incomplete, or the user explicitly asks for source-level verification.
6. Always cite graph evidence in the answer: node IDs, edge types, file paths, source locations, diagnostics, or framework analyzer output.
7. State confidence from graph evidence. Do not guess confidence.

## Useful Ontoly Capabilities

- `ExplainArchitecture` for repository and package topology
- `FindDependencies` for dependency trees and direct consumers
- `ImpactAnalysis` for refactor blast radius
- `TraceExecution` for request, route, and call-flow tracing
- `FindConfigurationUsage` for configuration and environment variable usage
- `FrameworkReport` for detected framework concepts such as modules, controllers, providers, and routes
- `FindDeadCode` for unreachable or unused graph regions

## Answer Shape

When answering, include:

- the direct answer
- graph evidence
- confidence
- diagnostics or caveats
- fallback source inspection only if needed

Example:

```text
AuthController handles authentication.

Evidence:
- node: class:src/auth/auth.controller.ts:AuthController
- route edges: HANDLES POST /login, POST /logout
- dependency edges: USES AuthService, JwtService

Confidence: high, because the graph has controller, route, and dependency edges with source locations.
```

## Fallback Rules

- If the graph is missing, build it first when allowed.
- If graph validation fails, report the failure and use source search only to verify the affected area.
- If multiple nodes match the same name, ask for disambiguation or show the candidates with package/module context.
- If the requested concept is not in the graph, return `NOT_FOUND` with the closest graph evidence instead of inventing an answer.

29 changes: 29 additions & 0 deletions skills/ontoly-software-graph/metadata.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
{
"name": "ontoly-software-graph",
"version": "1.0.0",
"description": "Use Ontoly's deterministic Software Graph and MCP capabilities for architecture review, request tracing, dependency analysis, configuration lookup, and impact analysis.",
"author": "0xsarwagya",
"dependencies": {
"node": ">=20"
},
"platforms": ["macOS", "Linux", "Windows"],
"tags": [
"ontoly",
"software-graph",
"mcp",
"typescript",
"architecture",
"dependency-analysis",
"impact-analysis",
"codebase-understanding"
],
"triggers": [
"Ontoly",
"Software Graph",
"trace request",
"impact analysis",
"dependency graph",
"architecture review",
"configuration audit"
]
}