You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Chinese documentation: [README.zh-CN.md](https://github.com/oceanusXXD/code2skill/blob/main/README.zh-CN.md).
7
+
Language: English | [简体中文](https://github.com/oceanusXXD/code2skill/blob/main/README.zh-CN.md)
8
8
9
-
`code2skill`compiles a Python repository into reviewable AI working instructions.
9
+
`code2skill`turns a Python repository into instruction files for coding assistants.
10
10
11
-
It reads real source-code evidence, builds a repository blueprint, asks an LLM to plan and write focused Skills, and can publish the same knowledge to Codex, Claude Code, Cursor, GitHub Copilot, and Windsurf. The result is a committed, testable instruction layer instead of stale chat context or scattered hand-written rules.
11
+
It scans sourcecode and configuration, writes a `.code2skill/` bundle, generates focused Skill documents, and publishes them to Codex, Claude Code, Cursor, GitHub Copilot, or Windsurf. The files stay in the repository, so maintainers can review them, run them in CI, and update them when code changes.
12
12
13
-
Use it when a Python project needs AI coding assistants to understand current module boundaries, workflows, contracts, and maintenance rules from the code that actually exists.
13
+
Use it when a Python project needs coding assistants to follow the current module boundaries, workflows, API contracts, and maintenance rules.
14
14
15
-
## What It Solves
15
+
## What This Repository Can Do
16
16
17
-
- Turns repository structure and source evidence into AI-ready Skills.
18
-
- Keeps generated knowledge reviewable in Git and refreshable in CI.
19
-
- Publishes one Skill layer to several AI coding tools.
20
-
- Preserves hand-written target-file content through managed blocks.
21
-
- Validates generated bundles and adapted tool files with `doctor`.
- Analyze a Python repository with AST parsing, import graph checks, config extraction, and file-role inference.
18
+
- Write a `.code2skill/` bundle with a project summary, references, a Skill plan, generated Skills, a report, and incremental state.
19
+
- Estimate model cost and affected Skills before generation.
20
+
- Generate Skill Markdown from repository evidence using OpenAI Responses API, OpenAI-compatible Responses endpoints, Claude, or Qwen.
21
+
- Publish generated Skills into `AGENTS.md`, `CLAUDE.md`, `.cursor/rules/*`, `.github/copilot-instructions.md`, and `.windsurfrules`.
22
+
- Refresh outputs in CI with full or incremental mode.
23
+
- Validate the bundle and target files with `doctor`.
23
24
24
-
## Who Uses It
25
+
## Who It Is For
25
26
26
-
| User profile | What they need | How code2skill helps|
27
+
| User | Need | What code2skill provides|
27
28
|---|---|---|
28
-
| Python maintainers |AI assistants that respect current module boundaries and extension patterns |Generates evidence-backed Skills from source code and keeps them reviewable|
29
-
| DevEx and platform teams |A repeatable way to standardize AI coding context across many repositories | Exposes CLI, Python API, CI refresh, and readiness checks|
30
-
| Open-source maintainers |Contributor-facing AI instructions that can be audited like normal docs | Writes committed artifacts and target files instead of relying on private chat history|
31
-
|AI tooling evaluators | One repository knowledge layer that works across several assistants |Publishes the same Skills to Codex, Claude Code, Cursor, GitHub Copilot, and Windsurf|
29
+
| Python maintainers |Assistants should follow local architecture and naming patterns |Source-based Skill files and readiness checks|
30
+
| DevEx and platform teams |Several services need the same assistant setup process |CLI, Python API, CI refresh, and shared output layout|
31
+
| Open-source maintainers |Contributors need public project instructions instead of untracked notes | Committed files that can be reviewed with the rest of the repo|
32
+
|Tooling evaluators | One repository needs to work with several coding assistants |One generated Skill layer adapted into multiple target formats|
32
33
33
-
## Business Scenarios
34
+
## Common Scenarios
34
35
35
-
| Scenario |Trigger | Success signal|
36
+
| Scenario |When to use it | Expected result|
36
37
|---|---|---|
37
-
| First AI adoption| A repository starts using Codex, Cursor, Claude Code, Copilot, or Windsurf |`scan`, `adapt`, and `doctor` produce a ready target file |
38
-
|PR knowledge refresh | Code changes may invalidate existing AI instructions |`ci --mode auto` reports affected files and affected Skills |
39
-
| Multi-tool rollout| A team uses more than one AI coding assistant |`adapt --target all` writes consistent target outputs|
40
-
| Platform automation | A DevEx team runs repository-knowledge checks across many services | Python API returns structured results and readiness status |
41
-
|Open-source contributor onboarding | New contributors need implementation rules before changing code | Generated Skills and README/docs explain the repo's working contracts |
38
+
| First assistant setup| A repo starts using Codex, Cursor, Claude Code, Copilot, or Windsurf |`scan`, `adapt`, and `doctor` produce a ready target file |
39
+
|Pull request refresh | Code changes may make previous instructions stale |`ci --mode auto` reports changed files, affected files, and affected Skills |
40
+
| Multi-tool setup| A team uses more than one coding assistant |`adapt --target all` writes consistent target files|
41
+
| Platform automation | A DevEx team runs the workflow across many Python services | Python API returns structured results and readiness status |
42
+
|Contributor onboarding | New contributors need project-specific implementation rules | Generated Skills and docs describe the repo's working contracts |
42
43
43
44
## Install
44
45
@@ -231,6 +232,8 @@ For lower-level automation, use `create_scan_config(...)` with `scan_repository(
231
232
232
233
## Documentation
233
234
235
+
- English README: [README.md](https://github.com/oceanusXXD/code2skill/blob/main/README.md)
236
+
- Chinese README: [README.zh-CN.md](https://github.com/oceanusXXD/code2skill/blob/main/README.zh-CN.md)
Copy file name to clipboardExpand all lines: docs/ci.md
+2-2Lines changed: 2 additions & 2 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -1,6 +1,6 @@
1
1
# CI Guide
2
2
3
-
`code2skill ci --mode auto`is the automation-oriented entrypoint for keeping AI-facing repository knowledge current as code changes.
3
+
`code2skill ci --mode auto`refreshes generated repository instructions as code changes.
4
4
5
5
Auto mode uses the previous `.code2skill/state/analysis-state.json`, the previous `skill-plan.json`, and the current diff to choose between a full rebuild and an incremental refresh.
6
6
@@ -132,7 +132,7 @@ If these conditions are missing or invalid, `code2skill` falls back to a full re
132
132
133
133
## PR Review Strategy
134
134
135
-
Review these files when a PR changes generated repository knowledge:
135
+
Review these files when a PR changes generated instruction files:
-`estimate`: preview cost and impact without generating Skills or state
7
7
-`ci`: run automation-friendly full or incremental refresh
8
-
-`adapt`: publish generated Skills to target AI tool instruction files
8
+
-`adapt`: publish generated Skills to target tool instruction files
9
9
-`doctor`: verify that the bundle and optional target output are ready to use
10
10
11
11
`repo_path` is optional for every command and defaults to `.`. Relative paths are resolved from the target repository root, so you can run the CLI from inside or outside the repository.
Copy file name to clipboardExpand all lines: docs/output-layout.md
+3-3Lines changed: 3 additions & 3 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -2,7 +2,7 @@
2
2
3
3
By default, `code2skill` writes workflow artifacts under `.code2skill/` inside the target repository.
4
4
5
-
This bundle separates final AI-facing Skill products from intermediate artifacts used for review, diagnostics, cost reporting, and incremental CI refresh.
5
+
This bundle separates generated Skill files from intermediate artifacts used for diagnostics, cost reporting, and incremental CI refresh.
6
6
7
7
```text
8
8
.code2skill/
@@ -28,7 +28,7 @@ This bundle separates final AI-facing Skill products from intermediate artifacts
28
28
### Final Product Artifacts
29
29
30
30
-`skills/index.md`: the generated Skill inventory.
0 commit comments