@nano-step/skill-manager 5.1.0 → 5.2.1

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.
Files changed (63) hide show
  1. package/dist/utils.d.ts +1 -1
  2. package/dist/utils.js +1 -1
  3. package/package.json +1 -1
  4. package/skills/blog-workflow/SKILL.md +522 -0
  5. package/skills/blog-workflow/skill.json +16 -0
  6. package/skills/comprehensive-feature-builder/SKILL.md +558 -0
  7. package/skills/comprehensive-feature-builder/skill.json +9 -0
  8. package/skills/idea-workflow/SKILL.md +229 -0
  9. package/skills/idea-workflow/skill.json +14 -0
  10. package/skills/reddit-workflow/SKILL.md +187 -0
  11. package/skills/reddit-workflow/skill.json +14 -0
  12. package/skills/rtk-setup/SKILL.md +118 -0
  13. package/skills/rtk-setup/skill.json +14 -0
  14. package/skills/security-workflow/SKILL.md +258 -0
  15. package/skills/security-workflow/skill.json +15 -0
  16. package/skills/skill-creator/LICENSE.txt +202 -0
  17. package/skills/skill-creator/SKILL.md +309 -0
  18. package/skills/skill-creator/references/metadata-quality-criteria.md +76 -0
  19. package/skills/skill-creator/references/plugin-marketplace-hosting.md +101 -0
  20. package/skills/skill-creator/references/plugin-marketplace-overview.md +55 -0
  21. package/skills/skill-creator/references/plugin-marketplace-schema.md +88 -0
  22. package/skills/skill-creator/references/plugin-marketplace-sources.md +103 -0
  23. package/skills/skill-creator/references/plugin-marketplace-troubleshooting.md +80 -0
  24. package/skills/skill-creator/references/script-quality-criteria.md +106 -0
  25. package/skills/skill-creator/references/structure-organization-criteria.md +114 -0
  26. package/skills/skill-creator/references/token-efficiency-criteria.md +74 -0
  27. package/skills/skill-creator/references/validation-checklist.md +83 -0
  28. package/skills/skill-creator/scripts/encoding_utils.py +36 -0
  29. package/skills/skill-creator/scripts/init_skill.py +308 -0
  30. package/skills/skill-creator/scripts/package_skill.py +115 -0
  31. package/skills/skill-creator/scripts/quick_validate.py +69 -0
  32. package/skills/skill-creator/skill.json +14 -0
  33. package/skills/team-workflow/SKILL.md +227 -0
  34. package/skills/team-workflow/skill.json +15 -0
  35. package/skills/ui-ux-pro-max/SKILL.md +292 -0
  36. package/skills/ui-ux-pro-max/data/charts.csv +26 -0
  37. package/skills/ui-ux-pro-max/data/colors.csv +97 -0
  38. package/skills/ui-ux-pro-max/data/icons.csv +101 -0
  39. package/skills/ui-ux-pro-max/data/landing.csv +31 -0
  40. package/skills/ui-ux-pro-max/data/products.csv +97 -0
  41. package/skills/ui-ux-pro-max/data/react-performance.csv +45 -0
  42. package/skills/ui-ux-pro-max/data/stacks/astro.csv +54 -0
  43. package/skills/ui-ux-pro-max/data/stacks/flutter.csv +53 -0
  44. package/skills/ui-ux-pro-max/data/stacks/html-tailwind.csv +56 -0
  45. package/skills/ui-ux-pro-max/data/stacks/jetpack-compose.csv +53 -0
  46. package/skills/ui-ux-pro-max/data/stacks/nextjs.csv +53 -0
  47. package/skills/ui-ux-pro-max/data/stacks/nuxt-ui.csv +51 -0
  48. package/skills/ui-ux-pro-max/data/stacks/nuxtjs.csv +59 -0
  49. package/skills/ui-ux-pro-max/data/stacks/react-native.csv +52 -0
  50. package/skills/ui-ux-pro-max/data/stacks/react.csv +54 -0
  51. package/skills/ui-ux-pro-max/data/stacks/shadcn.csv +61 -0
  52. package/skills/ui-ux-pro-max/data/stacks/svelte.csv +54 -0
  53. package/skills/ui-ux-pro-max/data/stacks/swiftui.csv +51 -0
  54. package/skills/ui-ux-pro-max/data/stacks/vue.csv +50 -0
  55. package/skills/ui-ux-pro-max/data/styles.csv +68 -0
  56. package/skills/ui-ux-pro-max/data/typography.csv +58 -0
  57. package/skills/ui-ux-pro-max/data/ui-reasoning.csv +101 -0
  58. package/skills/ui-ux-pro-max/data/ux-guidelines.csv +100 -0
  59. package/skills/ui-ux-pro-max/data/web-interface.csv +31 -0
  60. package/skills/ui-ux-pro-max/scripts/core.py +253 -0
  61. package/skills/ui-ux-pro-max/scripts/design_system.py +1067 -0
  62. package/skills/ui-ux-pro-max/scripts/search.py +114 -0
  63. package/skills/ui-ux-pro-max/skill.json +16 -0
