Contributor Documentation Index
This documentation is for contributors and developers. If you're a new user, see README.md for installation and usage.
- π User Guide: README.md - Installation, usage, controls
- π€ AI Context: CLAUDE.md - Quick reference for AI assistants
- π Features: Features Overview below
- ποΈ Architecture: docs/steering/structure.md
- π οΈ Tech Stack: docs/steering/tech.md
- π Releases: docs/steering/release-process.md
This documentation follows a feature-based organization aligned with the global CLAUDE.md workflow. Each feature has its complete lifecycle tracked in its own folder.
For each feature, we maintain three documents following this progression:
-
requirements.md - WHAT to build (EARS format)
- Structured as:
WHEN [condition] THE SYSTEM SHALL [behavior] - Clear, testable requirements
- Future phase requirements marked as FUTURE
- Structured as:
-
design.md - HOW to build it (technical architecture)
- System architecture and data flows
- Implementation details and algorithms
- Design decisions and rationale
- Testing strategy
-
tasks.md - Progress tracking (discrete tasks)
- Implementation status (completed/pending)
- Phase organization (Phase 1 MVP, Phase 2+, Phase 3+)
- Implementation notes and decisions
- Test coverage details
Located in docs/steering/:
- product.md - Product vision, target users, key features, success metrics
- tech.md - Technology stack decisions, dependencies, build tools, rationale
- structure.md - Architecture patterns, module design, file organization
These documents represent persistent knowledge about the project that doesn't change with individual features.
Located in docs/features/<feature-name>/:
Each feature folder contains the complete Requirements β Design β Tasks workflow.
Core typing engine, scoring algorithms, and session management.
Module: src/engine/
- Character-by-character input validation
- Real-time WPM and accuracy calculation
- Session lifecycle management
- Performance: <50ms input latency
Content generation for AZERTY home row practice.
Module: src/content/
- Progressive difficulty (Level 1: f,j β Level 6: French words)
- Deterministic content generation
- Integration with keyboard layout
- Lesson selection menu with keyboard navigation
- All 6 levels with cumulative progression β Completed
Statistics persistence for cross-session tracking.
Module: src/data/
- JSON storage at
~/.config/typer-cli/stats.json - SessionRecord: timestamp, lesson type, WPM, accuracy, duration
- XDG Base Directory compliance
- Graceful error handling
Terminal UI rendering with ratatui.
Module: src/ui/
- Minimal, distraction-free design
- Real-time visual feedback (green/red/gray)
- Live statistics panel
- Results screen with session summary
AZERTY layout definitions and finger mappings.
Module: src/keyboard/
- Home row: q, s, d, f, g, h, j, k, l, m
- Finger-to-key mapping
- Progressive key groups
- Extensible for future layouts (BΓPO, Dvorak)
Comprehensive requirements and design documented in feature folders:
bigram-training/ β COMPLETED
Practice common two-letter combinations for increased fluency.
Module: src/content/bigram.rs, src/content/bigram_generator.rs
- 3 languages: French, English, Code
- 3 levels per language: Drill β Word context β Realistic text
- 9 total lessons (3 languages Γ 3 levels)
- French bigrams: qu, ou, en, on, an, es, ai, er, re, de
- English bigrams: th, he, in, er, an, re, on, at, en, ed
- Code bigrams: ->, ::, =>, !=, ==, <=, >=, &&, ||, //
- Frequency-ordered (most common first)
- Deterministic generation for consistent practice
code-symbols/ β COMPLETED
Master programming symbols across different languages.
Module: src/content/code_symbols.rs, src/content/code_generator.rs
- 3 programming languages: TypeScript, Rust, Python
- 6 levels per language: Brackets β Operators β Comparisons β Arrows β Compound β Realistic
- 18 total lessons (3 languages Γ 6 levels)
- TypeScript: Arrow functions (=>), type annotations (:), const/let
- Rust: Function arrows (->), match arms (=>), path separator (::), closures
- Python: List/dict comprehensions, f-strings, decorators (@), type hints
- Syntactically valid code snippets for each language
- Progressive difficulty from simple brackets to complex code
adaptive-mode/ β COMPLETED (MVP)
Personalized training based on individual weaknesses.
Modules: src/engine/analytics.rs, src/engine/adaptive.rs, src/content/adaptive_generator.rs
- Per-key and per-bigram statistics tracking β
- Weakness detection (accuracy < 80%, speed > 75th percentile) β
- Spaced repetition algorithm (intervals by mastery level) β
- Adaptive content generation (60% weak, 30% moderate, 10% mastered) β
- Recommendation engine for next practice β
- Mastery level progression (Beginner β Learning β Proficient β Mastered) β
- Local data storage with backward compatibility β
- Automatic analytics tracking after each session β
- Conditional menu appearance (>= 10 sessions, >= 100 keystrokes) β
keyboard-display/ β COMPLETED
Visual AZERTY keyboard layout with real-time highlighting.
Module: src/ui/keyboard.rs, src/keyboard/azerty.rs
- Full 5-row keyboard rendering (Number, Top, Home, Bottom, Modifier rows)
- Real-time next-key highlighting (cyan background)
- Shift state indication (both shift keys highlight)
- Finger color hints toggle (Ctrl+F)
- Accuracy heatmap overlay toggle (Ctrl+H)
- Keyboard visibility toggle (Tab)
finger-training/ β COMPLETED
Targeted finger-pair practice with bilateral drills.
Module: src/content/finger_generator.rs
- 24 lessons: 4 finger pairs Γ 6 variants
- 3 difficulty levels: Home Row, Extended, All Keys
- Base and shift variants for each level
- Corrected French AZERTY finger mappings (16 fixes)
- Auto-generated drills with 3-phase pattern
- Prioritized menu placement (after adaptive mode)
two-level-menu/ β COMPLETED
Hierarchical navigation system for improved lesson discovery.
Module: src/content/category.rs, src/app.rs, src/ui/render.rs
- Two-screen navigation: Category selection β Lesson selection
- 6 lesson categories: Adaptive, Finger Training, Row Training, Languages, Code, Custom
- Category-based lesson filtering
- Visual descriptions and color coding
- Number shortcuts (1-5 for categories, 1-9 for lessons)
- ESC navigation: Lessons β Categories β Quit
- Context preservation after session completion
statistics-page/ β COMPLETED
Performance analytics dashboard with visual keyboard heatmap.
Module: src/ui/render.rs, src/app.rs
- Overall session statistics (sessions, keystrokes, WPM, accuracy)
- Mastery level breakdown (Mastered, Proficient, Learning, Beginner counts)
- Top 10 weaknesses list (< 80% accuracy with error details)
- Common mistype patterns (top 5 error patterns)
- Visual keyboard heatmap with accuracy-based color coding
- Two-column layout (40% stats / 60% heatmap)
- Accessible via 's' key from main menu
- Graceful placeholder when no analytics data exists
custom-lessons/ β COMPLETED
User-provided markdown lessons for personalized typing practice.
Module: src/content/custom.rs
- Load from
~/.config/typer-cli/custom/and./custom/ - YAML front matter support (title, description)
- Automatic deduplication of titles with (1), (2) suffix
- Preserved formatting (line breaks, spacing, indentation)
- New "Custom" category in menu
- Stats tracking with lesson title as identifier
- Graceful error handling with warning messages
- No external dependencies (uses std library only)
- Enhanced analytics - Trend graphs, progress charts over time, session history visualization
- Enhanced adaptive UI - Pre/post-session feedback, progress indicators
- Data export - JSON/CSV export for external analysis
- Themes - Multiple color schemes, high contrast options
- Multi-layout - BΓPO, Dvorak, custom keyboard layouts
- Gamification - Optional achievements, streaks, challenges
- Advanced adaptive - Machine learning, optimal schedules, fatigue detection
- Understand the product: Start with
docs/steering/product.md - Understand the tech stack: Read
docs/steering/tech.md - Understand the architecture: Review
docs/steering/structure.md - Pick a feature: Browse
docs/features/for areas of interest
- Create folder:
docs/features/feature-name/ - Write requirements:
requirements.md(EARS format) - Design solution:
design.md(architecture and implementation) - Track progress:
tasks.md(discrete, trackable tasks) - Update this README with feature description
Each feature folder contains:
- requirements.md - What problem does it solve?
- design.md - How is it implemented?
- tasks.md - What's done and what's planned?
Module locations are documented in each feature's design.md:
src/app.rs- Application state machine and two-level navigationsrc/engine/- Typing session core, analytics, adaptive algorithmssrc/content/- Lesson generation and categorizationcategory.rs- Category filtering (see two-level-menu/design.md)
src/data/- Statistics persistence (see session-storage/design.md)src/ui/- Terminal interfacerender.rs- Category menu, lesson menu, session renderingkeyboard.rs- Visual keyboard display
src/keyboard/- Layout definitions and finger mappings
- Identify which feature it belongs to
- Add to
docs/features/<feature>/requirements.mdin EARS format - Update
design.mdif architecture changes - Add tasks to
tasks.md
- Check
requirements.mdfor what to build - Review
design.mdfor how to build it - Update
tasks.mdas you complete work - Mark tasks as completed with [x]
- Find the feature folder:
docs/features/<feature>/ - Verify implementation matches
requirements.md - Check design patterns match
design.md - Confirm
tasks.mdis up to date
Current Phase: Phase 3.6 Complete (Custom Lessons) β
Total Tests: 146 passing
- 13 tests: typing-session
- 7 tests: home-row-lessons
- 12 tests: bigram-training
- 12 tests: code-symbols
- 9 tests: analytics
- 9 tests: adaptive algorithms
- 6 tests: adaptive generator
- 7 tests: session-storage
- 2 tests: keyboard-layout
- 3 tests: content generation
- 1 test: data structures
- 11 tests: custom lessons
- 54 tests: other features (trigrams, common words, finger training, etc.)
Completed Features:
- Phase 1: Home row Level 1 β
- Phase 2: Home row Levels 2-6 β
- Phase 2: Bigram training (French, English, Code) β
- Phase 2: Trigram training (French, English) β
- Phase 2: Common words (French, English) β
- Phase 2: Code symbols (TypeScript, Rust, Python) β
- Phase 2+: Adaptive Mode β
- Phase 3: Visual keyboard display β
- Phase 3.1: Layout improvements β
- Phase 3.2: Finger training β
- Phase 3.3: Two-level menu system β
- Phase 3.4: Menu grouping β
- Phase 3.5: Statistics dashboard β
- Phase 3.6: Custom lessons β
Total Lessons: 60 (27 standard + 24 finger training + 8 row training + 1 adaptive)
Next Phase: Enhanced analytics (trend graphs, data export) and gamification (Phase 3+)
- User documentation:
README.mdat project root - AI assistant context:
CLAUDE.mdat project root - Global workflow:
~/.claude/CLAUDE.md(defines Requirements β Design β Tasks pattern)
- Product questions: See
docs/steering/product.md - Technical questions: See
docs/steering/tech.md - Architecture questions: See
docs/steering/structure.md - Feature-specific: Check the feature's folder in
docs/features/