refacil-sdd-ai 5.0.1 → 5.0.3

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.md CHANGED
@@ -6,6 +6,8 @@ Installs **skills** and **sub-agents** for **Claude Code**, **Cursor**, and **Op
6
6
 
7
7
  ---
8
8
 
9
+ **npm:** [refacil-sdd-ai](https://www.npmjs.com/package/refacil-sdd-ai) | **GitHub:** [Erikole21/refacil-sdd-ai](https://github.com/Erikole21/refacil-sdd-ai)
10
+
9
11
  ## Requirements
10
12
 
11
13
  - **Node.js >= 20.0.0**
@@ -48,6 +48,7 @@ If you prefer to continue here, provide:
48
48
  - **In mode=fix: you have Edit and Write** to implement the fix, generate tests, and create `summary.md`.
49
49
  - **The fix must be MINIMAL** — do not refactor anything beyond the bug.
50
50
  - **Return ONE final message** with the report + JSON block corresponding to the mode.
51
+ - **Language policy for written files**: any source/tests/comments/identifiers and file/folder names written in mode=fix must be English-only. Only user-facing narrative may follow the user's language.
51
52
 
52
53
  ---
53
54
 
@@ -59,6 +59,7 @@ Apply these 4 rules in each implementation task:
59
59
  - **Do NOT generate SDD artifacts** (proposal, specs, design, tasks) — that is `/refacil:propose`'s responsibility.
60
60
  - **Do NOT change branches or make commits** — the skill wrapper handles that before invoking you.
61
61
  - **Return ONE final message** with the report + JSON block.
62
+ - **Language policy for implementation output**: all created/modified code artifacts must be in English (file/folder names, identifiers, test descriptions, and code comments), regardless of user language or SDD artifact language.
62
63
 
63
64
  ## Flow
64
65
 
@@ -48,6 +48,7 @@ Exploration is necessary in this agent but must be **directed**, not exhaustive.
48
48
  - **NEVER write, modify, or generate source code** — only planning artifacts: `proposal.md`, `design.md`, `tasks.md`, specifications in `specs.md` and/or `specs/**/*.md`.
49
49
  - **Return ONE final message** with the summary + JSON block.
50
50
  - Your session context is isolated: explore with focus — depth in relevant modules, not breadth across the whole codebase.
51
+ - **Language boundary**: `artifactLanguage` applies only to SDD artifact prose. If you include example identifiers/paths/snippets in artifacts, keep them in English and never generate real source code.
51
52
 
52
53
  ## Artifact templates
53
54
 
package/agents/tester.md CHANGED
@@ -46,6 +46,7 @@ If you prefer to continue here, provide:
46
46
  - **You do NOT modify source code** — only generate test files.
47
47
  - **You do NOT create SDD planning artifacts** (proposal/specs/design/tasks) — that is `/refacil:propose`'s responsibility.
48
48
  - **Return ONE final message** with the report + JSON block.
49
+ - **Language policy for tests**: generated test files must be English-only (file names, test names/descriptions, identifiers, and comments), regardless of user language or SDD artifact language.
49
50
 
50
51
  ## Stack detection (minimum focus)
51
52
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "refacil-sdd-ai",
3
- "version": "5.0.1",
3
+ "version": "5.0.3",
4
4
  "description": "SDD-AI: Specification-Driven Development with AI — development methodology using AI with Claude Code, Cursor and OpenCode",
5
5
  "bin": {
6
6
  "refacil-sdd-ai": "./bin/cli.js"
@@ -182,4 +182,5 @@ If the sub-agent returned `result: "PARTIAL"` or `"FAILED"`, present the `issues
182
182
  - Meet the preconditions of Step 0 (complete artifacts) and Step 1 (valid working branch) **before delegating**.
183
183
  - **Always build the briefing (Step 1.5) before delegating** — it is the key piece that reduces the sub-agent cost.
184
184
  - **Always delegate implementation to the sub-agent**. Do not replicate implementation logic or SDD artifact-apply logic here.
185
+ - Even when artifacts are Spanish, implementation output is English-only: created file/folder names, source code, test code, identifiers, and code comments.
185
186
  - **Flow continuity**: if the user confirms affirmatively ("yes", "ok", "go", "continue", etc.) the continuity question in Step 3, immediately invoke the **Skill tool** with `skill: "refacil:test"`. Do not describe it in text or wait for the user to type `/refacil:test`. (See `METHODOLOGY-CONTRACT.md §5`.)
@@ -165,5 +165,6 @@ If the sub-agent returned `result: "FAILED"` (tests not passing), present the fa
165
165
  - **NEVER implement without explicit user approval** (Step 3).
166
166
  - **Always validate the branch** (Step 4) before delegating the fix.
167
167
  - **Do not replicate investigation or implementation logic here** — that lives in `refacil-debugger`.
168
+ - Bugfix implementation output is English-only: source/test file names, identifiers, test descriptions, and code comments, regardless of the language used in user-facing text or SDD artifacts.
168
169
  - Step 3 (bus cross-repo) is **optional** — only applies if the sub-agent reported `crossRepo: true`.
169
170
  - **Flow continuity**: if the user confirms affirmatively ("yes", "ok", "go", "continue", etc.) the continuity question in Step 6, immediately invoke the **Skill tool** with `skill: "refacil:review"`. Do not describe it in text or wait for the user to type `/refacil:review`. (See `METHODOLOGY-CONTRACT.md §5`.)
@@ -152,4 +152,9 @@ If the user does not request detail, use concise mode.
152
152
  - **Agent and skill internal instructions**: always in **English** (reduces token cost, improves LLM performance).
153
153
  - **Responses to the user**: in the **user's language**. If the user writes in Spanish, respond in Spanish. If in English, respond in English. Default: Spanish.
154
154
  - **SDD artifacts** (proposal.md, specs, design.md, tasks.md): in the **user's language** (or the language the team agreed on for the project).
155
- - Technical terms, code identifiers, and proper nouns stay in their canonical language regardless.
155
+ - **Source code and generated files are always English-only**, regardless of `artifactLanguage`:
156
+ - code identifiers (variables, functions, classes, types, interfaces, enums)
157
+ - test code and test names/descriptions
158
+ - source file and folder names created during implementation
159
+ - code comments and commit/PR technical text produced by the agent
160
+ - Never translate existing canonical API names, library symbols, or protocol/domain terms.
@@ -105,4 +105,5 @@ Do you want me to continue with /refacil:apply?
105
105
 
106
106
  - **Change folder name**: always validate with `refacil-sdd-ai sdd validate-name <slug>` before delegating. Do not proceed if it exits 1.
107
107
  - **Always delegate generation to the sub-agent**. Do not replicate the codebase exploration or artifact generation logic here.
108
+ - `artifactLanguage` affects **only SDD artifacts**. Any code snippets, file/folder names, identifiers, and technical comments that may appear during proposal work must stay in **English**.
108
109
  - **Flow continuity**: if the user confirms affirmatively ("yes", "ok", "go", "continue", etc.) the continuity question in Step 4, immediately invoke the **Skill tool** with `skill: "refacil:apply"`. Do not describe it in text or wait for the user to type `/refacil:apply`. (See `METHODOLOGY-CONTRACT.md §5`.)
@@ -141,7 +141,16 @@ A monorepo may add `.agents/services.md`; a library may combine testing in stack
141
141
 
142
142
  ### Step 4b: Overwrite `CLAUDE.md` and `.cursorrules`
143
143
 
144
- Always **overwrite** both files even if they already exist they are thin indexes toward `AGENTS.md`, they must not contain project detail.
144
+ Before writing IDE-specific files, detect installed IDE directories in repo root (`.claude/`, `.cursor/`, `.opencode/`).
145
+ Only create/update files for IDEs whose directory exists. Never create files for an IDE that is not present.
146
+
147
+ Rules:
148
+ - If `.claude/` exists: overwrite `CLAUDE.md`.
149
+ - If `.cursor/` exists: overwrite `.cursorrules`.
150
+ - If both exist: overwrite both.
151
+ - If neither exists: do not create either file; report that no supported IDE folder was detected and suggest running `refacil-sdd-ai init`.
152
+
153
+ When created, these files are thin indexes toward `AGENTS.md` and must not contain project detail.
145
154
 
146
155
  **`CLAUDE.md`** — minimal index, no project content:
147
156
 
@@ -158,12 +167,17 @@ All project detail, stack, rules and `refacil:*` commands live in `.agents/` and
158
167
 
159
168
  ### Step 5: Context exclusion files
160
169
 
161
- `refacil-sdd-ai init` automatically creates or updates `.claudeignore` and `.cursorignore` with standard entries (node_modules/, dist/, logs, binaries, secrets, etc.).
170
+ Sync ignore files only for detected IDE directories:
171
+ - `.claude/` → `.claudeignore`
172
+ - `.cursor/` → `.cursorignore`
173
+ - `.opencode/` → `.opencodeignore`
174
+
175
+ Do not create `.claudeignore`, `.cursorignore`, or `.opencodeignore` if the matching IDE directory does not exist.
162
176
 
163
177
  If the files already exist, only missing entries are added — custom content is not overwritten.
164
178
 
165
179
  Inform the user of the result:
166
- - **Created**: both files were created from scratch.
180
+ - **Created**: the detected IDE ignore file(s) were created from scratch.
167
181
  - **Updated**: missing entries were added.
168
182
  - **No changes**: they already had all the entries.
169
183
 
@@ -171,14 +185,18 @@ If the user wants to customize additional exclusions, they can edit them directl
171
185
 
172
186
  ### Step 6: Verify skills
173
187
 
174
- - Refacil: `refacil-*` folders under `.claude/skills/` and `.cursor/skills/`. If not: `refacil-sdd-ai init` + restart session.
188
+ - Refacil: verify `refacil-*` folders only under detected IDE directories:
189
+ - `.claude/` detected → check `.claude/skills/`
190
+ - `.cursor/` detected → check `.cursor/skills/`
191
+ - `.opencode/` detected → check `.opencode/skills/`
192
+ If missing for any detected IDE: run `refacil-sdd-ai init` and restart session.
175
193
  - Verify `sdd` subcommand: `refacil-sdd-ai sdd 2>&1 || true` — must show subcommands `status`, `mark-reviewed`, `tasks-update`, `archive`.
176
194
 
177
195
  ### Step 7: Final summary
178
196
 
179
197
  ```
180
198
  === refacil:setup completed ===
181
- Node.js / refacil-sdd-ai / refacil-sdd/changes/ / branch config / AGENTS.md / CLAUDE.md / .cursorrules / .claudeignore / .cursorignore / skills OK
199
+ Node.js / refacil-sdd-ai / refacil-sdd/changes/ / branch config / AGENTS.md / IDE files (detected only) / ignore files (detected only) / skills OK
182
200
 
183
201
  Restart Claude Code or Cursor session if this is the first skills installation.
184
202
  The next step is to review the available flow.
@@ -100,4 +100,5 @@ Do you want me to continue with /refacil:verify?
100
100
  - **Always build the briefing in change mode (Step 1) before delegating** — reduces the sub-agent tool calls.
101
101
  - **Always delegate to the sub-agent**. Do not replicate stack detection or generation logic here.
102
102
  - **Do not invoke with ambiguous scope**. If there are multiple active changes, ask for selection first.
103
+ - Test implementation is English-only (test file names, test cases/descriptions, identifiers, and comments), regardless of the SDD artifact language.
103
104
  - **Flow continuity**: if the user confirms affirmatively ("yes", "ok", "go", "continue", etc.) the continuity question **and tests passed (`passed: true`)**, immediately invoke the **Skill tool** with `skill: "refacil:verify"`. Do not describe it in text or wait for the user to type `/refacil:verify`. (See `METHODOLOGY-CONTRACT.md §5`.)