@dex-ai/coding-extensions 0.2.4

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.
@@ -0,0 +1,167 @@
1
+ ---
2
+ name: git-workflow
3
+ description: Multi-repository git coordination — coordinated commits, branch management, version bumps, and release workflows across workspace repos.
4
+ ---
5
+
6
+ ## What I do
7
+
8
+ - Coordinate git operations across multiple repositories in a workspace
9
+ - Manage version bumps and package publishing sequences
10
+ - Handle branch creation, commits, and merges across repos
11
+ - Ensure dependency ordering for cross-repo changes
12
+ - Guide release workflows with proper verification
13
+
14
+ ## When to use me
15
+
16
+ Use this skill when:
17
+ - Making changes that span multiple repositories
18
+ - Performing version bumps across interdependent packages
19
+ - Publishing packages to a registry (Verdaccio, npm)
20
+ - Creating coordinated branches or PRs across repos
21
+ - Needing to understand dependency order for changes
22
+
23
+ ## Core Principles
24
+
25
+ ### Dependency Order Matters
26
+
27
+ When making cross-repo changes, work bottom-up through the dependency graph:
28
+ 1. SDK/core packages first (they have no internal deps)
29
+ 2. Mid-level packages that depend on SDK
30
+ 3. Top-level packages (CLI, agent) last
31
+
32
+ ### Atomic Logical Units
33
+
34
+ Each commit should be a logical unit of work. For cross-repo changes:
35
+ - Each repo gets its own commit(s)
36
+ - Commits should reference the same feature/fix
37
+ - The workspace should be buildable after each repo's commit
38
+
39
+ ### Verify Before Commit
40
+
41
+ Always verify before committing:
42
+ - `bun run typecheck` passes
43
+ - `bun run test` passes (or at least no regressions)
44
+ - Build succeeds if applicable
45
+
46
+ ---
47
+
48
+ ## Patterns
49
+
50
+ ### Coordinated Cross-Repo Change
51
+
52
+ When a change touches multiple repos (e.g., adding a new SDK export used by CLI):
53
+
54
+ ```bash
55
+ # 1. Make SDK change
56
+ cd dex-ai-sdk
57
+ # ... make changes ...
58
+ bun run typecheck && bun run test
59
+ git add -A && git commit -m "feat: add new export"
60
+
61
+ # 2. Publish SDK (if using Verdaccio)
62
+ bun publish --registry http://localhost:4873
63
+
64
+ # 3. Update consumer
65
+ cd ../dex-ai-coding-agent
66
+ bun install # picks up new SDK version
67
+ # ... make changes using new export ...
68
+ bun run typecheck && bun run test
69
+ git add -A && git commit -m "feat: use new SDK export"
70
+ ```
71
+
72
+ ### Version Bump Workflow
73
+
74
+ For bumping versions across the workspace:
75
+
76
+ ```bash
77
+ # 1. Determine bump type (patch/minor/major)
78
+ # 2. Bump in dependency order:
79
+
80
+ # Core SDK
81
+ cd dex-ai-sdk
82
+ # bump version in package.json
83
+ git add -A && git commit -m "chore: bump to X.Y.Z"
84
+ bun publish --registry http://localhost:4873
85
+
86
+ # Each dependent package
87
+ cd ../dex-ai-providers
88
+ # bump version, update @dex-ai/sdk dep version
89
+ git add -A && git commit -m "chore: bump to X.Y.Z"
90
+ bun publish --registry http://localhost:4873
91
+
92
+ # ... continue up the dependency tree
93
+ ```
94
+
95
+ ### Feature Branch Across Repos
96
+
97
+ ```bash
98
+ BRANCH="feat/my-feature"
99
+
100
+ # Create branch in all affected repos
101
+ for repo in dex-ai-sdk dex-ai-providers dex-ai-coding-agent; do
102
+ cd /path/to/$repo
103
+ git checkout -b $BRANCH
104
+ done
105
+
106
+ # Work on changes, commit in each repo
107
+ # When done, merge in dependency order (SDK first)
108
+ ```
109
+
110
+ ### Quick Status Check
111
+
112
+ ```bash
113
+ # Check status across all repos
114
+ for dir in /path/to/workspace/dex-ai-*/; do
115
+ echo "=== $(basename $dir) ==="
116
+ cd "$dir"
117
+ git status --short
118
+ echo
119
+ done
120
+ ```
121
+
122
+ ---
123
+
124
+ ## Commit Message Convention
125
+
126
+ Use conventional commits:
127
+ - `feat:` — New feature
128
+ - `fix:` — Bug fix
129
+ - `chore:` — Maintenance (version bumps, deps)
130
+ - `docs:` — Documentation only
131
+ - `refactor:` — Code restructuring without behavior change
132
+ - `test:` — Adding or updating tests
133
+
134
+ Keep messages concise. Reference related repos when relevant:
135
+ ```
136
+ feat: add streaming support
137
+
138
+ Required by dex-ai-coding-agent for real-time output.
139
+ ```
140
+
141
+ ---
142
+
143
+ ## Safety Rules
144
+
145
+ - **Never force push** to main/master without explicit user approval
146
+ - **Never rebase shared branches** without confirmation
147
+ - **Always check `git status`** before committing to avoid unintended files
148
+ - **Verify builds pass** before pushing
149
+ - **Use `git diff --stat`** to review what's changing before commit
150
+
151
+ ## Dependency Graph (Dex Project)
152
+
153
+ ```
154
+ dex-ai-sdk (base — no internal deps)
155
+ ├── dex-ai-providers
156
+ ├── dex-ai-context
157
+ ├── dex-ai-memory
158
+ ├── dex-ai-knowledge
159
+ ├── dex-ai-mcp
160
+ ├── dex-ai-devtools
161
+ ├── dex-ai-core-extensions
162
+ ├── dex-ai-coding-extensions
163
+ ├── dex-pi-compat
164
+ ├── dex-ai-vue-tui-markdown
165
+ ├── dex-ai-vue-tui
166
+ └── dex-ai-coding-agent (top — depends on most others)
167
+ ```
@@ -0,0 +1,194 @@
1
+ ---
2
+ name: retrospective
3
+ description: Performs a post-session retrospective to extract learnings into Dex's persistent memory. Stores facts, updates procedures, and removes stale knowledge. Focused on information that can't be discovered or inferred from the codebase.
4
+ ---
5
+
6
+ ## What I do
7
+
8
+ - Analyze the completed conversation to extract actionable learnings
9
+ - Store durable knowledge as **facts** via `memory_remember_fact`
10
+ - Create/update **procedures** via `memory_store_procedure` for reusable workflows
11
+ - Remove stale facts via `memory_forget_fact`
12
+ - Filter out anything discoverable from the codebase or inferrable from context
13
+
14
+ ## When to use me
15
+
16
+ Use this skill when:
17
+ - A significant task or feature has been completed
18
+ - The user asks for a retrospective
19
+ - Multiple decisions were made that could inform future work
20
+ - User preferences or patterns were revealed through interaction
21
+ - At the end of a work session to capture learnings
22
+
23
+ ## Core Principles
24
+
25
+ ### Only What I Can't Discover
26
+
27
+ If I can find it by reading code, exploring the filesystem, or inferring from context — DO NOT capture it. Only capture things that:
28
+ - Were explicitly stated by the user as a preference
29
+ - Were decided through conversation (not obvious from context)
30
+ - Represent a pattern that repeated across the session
31
+ - Would save time or prevent mistakes in future sessions
32
+
33
+ ### Specific Over General
34
+
35
+ Bad: "The user prefers clean code"
36
+ Good: "The user rejects emoji in code files and comments"
37
+
38
+ Bad: "The project uses TypeScript"
39
+ Good: "The user wants snake_case for database columns but camelCase everywhere else"
40
+
41
+ ### Actionable & Atomic
42
+
43
+ Each fact should be a single, specific claim. Each procedure should be a concrete, repeatable workflow.
44
+
45
+ ---
46
+
47
+ ## Retrospective Workflow
48
+
49
+ ### Step 1: Analyze the Conversation
50
+
51
+ Review the entire session and identify:
52
+
53
+ **User Preferences** — Things the user told me about how they want me to behave:
54
+ - Communication style preferences
55
+ - Code style preferences not enforced by tooling
56
+ - Workflow preferences (e.g., "always ask before committing")
57
+ - Things they corrected me on (patterns to avoid)
58
+ - Things they praised (patterns to repeat)
59
+
60
+ **Project Learnings** — Things about THIS project not obvious from code:
61
+ - Architectural decisions explained by the user
62
+ - Historical context ("we used to do X but switched to Y because...")
63
+ - Team conventions not yet codified
64
+ - Known issues or gotchas mentioned
65
+ - Preferred patterns for new code
66
+
67
+ **Workflow Patterns** — Multi-step processes discovered or taught:
68
+ - Build/deploy sequences
69
+ - Testing workflows
70
+ - Release processes
71
+ - Debugging approaches that worked
72
+
73
+ **Skill Feedback** — How well did active skills perform:
74
+ - What was missing or unclear
75
+ - What I had to figure out that a skill should have told me
76
+ - Steps that were awkward or could be streamlined
77
+
78
+ ### Step 2: Filter
79
+
80
+ For each potential learning, ask:
81
+
82
+ 1. **Can I discover this from the codebase?** → Discard
83
+ 2. **Can I infer this from context?** → Discard
84
+ 3. **Is this specific and actionable?** → If no, discard
85
+ 4. **Will this help me in future sessions?** → If no, discard
86
+
87
+ ### Step 3: Execute Memory Operations
88
+
89
+ #### Facts (via `memory_remember_fact`)
90
+
91
+ For user preferences and project learnings:
92
+
93
+ ```
94
+ Subject: "user" or project/package name
95
+ Predicate: concise relationship (e.g., "prefers", "requires", "avoids")
96
+ Object: the specific value
97
+ ```
98
+
99
+ Examples:
100
+ - `("user", "prefers", "concise responses without explanations unless asked")`
101
+ - `("user", "commit-style", "imperative mood, no emoji, reference issue numbers")`
102
+ - `("dex-ai-sdk", "testing-pattern", "vitest with happy-dom, mock external deps")`
103
+ - `("project", "deploy-requires", "version bump → verdaccio publish → CLI rebuild")`
104
+
105
+ #### Procedures (via `memory_store_procedure`)
106
+
107
+ For multi-step workflows discovered or taught:
108
+
109
+ ```
110
+ Title: descriptive action phrase
111
+ Body: step-by-step markdown with exact commands/paths
112
+ Tags: relevant categories
113
+ ```
114
+
115
+ Examples:
116
+ - Title: "Publishing a new package version"
117
+ - Title: "Debugging TUI rendering issues"
118
+ - Title: "Adding a new extension to the CLI"
119
+
120
+ #### Removals (via `memory_forget_fact`)
121
+
122
+ For stale or incorrect facts discovered during the session:
123
+ - Facts contradicted by new information
124
+ - Facts about things that no longer exist
125
+ - Facts the user explicitly corrected
126
+
127
+ ### Step 4: Present Summary
128
+
129
+ Format the output as:
130
+
131
+ ```markdown
132
+ # Retrospective Summary
133
+
134
+ ## Facts Stored
135
+ | Subject | Predicate | Object | Source |
136
+ |---------|-----------|--------|--------|
137
+ | ... | ... | ... | [What prompted this] |
138
+
139
+ ## Facts Removed
140
+ | Subject | Predicate | Reason |
141
+ |---------|-----------|--------|
142
+ | ... | ... | [Why removed] |
143
+
144
+ ## Procedures Stored/Updated
145
+ | Title | Tags | Summary |
146
+ |-------|------|---------|
147
+ | ... | ... | [Brief description] |
148
+
149
+ ## Discarded (Discoverable/Inferrable)
150
+ - [Things considered but rejected]
151
+
152
+ ## Skill Improvement Notes
153
+ - [Observations about skill performance for future updates]
154
+ ```
155
+
156
+ ---
157
+
158
+ ## Filtering Heuristics
159
+
160
+ ### DISCARD — Discoverable from codebase:
161
+ - Programming language, framework, dependencies
162
+ - File structure and organization
163
+ - Naming conventions visible in existing code
164
+ - Test framework from config files
165
+ - Lint rules, build scripts, TypeScript config
166
+ - Any pattern that appears in existing code
167
+
168
+ ### DISCARD — Inferrable from context:
169
+ - Monorepo structure (if packages/ exists)
170
+ - TypeScript usage (if .ts files exist)
171
+ - General coding best practices
172
+
173
+ ### KEEP — Not discoverable:
174
+ - "I prefer X over Y even though Y is more common"
175
+ - "We tried X before and it didn't work because [context]"
176
+ - "Always do X when Y" (explicit instruction)
177
+ - "Don't do X" (explicit prohibition)
178
+ - Historical context and reasoning
179
+ - Corrections to my behavior
180
+ - Workflow preferences
181
+
182
+ ---
183
+
184
+ ## Quality Checks
185
+
186
+ Before executing memory operations:
187
+
188
+ - [ ] Every fact is specific and atomic (one claim per fact)
189
+ - [ ] No fact is discoverable from the codebase
190
+ - [ ] No fact is inferrable from context
191
+ - [ ] Each fact has a clear source from the conversation
192
+ - [ ] Procedures have exact commands/paths, not vague steps
193
+ - [ ] Existing facts checked — update rather than duplicate
194
+ - [ ] Stale facts identified for removal
@@ -0,0 +1,145 @@
1
+ ---
2
+ name: skill-creator
3
+ description: Expert at creating, updating, and managing Dex skills (SKILL.md files and extension-based skills) with proper structure, naming, and best practices.
4
+ ---
5
+
6
+ ## What I do
7
+
8
+ - Create well-structured Dex skills with proper YAML frontmatter and markdown content
9
+ - Update existing skills while preserving conventions
10
+ - Validate skill structure and naming
11
+ - Create both file-based skills (~/.dex/skills/) and extension-based skills
12
+ - Advise on skill design, scope, and reusability
13
+
14
+ ## When to use me
15
+
16
+ Use this skill when:
17
+ - Creating a new Dex skill
18
+ - Updating or refactoring an existing skill
19
+ - Validating skill structure
20
+ - Learning best practices for skill design
21
+
22
+ ## Skill Locations
23
+
24
+ ### File-based skills (user-defined)
25
+ ```
26
+ ~/.dex/skills/<skill-name>/SKILL.md
27
+ ```
28
+
29
+ ### Extension-based skills (bundled)
30
+ ```typescript
31
+ // In an extension package
32
+ export function myExtension(): Extension {
33
+ return {
34
+ name: "my-extension",
35
+ skills: [{
36
+ name: "my-skill",
37
+ description: "What it does",
38
+ content: "## Markdown content...",
39
+ }],
40
+ };
41
+ }
42
+ ```
43
+
44
+ ### Project-scoped skills
45
+ ```
46
+ <project>/.dex/skills/<skill-name>/SKILL.md
47
+ ```
48
+
49
+ ## Directory Layout
50
+
51
+ A file-based skill directory:
52
+ ```
53
+ my-skill/
54
+ ├── SKILL.md # Required entrypoint
55
+ ├── reference.md # Optional: loaded on demand via get_skill
56
+ ├── examples/
57
+ │ └── sample.md
58
+ └── scripts/
59
+ └── helper.sh
60
+ ```
61
+
62
+ ## Naming Rules
63
+
64
+ Skill names MUST:
65
+ - Be 1-64 characters
66
+ - Be lowercase alphanumeric with single hyphen separators
67
+ - Not start or end with `-`
68
+ - Not contain consecutive `--`
69
+ - Match regex: `^[a-z0-9]+(-[a-z0-9]+)*$`
70
+
71
+ Valid: `git-release`, `code-review`, `api-docs`, `test-helper`
72
+ Invalid: `GitRelease`, `api_docs`, `-test`, `my--skill`
73
+
74
+ ## Frontmatter
75
+
76
+ Every SKILL.md starts with YAML frontmatter:
77
+
78
+ ```yaml
79
+ ---
80
+ name: <skill-name> # Optional, overrides directory name
81
+ description: <1-1536 chars> # Strongly recommended, used for catalog/auto-invocation
82
+ ---
83
+ ```
84
+
85
+ The `description` is what Dex uses in the "Available Skills" catalog listing. Make it specific enough to trigger on the right tasks but not so narrow it never activates.
86
+
87
+ ## Content Structure
88
+
89
+ After frontmatter, structure with clear sections:
90
+
91
+ 1. **What I do** — Bullet list of capabilities
92
+ 2. **When to use me** — Trigger conditions and use cases
93
+ 3. **Core Principles** — Key rules and guidelines
94
+ 4. **Step-by-step workflows** — Numbered procedures
95
+ 5. **Templates** — Output format templates if applicable
96
+ 6. **Exit Criteria** — How to know when done
97
+
98
+ ## Creation Workflow
99
+
100
+ ### Step 1: Define the skill
101
+ - What problem does this skill solve?
102
+ - When should the agent use it?
103
+ - What are the key steps or rules?
104
+ - What tools does it leverage?
105
+
106
+ ### Step 2: Choose a name
107
+ - Concise and descriptive
108
+ - Follows naming rules
109
+ - Doesn't conflict with existing skills
110
+
111
+ ### Step 3: Write the description
112
+ - 1-1536 characters
113
+ - Front-loads the key use case
114
+ - Specific enough to avoid false matches
115
+ - Mentions key actions/outputs
116
+
117
+ ### Step 4: Write the content
118
+ - Clear, actionable instructions
119
+ - Use markdown headers for structure
120
+ - Include templates/examples
121
+ - Reference specific Dex tools by name
122
+ - Add exit criteria
123
+
124
+ ### Step 5: Create the file
125
+ For file-based: `~/.dex/skills/<name>/SKILL.md`
126
+ For extension-based: create a package under `skills/` with `src/index.ts`
127
+
128
+ ### Step 6: Validate
129
+ - [ ] SKILL.md exists (ALL CAPS filename)
130
+ - [ ] Frontmatter has at minimum a `description`
131
+ - [ ] Name passes validation regex
132
+ - [ ] Description is 1-1536 characters
133
+ - [ ] Content is clear and actionable
134
+ - [ ] References valid tool names
135
+
136
+ ## Best Practices
137
+
138
+ - Keep skills focused on a single domain or workflow
139
+ - Use bullet points and numbered lists for clarity
140
+ - Include examples whenever possible
141
+ - Reference specific Dex tools (`memory_remember_fact`, `ast_grep_search`, `lsp_diagnostics`, etc.)
142
+ - Keep descriptions specific but not overly narrow
143
+ - Include exit criteria so the agent knows when it's done
144
+ - For complex skills, use phases with clear gates between them
145
+ - Avoid duplicating information the agent already has in its system prompt