@dzhechkov/keysarium 1.4.0 → 1.5.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 (80) hide show
  1. package/README.md +52 -5
  2. package/README.ru.md +541 -0
  3. package/bin/cli.js +0 -0
  4. package/package.json +11 -9
  5. package/templates/.claude/commands/analyst-manual.md +38 -0
  6. package/templates/.claude/commands/casarium.md +55 -4
  7. package/templates/.claude/commands/feature-adr.md +8 -0
  8. package/templates/.claude/rules/trust-tiers.md +5 -0
  9. package/templates/.claude/shards/feature-adr.shard.md +64 -10
  10. package/templates/.claude/shards/phase-ai-factory.shard.md +109 -0
  11. package/templates/.claude/skills/ai-factory-mapper/README.md +90 -0
  12. package/templates/.claude/skills/ai-factory-mapper/SKILL.md +309 -0
  13. package/templates/.claude/skills/ai-factory-mapper/assets/report-template.md +123 -0
  14. package/templates/.claude/skills/ai-factory-mapper/references/catalog.md +230 -0
  15. package/templates/.claude/skills/ai-factory-mapper/references/coverage-formula.md +219 -0
  16. package/templates/.claude/skills/ai-factory-mapper/references/decomposition-checklist.md +183 -0
  17. package/templates/.claude/skills/ai-factory-mapper/references/pattern-library.md +312 -0
  18. package/templates/.claude/skills/ai-factory-mapper/scripts/build_docx_report.js +423 -0
  19. package/templates/.claude/skills/analyst-manual-full/SKILL.md +286 -0
  20. package/templates/.claude/skills/edu-site-generator/SKILL.md +254 -0
  21. package/templates/.claude/skills/edu-site-generator/examples/sample-course-structure.md +116 -0
  22. package/templates/.claude/skills/edu-site-generator/modules/00-content-analysis.md +84 -0
  23. package/templates/.claude/skills/edu-site-generator/modules/01-course-structure.md +75 -0
  24. package/templates/.claude/skills/edu-site-generator/modules/02-data-generation.md +186 -0
  25. package/templates/.claude/skills/edu-site-generator/modules/03-scaffold.md +249 -0
  26. package/templates/.claude/skills/edu-site-generator/modules/04-components.md +130 -0
  27. package/templates/.claude/skills/edu-site-generator/modules/05-gamification.md +163 -0
  28. package/templates/.claude/skills/edu-site-generator/modules/06-deploy.md +88 -0
  29. package/templates/.claude/skills/edu-site-generator/modules/07-verification.md +97 -0
  30. package/templates/.claude/skills/edu-site-generator/references/component-templates.md +436 -0
  31. package/templates/.claude/skills/edu-site-generator/references/data-schemas.md +164 -0
  32. package/templates/.claude/skills/edu-site-generator/references/exercise-catalog.md +110 -0
  33. package/templates/.claude/skills/edu-site-generator/references/tech-stack.md +69 -0
  34. package/templates/.claude/skills/feature-adr/SKILL.md +245 -59
  35. package/templates/.claude/skills/feature-adr/modules/03-adr.md +43 -0
  36. package/templates/.claude/skills/feature-adr/modules/03.5-ideation-swarm.md +180 -0
  37. package/templates/.claude/skills/feature-adr/modules/06-implementation-plan.md +56 -7
  38. package/templates/.claude/skills/feature-adr/modules/08-qe.md +87 -23
  39. package/templates/.claude/skills/feature-adr/modules/09-fleet-qe.md +305 -0
  40. package/templates/.claude/skills/feature-adr/references/agentic-qe/README.md +143 -0
  41. package/templates/.claude/skills/feature-adr/references/agentic-qe/brutal-honesty-review.md +240 -0
  42. package/templates/.claude/skills/feature-adr/references/agentic-qe/chaos-engineering-resilience.md +163 -0
  43. package/templates/.claude/skills/feature-adr/references/agentic-qe/code-goal-planner.md +446 -0
  44. package/templates/.claude/skills/feature-adr/references/agentic-qe/enterprise-integration-testing.md +111 -0
  45. package/templates/.claude/skills/feature-adr/references/agentic-qe/mutation-testing.md +236 -0
  46. package/templates/.claude/skills/feature-adr/references/agentic-qe/performance-testing.md +315 -0
  47. package/templates/.claude/skills/feature-adr/references/agentic-qe/qcsd-ideation-swarm.md +126 -0
  48. package/templates/.claude/skills/feature-adr/references/agentic-qe/qcsd-production-swarm.md +108 -0
  49. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-coverage-analysis.md +193 -0
  50. package/templates/.claude/skills/feature-adr/references/agentic-qe/qe-requirements-validation.md +254 -0
  51. package/templates/.claude/skills/feature-adr/references/agentic-qe/regression-testing.md +233 -0
  52. package/templates/.claude/skills/feature-adr/references/agentic-qe/risk-based-testing.md +212 -0
  53. package/templates/.claude/skills/feature-adr/references/agentic-qe/security-testing.md +311 -0
  54. package/templates/.claude/skills/feature-adr/references/agentic-qe/shift-left-testing.md +231 -0
  55. package/templates/.claude/skills/feature-adr/references/agentic-qe/tdd-london-chicago.md +249 -0
  56. package/templates/.claude/skills/transcript-site-generator/SKILL.md +287 -0
  57. package/templates/.claude/skills/transcript-site-generator/examples/sample-text-only-site.md +123 -0
  58. package/templates/.claude/skills/transcript-site-generator/examples/sample-transcript-site.md +134 -0
  59. package/templates/.claude/skills/transcript-site-generator/modules/00-input-analysis.md +132 -0
  60. package/templates/.claude/skills/transcript-site-generator/modules/01-content-parsing.md +117 -0
  61. package/templates/.claude/skills/transcript-site-generator/modules/02-site-generation.md +293 -0
  62. package/templates/.claude/skills/transcript-site-generator/modules/03-interactivity.md +406 -0
  63. package/templates/.claude/skills/transcript-site-generator/modules/04-deploy.md +130 -0
  64. package/templates/.claude/skills/transcript-site-generator/modules/05-verification.md +155 -0
  65. package/templates/.claude/skills/transcript-site-generator/references/component-catalog.md +86 -0
  66. package/templates/.claude/skills/transcript-site-generator/references/data-schemas.md +123 -0
  67. package/templates/.claude/skills/transcript-site-generator/references/tech-stack.md +132 -0
  68. package/templates/CLAUDE.md +9 -2
  69. package/templates/docs/edu-site-generator/01-deployment-guide.md +911 -0
  70. package/templates/docs/edu-site-generator/02-admin-guide.md +901 -0
  71. package/templates/docs/edu-site-generator/03-user-guide.md +1008 -0
  72. package/templates/docs/edu-site-generator/04-infrastructure-requirements.md +489 -0
  73. package/templates/docs/edu-site-generator/05-architecture.md +902 -0
  74. package/templates/docs/edu-site-generator/06-user-flows.md +759 -0
  75. package/templates/docs/transcript-site-generator/01-deployment-guide.md +1042 -0
  76. package/templates/docs/transcript-site-generator/02-admin-guide.md +918 -0
  77. package/templates/docs/transcript-site-generator/03-user-guide.md +925 -0
  78. package/templates/docs/transcript-site-generator/04-infrastructure-requirements.md +482 -0
  79. package/templates/docs/transcript-site-generator/05-architecture.md +1068 -0
  80. package/templates/docs/transcript-site-generator/06-user-flows.md +855 -0