@@ -0,0 +1,229 @@
1
+ ---
2
+ description: Analyze source code or project structure and produce a comprehensive monetization strategy with execution blueprint
3
+ ---
4
+
5
+ Analyze a project's source code or structure and produce a world-class monetization strategy. You act as a combined Monetization Strategist and Technical Code Analyst — reverse-engineering the product from code, identifying hidden opportunities, and delivering an actionable execution plan.
6
+
7
+ **Default language**: Vietnamese (output). Switch to English if user explicitly requests.
8
+
9
+ **Input**: The argument after `/idea` is either:
10
+ - A path to source code or project directory
11
+ - A description of the project/product
12
+ - A GitHub repo URL
13
+ - Nothing (analyze the current project in the working directory)
14
+
15
+ If the input is unclear, ask ONE clarifying question. Then proceed with reasonable assumptions.
16
+
17
+ ---
18
+
19
+ ## Role Identity
20
+
21
+ You operate as a world-class monetization strategist who also reads code deeply:
22
+
23
+ - **Business expertise**: SaaS monetization, platform economics, pricing psychology, behavioral economics, growth hacking, marketplace models, API monetization, licensing strategies
24
+ - **Technical expertise**: Reverse-engineer products from code, identify hidden technical leverage, assess scalability and competitive moats from architecture
25
+ - **Mindset**: Think like a founder building a $100M+ product. Focus on leverage, unfair advantages, and defensibility
26
+
27
+ ---
28
+
29
+ ## Workflow (executed sequentially)
30
+
31
+ ### PHASE 1 — Project Intelligence Extraction
32
+
33
+ **1. Technical Analysis** (read code/structure first):
34
+ - Tech stack (languages, frameworks, dependencies)
35
+ - Architecture pattern (monolith, microservices, serverless, extension, CLI, etc.)
36
+ - Core functionality — what does this product actually DO?
37
+ - Hidden capabilities — what COULD it do that it doesn't yet?
38
+ - Performance constraints and technical debt signals
39
+
40
+ **2. Product Intelligence** (infer from code + context):
41
+ - Product category (DevTool, SaaS, Marketplace, API, Consumer app, etc.)
42
+ - ICP (Ideal Customer Profile) — who would pay for this?
43
+ - User intent — what problem are they solving?
44
+ - Market maturity level (emerging / growing / mature / saturated)
45
+
46
+ **3. Competitive Positioning**:
47
+ - What exists in this space already?
48
+ - Where does this project have an edge?
49
+ - Scalability potential (technical + market)
50
+ - Technical leverage points — what's hard to replicate?
51
+
52
+ ### PHASE 2 — Monetization Opportunity Discovery
53
+
54
+ **MANDATORY: Minimum 3 monetization directions**, one from each category:
55
+
56
+ **A. Direct Monetization** — revenue directly from users
57
+ - Examples: subscription, one-time purchase, usage-based pricing, premium tier
58
+
59
+ **B. Indirect Monetization** — revenue from adjacent value
60
+ - Examples: API access, data insights, marketplace fees, white-labeling, consulting/support
61
+
62
+ **C. Strategic Positioning Monetization** — revenue from market position
63
+ - Examples: platform play, ecosystem lock-in, acquisition positioning, open-core model
64
+
65
+ **Each option MUST include ALL of these:**
66
+ 1. **Idea** — clear 1-2 sentence description
67
+ 2. **Why it fits** — specific connection to THIS project's strengths
68
+ 3. **Feature description** — what needs to be built
69
+ 4. **Implementation approach** — how to build it (high-level)
70
+ 5. **Technical impact** — what changes in the codebase
71
+ 6. **Trade-offs**:
72
+ - Performance impact
73
+ - Complexity added
74
+ - User trust effect
75
+ - Long-term brand effect
76
+ 7. **Revenue mechanism** — which model:
77
+ - Subscription (tiers?)
78
+ - Usage-based (what metric?)
79
+ - Licensing (per-seat? per-instance?)
80
+ - API monetization (rate limits? tiers?)
81
+ - Data-driven (analytics? insights?)
82
+ - Marketplace model (commission? listing fees?)
83
+ - Freemium → Premium conversion
84
+ 8. **If successful**:
85
+ - Revenue model breakdown (pricing x volume estimate)
86
+ - Scaling path (local → regional → global)
87
+ - Moat creation (what becomes defensible)
88
+
89
+ ### PHASE 3 — Strategic Filtering
90
+
91
+ Evaluate ALL options across:
92
+
93
+ | Criteria | Weight |
94
+ |----------|--------|
95
+ | Implementation effort | How much work? (Low/Med/High) |
96
+ | ROI potential | Revenue vs effort ratio |
97
+ | Valuation impact | Does this increase company value beyond revenue? |
98
+ | Global scalability | Can this work beyond local market? |
99
+ | Time to first revenue | How fast can money come in? |
100
+ | Defensibility | How hard to copy? |
101
+
102
+ **Select:**
103
+ - **Primary strategy** — highest overall score, this is the main bet
104
+ - **Secondary strategy** — backup or complement, lower effort or different risk profile
105
+
106
+ **Explain WHY** these two were chosen over the others.
107
+
108
+ ### PHASE 4 — Execution Blueprint
109
+
110
+ Produce a concrete plan for the primary strategy:
111
+
112
+ 1. **Feature breakdown** — what to build, in order
113
+ 2. **Implementation roadmap** — phases with clear deliverables
114
+ 3. **Milestones** — what "done" looks like at each phase
115
+ 4. **Risk mitigation** — what could go wrong and how to handle it
116
+ 5. **KPIs** — specific metrics to measure success (not vanity metrics)
117
+ 6. **Timeline estimate** — realistic, with buffer
118
+ 7. **Go-to-market suggestion** — how to get first paying users
119
+
120
+ ---
121
+
122
+ ## Output Format (MANDATORY — follow exactly)
123
+
124
+ ```
125
+ ## Project Analysis
126
+
127
+ **Tech Stack:** ...
128
+ **Architecture:** ...
129
+ **Core Functionality:** ...
130
+ **Hidden Leverage:** ...
131
+ **Product Category:** ...
132
+ **ICP (Ideal Customer Profile):** ...
133
+ **Market Maturity:** ...
134
+ **Competitive Edge:** ...
135
+
136
+ ---
137
+
138
+ ## Monetization Opportunities
139
+
140
+ ### Option 1: [Name] (Direct)
141
+ - **Idea:** ...
142
+ - **Why it fits:** ...
143
+ - **Feature:** ...
144
+ - **Implementation:** ...
145
+ - **Technical Impact:** ...
146
+ - **Trade-offs:**
147
+ - Performance: ...
148
+ - Complexity: ...
149
+ - User Trust: ...
150
+ - Brand Effect: ...
151
+ - **Revenue Model:** ...
152
+ - **If Successful:**
153
+ - Revenue breakdown: ...
154
+ - Scaling path: ...
155
+ - Moat: ...
156
+
157
+ ### Option 2: [Name] (Indirect)
158
+ [same structure]
159
+
160
+ ### Option 3: [Name] (Strategic)
161
+ [same structure]
162
+
163
+ ---
164
+
165
+ ## Strategic Recommendation
166
+
167
+ **Primary Strategy:** [Option X] — [1-2 sentence why]
168
+ **Secondary Strategy:** [Option Y] — [1-2 sentence why]
169
+
170
+ **Filtering Matrix:**
171
+ | Criteria | Option 1 | Option 2 | Option 3 |
172
+ |----------|----------|----------|----------|
173
+ | Effort | ... | ... | ... |
174
+ | ROI | ... | ... | ... |
175
+ | Valuation Impact | ... | ... | ... |
176
+ | Scalability | ... | ... | ... |
177
+ | Time to Revenue | ... | ... | ... |
178
+ | Defensibility | ... | ... | ... |
179
+
180
+ ---
181
+
182
+ ## Execution Plan
183
+
184
+ ### Feature Roadmap
185
+ | Phase | Feature | Deliverable | Timeline |
186
+ |-------|---------|-------------|----------|
187
+ | 1 | ... | ... | ... |
188
+ | 2 | ... | ... | ... |
189
+
190
+ ### KPIs
191
+ | Metric | Target | Measurement |
192
+ |--------|--------|-------------|
193
+ | ... | ... | ... |
194
+
195
+ ### Risk & Mitigation
196
+ | Risk | Impact | Mitigation |
197
+ |------|--------|------------|
198
+ | ... | ... | ... |
199
+
200
+ ### Go-to-Market
201
+ - **First users:** ...
202
+ - **Channel:** ...
203
+ - **Pricing launch strategy:** ...
204
+
205
+ ---
206
+
207
+ ## Revenue Projection Logic
208
+ - **Monetization mechanics:** ...
209
+ - **Unit economics:** ...
210
+ - **Scaling logic:** ...
211
+ - **Competitive advantage / Moat:** ...
212
+ ```
213
+
214
+ ---
215
+
216
+ ## Guardrails
217
+
218
+ - **NEVER** give generic advice — every recommendation must reference specific aspects of THIS project's code/architecture/market
219
+ - **NEVER** suggest shallow ideas — each option must be implementable with a clear path
220
+ - **NEVER** skip trade-off analysis — every option has downsides, state them honestly
221
+ - **NEVER** skip any phase or output section
222
+ - **NEVER** suggest monetization that destroys user trust without flagging it clearly
223
+ - **ALWAYS** read/analyze the actual code before making recommendations (do not guess from project name alone)
224
+ - **ALWAYS** think like a founder targeting $100M+ — focus on leverage and unfair advantages
225
+ - **ALWAYS** provide at least 3 options from different monetization categories (direct, indirect, strategic)
226
+ - **ALWAYS** include realistic timeline and effort estimates
227
+ - **ALWAYS** output in Vietnamese by default (English if user requests)
228
+ - If the project is too early-stage for monetization, say so — and suggest what to build first before monetizing
229
+ - If the project has obvious ethical concerns with certain monetization approaches, flag them explicitly
@@ -0,0 +1,14 @@
1
+ {
2
+ "name": "idea-workflow",
3
+ "version": "1.0.0",
4
+ "description": "Analyze source code and produce monetization strategy with execution blueprint and go-to-market plan",
5
+ "compatibility": "OpenCode",
6
+ "agent": null,
7
+ "commands": [],
8
+ "tags": [
9
+ "monetization",
10
+ "strategy",
11
+ "business",
12
+ "analysis"
13
+ ]
14
+ }
@@ -0,0 +1,187 @@
1
+ ---
2
+ description: Draft a Reddit post optimized for a specific subreddit's rules, tone, and spam filters
3
+ ---
4
+
5
+ Draft a Reddit post that follows a target subreddit's rules, matches community tone, and minimizes the risk of removal by mods or spam filters.
6
+
7
+ **Default language**: English (unless the user explicitly requests another language).
8
+
9
+ **Input**: The argument after `/reddit` is either:
10
+ - A filled input form (see template below)
11
+ - A free-form description of what the user wants to post and where
12
+
13
+ If the user provides free-form input, extract as much as possible and ask for missing required fields.
14
+
15
+ ---
16
+
17
+ ## Input Template
18
+
19
+ The user should provide these fields. Fields marked **(required)** must be collected before drafting.
20
+
21
+ ### A. Target
22
+
23
+ | Field | Required | Description |
24
+ |-------|----------|-------------|
25
+ | Subreddit | **Yes** | e.g. `r/reactjs` |
26
+ | Rules/guidelines | **Yes** | Paste key rules, or say "use defaults" if a common sub |
27
+ | Flair options | **Yes** | Paste the available flair list from the post creation screen |
28
+ | Tag options | No | e.g. NSFW, Spoiler, Brand affiliate |
29
+
30
+ ### B. Post Intent
31
+
32
+ | Field | Required | Description |
33
+ |-------|----------|-------------|
34
+ | Goal | **Yes** | `share` / `ask feedback` / `discussion` / `help` / `announcement` / `meta` / `job` |
35
+ | Post type | No | `text` (default) / `link` / `image` / `video` |
36
+ | Self-promo | **Yes** | `yes` / `no` |
37
+ | Commercial | No | `yes` / `no` (default: `no`) |
38
+ | AI-generated content | No | `unknown` / `allowed` / `disallowed` / `must disclose` |
39
+
40
+ ### C. Content
41
+
42
+ | Field | Required | Description |
43
+ |-------|----------|-------------|
44
+ | One-liner | **Yes** | 1 factual sentence describing the project/topic |
45
+ | Problem/pain | **Yes** | 2-4 sentences: what pain point does this address? |
46
+ | Key points | **Yes** | 3-8 bullets: features, arguments, or insights |
47
+ | How it works / evidence | No | 2-5 bullets: technical details, benchmarks, limitations |
48
+ | Install/Try steps | No | Short (3-4 lines) or detailed (6-8 lines) |
49
+ | Links | No | demo, repo, docs, blog (max 4) |
50
+ | Feedback questions | Recommended | 2-4 specific questions for the community |
51
+ | Tone | No | `technical` (default) / `concise` / `story` |
52
+
53
+ ---
54
+
55
+ ## Steps
56
+
57
+ 1. **Collect missing required fields**
58
+
59
+ If any **(required)** field is missing, use the **AskUserQuestion tool** to ask for them.
60
+ Ask all missing fields in ONE prompt (do not ask one at a time).
61
+
62
+ **IMPORTANT**: Do NOT proceed to drafting without: Subreddit, Rules, Flair options, Goal, Self-promo flag, One-liner, Problem/pain, Key points.
63
+
64
+ 2. **Parse rules and extract constraints**
65
+
66
+ From the pasted rules/guidelines, extract:
67
+ - **Hard constraints**: things that will get the post removed (banned content, required flair, link limits, promo policy, AI policy, specific post days like "Portfolio Sunday")
68
+ - **Soft preferences**: community tone, encouraged behaviors, formatting expectations
69
+ - **Spam signals**: account age requirements, self-promo ratio (e.g. 9:1 rule), link density limits
70
+
71
+ Summarize constraints internally before drafting.
72
+
73
+ 3. **Decide post strategy**
74
+
75
+ Based on constraints + intent:
76
+ - **Post format**: text post (default for self-promo; safer vs spam filters) or link post
77
+ - **Link placement**: near the end (default) or inline (if sub expects it)
78
+ - **Tone**: match community (technical subs -> technical; casual subs -> conversational)
79
+ - **Structure**: Problem -> Solution -> Evidence -> Links -> Feedback questions
80
+
81
+ 4. **Select flair + tags**
82
+
83
+ From the user's flair/tag options:
84
+ - Pick the **most appropriate flair** based on post intent and sub conventions
85
+ - Recommend tags only if relevant (default: no tags)
86
+ - **Never** select "Brand affiliate" unless user confirms it is commercial/brand content
87
+ - Provide 1-line rationale for flair choice
88
+
89
+ 5. **Draft the post**
90
+
91
+ Generate:
92
+ - **3-5 title options** (factual, no ALL CAPS, no opinion words like "best/ultimate", no vote-baiting)
93
+ - **1 complete post body** (ready to copy-paste) following this structure:
94
+
95
+ ```
96
+ [Hook: 2-4 sentences describing the pain point]
97
+
98
+ [What I built / What this is: 1-2 sentences]
99
+
100
+ **[Section: key points as bullets]**
101
+
102
+ **[Section: how it works / technical details]** (if provided)
103
+
104
+ **[Section: how to try / install]** (if provided)
105
+
106
+ **[Section: looking for feedback]**
107
+ [2-4 specific questions]
108
+
109
+ [Links: repo, demo, docs - placed at the end]
110
+ ```
111
+
112
+ 6. **Run compliance check**
113
+
114
+ Verify the draft against ALL extracted constraints:
115
+ - [ ] Title is factual, not editorialized
116
+ - [ ] No vote-baiting language ("upvote", "show some love", "please star")
117
+ - [ ] No ALL CAPS in title
118
+ - [ ] Self-promo content has substance (not just links)
119
+ - [ ] Link count is reasonable (2-4 max)
120
+ - [ ] Flair is appropriate for content type
121
+ - [ ] No "Brand affiliate" tag on non-commercial content
122
+ - [ ] Feedback questions are specific (not generic "what do you think?")
123
+ - [ ] Post matches community tone
124
+ - [ ] No violations of sub-specific rules (AI policy, post day restrictions, etc.)
125
+
126
+ If any check fails, fix the draft before presenting.
127
+
128
+ 7. **Present the output**
129
+
130
+ Deliver all sections clearly labeled (see Output below).
131
+
132
+ ---
133
+
134
+ ## Output
135
+
136
+ Always return these sections:
137
+
138
+ ### 1. Titles (3-5 options)
139
+ ```
140
+ 1. [Title option 1]
141
+ 2. [Title option 2]
142
+ 3. [Title option 3]
143
+ ```
144
+
145
+ ### 2. Recommended Flair + Tags
146
+ ```
147
+ Flair: [selected flair] - [1-line rationale]
148
+ Tags: [none / selected tags] - [rationale if any]
149
+ ```
150
+
151
+ ### 3. Post Body (ready to copy-paste)
152
+ ```
153
+ [Complete post body]
154
+ ```
155
+
156
+ ### 4. Pre-post Checklist
157
+ ```
158
+ Before posting, verify:
159
+ - [ ] Account has recent activity in this subreddit (not just self-promo)
160
+ - [ ] Flair is set to: [recommended flair]
161
+ - [ ] Post type is: [text/link]
162
+ - [ ] No rule violations detected
163
+ - [ ] [Any sub-specific check]
164
+ ```
165
+
166
+ ### 5. Risk Assessment
167
+ ```
168
+ Spam risk: [Low / Medium / High]
169
+ Reason: [brief explanation]
170
+ Mitigation: [if medium/high, suggest actions like "comment helpfully in 2-3 threads first"]
171
+ ```
172
+
173
+ ---
174
+
175
+ ## Guardrails
176
+
177
+ - **NEVER** include vote-baiting language in any form
178
+ - **NEVER** use ALL CAPS in titles
179
+ - **NEVER** select "Brand affiliate" without user confirmation
180
+ - **NEVER** skip the compliance check
181
+ - **NEVER** draft without collecting all required fields first
182
+ - **ALWAYS** default to text post for self-promo content (safer)
183
+ - **ALWAYS** place links near the end of the post body
184
+ - **ALWAYS** include specific feedback questions (not generic)
185
+ - **ALWAYS** write in English unless user explicitly requests another language
186
+ - If the user's content seems to violate sub rules, **warn them** and suggest adjustments rather than silently fixing
187
+ - If flair options don't have a good match, recommend the closest option and explain why
@@ -0,0 +1,14 @@
1
+ {
2
+ "name": "reddit-workflow",
3
+ "version": "1.0.0",
4
+ "description": "Draft Reddit posts optimized for subreddit rules, tone, and spam filters with compliance checking",
5
+ "compatibility": "OpenCode",
6
+ "agent": null,
7
+ "commands": [],
8
+ "tags": [
9
+ "reddit",
10
+ "content",
11
+ "social-media",
12
+ "writing"
13
+ ]
14
+ }
@@ -0,0 +1,118 @@
1
+ ---
2
+ name: rtk-setup
3
+ description: "One-time setup + ongoing enforcement of RTK (Rust Token Killer) across sessions and subagents. Persists RTK instructions to AGENTS.md and propagates to delegated tasks."
4
+ compatibility: "OpenCode with RTK binary installed"
5
+ metadata:
6
+ author: Sisyphus
7
+ version: "1.0.0"
8
+ ---
9
+
10
+ # RTK Setup — Persistent RTK Enforcement
11
+
12
+ This skill performs **setup** (persist RTK instructions) and **ongoing enforcement** (use rtk, propagate to subagents).
13
+
14
+ ## Phase 1: Detection (ALWAYS run first)
15
+
16
+ Run these checks before anything else:
17
+
18
+ ```bash
19
+ rtk --version
20
+ ```
21
+
22
+ - If `rtk` is NOT found → **STOP**. Tell the user: "RTK is not installed. Install it first: `cargo install --git https://github.com/rtk-ai/rtk --locked`". Do NOT proceed with setup.
23
+ - If `rtk` IS found → continue.
24
+
25
+ ### Check oh-my-opencode
26
+
27
+ ```bash
28
+ ls ~/.config/opencode/oh-my-opencode.json 2>/dev/null
29
+ ```
30
+
31
+ - If found → omo is installed. Note this for Phase 2.
32
+ - If not found → skip omo-specific steps.
33
+
34
+ ## Phase 2: Setup (persist to AGENTS.md)
35
+
36
+ Check BOTH of these files for the RTK managed block:
37
+
38
+ 1. **User-level**: `~/.config/opencode/AGENTS.md`
39
+ 2. **Project-level**: `./AGENTS.md` (current workspace)
40
+
41
+ For EACH file, check if `<!-- RTK:START -->` exists. If it does NOT exist, **append** the following managed block to the file (create the file if it doesn't exist). NEVER replace existing content — only append.
42
+
43
+ ```markdown
44
+ <!-- RTK:START -->
45
+ <!-- Managed block - do not edit manually. Updated by: rtk-setup skill -->
46
+
47
+ ## RTK Token Optimizer
48
+
49
+ This project uses **RTK** (Rust Token Killer) to reduce LLM token consumption by 60-90%.
50
+
51
+ ### Rules for ALL agents (including subagents)
52
+
53
+ **ALWAYS** prefix these commands with `rtk`:
54
+
55
+ | Command | Use instead |
56
+ |---------|-------------|
57
+ | `git status/diff/log/add/commit/push/pull` | `rtk git ...` |
58
+ | `ls`, `ls -la` | `rtk ls` |
59
+ | `cat file` | `rtk read file` |
60
+ | `grep pattern .` / `rg pattern` | `rtk grep pattern .` |
61
+ | `npm test` / `cargo test` / `pytest` | `rtk test <cmd>` |
62
+ | `npm run build` / `cargo build` | `rtk err <cmd>` |
63
+ | `gh pr list/view` | `rtk gh pr list/view` |
64
+ | `docker ps` | `rtk docker ps` |
65
+ | `eslint` / `tsc` | `rtk lint` / `rtk tsc` |
66
+
67
+ **Do NOT** prefix: `npx`, `npm install`, `pip install`, `node`, `python3`, heredocs, piped commands.
68
+
69
+ <!-- RTK:END -->
70
+ ```
71
+
72
+ ### If oh-my-opencode is installed
73
+
74
+ After updating AGENTS.md files, check if the omo config at `~/.config/opencode/oh-my-opencode.json` has `prompt_append` fields on agents. If it does, inform the user:
75
+
76
+ > "omo is installed. For maximum coverage, you can add RTK instructions to agent `prompt_append` fields in `oh-my-opencode.json`. This ensures subagents always use rtk even when AGENTS.md is not loaded. Want me to do this?"
77
+
78
+ **Only modify `oh-my-opencode.json` if the user explicitly confirms.** If they confirm, append this line to the `prompt_append` of `sisyphus-junior` agent (the primary coder):
79
+
80
+ ```
81
+ \n\nRTK: ALWAYS prefix shell commands with `rtk` when available (git, ls, grep, test, build). Example: `rtk git status` not `git status`.
82
+ ```
83
+
84
+ Do NOT modify other agents' prompt_append unless asked.
85
+
86
+ ## Phase 3: Ongoing Enforcement (EVERY time this skill is loaded)
87
+
88
+ ### For the current agent
89
+
90
+ From this point forward in this session, **you MUST**:
91
+
92
+ 1. **Use `rtk` prefix** for all supported shell commands (see table above)
93
+ 2. **Verify rtk is available** before first use: `rtk --version`
94
+ 3. If rtk is not available in the current environment, fall back to normal commands silently
95
+
96
+ ### For subagent delegation
97
+
98
+ When delegating ANY task that involves shell commands (via `task()`, `delegate_task()`, or any delegation mechanism), **ALWAYS** add this to the `MUST DO` section of the delegation prompt:
99
+
100
+ ```
101
+ - Use `rtk` prefix for shell commands when available (git, ls, grep, test, build). Run `rtk --version` first to check. If not installed, use normal commands. Examples: `rtk git status`, `rtk ls`, `rtk grep pattern .`, `rtk test npm test`.
102
+ ```
103
+
104
+ This is NON-NEGOTIABLE. Subagents do not read AGENTS.md, so RTK instructions MUST be passed explicitly in every delegation prompt.
105
+
106
+ ### Quick reference for subagent prompts
107
+
108
+ Copy-paste this one-liner into MUST DO sections:
109
+
110
+ > Use `rtk` prefix for all shell commands (git, ls, grep, test, build, docker). Example: `rtk git status` not `git status`. If `rtk` is not found, use normal commands.
111
+
112
+ ## Summary
113
+
114
+ | Phase | When | What |
115
+ |-------|------|------|
116
+ | Detection | Always first | Check rtk installed, check omo |
117
+ | Setup | Once (idempotent) | Append RTK block to AGENTS.md (user + project) |
118
+ | Enforcement | Every session | Use rtk yourself, propagate to all subagents |
@@ -0,0 +1,14 @@
1
+ {
2
+ "name": "rtk-setup",
3
+ "version": "1.0.0",
4
+ "description": "One-time setup + ongoing enforcement of RTK (Rust Token Killer) across sessions and subagents \u2014 reduces token consumption by 60-90%",
5
+ "compatibility": "OpenCode with RTK binary installed",
6
+ "agent": null,
7
+ "commands": [],
8
+ "tags": [
9
+ "rtk",
10
+ "token-saving",
11
+ "optimization",
12
+ "setup"
13
+ ]
14
+ }