|
| 1 | +--- |
| 2 | +status: planned |
| 3 | +created: '2025-11-18' |
| 4 | +tags: [] |
| 5 | +priority: medium |
| 6 | +created_at: '2025-11-18T13:42:51.756Z' |
| 7 | +related: |
| 8 | + - 106-ui-package-documentation |
| 9 | + - 087-cli-ui-command |
| 10 | + - 035-live-specs-showcase |
| 11 | +updated_at: '2025-11-18T14:36:33.079Z' |
| 12 | +--- |
| 13 | + |
| 14 | +# Documentation Site Optimization and Enhancements |
| 15 | + |
| 16 | +> **Status**: 🗓️ Planned · **Priority**: Medium · **Created**: 2025-11-18 |
| 17 | +
|
| 18 | +**Project**: lean-spec |
| 19 | +**Team**: Core Development |
| 20 | + |
| 21 | +## Overview |
| 22 | + |
| 23 | +This spec addresses comprehensive improvements to the documentation site based on structural issues, content accuracy, translation gaps, and user experience concerns identified during review. |
| 24 | + |
| 25 | +### Problems |
| 26 | + |
| 27 | +**Content Structure Issues:** |
| 28 | +- Navigation hierarchy is confusing for first-time users |
| 29 | +- Content is scattered across multiple levels when it should be consolidated |
| 30 | +- Tutorial content includes video walkthrough placeholders that don't align with AI-first approach |
| 31 | + |
| 32 | +**Content Accuracy Issues:** |
| 33 | +- Outdated references to line-count metrics instead of token-based |
| 34 | +- Usage docs don't match current implementation |
| 35 | +- Reference docs may be out of sync with codebase |
| 36 | + |
| 37 | +**Translation & Localization Issues:** |
| 38 | +- Examples section not translated to Chinese |
| 39 | +- Missing translations in other sections |
| 40 | +- Poor quality Chinese translations in landing page |
| 41 | +- "Web App" needs better Chinese translation |
| 42 | + |
| 43 | +**Missing Content:** |
| 44 | +- `lean-spec ui` / `@leanspec/ui` package not documented (needs separate spec) |
| 45 | + |
| 46 | +### Goals |
| 47 | + |
| 48 | +1. **Improve Information Architecture**: Restructure docs to guide users from beginner → intermediate → advanced |
| 49 | +2. **Update Content Accuracy**: Align all docs with current implementation (token-based, not line-based) |
| 50 | +3. **Complete Translations**: Ensure feature parity between English and Chinese docs |
| 51 | +4. **Enhance User Experience**: Simplify landing experience, remove placeholders, improve tutorial flow |
| 52 | + |
| 53 | +## Design |
| 54 | + |
| 55 | +### 1. Information Architecture Restructuring |
| 56 | + |
| 57 | +**Introduction Section:** |
| 58 | +- Simplify "Overview" - make it concise and intuitive for first-timers |
| 59 | +- Consider merging with "Core Concepts -> What Is LeanSpec" for consistency |
| 60 | +- Move "Migrating to LeanSpec" to top-level navigation (beside Roadmap) |
| 61 | + |
| 62 | +**Core Concepts Reorganization:** |
| 63 | +- Rename "Understanding Specs" → "Understanding LeanSpec" (broader scope) |
| 64 | +- Remove "Terminology Overview" as separate page |
| 65 | +- Restructure terminology directly after "Understanding LeanSpec": |
| 66 | + - **Keep as-is**: "Spec", "SDD Workflow" |
| 67 | + - **Merge**: "Sub-Specs" content into "Spec" concept |
| 68 | + - **Consolidate**: "Status", "Dependencies", "Tags & Priority" into "Built-in Fields" or "Metadata" concept |
| 69 | +- Expand terminology content with in-depth explanations: |
| 70 | + - Why LeanSpec is designed this way |
| 71 | + - How concepts work behind the scenes |
| 72 | + - Help users transition from beginner → intermediate/advanced |
| 73 | + |
| 74 | +**Usage Section Restructuring:** |
| 75 | +- Remove "AI-Assisted Workflows -> Writing Specs AI Can Execute" |
| 76 | +- Lift "AI-Assisted Workflows" docs up one level (after "Advanced Features") |
| 77 | + |
| 78 | +**Examples Section:** |
| 79 | +- Fix: Default doc should not be named "index" (use proper descriptive name) |
| 80 | + |
| 81 | +### 2. Content Updates |
| 82 | + |
| 83 | +**Switch from Line-Count to Token-Based:** |
| 84 | +- Audit all docs for line-count references (especially "Advanced Topics") |
| 85 | +- Replace with token-based metrics |
| 86 | +- Ensure consistency with current implementation |
| 87 | + |
| 88 | +**Update Outdated Content:** |
| 89 | +- Review all "Usage" docs against current codebase |
| 90 | +- Update "Reference" tab to match current CLI implementation |
| 91 | +- Verify code examples and command outputs are current |
| 92 | + |
| 93 | +**Tutorial Content:** |
| 94 | +- Remove video walkthrough placeholders (timestamps like 00:30, 02:10) |
| 95 | +- Rewrite tutorials emphasizing AI-assisted workflow: |
| 96 | + - Human developer expresses intent |
| 97 | + - AI helps with spec creation, drafting, and implementation |
| 98 | + - Focus on conversational, intent-driven development |
| 99 | + |
| 100 | +### 3. Translation & Localization |
| 101 | + |
| 102 | +**Complete Missing Translations:** |
| 103 | +- Translate all "Examples" docs to Chinese |
| 104 | +- Audit for other missing translations (systematic review) |
| 105 | +- Ensure feature parity between English and Chinese versions |
| 106 | + |
| 107 | +**Improve Translation Quality:** |
| 108 | +- Landing page: Replace "轻量级规范方法论,助力 AI 驱动开发" with better tagline |
| 109 | + - Consider: Focus on clarity and natural Chinese phrasing |
| 110 | + - Avoid literal translation |
| 111 | +- "Web App" → Find more natural Chinese equivalent |
| 112 | + - Consider: "网页应用" or context-specific term |
| 113 | + |
| 114 | +### 4. Deferred Items |
| 115 | + |
| 116 | +**Out of Scope for This Spec:** |
| 117 | +- `lean-spec ui` / `@leanspec/ui` documentation (track in separate spec) |
| 118 | + |
| 119 | +### Technical Approach |
| 120 | + |
| 121 | +1. **Content Audit Phase:** |
| 122 | + - Script to find all line-count references |
| 123 | + - Manual review of outdated content in Usage/Reference sections |
| 124 | + - Translation gap analysis |
| 125 | + |
| 126 | +2. **Restructuring Phase:** |
| 127 | + - Update sidebars.ts for navigation changes |
| 128 | + - Move/rename files as needed |
| 129 | + - Update cross-references and links |
| 130 | + |
| 131 | +3. **Content Improvement Phase:** |
| 132 | + - Rewrite simplified content with depth |
| 133 | + - Update examples and commands |
| 134 | + - Improve tutorials |
| 135 | + |
| 136 | +4. **Translation Phase:** |
| 137 | + - Translate missing content |
| 138 | + - Improve existing translations |
| 139 | + - Verify completeness |
| 140 | + |
| 141 | +## Plan |
| 142 | + |
| 143 | +### Phase 1: Content Audit |
| 144 | +- [ ] Grep search for "line" references that should be "token" |
| 145 | +- [ ] Review "Advanced Topics" docs for line-count metrics |
| 146 | +- [ ] List all "Usage" docs and check against current implementation |
| 147 | +- [ ] Review "Reference" docs against CLI codebase |
| 148 | +- [ ] Identify all translation gaps (English vs Chinese) |
| 149 | +- [ ] List all "Examples" that need Chinese translation |
| 150 | + |
| 151 | +### Phase 2: Information Architecture |
| 152 | +- [ ] Update sidebars.ts for navigation restructure |
| 153 | +- [ ] Simplify "Introduction -> Overview" |
| 154 | +- [ ] Move "Migrating to LeanSpec" to top level |
| 155 | +- [ ] Rename "Understanding Specs" → "Understanding LeanSpec" |
| 156 | +- [ ] Remove "Terminology Overview" page |
| 157 | +- [ ] Restructure terminology concepts (merge Sub-Specs, consolidate metadata) |
| 158 | +- [ ] Move "AI-Assisted Workflows" up one level |
| 159 | +- [ ] Remove "Writing Specs AI Can Execute" page |
| 160 | +- [ ] Fix "Examples" default doc name |
| 161 | + |
| 162 | +### Phase 3: Content Updates |
| 163 | +- [ ] Replace all line-count references with token-based |
| 164 | +- [ ] Update outdated "Usage" docs |
| 165 | +- [ ] Update "Reference" docs to match current CLI |
| 166 | +- [ ] Expand terminology with in-depth explanations |
| 167 | +- [ ] Rewrite tutorials (remove video placeholders, focus on AI-assisted) |
| 168 | +- [ ] Update code examples and command outputs |
| 169 | + |
| 170 | +### Phase 4: Translation & Localization |
| 171 | +- [ ] Translate all "Examples" to Chinese |
| 172 | +- [ ] Fill other translation gaps identified in audit |
| 173 | +- [ ] Improve landing page Chinese tagline |
| 174 | +- [ ] Improve "Web App" Chinese translation |
| 175 | +- [ ] Verify feature parity between languages |
| 176 | + |
| 177 | +### Phase 5: Validation |
| 178 | +- [ ] Build docs-site and verify no broken links |
| 179 | +- [ ] Review navigation flow (beginner → advanced) |
| 180 | +- [ ] Spot-check translations for quality |
| 181 | +- [ ] Verify all commands and examples work |
| 182 | + |
| 183 | +## Test |
| 184 | + |
| 185 | +### Navigation & Structure |
| 186 | +- [ ] Introduction section is concise and intuitive for new users |
| 187 | +- [ ] "Migrating to LeanSpec" appears at top level beside Roadmap |
| 188 | +- [ ] "Understanding LeanSpec" (renamed) appears in Core Concepts |
| 189 | +- [ ] Terminology concepts are properly organized and consolidated |
| 190 | +- [ ] "AI-Assisted Workflows" is at correct hierarchy level |
| 191 | +- [ ] Examples section has proper default doc name (not "index") |
| 192 | + |
| 193 | +### Content Accuracy |
| 194 | +- [ ] No line-count references remain (all token-based) |
| 195 | +- [ ] All "Usage" docs match current implementation |
| 196 | +- [ ] All "Reference" docs match current CLI |
| 197 | +- [ ] All code examples execute correctly |
| 198 | +- [ ] Command outputs are current |
| 199 | + |
| 200 | +### Tutorial Quality |
| 201 | +- [ ] No video walkthrough placeholders (timestamps removed) |
| 202 | +- [ ] Tutorials emphasize AI-assisted workflow |
| 203 | +- [ ] Clear examples of intent → AI spec creation → implementation |
| 204 | + |
| 205 | +### Translation Completeness |
| 206 | +- [ ] All English docs have Chinese equivalents |
| 207 | +- [ ] Examples section fully translated |
| 208 | +- [ ] Landing page Chinese tagline reads naturally |
| 209 | +- [ ] "Web App" has appropriate Chinese translation |
| 210 | + |
| 211 | +### Build & Technical |
| 212 | +- [ ] `npm run build` succeeds in docs-site |
| 213 | +- [ ] No broken links or 404s |
| 214 | +- [ ] Cross-references work between restructured pages |
| 215 | +- [ ] Navigation hierarchy makes sense (test with fresh eyes) |
| 216 | + |
| 217 | +### User Experience |
| 218 | +- [ ] New users can understand LeanSpec quickly from Introduction |
| 219 | +- [ ] Core Concepts provide depth for learning |
| 220 | +- [ ] Terminology concepts have "why" and "how" explanations |
| 221 | +- [ ] Chinese content is natural and high-quality |
| 222 | + |
| 223 | +## Notes |
| 224 | + |
| 225 | +### Original Feedback Summary |
| 226 | + |
| 227 | +All 18 feedback points from initial review: |
| 228 | + |
| 229 | +1. ✓ Missing `lean-spec ui` docs → Deferred to separate spec |
| 230 | +2. ✓ "Introduction -> Overview" too long → Simplify |
| 231 | +3. ✓ Move "Migrating to LeanSpec" → Top level |
| 232 | +4. ✓ Remove video walkthrough placeholders from tutorials |
| 233 | +5. ✓ Rewrite tutorials for AI-assisted workflow |
| 234 | +6. ✓ Restructure "Understanding Specs" and terminology |
| 235 | +7. ✓ Rename to "Understanding LeanSpec" |
| 236 | +8. ✓ Reorganize terminology concepts |
| 237 | +9. ✓ Expand terminology with depth and rationale |
| 238 | +10. ✓ Remove "Writing Specs AI Can Execute" |
| 239 | +11. ✓ Lift "AI-Assisted Workflows" up one level |
| 240 | +12. ✓ Update outdated "Usage" docs |
| 241 | +13. ✓ Fix line-count → token-based references |
| 242 | +14. ✓ Complete Chinese translations for Examples |
| 243 | +15. ✓ Fix "index" naming in Examples |
| 244 | +16. ✓ Update Reference docs against codebase |
| 245 | +17. ✓ Improve "Web App" Chinese translation |
| 246 | +18. ✓ Improve landing page Chinese tagline |
| 247 | + |
| 248 | +### Design Decisions |
| 249 | + |
| 250 | +**Why consolidate metadata concepts?** |
| 251 | +Status, Dependencies, Tags, and Priority are all system-managed frontmatter fields. Grouping them helps users understand LeanSpec's metadata model holistically rather than as fragmented concepts. |
| 252 | + |
| 253 | +**Why expand terminology content?** |
| 254 | +Original feedback noted over-simplification. Users need to understand the "why" behind LeanSpec's design to appreciate its value and use it effectively. This bridges the gap from beginner to intermediate/advanced usage. |
| 255 | + |
| 256 | +**Why lift AI-Assisted Workflows?** |
| 257 | +These workflows are central to LeanSpec's value proposition and should be prominent in navigation, not buried under Usage section. |
| 258 | + |
| 259 | +**Why focus tutorials on AI-assisted approach?** |
| 260 | +LeanSpec is designed for AI-first development. Video walkthrough placeholders suggest manual, traditional workflows. Rewriting with AI-assisted focus aligns tutorials with core methodology. |
| 261 | + |
| 262 | +### Open Questions |
| 263 | + |
| 264 | +- **Chinese tagline alternatives**: Need to brainstorm better options than current "轻量级规范方法论,助力 AI 驱动开发" |
| 265 | + - Consider focus on outcomes vs methodology |
| 266 | + - Test with native speakers |
| 267 | + |
| 268 | +- **Examples naming convention**: What should default doc be called instead of "index"? |
| 269 | + - "Overview"? |
| 270 | + - "Getting Started"? |
| 271 | + - Or directly use first real example? |
| 272 | + |
| 273 | +### Related Work |
| 274 | + |
| 275 | +- Separate spec needed for `@leanspec/ui` documentation |
| 276 | +- May want to track translation process improvements if this reveals systematic issues |
0 commit comments