@@ -0,0 +1,1008 @@
1
+ # User Guide — @dzhechkov/skills-edu-site
2
+
3
+ This guide covers everything you need to use the edu-site skill pack for Claude Code. It is intended for developers, educators, and content creators who want to generate gamified educational SPA websites from documentation, topics, or raw text — with zero frontend coding required.
4
+
5
+ ---
6
+
7
+ ## Contents
8
+
9
+ 1. [Quick Start (5 minutes)](#1-quick-start-5-minutes)
10
+ 2. [Input Types](#2-input-types)
11
+ 3. [The 8-Step Pipeline](#3-the-8-step-pipeline)
12
+ 4. [Exercise Types Explained](#4-exercise-types-explained)
13
+ 5. [Gamification Features](#5-gamification-features)
14
+ 6. [Final Assessment](#6-final-assessment)
15
+ 7. [Customization Options](#7-customization-options)
16
+ 8. [Data Files Reference](#8-data-files-reference)
17
+ 9. [Common Scenarios](#9-common-scenarios)
18
+ 10. [Tips and Best Practices](#10-tips-and-best-practices)
19
+ 11. [FAQ](#11-faq)
20
+
21
+ ---
22
+
23
+ ## 1. Quick Start (5 minutes)
24
+
25
+ Edu-site gives you one primary command that generates a complete educational website:
26
+
27
+ ```
28
+ /edu-site [topic, URL, file path, or pasted text]
29
+ ```
30
+
31
+ ### Your first edu-site run
32
+
33
+ The fastest way to see edu-site in action is to provide a topic:
34
+
35
+ ```
36
+ /edu-site "Introduction to Docker: containers, images, Dockerfile, docker-compose"
37
+ ```
38
+
39
+ Within 5-10 minutes, Claude Code will execute an 8-step pipeline and produce a complete project directory:
40
+
41
+ ```
42
+ docker-course/
43
+ +-- package.json
44
+ +-- vite.config.js
45
+ +-- index.html
46
+ +-- src/
47
+ +-- App.jsx
48
+ +-- data/
49
+ | +-- sections.js (5 sections)
50
+ | +-- exercises.js (19 exercises, 6 types)
51
+ | +-- quizQuestions.js (25 final test questions)
52
+ | +-- achievements.js (12 achievements)
53
+ +-- components/
54
+ +-- pages/
55
+ +-- store/
56
+ ```
57
+
58
+ To see it live:
59
+
60
+ ```bash
61
+ cd docker-course/
62
+ npm install
63
+ npm run dev
64
+ # Open http://localhost:5173
65
+ ```
66
+
67
+ ### Trigger phrases
68
+
69
+ The `/edu-site` command responds to various input styles:
70
+
71
+ ```
72
+ # Topic description
73
+ /edu-site "Learn Python basics: variables, loops, functions, classes"
74
+
75
+ # Documentation URL
76
+ /edu-site https://docs.example.com/api-reference
77
+
78
+ # Local file
79
+ /edu-site ./docs/cli-manual.md
80
+
81
+ # Direct text (paste documentation into the chat)
82
+ /edu-site "Here is the content: [your text]"
83
+ ```
84
+
85
+ ### What you get
86
+
87
+ Every edu-site run produces a self-contained React SPA with:
88
+
89
+ - **Structured learning path** — content organized into progressive sections
90
+ - **6 exercise types** — Quiz, Flashcards, Matching, Drag-to-Order, Command Builder, Scenario Game
91
+ - **Gamification** — points, achievements, streaks, progress tracking
92
+ - **Final assessment** — graded test covering all sections
93
+ - **GitHub Pages deployment** — one push to deploy
94
+ - **Persistent progress** — localStorage-backed state, survives page refresh
95
+
96
+ ---
97
+
98
+ ## 2. Input Types
99
+
100
+ Edu-site accepts four types of input. The pipeline automatically detects which type you provided and adjusts the Content Analysis step accordingly.
101
+
102
+ ### 2.1. Documentation URL
103
+
104
+ ```
105
+ /edu-site https://docs.docker.com/get-started/
106
+ ```
107
+
108
+ The pipeline will:
109
+ 1. Fetch the page content
110
+ 2. Follow internal links up to 3 levels deep (configurable)
111
+ 3. Extract text, code blocks, and headings
112
+ 4. Discard navigation, footers, and boilerplate
113
+
114
+ **Best for:** Official documentation, API references, tutorials with multiple pages.
115
+
116
+ **Limitations:** Sites behind authentication or with aggressive anti-bot protection may not be fetchable. In that case, download the content manually and provide it as a file.
117
+
118
+ ### 2.2. Local file path
119
+
120
+ ```
121
+ /edu-site ./docs/git-guide.md
122
+ /edu-site /absolute/path/to/manual.txt
123
+ ```
124
+
125
+ Supported formats:
126
+ - Markdown (`.md`) — best results, preserves structure
127
+ - Plain text (`.txt`) — works but loses heading hierarchy
128
+ - HTML (`.html`) — parsed and cleaned automatically
129
+ - Multiple files — provide a directory path to include all `.md` files
130
+
131
+ ```
132
+ /edu-site ./docs/
133
+ ```
134
+
135
+ When given a directory, the pipeline reads all markdown files, sorts them alphabetically, and combines them into a single content stream.
136
+
137
+ ### 2.3. Pasted text
138
+
139
+ Paste documentation content directly into the chat:
140
+
141
+ ```
142
+ /edu-site "Here is the documentation for our CLI tool:
143
+
144
+ ## Installation
145
+ Run npm install -g my-tool
146
+
147
+ ## Commands
148
+ ### my-tool init
149
+ Initializes a new project...
150
+
151
+ ### my-tool build
152
+ Builds the project...
153
+ "
154
+ ```
155
+
156
+ **Best for:** Quick generation from short documentation, README files, or notes you have on hand.
157
+
158
+ ### 2.4. Topic description
159
+
160
+ Provide a topic and the pipeline will generate educational content from scratch:
161
+
162
+ ```
163
+ /edu-site "Fundamentals of SQL: SELECT, WHERE, JOIN, GROUP BY, subqueries, indexes"
164
+ ```
165
+
166
+ When given a topic description (no URL, no file path, no extensive text), the pipeline enters **generative mode** — it creates educational content based on the AI's knowledge of the topic, rather than analyzing existing documentation.
167
+
168
+ **Best for:** Well-known topics where official documentation is unnecessary. Programming languages, frameworks, design patterns, algorithms.
169
+
170
+ **Caution:** For niche or proprietary tools, provide actual documentation rather than a topic description. The AI cannot invent accurate details about tools it has not been trained on.
171
+
172
+ ---
173
+
174
+ ## 3. The 8-Step Pipeline
175
+
176
+ The pipeline runs automatically from start to finish. Here is what happens at each step and what output to expect.
177
+
178
+ ### Step 1: Content Analysis
179
+
180
+ **What happens:** The pipeline reads your input, detects the language (Russian or English), identifies key topics, extracts terminology, and estimates the scope of the course.
181
+
182
+ **Expected output:**
183
+
184
+ ```
185
+ Step 1/8: Content Analysis
186
+ ---
187
+ Input type: documentation URL
188
+ Detected language: en
189
+ Content length: 4,200 words
190
+ Topics identified: 14
191
+ Key concepts: 38
192
+ Technical terms: 22
193
+ Code examples found: 8
194
+ Estimated sections: 5-6
195
+ ---
196
+ Proceeding to Step 2...
197
+ ```
198
+
199
+ **What can go wrong:** If the input is too short (under 500 characters), the pipeline will warn you and suggest providing more content. If a URL is unreachable, it will offer alternative input methods.
200
+
201
+ ### Step 2: Course Structure
202
+
203
+ **What happens:** Topics are organized into a hierarchical structure of sections and subsections. The pipeline determines the learning order, identifies dependencies between topics, and assigns exercise types based on content characteristics.
204
+
205
+ **Expected output:**
206
+
207
+ ```
208
+ Step 2/8: Course Structure
209
+ ---
210
+ Sections planned:
211
+
212
+ 1. Getting Started
213
+ - Installation (Flashcards)
214
+ - First Project (CommandBuilder)
215
+ - Basic Concepts (Quiz)
216
+
217
+ 2. Core Commands
218
+ - File Operations (CommandBuilder)
219
+ - Status and Diff (Matching)
220
+ - Commit Workflow (DragToOrder)
221
+ - Undo Changes (ScenarioGame)
222
+
223
+ 3. Branching
224
+ - Create and Switch (CommandBuilder)
225
+ - Merge Basics (DragToOrder)
226
+ - Conflict Resolution (ScenarioGame)
227
+
228
+ 4. Remote Repositories
229
+ - Clone and Fork (Flashcards)
230
+ - Push and Pull (CommandBuilder)
231
+ - Pull Requests (ScenarioGame)
232
+
233
+ 5. Advanced Topics
234
+ - Rebase (DragToOrder)
235
+ - Cherry Pick (Quiz)
236
+ - Stash (Matching)
237
+
238
+ Total: 5 sections, 15 exercises
239
+ ---
240
+ Proceeding to Step 3...
241
+ ```
242
+
243
+ ### Step 3: Data Generation
244
+
245
+ **What happens:** Four JavaScript data files are generated containing all course content: sections with descriptions, exercises with questions and answers, final test questions, and achievements.
246
+
247
+ **Expected output:**
248
+
249
+ ```
250
+ Step 3/8: Data Generation
251
+ ---
252
+ Generated files:
253
+ - src/data/sections.js (5 sections, 15 subsections)
254
+ - src/data/exercises.js (15 exercises across 6 types)
255
+ - src/data/quizQuestions.js (25 questions for final test)
256
+ - src/data/achievements.js (12 achievements)
257
+ ---
258
+ Proceeding to Step 4...
259
+ ```
260
+
261
+ ### Step 4: Scaffold
262
+
263
+ **What happens:** The project skeleton is created: `package.json` with all dependencies, Vite configuration, TailwindCSS v4 setup, `index.html` with SEO tags, GitHub Actions workflow for deployment.
264
+
265
+ **Expected output:**
266
+
267
+ ```
268
+ Step 4/8: Scaffold
269
+ ---
270
+ Created project structure:
271
+ - package.json (React 19, Vite 6, TailwindCSS 4, Zustand 5)
272
+ - vite.config.js (base: /docker-course/)
273
+ - index.html (OG tags, JSON-LD, lang="en")
274
+ - src/app.css (TailwindCSS v4 @theme)
275
+ - src/main.jsx (entry point)
276
+ - .github/workflows/deploy.yml
277
+ ---
278
+ Proceeding to Step 5...
279
+ ```
280
+
281
+ ### Step 5: Components
282
+
283
+ **What happens:** All React components are generated — layout (Header, Footer, Sidebar), interactive exercises (6 types), common UI elements (Toast, ProgressBar, Badge), and page components (Home, Section, FinalTest, Results).
284
+
285
+ **Expected output:**
286
+
287
+ ```
288
+ Step 5/8: Components
289
+ ---
290
+ Generated 22 components:
291
+ Layout (4): Header, Footer, Sidebar, Navigation
292
+ Interactive (6): Quiz, Flashcards, Matching, DragToOrder,
293
+ CommandBuilder, ScenarioGame
294
+ Common (6): Toast, ProgressBar, Badge, AchievementPopup,
295
+ Button, Card
296
+ Pages (4): HomePage, SectionPage, FinalTestPage, ResultsPage
297
+ Sections (2): SectionList, ExerciseRenderer
298
+ ---
299
+ Proceeding to Step 6...
300
+ ```
301
+
302
+ ### Step 6: Gamification
303
+
304
+ **What happens:** The Zustand store is configured with persist middleware, point calculations are wired to exercise completion, achievement unlock logic is connected, and toast notifications are set up.
305
+
306
+ **Expected output:**
307
+
308
+ ```
309
+ Step 6/8: Gamification
310
+ ---
311
+ Configured:
312
+ - Zustand store (persist -> localStorage)
313
+ - Points: +10 per exercise, +5 streak bonus
314
+ - 12 achievements with criteria
315
+ - Progress tracking per section
316
+ - Toast notifications
317
+ - Streak counter (resets on wrong answer)
318
+ ---
319
+ Proceeding to Step 7...
320
+ ```
321
+
322
+ ### Step 7: Deploy
323
+
324
+ **What happens:** A GitHub Actions workflow file is generated that automates building and deploying the site to GitHub Pages on every push to main.
325
+
326
+ **Expected output:**
327
+
328
+ ```
329
+ Step 7/8: Deploy
330
+ ---
331
+ Created:
332
+ - .github/workflows/deploy.yml
333
+ - Vite base path: /docker-course/
334
+ - Build command: npm run build
335
+ - Deploy target: GitHub Pages
336
+ ---
337
+ Proceeding to Step 8...
338
+ ```
339
+
340
+ ### Step 8: Verification
341
+
342
+ **What happens:** The pipeline runs automated checks on the generated project to ensure everything is correctly wired.
343
+
344
+ **Expected output:**
345
+
346
+ ```
347
+ Step 8/8: Verification
348
+ ---
349
+ Checks:
350
+ [PASS] All imports resolve (22 components, 4 data files)
351
+ [PASS] Data file structure valid (sections, exercises, quizzes, achievements)
352
+ [PASS] Component hierarchy correct (App -> Router -> Pages -> Layout)
353
+ [PASS] Router configuration valid (4 routes, all point to existing pages)
354
+ [PASS] Build simulation passed (no compilation errors detected)
355
+
356
+ All 5 checks passed!
357
+ ---
358
+ Generation complete. Your project is at: ./docker-course/
359
+ Next steps:
360
+ cd docker-course && npm install && npm run dev
361
+ ```
362
+
363
+ ---
364
+
365
+ ## 4. Exercise Types Explained
366
+
367
+ Each exercise type is designed for a specific kind of learning content. The pipeline automatically selects the best type for each topic, but you can override this.
368
+
369
+ ### 4.1. Quiz
370
+
371
+ **What it is:** A question with 2-4 answer options. The student selects one (or multiple for multi-select). Immediate feedback is provided.
372
+
373
+ **When it is used:** Testing knowledge of facts, definitions, concepts, or syntax. Best for "what is X" or "which of the following" questions.
374
+
375
+ **Example:**
376
+
377
+ ```
378
+ Question: Which command creates a new Git branch?
379
+ A) git branch new-feature <- correct
380
+ B) git checkout new-feature
381
+ C) git create new-feature
382
+ D) git new new-feature
383
+
384
+ [Select answer] -> [Show result + explanation]
385
+ ```
386
+
387
+ **Scoring:** +10 points for correct answer, 0 for incorrect.
388
+
389
+ ### 4.2. Flashcards
390
+
391
+ **What it is:** A card with a question or term on the front side. The student mentally recalls the answer, then flips the card to verify. They mark the card as "Known" or "Review again."
392
+
393
+ **When it is used:** Memorization of terms, definitions, command syntax, keyboard shortcuts. Effective for vocabulary-style learning.
394
+
395
+ **Example:**
396
+
397
+ ```
398
+ Front: git stash
399
+ [Flip card]
400
+ Back: Temporarily saves uncommitted changes and reverts
401
+ the working directory to the last commit state.
402
+
403
+ [I knew it] [Review again]
404
+ ```
405
+
406
+ **Scoring:** +10 points per card marked "Known". Cards marked "Review again" can be revisited.
407
+
408
+ ### 4.3. Matching
409
+
410
+ **What it is:** Two columns of items. The student drags items from the left column to match them with the correct items in the right column.
411
+
412
+ **When it is used:** Linking related concepts: command to description, term to definition, input to output, flag to behavior.
413
+
414
+ **Example:**
415
+
416
+ ```
417
+ Left column: Right column:
418
+ git add Stage changes for commit
419
+ git commit Record staged changes
420
+ git push Upload commits to remote
421
+ git pull Download and merge remote changes
422
+ ```
423
+
424
+ **Scoring:** +10 points if all matches are correct. Partial credit: +5 for 75%+ correct.
425
+
426
+ ### 4.4. Drag-to-Order
427
+
428
+ **What it is:** A list of items displayed in random order. The student reorders them by dragging items into the correct sequence.
429
+
430
+ **When it is used:** Sequences of steps, priority ordering, lifecycle stages, workflow steps.
431
+
432
+ **Example:**
433
+
434
+ ```
435
+ Put these Git workflow steps in order:
436
+ [ ] Push to remote
437
+ [ ] Stage changes (git add)
438
+ [ ] Make changes to files
439
+ [ ] Create a commit (git commit)
440
+
441
+ Correct order: Make changes -> Stage -> Commit -> Push
442
+ ```
443
+
444
+ **Scoring:** +10 points for fully correct order. +5 for one swap away from correct.
445
+
446
+ ### 4.5. Command Builder
447
+
448
+ **What it is:** The student assembles a command from individual parts (base command, subcommand, flags, arguments) by selecting or dragging pieces into a command line.
449
+
450
+ **When it is used:** CLI tools, SQL queries, API requests, shell commands. Any scenario where the student needs to construct a precise command.
451
+
452
+ **Example:**
453
+
454
+ ```
455
+ Build the command to clone a repository with depth 1:
456
+
457
+ Available parts:
458
+ [git] [clone] [--depth] [1] [--branch] [main] [https://repo.url]
459
+
460
+ Build area:
461
+ [ git ] [ clone ] [ --depth ] [ 1 ] [ https://repo.url ]
462
+
463
+ [Check command]
464
+ ```
465
+
466
+ **Scoring:** +10 points for exact match. +5 for correct command with extra unnecessary flags.
467
+
468
+ ### 4.6. Scenario Game
469
+
470
+ **What it is:** A narrative scenario is presented (a situation, a problem, a decision point). The student reads the context and chooses one of 2-4 actions. Each action leads to an outcome with feedback explaining why it was correct or suboptimal.
471
+
472
+ **When it is used:** Decision-making, troubleshooting, best practices, conflict resolution, real-world application of knowledge.
473
+
474
+ **Example:**
475
+
476
+ ```
477
+ Scenario:
478
+ You are working on a feature branch and your teammate tells you
479
+ that the main branch has critical fixes you need. Your branch
480
+ has 5 uncommitted files.
481
+
482
+ What do you do?
483
+ A) git merge main (merging into dirty working directory)
484
+ B) git stash && git pull origin main && git stash pop
485
+ C) git commit -a -m "WIP" && git merge main
486
+ D) git checkout main (switching with uncommitted changes)
487
+
488
+ Best answer: B
489
+ Explanation: Stashing saves your work cleanly, lets you update
490
+ from main, and restores your changes afterward. Option C creates
491
+ an unnecessary WIP commit. Options A and D risk losing changes.
492
+ ```
493
+
494
+ **Scoring:** +10 points for the best answer. +5 for acceptable alternative (if marked as such in data).
495
+
496
+ ---
497
+
498
+ ## 5. Gamification Features
499
+
500
+ ### 5.1. Points
501
+
502
+ Every interaction earns points:
503
+
504
+ | Action | Points | Condition |
505
+ |--------|-------:|-----------|
506
+ | Correct exercise answer | +10 | Always |
507
+ | Streak bonus | +5 | 3+ correct answers in a row |
508
+ | Section completion bonus | +25 | Complete all exercises in a section |
509
+ | Achievement unlock | +50 to +200 | Varies by achievement rarity |
510
+ | Final test passing | +100 | Score >= 70% |
511
+ | Final test perfect | +300 | Score = 100% |
512
+
513
+ Points are displayed in the Header component and update in real-time as the student progresses.
514
+
515
+ ### 5.2. Achievements
516
+
517
+ Achievements are unlocked by meeting specific criteria. When an achievement unlocks, a toast notification slides in from the corner with the achievement name, icon, and points earned.
518
+
519
+ **Achievement rarity tiers:**
520
+
521
+ | Rarity | Points | Typical criteria |
522
+ |--------|-------:|-----------------|
523
+ | Common | 50 | Complete first exercise, visit all sections |
524
+ | Uncommon | 75 | Complete a section, reach a point milestone |
525
+ | Rare | 100 | Perfect score on a section, 10-streak |
526
+ | Epic | 150 | Complete all sections, pass final test |
527
+ | Legendary | 200 | Perfect final test, unlock all other achievements |
528
+
529
+ **Sample achievements:**
530
+
531
+ ```
532
+ First Step (Common) - Complete your first exercise
533
+ Fast Learner (Common) - Complete 5 exercises
534
+ Streak Master (Rare) - Get 10 correct answers in a row
535
+ Perfectionist (Rare) - Score 100% on any section
536
+ Scholar (Epic) - Complete all sections
537
+ Grand Master (Legendary) - Score 100% on the final test
538
+ ```
539
+
540
+ ### 5.3. Progress tracking
541
+
542
+ Progress is tracked at two levels:
543
+
544
+ **Section-level progress:** A percentage bar on each section card shows how many exercises have been completed. 100% means all exercises in the section are done.
545
+
546
+ **Overall progress:** The sidebar (or header on mobile) shows total course progress as a percentage of all exercises completed across all sections.
547
+
548
+ Progress persists across browser sessions via localStorage (Zustand persist middleware). Clearing browser data resets progress.
549
+
550
+ ### 5.4. Toast notifications
551
+
552
+ Toasts appear for:
553
+ - Achievement unlocked (gold border, achievement icon)
554
+ - Section completed (green border, checkmark)
555
+ - Streak milestone (blue border, flame icon)
556
+ - Points earned (+10, +25, etc.)
557
+
558
+ Toasts auto-dismiss after 4 seconds. They stack if multiple events fire simultaneously (e.g., completing an exercise that also triggers an achievement).
559
+
560
+ ---
561
+
562
+ ## 6. Final Assessment
563
+
564
+ ### 6.1. How it works
565
+
566
+ The final test is a timed quiz covering all course sections. Questions are drawn from `quizQuestions.js` and shuffled randomly. Each question has 4 options with one correct answer.
567
+
568
+ **Flow:**
569
+
570
+ 1. Student navigates to "Final Test" from the navigation menu
571
+ 2. All questions are presented (no section-by-section breakdown)
572
+ 3. Student answers each question and can navigate forward/backward
573
+ 4. Upon submission, answers are graded immediately
574
+ 5. Results page shows: total score, per-section breakdown, letter grade
575
+
576
+ ### 6.2. Grading
577
+
578
+ The grading scale:
579
+
580
+ | Grade | Score range | Label |
581
+ |-------|-----------|-------|
582
+ | A | 90-100% | Excellent |
583
+ | B | 80-89% | Good |
584
+ | C | 70-79% | Satisfactory (passing) |
585
+ | D | 60-69% | Needs improvement |
586
+ | F | 0-59% | Failing |
587
+
588
+ The default passing threshold is 70% (grade C or higher). This can be configured in the admin settings.
589
+
590
+ ### 6.3. After the test
591
+
592
+ - Results are saved in the Zustand store (persisted to localStorage)
593
+ - The student can retake the test at any time — the latest score replaces the previous one
594
+ - If the student passes, the "Final Test Passed" achievement unlocks
595
+ - If the student scores 100%, the "Perfect Score" achievement unlocks
596
+ - The results page shows which sections had the most incorrect answers, helping the student identify areas for review
597
+
598
+ ---
599
+
600
+ ## 7. Customization Options
601
+
602
+ ### 7.1. Language
603
+
604
+ ```
605
+ /edu-site "Docker basics" --lang ru # Force Russian
606
+ /edu-site "Docker basics" --lang en # Force English
607
+ /edu-site "Docker basics" # Auto-detect
608
+ ```
609
+
610
+ Language affects all UI labels, exercise instructions, achievement names, and toast messages.
611
+
612
+ ### 7.2. Theme and color palette
613
+
614
+ ```
615
+ /edu-site "Git basics" --palette tech-blue
616
+ /edu-site "Git basics" --palette green-learn
617
+ /edu-site "Git basics" --palette purple-code
618
+ /edu-site "Git basics" --palette warm-orange
619
+ /edu-site "Git basics" --palette dark-mode
620
+ ```
621
+
622
+ You can also edit `src/app.css` after generation to fully customize the theme via TailwindCSS v4 `@theme` variables.
623
+
624
+ ### 7.3. Exercise types per section
625
+
626
+ Force specific exercise types for specific sections:
627
+
628
+ ```
629
+ /edu-site "Git basics" --exercise-mix "quiz:3,commandbuilder:5,scenario:3"
630
+ ```
631
+
632
+ Or let the pipeline choose automatically (default behavior).
633
+
634
+ ### 7.4. Achievement count
635
+
636
+ ```
637
+ /edu-site "Git basics" --achievements 8 # Minimal
638
+ /edu-site "Git basics" --achievements 20 # Comprehensive
639
+ ```
640
+
641
+ Default: 12 achievements.
642
+
643
+ ### 7.5. Base path for deployment
644
+
645
+ ```
646
+ /edu-site "Git basics" --base /my-git-course/
647
+ ```
648
+
649
+ This sets the Vite `base` configuration for correct asset loading on GitHub Pages.
650
+
651
+ ### 7.6. Output directory
652
+
653
+ ```
654
+ /edu-site "Git basics" --output ./my-custom-directory/
655
+ ```
656
+
657
+ Default: a directory named after the course topic (kebab-case).
658
+
659
+ ---
660
+
661
+ ## 8. Data Files Reference
662
+
663
+ The generated project has four data files in `src/data/`. Understanding their structure helps you customize the course after generation.
664
+
665
+ ### 8.1. sections.js
666
+
667
+ ```javascript
668
+ export const sections = [
669
+ {
670
+ id: 'getting-started',
671
+ title: 'Getting Started',
672
+ description: 'Set up your environment and learn the basics.',
673
+ icon: 'rocket', // emoji or icon name
674
+ order: 1,
675
+ subsections: [
676
+ {
677
+ id: 'installation',
678
+ title: 'Installation',
679
+ content: 'How to install Git on your system...',
680
+ },
681
+ // ...
682
+ ],
683
+ },
684
+ // ...
685
+ ]
686
+ ```
687
+
688
+ ### 8.2. exercises.js
689
+
690
+ ```javascript
691
+ export const exercises = [
692
+ {
693
+ id: 'ex-001',
694
+ sectionId: 'getting-started',
695
+ type: 'quiz', // quiz | flashcards | matching | drag-to-order | command-builder | scenario-game
696
+ title: 'Installation Check',
697
+ data: {
698
+ question: 'Which command verifies Git installation?',
699
+ options: ['git --version', 'git check', 'git verify', 'git status'],
700
+ correctAnswer: 0,
701
+ explanation: 'git --version prints the installed Git version.',
702
+ },
703
+ points: 10,
704
+ order: 1,
705
+ },
706
+ {
707
+ id: 'ex-002',
708
+ sectionId: 'core-commands',
709
+ type: 'command-builder',
710
+ title: 'Build a Clone Command',
711
+ data: {
712
+ instruction: 'Clone a repository with shallow depth of 1',
713
+ parts: ['git', 'clone', '--depth', '1', '--branch', 'main', 'https://github.com/user/repo.git'],
714
+ correctCommand: ['git', 'clone', '--depth', '1', 'https://github.com/user/repo.git'],
715
+ acceptableAlternatives: [
716
+ ['git', 'clone', '--depth', '1', '--branch', 'main', 'https://github.com/user/repo.git'],
717
+ ],
718
+ },
719
+ points: 10,
720
+ order: 1,
721
+ },
722
+ {
723
+ id: 'ex-003',
724
+ sectionId: 'branching',
725
+ type: 'scenario-game',
726
+ title: 'Merge Conflict',
727
+ data: {
728
+ situation: 'You and your colleague both edited the same file. When you pull, Git reports a merge conflict.',
729
+ choices: [
730
+ {
731
+ text: 'Delete your changes and accept theirs',
732
+ outcome: 'This works but you lose your work. Not ideal unless your changes were minor.',
733
+ isOptimal: false,
734
+ points: 5,
735
+ },
736
+ {
737
+ text: 'Open the file, review both versions, and manually resolve the conflict',
738
+ outcome: 'This is the recommended approach. You preserve the best of both changes.',
739
+ isOptimal: true,
740
+ points: 10,
741
+ },
742
+ {
743
+ text: 'Force push your version',
744
+ outcome: 'This overwrites your colleague\'s work without review. Never do this on shared branches.',
745
+ isOptimal: false,
746
+ points: 0,
747
+ },
748
+ ],
749
+ },
750
+ points: 10,
751
+ order: 2,
752
+ },
753
+ // ... more exercises
754
+ ]
755
+ ```
756
+
757
+ ### 8.3. quizQuestions.js
758
+
759
+ ```javascript
760
+ export const quizQuestions = [
761
+ {
762
+ id: 'fq-001',
763
+ sectionId: 'getting-started',
764
+ question: 'What does git init do?',
765
+ options: [
766
+ 'Creates a new Git repository',
767
+ 'Initializes a remote connection',
768
+ 'Installs Git on your system',
769
+ 'Creates a .gitignore file',
770
+ ],
771
+ correctAnswer: 0,
772
+ explanation: 'git init creates a new .git directory in the current folder, initializing a new repository.',
773
+ },
774
+ // ... 15-30 questions
775
+ ]
776
+ ```
777
+
778
+ ### 8.4. achievements.js
779
+
780
+ ```javascript
781
+ export const achievements = [
782
+ {
783
+ id: 'first-exercise',
784
+ title: 'First Step',
785
+ description: 'Complete your first exercise',
786
+ icon: 'rocket',
787
+ criteria: { type: 'exercise_count', count: 1 },
788
+ points: 50,
789
+ rarity: 'common',
790
+ },
791
+ {
792
+ id: 'streak-10',
793
+ title: 'On Fire',
794
+ description: 'Get 10 correct answers in a row',
795
+ icon: 'fire',
796
+ criteria: { type: 'streak', count: 10 },
797
+ points: 100,
798
+ rarity: 'rare',
799
+ },
800
+ {
801
+ id: 'final-master',
802
+ title: 'Grand Master',
803
+ description: 'Score 100% on the final test',
804
+ icon: 'trophy',
805
+ criteria: { type: 'final_test_perfect' },
806
+ points: 200,
807
+ rarity: 'legendary',
808
+ },
809
+ // ...
810
+ ]
811
+ ```
812
+
813
+ ---
814
+
815
+ ## 9. Common Scenarios
816
+
817
+ ### Scenario A: CLI tool documentation
818
+
819
+ You have a CLI tool with a README or docs site and want to create an interactive training course.
820
+
821
+ ```
822
+ /edu-site https://docs.my-tool.dev/getting-started
823
+ ```
824
+
825
+ The pipeline will:
826
+ 1. Fetch and parse the documentation pages
827
+ 2. Identify commands, flags, and options
828
+ 3. Generate CommandBuilder exercises for each command
829
+ 4. Create ScenarioGame exercises for troubleshooting scenarios
830
+ 5. Add Flashcards for memorizing flag meanings
831
+ 6. Build a final test with questions from all sections
832
+
833
+ **Result:** A gamified training site that teaches users your CLI tool interactively.
834
+
835
+ ### Scenario B: API reference
836
+
837
+ ```
838
+ /edu-site ./docs/api-reference.md
839
+ ```
840
+
841
+ The pipeline adapts to API content by:
842
+ - Creating Matching exercises (endpoint -> description)
843
+ - Generating Quiz questions about HTTP methods, status codes, authentication
844
+ - Building CommandBuilder exercises for API calls (curl commands)
845
+ - Adding ScenarioGame for error handling scenarios
846
+
847
+ ### Scenario C: Onboarding course for a new team member
848
+
849
+ ```
850
+ /edu-site "Onboarding for Backend Team: our tech stack (Node.js, PostgreSQL, Redis, Docker), coding conventions, PR review process, deployment pipeline, monitoring with Grafana"
851
+ ```
852
+
853
+ In generative mode, the pipeline creates educational content from scratch. Ideal for internal training materials where no formal documentation exists.
854
+
855
+ ### Scenario D: Programming tutorial
856
+
857
+ ```
858
+ /edu-site "Python for Data Science: pandas DataFrames, data cleaning, visualization with matplotlib, basic statistics, linear regression"
859
+ ```
860
+
861
+ The pipeline generates:
862
+ - Progressive sections from basics to advanced
863
+ - Quiz exercises for theory (statistics concepts)
864
+ - CommandBuilder exercises for code construction
865
+ - DragToOrder exercises for data processing workflows
866
+ - Flashcards for function/method signatures
867
+
868
+ ### Scenario E: Language learning (non-programming)
869
+
870
+ While designed for technical content, edu-site can work for any factual knowledge:
871
+
872
+ ```
873
+ /edu-site "Introduction to Music Theory: notes, scales, chords, rhythm, time signatures, key signatures"
874
+ ```
875
+
876
+ Exercises adapt:
877
+ - Matching: note name to frequency, chord to its notes
878
+ - Quiz: identify intervals, recognize scales
879
+ - DragToOrder: arrange notes in a scale
880
+ - Flashcards: musical term definitions
881
+
882
+ ---
883
+
884
+ ## 10. Tips and Best Practices
885
+
886
+ ### Provide structured input for best results
887
+
888
+ The more structured your input, the better the course structure. Markdown with headings produces better section hierarchies than plain text:
889
+
890
+ ```markdown
891
+ # Good input (structured)
892
+ ## Installation
893
+ Install with npm install -g my-tool
894
+
895
+ ## Basic Commands
896
+ ### init
897
+ Creates a new project...
898
+
899
+ ### build
900
+ Compiles the project...
901
+ ```
902
+
903
+ ```
904
+ # Weaker input (unstructured)
905
+ My tool can do init and build. Init creates a project.
906
+ Build compiles it. You install with npm.
907
+ ```
908
+
909
+ ### Keep sections focused
910
+
911
+ Each section should cover one cohesive topic. If a section spans too many concepts, the exercises become unfocused and less effective. Aim for 3-5 exercises per section.
912
+
913
+ ### Review generated data files
914
+
915
+ After generation, skim through the data files (`sections.js`, `exercises.js`, `quizQuestions.js`, `achievements.js`). Fix any factual errors, adjust difficulty levels, and add context-specific alternatives for CommandBuilder exercises.
916
+
917
+ ### Test on mobile
918
+
919
+ The generated site uses TailwindCSS responsive utilities and works on mobile browsers. Check that:
920
+ - Navigation collapses properly
921
+ - Drag-to-Order and Matching exercises are usable with touch
922
+ - Text is readable without horizontal scrolling
923
+
924
+ ### Use the final test as a quality check
925
+
926
+ Take the final test yourself. If questions are ambiguous, options are too similar, or explanations are unclear, edit `quizQuestions.js` directly. Each question has an `explanation` field — use it to provide helpful context.
927
+
928
+ ### Commit the generated project to git before editing
929
+
930
+ ```bash
931
+ cd generated-site/
932
+ git init
933
+ git add .
934
+ git commit -m "initial generation"
935
+ ```
936
+
937
+ This gives you a clean baseline to diff against after manual edits.
938
+
939
+ ### Choose the right exercise type for the content
940
+
941
+ | Content type | Best exercise types |
942
+ |-------------|-------------------|
943
+ | Definitions, terminology | Flashcards, Quiz |
944
+ | CLI commands, syntax | CommandBuilder |
945
+ | Step-by-step processes | DragToOrder |
946
+ | Concept relationships | Matching |
947
+ | Decision-making, best practices | ScenarioGame |
948
+ | Multiple-choice knowledge checks | Quiz |
949
+
950
+ ---
951
+
952
+ ## 11. FAQ
953
+
954
+ ### Q: How long does generation take?
955
+
956
+ Approximately 5-10 minutes for a typical course (5-8 sections, 15-25 exercises). Larger inputs with more topics may take up to 15 minutes.
957
+
958
+ ### Q: Can I edit the generated site after creation?
959
+
960
+ Yes. The generated project is a standard React + Vite project. Edit any file — components, data, styles — using your preferred editor. Run `npm run dev` to see changes instantly with hot module replacement.
961
+
962
+ ### Q: Does the site require a backend server?
963
+
964
+ No. The generated site is a fully static SPA. All content is embedded in JavaScript data files. No API calls are made at runtime. After `npm run build`, the `dist/` directory can be served by any static file server.
965
+
966
+ ### Q: Can I add my own exercises after generation?
967
+
968
+ Yes. Add entries to `src/data/exercises.js` following the existing format. Each exercise must have a unique `id`, a valid `sectionId` matching a section in `sections.js`, and a `type` matching one of the six supported types. The `ExerciseRenderer` component will automatically render the new exercise.
969
+
970
+ ### Q: How do I change the passing score for the final test?
971
+
972
+ Edit `src/pages/FinalTestPage.jsx`. Find the constant `PASSING_THRESHOLD` (default: `0.7` for 70%) and change it to your preferred value.
973
+
974
+ ### Q: Can I deploy to Vercel or Netlify instead of GitHub Pages?
975
+
976
+ Yes. The generated project builds to a standard `dist/` directory. For Vercel or Netlify:
977
+ 1. Set `base: '/'` in `vite.config.js` (not the GitHub Pages repo name)
978
+ 2. Connect your repository to Vercel/Netlify
979
+ 3. Set build command: `npm run build`
980
+ 4. Set output directory: `dist`
981
+
982
+ ### Q: What browsers are supported?
983
+
984
+ Modern browsers supporting ES2020+: Chrome 80+, Firefox 80+, Safari 14+, Edge 80+. No IE11 support.
985
+
986
+ ### Q: Can I generate a course in a language other than English or Russian?
987
+
988
+ The pipeline auto-detects English and Russian. For other languages, provide content in the desired language and set `--lang en` or `--lang ru` for UI elements. The exercises and content will use whatever language you provided; only the UI chrome (buttons, labels) will be in the specified language.
989
+
990
+ ### Q: How do I reset student progress?
991
+
992
+ Students can clear their progress by clearing localStorage in their browser (Developer Tools > Application > Local Storage > delete `edu-site-storage`). Alternatively, add a "Reset Progress" button to the settings page by wiring it to the `resetProgress` action in the Zustand store.
993
+
994
+ ### Q: Can I use TypeScript instead of JavaScript?
995
+
996
+ The default generation uses `.jsx` files. TypeScript support can be added by renaming files to `.tsx`, adding a `tsconfig.json`, and installing TypeScript dependencies. This is a manual post-generation step.
997
+
998
+ ### Q: The generated site has a factual error in an exercise. How do I fix it?
999
+
1000
+ Edit the corresponding entry in `src/data/exercises.js`. Find the exercise by its `id` or `title`, correct the data (question text, answer options, correct answer index, explanation), save, and the change takes effect immediately in dev mode.
1001
+
1002
+ ### Q: Can I add images to the exercises?
1003
+
1004
+ The default exercise types are text-based. To add images, modify the exercise data to include image URLs and update the corresponding exercise component to render `<img>` tags. Images should be placed in the `public/` directory for static serving.
1005
+
1006
+ ### Q: How much does the generated site weigh?
1007
+
1008
+ The production build is typically 80-160 KB gzipped, depending on content volume. This includes React, Zustand, TailwindCSS (tree-shaken), and all application code plus data. It loads in under 2 seconds on broadband connections.