you-skills 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.en.md +172 -0
- package/README.md +174 -0
- package/README.zh.md +162 -0
- package/client/index.html +15 -0
- package/client/src/App.vue +973 -0
- package/client/src/components/PathInput.vue +41 -0
- package/client/src/components/SkillCard.vue +242 -0
- package/client/src/components/SkillDetail.vue +75 -0
- package/client/src/components/SkillDrawer.vue +227 -0
- package/client/src/components/SkillList.vue +97 -0
- package/client/src/components/SkillListRow.vue +129 -0
- package/client/src/components/TheNav.vue +112 -0
- package/client/src/constants/themes.ts +209 -0
- package/client/src/i18n.ts +354 -0
- package/client/src/main.ts +5 -0
- package/client/src/styles/index.css +100 -0
- package/client/src/utils/fetchJson.ts +16 -0
- package/client/src/utils/markdown.ts +20 -0
- package/client/src/utils/sourceLabel.ts +11 -0
- package/client/vite.config.ts +18 -0
- package/dist/cli.d.ts +1 -0
- package/dist/cli.js +10 -0
- package/dist/client/assets/index-Bdvd5ggG.css +1 -0
- package/dist/client/assets/index-vzitjhDY.js +76 -0
- package/dist/client/index.html +16 -0
- package/dist/constants.d.ts +5 -0
- package/dist/constants.js +5 -0
- package/dist/server/index.d.ts +3 -0
- package/dist/server/index.js +93 -0
- package/dist/server/routes/browse.d.ts +1 -0
- package/dist/server/routes/browse.js +31 -0
- package/dist/server/routes/config.d.ts +12 -0
- package/dist/server/routes/config.js +80 -0
- package/dist/server/routes/skills.d.ts +7 -0
- package/dist/server/routes/skills.js +82 -0
- package/dist/skills/categoryCache.d.ts +27 -0
- package/dist/skills/categoryCache.js +85 -0
- package/dist/skills/classify.d.ts +10 -0
- package/dist/skills/classify.js +44 -0
- package/dist/skills/classifyScheme.d.ts +10 -0
- package/dist/skills/classifyScheme.js +69 -0
- package/dist/skills/config.d.ts +17 -0
- package/dist/skills/config.js +66 -0
- package/dist/skills/parse.d.ts +21 -0
- package/dist/skills/parse.js +47 -0
- package/dist/skills/paths.d.ts +9 -0
- package/dist/skills/paths.js +28 -0
- package/dist/skills/presets/classificationsData.d.ts +104 -0
- package/dist/skills/presets/classificationsData.js +54 -0
- package/dist/skills/scan.d.ts +20 -0
- package/dist/skills/scan.js +76 -0
- package/package.json +63 -0
- package/postcss.config.cjs +6 -0
- package/src/cli.ts +12 -0
- package/src/constants.ts +6 -0
- package/src/server/index.ts +103 -0
- package/src/server/routes/browse.ts +33 -0
- package/src/server/routes/config.ts +90 -0
- package/src/server/routes/skills.ts +84 -0
- package/src/skills/categoryCache.ts +91 -0
- package/src/skills/classify.ts +48 -0
- package/src/skills/classifyScheme.ts +72 -0
- package/src/skills/config.ts +94 -0
- package/src/skills/parse.ts +63 -0
- package/src/skills/paths.ts +35 -0
- package/src/skills/presets/classificationsData.ts +56 -0
- package/src/skills/scan.ts +76 -0
- package/tailwind.config.js +32 -0
- package/tsconfig.json +16 -0
- package/tsconfig.server.json +10 -0
package/README.en.md
ADDED
|
@@ -0,0 +1,172 @@
|
|
|
1
|
+
# YouSkills
|
|
2
|
+
|
|
3
|
+
Visual Management for Local Skills.
|
|
4
|
+
|
|
5
|
+
YouSkills is a **visual manager for local AI skills**. It scans standard skill folders on your machine (Codex / Cursor / OpenClaw / custom paths) and shows them in a clean web UI, while staying **strictly read‑only** and **agent‑friendly**.
|
|
6
|
+
|
|
7
|
+
---
|
|
8
|
+
|
|
9
|
+
## Features
|
|
10
|
+
|
|
11
|
+
- **Local‑only visualization**
|
|
12
|
+
- Scans standard skill roots (e.g. `~/.codex/skills`, `~/.cursor/skills`, `~/.openclaw/skills`, `~/.agents/skills`) and user‑specified paths.
|
|
13
|
+
- Card view and list view with rich filters.
|
|
14
|
+
|
|
15
|
+
- **Strictly read‑only**
|
|
16
|
+
- Never edits, renames or deletes any files inside your skill directories.
|
|
17
|
+
- Only reads metadata / `SKILL.md` and stores its own cache under `~/.you-skills/`.
|
|
18
|
+
|
|
19
|
+
- **Classification with local cache**
|
|
20
|
+
- Three schemes:
|
|
21
|
+
- **Output‑centric skills** (`by_output`)
|
|
22
|
+
- **Workflow‑centric skills** (`by_scenario`)
|
|
23
|
+
- **Role‑centric skills** (`by_role`)
|
|
24
|
+
- Leaf categories have Chinese + English labels and can be changed by the user.
|
|
25
|
+
- All user changes are written to a local cache file, not to the skills themselves.
|
|
26
|
+
|
|
27
|
+
- **Themes**
|
|
28
|
+
- 11 built‑in color themes (default light gray, matcha green, apricot, lavender, midnight tomato, sea‑salt teal, lotus pink, glacier dark, terracotta, lava black & gold, chalk blue).
|
|
29
|
+
- Switch themes in the UI; the choice is persisted to `~/.you-skills/config.json`.
|
|
30
|
+
|
|
31
|
+
- **Internationalization**
|
|
32
|
+
- First version ships with **Chinese + English**.
|
|
33
|
+
- The landing / consent flow and navigation include a language toggle (`中 / EN`).
|
|
34
|
+
|
|
35
|
+
- **Agent‑friendly HTTP API**
|
|
36
|
+
- Simple JSON endpoints like `/api/skills` and `/api/manifest` so agents can introspect the same local skills.
|
|
37
|
+
|
|
38
|
+
---
|
|
39
|
+
|
|
40
|
+
## Quick start
|
|
41
|
+
|
|
42
|
+
Requires **Node.js 18+**.
|
|
43
|
+
|
|
44
|
+
```bash
|
|
45
|
+
git clone <this-repo>
|
|
46
|
+
cd you_skills
|
|
47
|
+
|
|
48
|
+
npm install
|
|
49
|
+
npm run build
|
|
50
|
+
npm start # opens http://localhost:12434
|
|
51
|
+
```
|
|
52
|
+
|
|
53
|
+
After publishing to npm, you will be able to run:
|
|
54
|
+
|
|
55
|
+
```bash
|
|
56
|
+
npx you-skills
|
|
57
|
+
```
|
|
58
|
+
|
|
59
|
+
By default the app opens `http://localhost:12434` in your browser.
|
|
60
|
+
|
|
61
|
+
---
|
|
62
|
+
|
|
63
|
+
## Port & environment variables
|
|
64
|
+
|
|
65
|
+
- **Port**: `12434`
|
|
66
|
+
- **URL**: `http://localhost:12434`
|
|
67
|
+
|
|
68
|
+
Optional environment variables:
|
|
69
|
+
|
|
70
|
+
- `CODEX_HOME`: Codex home directory (defaults to `~/.codex`)
|
|
71
|
+
- `CURSOR_HOME`: Cursor home directory (defaults to `~/.cursor`)
|
|
72
|
+
|
|
73
|
+
If no skills are found under the default paths, the landing page asks you to enter or pick a custom root directory.
|
|
74
|
+
|
|
75
|
+
---
|
|
76
|
+
|
|
77
|
+
## API (for agents / integrations)
|
|
78
|
+
|
|
79
|
+
- `GET /api/skills?root=`
|
|
80
|
+
- List skills under the default roots or a custom `root` path.
|
|
81
|
+
- Response includes `path`, `name`, `description`, `category`, and more.
|
|
82
|
+
|
|
83
|
+
- `GET /api/skills/manifest` / `GET /api/manifest`
|
|
84
|
+
- Returns a structured manifest, suitable for agents to load all available skills at once.
|
|
85
|
+
|
|
86
|
+
- `PATCH /api/skills/category`
|
|
87
|
+
- Update the category for one skill.
|
|
88
|
+
- Body example:
|
|
89
|
+
```json
|
|
90
|
+
{ "path": "/absolute/path/to/skill", "category": "Document skills" }
|
|
91
|
+
```
|
|
92
|
+
- Writes to `~/.you-skills/category-cache.json` only.
|
|
93
|
+
|
|
94
|
+
- `GET /api/browse?path=`
|
|
95
|
+
- List sub‑directories under a given path, used by the UI when picking a root directory.
|
|
96
|
+
|
|
97
|
+
- `GET /api/config`
|
|
98
|
+
- Read current configuration: `classification_scheme_id`, `theme_id`, and scheme metadata.
|
|
99
|
+
|
|
100
|
+
- `PATCH /api/config`
|
|
101
|
+
- Update configuration. Body example:
|
|
102
|
+
```jsonc
|
|
103
|
+
{
|
|
104
|
+
"classification_scheme_id": "by_output" | "by_scenario" | "by_role",
|
|
105
|
+
"theme_id": "default" | "matcha" | "apricot" | ...
|
|
106
|
+
}
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
---
|
|
110
|
+
|
|
111
|
+
## Classification & cache
|
|
112
|
+
|
|
113
|
+
- **Schemes**
|
|
114
|
+
- `by_output` – Output‑centric skills.
|
|
115
|
+
- `by_scenario` – Workflow‑centric skills.
|
|
116
|
+
- `by_role` – Role‑centric skills.
|
|
117
|
+
|
|
118
|
+
- **Leaf categories** (examples)
|
|
119
|
+
- Output‑centric: *File generation*, *Web & interface*, *Tools & integrations*, *Content & writing*.
|
|
120
|
+
- Workflow‑centric: *Office documents*, *Design & visuals*, *Development & build*, *Knowledge & reference*.
|
|
121
|
+
- Role‑centric: *Managers & ops*, *Designers*, *Developers & engineers*, *Data analysts*, *HR / Legal / Admin*, *Marketing & brand*.
|
|
122
|
+
|
|
123
|
+
- **Cache file**
|
|
124
|
+
- `~/.you-skills/category-cache.json`
|
|
125
|
+
- Maps absolute skill paths to the final category chosen by the system + the user.
|
|
126
|
+
|
|
127
|
+
At scan time the app:
|
|
128
|
+
|
|
129
|
+
1. Reads the cache first.
|
|
130
|
+
2. If there is no entry, infers a category from the skill’s `name` / `description` using regex‑based rules.
|
|
131
|
+
3. Writes the result back to the cache.
|
|
132
|
+
4. Allows the user to override the category from the UI; overrides also go into the cache.
|
|
133
|
+
|
|
134
|
+
---
|
|
135
|
+
|
|
136
|
+
## Development
|
|
137
|
+
|
|
138
|
+
```bash
|
|
139
|
+
# build server only (debug API)
|
|
140
|
+
npm run build:server
|
|
141
|
+
|
|
142
|
+
# build client only
|
|
143
|
+
npm run build:client
|
|
144
|
+
|
|
145
|
+
# during development: build server, then run Vite dev server for the client
|
|
146
|
+
npm run build:server && npm run dev:client
|
|
147
|
+
|
|
148
|
+
# run the built server in another terminal
|
|
149
|
+
node dist/server/index.js
|
|
150
|
+
```
|
|
151
|
+
|
|
152
|
+
---
|
|
153
|
+
|
|
154
|
+
## Security & privacy
|
|
155
|
+
|
|
156
|
+
- Reads from local skill directories **only**; there is no login, no telemetry and no remote upload.
|
|
157
|
+
- The app **never** writes to, renames or deletes any user skill files or directories.
|
|
158
|
+
- All persistent state lives under `~/.you-skills/`:
|
|
159
|
+
- `config.json` – classification scheme + theme id.
|
|
160
|
+
- `category-cache.json` – path → category cache for classification.
|
|
161
|
+
|
|
162
|
+
---
|
|
163
|
+
|
|
164
|
+
## Fun facts
|
|
165
|
+
|
|
166
|
+
- **Why port `12434`?**
|
|
167
|
+
It is a small easter egg: the number echoes the average monthly salary in Shanghai in 2025. Easy to remember, and a quiet nod to everyday developers.
|
|
168
|
+
|
|
169
|
+
- **Why `YouSkills`, not `YourSkills`?**
|
|
170
|
+
From an AI’s point of view, humans themselves are becoming collections of skills.
|
|
171
|
+
The name `YouSkills` is a hint that *you* and your skills are both first‑class citizens here — it's about **“you = skills”**, not just “your skills” as external objects.
|
|
172
|
+
|
package/README.md
ADDED
|
@@ -0,0 +1,174 @@
|
|
|
1
|
+
# YouSkills
|
|
2
|
+
|
|
3
|
+
> [简体中文](./README.zh.md) | English
|
|
4
|
+
|
|
5
|
+
Visual Management for Local Skills.
|
|
6
|
+
|
|
7
|
+
YouSkills is a **visual manager for local AI skills**. It scans standard skill folders on your machine (Codex / Cursor / OpenClaw / custom paths) and shows them in a clean web UI, while staying **strictly read‑only** and **agent‑friendly**.
|
|
8
|
+
|
|
9
|
+
---
|
|
10
|
+
|
|
11
|
+
## Features
|
|
12
|
+
|
|
13
|
+
- **Local‑only visualization**
|
|
14
|
+
- Scans standard skill roots (e.g. `~/.codex/skills`, `~/.cursor/skills`, `~/.openclaw/skills`, `~/.agents/skills`) and user‑specified paths.
|
|
15
|
+
- Card view and list view with rich filters.
|
|
16
|
+
|
|
17
|
+
- **Strictly read‑only**
|
|
18
|
+
- Never edits, renames or deletes any files inside your skill directories.
|
|
19
|
+
- Only reads metadata / `SKILL.md` and stores its own cache under `~/.you-skills/`.
|
|
20
|
+
|
|
21
|
+
- **Classification with local cache**
|
|
22
|
+
- Three schemes:
|
|
23
|
+
- **Output‑centric skills** (`by_output`)
|
|
24
|
+
- **Workflow‑centric skills** (`by_scenario`)
|
|
25
|
+
- **Role‑centric skills** (`by_role`)
|
|
26
|
+
- Leaf categories have Chinese + English labels and can be changed by the user.
|
|
27
|
+
- All user changes are written to a local cache file, not to the skills themselves.
|
|
28
|
+
|
|
29
|
+
- **Themes**
|
|
30
|
+
- 11 built‑in color themes (default light gray, matcha green, apricot, lavender, midnight tomato, sea‑salt teal, lotus pink, glacier dark, terracotta, lava black & gold, chalk blue).
|
|
31
|
+
- Switch themes in the UI; the choice is persisted to `~/.you-skills/config.json`.
|
|
32
|
+
|
|
33
|
+
- **Internationalization**
|
|
34
|
+
- First version ships with **Chinese + English**.
|
|
35
|
+
- The landing / consent flow and navigation include a language toggle (`中 / EN`).
|
|
36
|
+
|
|
37
|
+
- **Agent‑friendly HTTP API**
|
|
38
|
+
- Simple JSON endpoints like `/api/skills` and `/api/manifest` so agents can introspect the same local skills.
|
|
39
|
+
|
|
40
|
+
---
|
|
41
|
+
|
|
42
|
+
## Quick start
|
|
43
|
+
|
|
44
|
+
Requires **Node.js 18+**.
|
|
45
|
+
|
|
46
|
+
```bash
|
|
47
|
+
git clone <this-repo>
|
|
48
|
+
cd you_skills
|
|
49
|
+
|
|
50
|
+
npm install
|
|
51
|
+
npm run build
|
|
52
|
+
npm start # opens http://localhost:12434
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
After publishing to npm, you will be able to run:
|
|
56
|
+
|
|
57
|
+
```bash
|
|
58
|
+
npx you-skills
|
|
59
|
+
```
|
|
60
|
+
|
|
61
|
+
By default the app opens `http://localhost:12434` in your browser.
|
|
62
|
+
|
|
63
|
+
---
|
|
64
|
+
|
|
65
|
+
## Port & environment variables
|
|
66
|
+
|
|
67
|
+
- **Port**: `12434`
|
|
68
|
+
- **URL**: `http://localhost:12434`
|
|
69
|
+
|
|
70
|
+
Optional environment variables:
|
|
71
|
+
|
|
72
|
+
- `CODEX_HOME`: Codex home directory (defaults to `~/.codex`)
|
|
73
|
+
- `CURSOR_HOME`: Cursor home directory (defaults to `~/.cursor`)
|
|
74
|
+
|
|
75
|
+
If no skills are found under the default paths, the landing page asks you to enter or pick a custom root directory.
|
|
76
|
+
|
|
77
|
+
---
|
|
78
|
+
|
|
79
|
+
## API (for agents / integrations)
|
|
80
|
+
|
|
81
|
+
- `GET /api/skills?root=`
|
|
82
|
+
- List skills under the default roots or a custom `root` path.
|
|
83
|
+
- Response includes `path`, `name`, `description`, `category`, and more.
|
|
84
|
+
|
|
85
|
+
- `GET /api/skills/manifest` / `GET /api/manifest`
|
|
86
|
+
- Returns a structured manifest, suitable for agents to load all available skills at once.
|
|
87
|
+
|
|
88
|
+
- `PATCH /api/skills/category`
|
|
89
|
+
- Update the category for one skill.
|
|
90
|
+
- Body example:
|
|
91
|
+
```json
|
|
92
|
+
{ "path": "/absolute/path/to/skill", "category": "Document skills" }
|
|
93
|
+
```
|
|
94
|
+
- Writes to `~/.you-skills/category-cache.json` only.
|
|
95
|
+
|
|
96
|
+
- `GET /api/browse?path=`
|
|
97
|
+
- List sub‑directories under a given path, used by the UI when picking a root directory.
|
|
98
|
+
|
|
99
|
+
- `GET /api/config`
|
|
100
|
+
- Read current configuration: `classification_scheme_id`, `theme_id`, and scheme metadata.
|
|
101
|
+
|
|
102
|
+
- `PATCH /api/config`
|
|
103
|
+
- Update configuration. Body example:
|
|
104
|
+
```jsonc
|
|
105
|
+
{
|
|
106
|
+
"classification_scheme_id": "by_output" | "by_scenario" | "by_role",
|
|
107
|
+
"theme_id": "default" | "matcha" | "apricot" | ...
|
|
108
|
+
}
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
---
|
|
112
|
+
|
|
113
|
+
## Classification & cache
|
|
114
|
+
|
|
115
|
+
- **Schemes**
|
|
116
|
+
- `by_output` – Output‑centric skills.
|
|
117
|
+
- `by_scenario` – Workflow‑centric skills.
|
|
118
|
+
- `by_role` – Role‑centric skills.
|
|
119
|
+
|
|
120
|
+
- **Leaf categories** (examples)
|
|
121
|
+
- Output‑centric: *File generation*, *Web & interface*, *Tools & integrations*, *Content & writing*.
|
|
122
|
+
- Workflow‑centric: *Office documents*, *Design & visuals*, *Development & build*, *Knowledge & reference*.
|
|
123
|
+
- Role‑centric: *Managers & ops*, *Designers*, *Developers & engineers*, *Data analysts*, *HR / Legal / Admin*, *Marketing & brand*.
|
|
124
|
+
|
|
125
|
+
- **Cache file**
|
|
126
|
+
- `~/.you-skills/category-cache.json`
|
|
127
|
+
- Maps absolute skill paths to the final category chosen by the system + the user.
|
|
128
|
+
|
|
129
|
+
At scan time the app:
|
|
130
|
+
|
|
131
|
+
1. Reads the cache first.
|
|
132
|
+
2. If there is no entry, infers a category from the skill’s `name` / `description` using regex‑based rules.
|
|
133
|
+
3. Writes the result back to the cache.
|
|
134
|
+
4. Allows the user to override the category from the UI; overrides also go into the cache.
|
|
135
|
+
|
|
136
|
+
---
|
|
137
|
+
|
|
138
|
+
## Development
|
|
139
|
+
|
|
140
|
+
```bash
|
|
141
|
+
# build server only (debug API)
|
|
142
|
+
npm run build:server
|
|
143
|
+
|
|
144
|
+
# build client only
|
|
145
|
+
npm run build:client
|
|
146
|
+
|
|
147
|
+
# during development: build server, then run Vite dev server for the client
|
|
148
|
+
npm run build:server && npm run dev:client
|
|
149
|
+
|
|
150
|
+
# run the built server in another terminal
|
|
151
|
+
node dist/server/index.js
|
|
152
|
+
```
|
|
153
|
+
|
|
154
|
+
---
|
|
155
|
+
|
|
156
|
+
## Security & privacy
|
|
157
|
+
|
|
158
|
+
- Reads from local skill directories **only**; there is no login, no telemetry and no remote upload.
|
|
159
|
+
- The app **never** writes to, renames or deletes any user skill files or directories.
|
|
160
|
+
- All persistent state lives under `~/.you-skills/`:
|
|
161
|
+
- `config.json` – classification scheme + theme id.
|
|
162
|
+
- `category-cache.json` – path → category cache for classification.
|
|
163
|
+
|
|
164
|
+
---
|
|
165
|
+
|
|
166
|
+
## Fun facts
|
|
167
|
+
|
|
168
|
+
- **Why port `12434`?**
|
|
169
|
+
It is a small easter egg: the number echoes the average monthly salary in Shanghai in 2025. Easy to remember, and a quiet nod to everyday developers.
|
|
170
|
+
|
|
171
|
+
- **Why `YouSkills`, not `YourSkills`?**
|
|
172
|
+
From an AI’s point of view, humans themselves are becoming collections of skills.
|
|
173
|
+
The name `YouSkills` is a hint that *you* and your skills are both first‑class citizens here — it's about **“you = skills”**, not just “your skills” as external objects.
|
|
174
|
+
|
package/README.zh.md
ADDED
|
@@ -0,0 +1,162 @@
|
|
|
1
|
+
# YouSkills
|
|
2
|
+
|
|
3
|
+
本地 Skills 可视化器:在浏览器中查看本机已安装的 AI Skills(Codex、Cursor、OpenClaw 等),**纯本地、只读、不修改用户数据**。
|
|
4
|
+
同时针对 Agent 友好,提供简单 API 方便二次集成。
|
|
5
|
+
|
|
6
|
+
---
|
|
7
|
+
|
|
8
|
+
## 特性一览
|
|
9
|
+
|
|
10
|
+
- **本地可视化**:扫描多种默认 Skills 安装目录,也支持自定义路径;结果以卡片视图和列表视图展示。
|
|
11
|
+
- **严格只读**:只做文件系统读取,不写入、不重命名、不删除用户的任何 Skills 文件。
|
|
12
|
+
- **动态分类 + 缓存**:支持多种分类方案(按输出物 / 按使用场景 / 按职业角色),并在本地缓存用户调整结果。
|
|
13
|
+
- **可调分类**:在卡片、列表行和详情抽屉中都可以直接修改分类,小分类使用中英双语展示。
|
|
14
|
+
- **主题与样式**:内置 11 套配色主题,可在界面中即时预览并保存。
|
|
15
|
+
- **国际化(i18n)**:目前支持 **中文 / 英文**,首屏和导航提供语言切换入口。
|
|
16
|
+
- **Agent 友好 API**:提供 `/api/skills`、`/api/manifest` 等接口,方便其他 Agent 或工具读取本地 Skills 清单。
|
|
17
|
+
|
|
18
|
+
---
|
|
19
|
+
|
|
20
|
+
## 快速开始
|
|
21
|
+
|
|
22
|
+
需要 Node.js **18+**。
|
|
23
|
+
|
|
24
|
+
```bash
|
|
25
|
+
# 安装依赖
|
|
26
|
+
npm install
|
|
27
|
+
|
|
28
|
+
# 构建(先前端后服务端)
|
|
29
|
+
npm run build
|
|
30
|
+
|
|
31
|
+
# 启动:本地服务 + 自动打开浏览器
|
|
32
|
+
npm start
|
|
33
|
+
# 或
|
|
34
|
+
node dist/cli.js
|
|
35
|
+
```
|
|
36
|
+
|
|
37
|
+
发布到 npm 之后,可以直接通过 npx 运行(无需 clone 仓库):
|
|
38
|
+
|
|
39
|
+
```bash
|
|
40
|
+
npx you-skills
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
默认会在浏览器中打开:`http://localhost:12434`。
|
|
44
|
+
|
|
45
|
+
---
|
|
46
|
+
|
|
47
|
+
## 端口与环境变量
|
|
48
|
+
|
|
49
|
+
- **服务端口**:固定为 `12434`
|
|
50
|
+
- **访问地址**:`http://localhost:12434`
|
|
51
|
+
|
|
52
|
+
可选环境变量(用于默认扫描路径):
|
|
53
|
+
|
|
54
|
+
- `CODEX_HOME`:Codex 根目录,默认 `~/.codex`
|
|
55
|
+
- `CURSOR_HOME`:Cursor 根目录,默认 `~/.cursor`
|
|
56
|
+
|
|
57
|
+
> 若默认路径下未找到 Skills,首屏会引导用户手动输入或选择 Skills 根目录。
|
|
58
|
+
|
|
59
|
+
---
|
|
60
|
+
|
|
61
|
+
## API(面向 Agent / 集成)
|
|
62
|
+
|
|
63
|
+
- **`GET /api/skills?root=`**
|
|
64
|
+
- 获取 Skills 列表。`root` 为空时使用默认扫描路径,否则使用指定路径。
|
|
65
|
+
- 返回字段包含 `path`、`name`、`description`、`category` 等。
|
|
66
|
+
|
|
67
|
+
- **`GET /api/skills/manifest`** / **`GET /api/manifest`**
|
|
68
|
+
- 以结构化形式返回 Skills 清单,方便 Agent 一次性读取所有可用技能。
|
|
69
|
+
|
|
70
|
+
- **`PATCH /api/skills/category`**
|
|
71
|
+
- 用户调整分类;Body 形如:
|
|
72
|
+
`{ "path": "<skill 绝对路径>", "category": "<新的类别名>" }`
|
|
73
|
+
- 写入本地缓存,不改动 Skills 本身。
|
|
74
|
+
|
|
75
|
+
- **`GET /api/browse?path=`**
|
|
76
|
+
- 列出指定路径下的子目录,用于前端“选择 Skills 根目录”时的目录浏览。
|
|
77
|
+
|
|
78
|
+
- **`GET /api/config`**
|
|
79
|
+
- 读取当前配置:`classification_scheme_id`、`theme_id` 以及可选的分类方案信息。
|
|
80
|
+
|
|
81
|
+
- **`PATCH /api/config`**
|
|
82
|
+
- 更新配置,Body 示例:
|
|
83
|
+
```jsonc
|
|
84
|
+
{
|
|
85
|
+
"classification_scheme_id": "by_output" | "by_scenario" | "by_role",
|
|
86
|
+
"theme_id": "default" | "matcha" | "apricot" | ...
|
|
87
|
+
}
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
---
|
|
91
|
+
|
|
92
|
+
## 配置与主题
|
|
93
|
+
|
|
94
|
+
- **配置文件路径**:`~/.you-skills/config.json`
|
|
95
|
+
- 字段:
|
|
96
|
+
- `classification_scheme_id`: `"by_output" | "by_scenario" | "by_role"`
|
|
97
|
+
- `theme_id`: 主题 id(如 `"default"`, `"matcha"`, `"apricot"` …)
|
|
98
|
+
|
|
99
|
+
- **内置主题**:
|
|
100
|
+
- 提供 11 套主题,包括浅灰默认、抹茶绿、杏粉、薰衣草、深夜番茄、海盐蓝绿、枯荷粉、冰川极光橙、砖红陶土、熔岩黑金、粉笔蓝 × 番红花等。
|
|
101
|
+
- 可在界面右上角的「Theme / 主题」入口中即时预览并保存。
|
|
102
|
+
|
|
103
|
+
---
|
|
104
|
+
|
|
105
|
+
## 分类与本地缓存
|
|
106
|
+
|
|
107
|
+
- **分类方案(大类)**:
|
|
108
|
+
- `by_output`:输出物维度(Output‑centric skills)
|
|
109
|
+
- `by_scenario`:使用场景维度(Workflow‑centric skills)
|
|
110
|
+
- `by_role`:职业角色维度(Role‑centric skills)
|
|
111
|
+
|
|
112
|
+
- **小类示例**:
|
|
113
|
+
- 输出物维度:`文件生成 / File generation`、`网页与界面 / Web & interface`、`工具与集成 / Tools & integrations`、`内容与写作 / Content & writing` 等。
|
|
114
|
+
- 使用场景维度:`文档办公 / Office documents`、`设计视觉 / Design & visuals`、`开发构建 / Development & build`、`知识参考 / Knowledge & reference` 等。
|
|
115
|
+
- 职业角色维度:`管理者 / 运营`、`设计师`、`开发者 / 工程师`、`数据分析师`、`HR / 法务 / 行政`、`市场 / 品牌` 等。
|
|
116
|
+
|
|
117
|
+
- **分类缓存文件**:`~/.you-skills/category-cache.json`
|
|
118
|
+
- 键:Skill 绝对路径
|
|
119
|
+
- 值:用户最终确认的分类(包括推断结果 + 手动修改)
|
|
120
|
+
|
|
121
|
+
- **工作方式**:
|
|
122
|
+
1. 扫描时优先读取缓存中的类别。
|
|
123
|
+
2. 若无缓存,则基于「名称 + 描述」与预设规则进行本地正则推断,并写回缓存。
|
|
124
|
+
3. 用户在界面中手动修改分类时,会通过 `PATCH /api/skills/category` 写入缓存。
|
|
125
|
+
|
|
126
|
+
---
|
|
127
|
+
|
|
128
|
+
## 开发说明
|
|
129
|
+
|
|
130
|
+
```bash
|
|
131
|
+
# 仅构建服务端(调试 API)
|
|
132
|
+
npm run build:server
|
|
133
|
+
|
|
134
|
+
# 仅构建前端
|
|
135
|
+
npm run build:client
|
|
136
|
+
|
|
137
|
+
# 开发时:先构建服务端,再单独跑 Vite(前端 dev 环境会通过代理访问 12434 端口)
|
|
138
|
+
npm run build:server && npm run dev:client
|
|
139
|
+
|
|
140
|
+
# 另开一个终端跑 Node 服务
|
|
141
|
+
node dist/server/index.js
|
|
142
|
+
```
|
|
143
|
+
|
|
144
|
+
---
|
|
145
|
+
|
|
146
|
+
## 安全与隐私
|
|
147
|
+
|
|
148
|
+
- 仅读取本机磁盘中的 Skills 目录,无登录、无远程上传、无遥测。
|
|
149
|
+
- **不会**对用户 Skills 目录或文件进行任何写入、删除、重命名或内容修改。
|
|
150
|
+
- 默认扫描路径:`$CODEX_HOME/skills`、`$CURSOR_HOME/skills`、`~/.openclaw/skills`、`~/.agents/skills`;若未找到,可在首屏或工具栏中输入 / 选择自定义路径。
|
|
151
|
+
|
|
152
|
+
---
|
|
153
|
+
|
|
154
|
+
## 趣味说明
|
|
155
|
+
|
|
156
|
+
- **为什么端口是 `12434`?**
|
|
157
|
+
这是 2025 年上海平均薪资的一个“影子记忆”,希望这个端口号既容易记,又带一点“打工人小彩蛋”的味道。
|
|
158
|
+
|
|
159
|
+
- **为什么叫 `YouSkills` 而不是 `YourSkills`?**
|
|
160
|
+
在 AI 视角下,人本身也会逐渐变成一组 Skills 的组合。
|
|
161
|
+
`YouSkills` 更像是一个对话:既是在管理 “your skills”,也是在提示 **“you = skills”**——你和你的技能,都是这个系统里的一等公民。
|
|
162
|
+
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
<!DOCTYPE html>
|
|
2
|
+
<html lang="zh-CN">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="UTF-8" />
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
6
|
+
<title>YouSkills</title>
|
|
7
|
+
<link rel="preconnect" href="https://fonts.googleapis.com" />
|
|
8
|
+
<link rel="preconnect" href="https://fonts.gstatic.com" crossorigin />
|
|
9
|
+
<link href="https://fonts.googleapis.com/css2?family=Inter:opsz,wght@14..32,300;14..32,400;14..32,500;14..32,600;14..32,700&family=JetBrains+Mono:wght@400;500&display=swap" rel="stylesheet" />
|
|
10
|
+
</head>
|
|
11
|
+
<body>
|
|
12
|
+
<div id="app"></div>
|
|
13
|
+
<script type="module" src="/src/main.ts"></script>
|
|
14
|
+
</body>
|
|
15
|
+
</html>
|