@dzhechkov/p-replicator 1.5.6 → 1.5.8
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/LICENSE +21 -0
- package/README/eng/01_quickstart.md +244 -0
- package/README/eng/02_user_guide.md +634 -0
- package/README/eng/03_admin_guide.md +333 -0
- package/README/eng/04_api_reference.md +302 -0
- package/README/eng/05_architecture.md +370 -0
- package/README/eng/06_troubleshooting.md +353 -0
- package/README/eng/07_changelog.md +134 -0
- package/README/eng/README.md +60 -0
- package/README/ru/01_quickstart.md +244 -0
- package/README/ru/02_user_guide.md +633 -0
- package/README/ru/03_admin_guide.md +337 -0
- package/README/ru/04_api_reference.md +333 -0
- package/README/ru/05_architecture.md +372 -0
- package/README/ru/06_troubleshooting.md +355 -0
- package/README/ru/07_changelog.md +146 -0
- package/README/ru/README.md +60 -0
- package/README/ru/html/build.js +553 -0
- package/README/ru/html/index.html +1312 -0
- package/README/ru/html/script.js +496 -0
- package/README/ru/html/style.css +804 -0
- package/bin/cli.js +0 -0
- package/package.json +10 -10
- package/src/cli.js +7 -1
- package/src/commands/init.js +4 -1
- package/templates/.claude/agents/replicate-coordinator.md +23 -21
- package/templates/.claude/commands/replicate.md +4 -2
- package/templates/.claude/rules/replicate-pipeline.md +16 -0
- package/templates/.claude/skills/cc-toolkit-generator-enhanced/modules/03-generate-p0.md +15 -0
- package/templates/.claude/skills/cc-toolkit-generator-enhanced/modules/04-generate-p1.md +20 -0
- package/templates/.claude/skills/cc-toolkit-generator-enhanced/modules/README.md +11 -0
- package/templates/.claude/skills/goap-research-ed25519/SKILL.md +3 -0
- package/templates/.claude/skills/problem-solver-enhanced/SKILL.md +3 -0
- package/templates/.claude/skills/reverse-engineering-unicorn/SKILL.md +3 -0
package/bin/cli.js
CHANGED
|
File without changes
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dzhechkov/p-replicator",
|
|
3
|
-
"version": "1.5.
|
|
3
|
+
"version": "1.5.8",
|
|
4
4
|
"description": "P-Replicator — Claude Code toolkit for AI-assisted product development (Vibe Coding). Full /replicate pipeline, 10 modular skills (194K+ chars), /harvest knowledge extraction, swarm agents, quality gates, security patterns, cross-project learning.",
|
|
5
5
|
"main": "src/cli.js",
|
|
6
6
|
"bin": {
|
|
@@ -11,14 +11,6 @@
|
|
|
11
11
|
"src/",
|
|
12
12
|
"templates/"
|
|
13
13
|
],
|
|
14
|
-
"scripts": {
|
|
15
|
-
"test": "node --test tests/unit/utils.test.js tests/e2e/lifecycle.test.js tests/snapshot/templates.test.js",
|
|
16
|
-
"test:unit": "node --test tests/unit/utils.test.js",
|
|
17
|
-
"test:e2e": "node --test tests/e2e/lifecycle.test.js",
|
|
18
|
-
"test:snapshot": "node --test tests/snapshot/templates.test.js",
|
|
19
|
-
"test:doctor": "node bin/cli.js doctor",
|
|
20
|
-
"snapshot:baseline": "node tests/snapshot/update-baseline.js"
|
|
21
|
-
},
|
|
22
14
|
"keywords": [
|
|
23
15
|
"claude",
|
|
24
16
|
"claude-code",
|
|
@@ -71,5 +63,13 @@
|
|
|
71
63
|
},
|
|
72
64
|
"publishConfig": {
|
|
73
65
|
"access": "public"
|
|
66
|
+
},
|
|
67
|
+
"scripts": {
|
|
68
|
+
"test": "node --test tests/unit/utils.test.js tests/e2e/lifecycle.test.js tests/snapshot/templates.test.js",
|
|
69
|
+
"test:unit": "node --test tests/unit/utils.test.js",
|
|
70
|
+
"test:e2e": "node --test tests/e2e/lifecycle.test.js",
|
|
71
|
+
"test:snapshot": "node --test tests/snapshot/templates.test.js",
|
|
72
|
+
"test:doctor": "node bin/cli.js doctor",
|
|
73
|
+
"snapshot:baseline": "node tests/snapshot/update-baseline.js"
|
|
74
74
|
}
|
|
75
|
-
}
|
|
75
|
+
}
|
package/src/cli.js
CHANGED
|
@@ -110,8 +110,14 @@ function parseArgs(argv) {
|
|
|
110
110
|
command = 'version';
|
|
111
111
|
break;
|
|
112
112
|
default:
|
|
113
|
-
if (
|
|
113
|
+
if (arg.startsWith('-')) {
|
|
114
|
+
error(`Unknown option: ${arg}`);
|
|
115
|
+
process.exit(1);
|
|
116
|
+
} else if (command === null) {
|
|
114
117
|
command = arg;
|
|
118
|
+
} else {
|
|
119
|
+
error(`Unexpected argument: ${arg}`);
|
|
120
|
+
process.exit(1);
|
|
115
121
|
}
|
|
116
122
|
break;
|
|
117
123
|
}
|
package/src/commands/init.js
CHANGED
|
@@ -85,7 +85,10 @@ function installComponent(key, comp, templatesDir, targetDir, options) {
|
|
|
85
85
|
return [comp.src];
|
|
86
86
|
}
|
|
87
87
|
|
|
88
|
-
|
|
88
|
+
// Track files from the TEMPLATE source, never a scan of the destination — matches
|
|
89
|
+
// update.js's invariant (line ~112). Walking dest would adopt user-created files
|
|
90
|
+
// into the manifest, and a later `remove` would then delete them (user data loss).
|
|
91
|
+
return getRelativePaths(src).map((rel) => path.join(comp.src, rel));
|
|
89
92
|
}
|
|
90
93
|
|
|
91
94
|
// ---------------------------------------------------------------------------
|
|
@@ -54,33 +54,35 @@ When skills reference `/mnt/skills/user/` paths, map them:
|
|
|
54
54
|
| `[project-name]-cc-toolkit/` | project root (in-place) |
|
|
55
55
|
| `[project-name].zip` | N/A (no packaging) |
|
|
56
56
|
|
|
57
|
-
## What /replicate Generates
|
|
57
|
+
## What /replicate Generates (post v1.4)
|
|
58
58
|
|
|
59
|
-
|
|
59
|
+
The workflow toolkit (all 11 commands, all 5 base rules, all 4 pipeline agents,
|
|
60
|
+
the 10 skills, and `.claude/settings.json` + hook scripts) is **pre-shipped by
|
|
61
|
+
`npx @dzhechkov/p-replicator init` — do NOT overwrite or regenerate it.** See
|
|
62
|
+
`.claude/rules/replicate-pipeline.md` → "What Gets Generated vs Pre-shipped"
|
|
63
|
+
for the authoritative contract that `verify` checks.
|
|
60
64
|
|
|
61
|
-
|
|
62
|
-
- `.claude/commands/start.md` — project bootstrap
|
|
63
|
-
- `.claude/commands/feature.md` — 4-phase feature lifecycle
|
|
64
|
-
- `.claude/commands/plan.md` — implementation planning
|
|
65
|
-
- `.claude/commands/myinsights.md` — insights capture
|
|
66
|
-
- `.claude/commands/deploy.md` — deployment workflow
|
|
67
|
-
- `.claude/commands/test.md` — test generation (if applicable)
|
|
65
|
+
Phase 3 generates ONLY project-specific artifacts derived from the SPARC docs:
|
|
68
66
|
|
|
69
67
|
### Generated Agents
|
|
70
|
-
- `.claude/agents/planner.md` — from Pseudocode.md
|
|
71
|
-
- `.claude/agents/code-reviewer.md` — from Refinement.md
|
|
72
|
-
- `.claude/agents/architect.md` — from Architecture.md + Solution_Strategy.md
|
|
68
|
+
- `.claude/agents/planner.md` — algorithm templates from Pseudocode.md
|
|
69
|
+
- `.claude/agents/code-reviewer.md` — edge cases from Refinement.md
|
|
70
|
+
- `.claude/agents/architect.md` — system design from Architecture.md + Solution_Strategy.md
|
|
73
71
|
|
|
74
72
|
### Generated Rules
|
|
75
|
-
- `.claude/rules/
|
|
76
|
-
- `.claude/rules/
|
|
77
|
-
- `.claude/rules/
|
|
78
|
-
- `.claude/rules/
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
- `.claude/
|
|
73
|
+
- `.claude/rules/security.md` — NFRs from Specification.md
|
|
74
|
+
- `.claude/rules/coding-style.md` — tech-stack conventions from Architecture.md
|
|
75
|
+
- `.claude/rules/secrets-management.md` — IF external APIs detected
|
|
76
|
+
- `.claude/rules/testing.md` — test strategy from Refinement.md
|
|
77
|
+
|
|
78
|
+
### Generated Skills (project-specific)
|
|
79
|
+
- `.claude/skills/project-context/` — domain knowledge
|
|
80
|
+
- `.claude/skills/coding-standards/` — tech-specific patterns
|
|
81
|
+
- `.claude/skills/security-patterns/` — IF external APIs
|
|
82
|
+
|
|
83
|
+
### Generated State + Conditional Config
|
|
84
|
+
- `.claude/feature-roadmap.json` — feature list from PRD MVP scope
|
|
85
|
+
- `.claude/commands/feature-ent.md` — IF DDD/ADR/C4 docs detected
|
|
84
86
|
- `.mcp.json` — IF external integrations
|
|
85
87
|
|
|
86
88
|
### Generated Documentation
|
|
@@ -394,7 +394,7 @@ git commit -m "chore: initial project setup from SPARC documentation"
|
|
|
394
394
|
│ ├── test-scenarios.md # BDD scenarios
|
|
395
395
|
│ └── features/ # For future features
|
|
396
396
|
├── .claude/
|
|
397
|
-
│ ├── commands/ # /start, /feature, /plan, /
|
|
397
|
+
│ ├── commands/ # /start, /feature, /plan, /go, /run, /deploy, /myinsights
|
|
398
398
|
│ ├── agents/ # planner, code-reviewer, architect
|
|
399
399
|
│ ├── skills/ # 8 shared + project-specific skills
|
|
400
400
|
│ ├── rules/ # git-workflow, security, coding-style, ...
|
|
@@ -410,7 +410,9 @@ git commit -m "chore: initial project setup from SPARC documentation"
|
|
|
410
410
|
- /start — bootstrap project from docs
|
|
411
411
|
- /feature [name] — full feature lifecycle
|
|
412
412
|
- /plan [feature] — plan implementation
|
|
413
|
-
- /
|
|
413
|
+
- /go [feature] — smart pipeline router (auto-dispatch)
|
|
414
|
+
- /run [mode] — autonomous build loop
|
|
415
|
+
- /next — pick the next feature from roadmap
|
|
414
416
|
- /deploy [env] — deploy to environment
|
|
415
417
|
- /myinsights — capture development insights
|
|
416
418
|
═══════════════════════════════════════════════════════════════
|
|
@@ -11,6 +11,22 @@ Product Discovery Planning Validation Toolkit Finalize
|
|
|
11
11
|
|
|
12
12
|
Never skip Phase 2 (Validation). Toolkit (Phase 3) MUST be built on validated documentation.
|
|
13
13
|
|
|
14
|
+
### Optional: UI replication (post-pipeline)
|
|
15
|
+
|
|
16
|
+
When the goal includes rebuilding a target's **frontend** (not just the business/toolkit), the
|
|
17
|
+
`clone-website` skill — [`@dzhechkov/skills-website-cloner`](https://www.npmjs.com/package/@dzhechkov/skills-website-cloner),
|
|
18
|
+
the implementation counterpart to `reverse-engineering-unicorn` — produces a pixel-perfect
|
|
19
|
+
Next.js clone of a live site.
|
|
20
|
+
|
|
21
|
+
| Skill | Required | Purpose | Fallback |
|
|
22
|
+
|-------|----------|---------|----------|
|
|
23
|
+
| `clone-website` | OPTIONAL (external) | Reverse-engineer a live site → running Next.js/shadcn clone | use `frontend-design` to build a fresh UI, or skip |
|
|
24
|
+
|
|
25
|
+
**Reference, not vendored** (per ADR-0001). It is NOT one of the pre-shipped p-replicator skills
|
|
26
|
+
and has hard runtime prerequisites (a browser-MCP + a Next.js/shadcn/Tailwind scaffold). Install
|
|
27
|
+
separately: `npx @dzhechkov/skills-website-cloner init` or `dz init --select clone-website`. If
|
|
28
|
+
absent or its prerequisites are unmet, skip the UI-clone step and log a warning.
|
|
29
|
+
|
|
14
30
|
## Skill Loading Protocol
|
|
15
31
|
|
|
16
32
|
When executing skills during the pipeline:
|
|
@@ -33,6 +33,21 @@ From the Instrument Map this module uses:
|
|
|
33
33
|
> AI systems routinely compress 211-line templates to 60 lines — this is a CRITICAL defect.
|
|
34
34
|
> Validate: generated file line count must be >= 80% of template line count.
|
|
35
35
|
|
|
36
|
+
> **CLAUDE CODE PRE-SHIPPED SKIP-LIST (post v1.4):** When this skill runs inside a
|
|
37
|
+
> p-replicator project, several "P0 mandatory" items below are **already pre-shipped
|
|
38
|
+
> by `npx @dzhechkov/p-replicator init`** and are protected by the do-not-overwrite
|
|
39
|
+
> gate in `.claude/rules/replicate-pipeline.md` ("What Gets Generated vs Pre-shipped").
|
|
40
|
+
> For these items, **VERIFY they exist — do NOT regenerate or overwrite them:**
|
|
41
|
+
> - Commands: `start.md` (Item 4), `myinsights.md` (Item 5), `feature.md` (Item 6)
|
|
42
|
+
> - Rules: `git-workflow.md` (Item 7), `insights-capture.md` (Item 8), `feature-lifecycle.md` (Item 9)
|
|
43
|
+
> - Config: `.claude/settings.json` + `.claude/hooks/` scripts (Item 10)
|
|
44
|
+
>
|
|
45
|
+
> Treat their "Generate `.claude/...`" instructions as "confirm present; enhance content
|
|
46
|
+
> only if explicitly requested". Generate fresh ONLY the project-specific items that are
|
|
47
|
+
> NOT in the pre-shipped contract (CLAUDE.md, security.md, coding-style.md, and the
|
|
48
|
+
> conditional P0 items). When running this skill standalone (no p-replicator init), generate
|
|
49
|
+
> everything as written.
|
|
50
|
+
|
|
36
51
|
### P0 Mandatory Items (always generated)
|
|
37
52
|
|
|
38
53
|
The following 16 items are generated for every project, regardless of pipeline
|
|
@@ -25,6 +25,26 @@ engine and conditionally included based on project characteristics and document
|
|
|
25
25
|
> AI systems routinely compress 211-line templates to 60 lines — this is a CRITICAL defect.
|
|
26
26
|
> Validate: generated file line count must be >= 80% of template line count.
|
|
27
27
|
|
|
28
|
+
> **CLAUDE CODE PRE-SHIPPED SKIP-LIST (post v1.4):** When this skill runs inside a
|
|
29
|
+
> p-replicator project, several P1 items below are **already pre-shipped by
|
|
30
|
+
> `npx @dzhechkov/p-replicator init`** and are protected by the do-not-overwrite gate
|
|
31
|
+
> in `.claude/rules/replicate-pipeline.md` ("What Gets Generated vs Pre-shipped").
|
|
32
|
+
> For these items, **VERIFY they exist — do NOT regenerate or overwrite them:**
|
|
33
|
+
> - Commands: `plan.md`, `deploy.md`, `next.md`, `go.md`, `run.md`, `docs.md`
|
|
34
|
+
> - Config merge: `.claude/settings.json` (already shipped; only add a new hook entry
|
|
35
|
+
> if a generated hook genuinely requires one, otherwise leave untouched)
|
|
36
|
+
>
|
|
37
|
+
> Note: `test.md` is **NOT** pre-shipped and is **NOT** part of the p-replicator command
|
|
38
|
+
> set — do not advertise it in any generated CLAUDE.md/README command list. Generate
|
|
39
|
+
> `test.md` only when this skill runs standalone (outside a p-replicator project) and the
|
|
40
|
+
> project actually needs a test command.
|
|
41
|
+
>
|
|
42
|
+
> Generate fresh the genuinely project-specific P1 items: the `planner`/`code-reviewer`/
|
|
43
|
+
> `architect` agents, `project-context`/`coding-standards`/`testing-patterns` skills,
|
|
44
|
+
> `testing.md` rule, `feature-roadmap.json`, and (IF DDD docs) `feature-ent.md` +
|
|
45
|
+
> enterprise lifecycle artifacts. When running standalone (no p-replicator init),
|
|
46
|
+
> generate everything as written.
|
|
47
|
+
|
|
28
48
|
### Step 1: Filter P1 Candidates
|
|
29
49
|
|
|
30
50
|
Select all instruments assigned tier P1 from the Instrument Map (score >= 12 after tier boosts).
|
|
@@ -3,6 +3,17 @@
|
|
|
3
3
|
Modular phase architecture for the toolkit generator.
|
|
4
4
|
Each module is self-contained with: INPUT → PROCESS → OUTPUT → QUALITY GATE.
|
|
5
5
|
|
|
6
|
+
> **Claude Code pre-shipped skip-list (post v1.4):** When these modules run inside a
|
|
7
|
+
> p-replicator project, several items listed below as "generated" are actually
|
|
8
|
+
> **pre-shipped by `npx @dzhechkov/p-replicator init`** and are protected by the
|
|
9
|
+
> do-not-overwrite gate in `.claude/rules/replicate-pipeline.md`. Modules 03 and 04
|
|
10
|
+
> carry an explicit skip-list note: those items must be **verified present, not
|
|
11
|
+
> regenerated** (commands `start`/`myinsights`/`feature`/`plan`/`deploy`/`next`/`go`/
|
|
12
|
+
> `run`/`docs`, base rules `git-workflow`/`insights-capture`/`feature-lifecycle`, and
|
|
13
|
+
> `.claude/settings.json` + hooks). `test.md` is neither pre-shipped nor part of the
|
|
14
|
+
> p-replicator command set. When run standalone (no p-replicator init), generate
|
|
15
|
+
> everything as written.
|
|
16
|
+
|
|
6
17
|
## Phase Modules (Core Pipeline)
|
|
7
18
|
|
|
8
19
|
| # | Module | File | Size | Purpose |
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: goap-research-ed25519
|
|
3
3
|
description: Advanced GOAP research system with Ed25519 cryptographic verification for anti-hallucination protection. Combines Goal-Oriented Action Planning with cryptographic signatures to ensure source authenticity, claim verification, and citation chain integrity. Use for high-stakes research requiring verifiable facts, competitive intelligence, legal/medical research, or any context where hallucination prevention is critical. Triggers on "verified research", "trusted sources only", "anti-hallucination", "signed sources", "cryptographic verification".
|
|
4
|
+
trust_tier: 1
|
|
5
|
+
trust_tier_label: "Structured"
|
|
6
|
+
trust_tier_path: "Run /bto-test to promote to Tier 2"
|
|
4
7
|
---
|
|
5
8
|
|
|
6
9
|
# GOAP Research Skill with Ed25519 Verification
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: problem-solver-enhanced
|
|
3
3
|
description: Elite problem-solving system combining first principles thinking, game theory, root cause analysis, systematic frameworks AND TRIZ inventive principles for solving complex challenges. Use when facing complex challenges with unclear solutions, strategic decisions with multiple stakeholders, problems requiring breakthrough (not incremental) solutions, trade-offs that seem impossible to resolve, competitive scenarios requiring game-theoretic analysis, system design problems, or any situation requiring both analytical rigor and inventive thinking beyond surface-level solutions.
|
|
4
|
+
trust_tier: 1
|
|
5
|
+
trust_tier_label: "Structured"
|
|
6
|
+
trust_tier_path: "Run /bto-test to promote to Tier 2"
|
|
4
7
|
---
|
|
5
8
|
|
|
6
9
|
# Elite Problem Solver (Enhanced with TRIZ)
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
---
|
|
2
2
|
name: reverse-engineering-unicorn
|
|
3
3
|
description: Reverse engineer any company into a launch playbook with clickable CJM prototype. Triggers on "проанализируй компанию", "reverse engineer", "разбери бизнес-модель", "playbook запуска".
|
|
4
|
+
trust_tier: 1
|
|
5
|
+
trust_tier_label: "Structured"
|
|
6
|
+
trust_tier_path: "Run /bto-test to promote to Tier 2"
|
|
4
7
|
---
|
|
5
8
|
|
|
6
9
|
# Reverse Engineering Unicorn v2
|