@iamnishankhan/opencode-kit-grok 1.0.0

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 (198) hide show
  1. package/bin/cli.js +46 -0
  2. package/kit/.opencode/AGENTS.md +392 -0
  3. package/kit/.opencode/README.md +71 -0
  4. package/kit/.opencode/USAGE.md +405 -0
  5. package/kit/.opencode/agents/backend-specialist.md +278 -0
  6. package/kit/.opencode/agents/code-archaeologist.md +114 -0
  7. package/kit/.opencode/agents/database-architect.md +233 -0
  8. package/kit/.opencode/agents/debugger.md +234 -0
  9. package/kit/.opencode/agents/devops-engineer.md +252 -0
  10. package/kit/.opencode/agents/documentation-writer.md +111 -0
  11. package/kit/.opencode/agents/explorer-agent.md +83 -0
  12. package/kit/.opencode/agents/frontend-specialist.md +606 -0
  13. package/kit/.opencode/agents/game-developer.md +169 -0
  14. package/kit/.opencode/agents/mobile-developer.md +385 -0
  15. package/kit/.opencode/agents/orchestrator.md +213 -0
  16. package/kit/.opencode/agents/penetration-tester.md +197 -0
  17. package/kit/.opencode/agents/performance-optimizer.md +194 -0
  18. package/kit/.opencode/agents/product-manager.md +120 -0
  19. package/kit/.opencode/agents/product-owner.md +103 -0
  20. package/kit/.opencode/agents/project-planner.md +418 -0
  21. package/kit/.opencode/agents/qa-automation-engineer.md +113 -0
  22. package/kit/.opencode/agents/security-auditor.md +179 -0
  23. package/kit/.opencode/agents/seo-specialist.md +119 -0
  24. package/kit/.opencode/agents/test-engineer.md +169 -0
  25. package/kit/.opencode/commands/brainstorm.md +113 -0
  26. package/kit/.opencode/commands/coordinate.md +72 -0
  27. package/kit/.opencode/commands/create.md +63 -0
  28. package/kit/.opencode/commands/debug.md +102 -0
  29. package/kit/.opencode/commands/deploy.md +175 -0
  30. package/kit/.opencode/commands/enhance.md +62 -0
  31. package/kit/.opencode/commands/orchestrate.md +241 -0
  32. package/kit/.opencode/commands/plan.md +89 -0
  33. package/kit/.opencode/commands/preview.md +80 -0
  34. package/kit/.opencode/commands/remember.md +67 -0
  35. package/kit/.opencode/commands/status.md +86 -0
  36. package/kit/.opencode/commands/test.md +143 -0
  37. package/kit/.opencode/commands/verify.md +71 -0
  38. package/kit/.opencode/memory/MEMORY.md +6 -0
  39. package/kit/.opencode/memory/feedback-history.md +9 -0
  40. package/kit/.opencode/memory/project-conventions.md +16 -0
  41. package/kit/.opencode/memory/tech-decisions.md +10 -0
  42. package/kit/.opencode/memory/user-preferences.md +9 -0
  43. package/kit/.opencode/opencode.json +15 -0
  44. package/kit/.opencode/scripts/README.md +95 -0
  45. package/kit/.opencode/scripts/auto_preview.py +149 -0
  46. package/kit/.opencode/scripts/checklist.py +75 -0
  47. package/kit/.opencode/scripts/component_registry.py +238 -0
  48. package/kit/.opencode/scripts/dependency_graph.py +73 -0
  49. package/kit/.opencode/scripts/generate_manifest.py +44 -0
  50. package/kit/.opencode/scripts/session_manager.py +120 -0
  51. package/kit/.opencode/scripts/tests/test_toolkit.py +238 -0
  52. package/kit/.opencode/scripts/validate_kit.py +397 -0
  53. package/kit/.opencode/scripts/validation_runner.py +216 -0
  54. package/kit/.opencode/scripts/verify_all.py +85 -0
  55. package/kit/.opencode/skills/api-patterns/SKILL.md +83 -0
  56. package/kit/.opencode/skills/api-patterns/api-style.md +42 -0
  57. package/kit/.opencode/skills/api-patterns/auth.md +24 -0
  58. package/kit/.opencode/skills/api-patterns/documentation.md +26 -0
  59. package/kit/.opencode/skills/api-patterns/graphql.md +41 -0
  60. package/kit/.opencode/skills/api-patterns/rate-limiting.md +31 -0
  61. package/kit/.opencode/skills/api-patterns/response.md +37 -0
  62. package/kit/.opencode/skills/api-patterns/rest.md +40 -0
  63. package/kit/.opencode/skills/api-patterns/scripts/api_validator.py +211 -0
  64. package/kit/.opencode/skills/api-patterns/security-testing.md +122 -0
  65. package/kit/.opencode/skills/api-patterns/trpc.md +41 -0
  66. package/kit/.opencode/skills/api-patterns/versioning.md +22 -0
  67. package/kit/.opencode/skills/app-builder/SKILL.md +78 -0
  68. package/kit/.opencode/skills/app-builder/agent-coordination.md +71 -0
  69. package/kit/.opencode/skills/app-builder/feature-building.md +53 -0
  70. package/kit/.opencode/skills/app-builder/project-detection.md +45 -0
  71. package/kit/.opencode/skills/app-builder/scaffolding.md +110 -0
  72. package/kit/.opencode/skills/app-builder/tech-stack.md +41 -0
  73. package/kit/.opencode/skills/app-builder/templates/SKILL.md +39 -0
  74. package/kit/.opencode/skills/app-builder/templates/astro-static/TEMPLATE.md +78 -0
  75. package/kit/.opencode/skills/app-builder/templates/chrome-extension/TEMPLATE.md +96 -0
  76. package/kit/.opencode/skills/app-builder/templates/cli-tool/TEMPLATE.md +88 -0
  77. package/kit/.opencode/skills/app-builder/templates/electron-desktop/TEMPLATE.md +97 -0
  78. package/kit/.opencode/skills/app-builder/templates/express-api/TEMPLATE.md +89 -0
  79. package/kit/.opencode/skills/app-builder/templates/flutter-app/TEMPLATE.md +93 -0
  80. package/kit/.opencode/skills/app-builder/templates/monorepo-turborepo/TEMPLATE.md +97 -0
  81. package/kit/.opencode/skills/app-builder/templates/nextjs-fullstack/TEMPLATE.md +126 -0
  82. package/kit/.opencode/skills/app-builder/templates/nextjs-saas/TEMPLATE.md +125 -0
  83. package/kit/.opencode/skills/app-builder/templates/nextjs-static/TEMPLATE.md +174 -0
  84. package/kit/.opencode/skills/app-builder/templates/nuxt-app/TEMPLATE.md +127 -0
  85. package/kit/.opencode/skills/app-builder/templates/python-fastapi/TEMPLATE.md +94 -0
  86. package/kit/.opencode/skills/app-builder/templates/react-native-app/TEMPLATE.md +121 -0
  87. package/kit/.opencode/skills/architecture/SKILL.md +57 -0
  88. package/kit/.opencode/skills/architecture/context-discovery.md +43 -0
  89. package/kit/.opencode/skills/architecture/examples.md +94 -0
  90. package/kit/.opencode/skills/architecture/pattern-selection.md +68 -0
  91. package/kit/.opencode/skills/architecture/patterns-reference.md +50 -0
  92. package/kit/.opencode/skills/architecture/trade-off-analysis.md +77 -0
  93. package/kit/.opencode/skills/bash-linux/SKILL.md +201 -0
  94. package/kit/.opencode/skills/batch-operations/SKILL.md +105 -0
  95. package/kit/.opencode/skills/behavioral-modes/SKILL.md +253 -0
  96. package/kit/.opencode/skills/brainstorming/SKILL.md +178 -0
  97. package/kit/.opencode/skills/brainstorming/dynamic-questioning.md +350 -0
  98. package/kit/.opencode/skills/clean-code/SKILL.md +201 -0
  99. package/kit/.opencode/skills/code-review-checklist/SKILL.md +111 -0
  100. package/kit/.opencode/skills/code-review-graph/SKILL.md +305 -0
  101. package/kit/.opencode/skills/context-compression/SKILL.md +145 -0
  102. package/kit/.opencode/skills/coordinator-mode/SKILL.md +208 -0
  103. package/kit/.opencode/skills/database-design/SKILL.md +54 -0
  104. package/kit/.opencode/skills/database-design/database-selection.md +43 -0
  105. package/kit/.opencode/skills/database-design/indexing.md +39 -0
  106. package/kit/.opencode/skills/database-design/migrations.md +48 -0
  107. package/kit/.opencode/skills/database-design/optimization.md +36 -0
  108. package/kit/.opencode/skills/database-design/orm-selection.md +30 -0
  109. package/kit/.opencode/skills/database-design/schema-design.md +56 -0
  110. package/kit/.opencode/skills/database-design/scripts/schema_validator.py +172 -0
  111. package/kit/.opencode/skills/deployment-procedures/SKILL.md +243 -0
  112. package/kit/.opencode/skills/design-spec/SKILL.md +185 -0
  113. package/kit/.opencode/skills/design-spec/collection.md +106 -0
  114. package/kit/.opencode/skills/documentation-templates/SKILL.md +196 -0
  115. package/kit/.opencode/skills/frontend-architecture/SKILL.md +245 -0
  116. package/kit/.opencode/skills/frontend-design/SKILL.md +1222 -0
  117. package/kit/.opencode/skills/frontend-design/redesign.md +178 -0
  118. package/kit/.opencode/skills/frontend-design/scripts/accessibility_checker.py +145 -0
  119. package/kit/.opencode/skills/frontend-design/scripts/ux_audit.py +722 -0
  120. package/kit/.opencode/skills/frontend-design/style-brutalist.md +92 -0
  121. package/kit/.opencode/skills/frontend-design/style-minimalist.md +85 -0
  122. package/kit/.opencode/skills/game-development/2d-games/SKILL.md +118 -0
  123. package/kit/.opencode/skills/game-development/3d-games/SKILL.md +134 -0
  124. package/kit/.opencode/skills/game-development/SKILL.md +169 -0
  125. package/kit/.opencode/skills/game-development/game-art/SKILL.md +184 -0
  126. package/kit/.opencode/skills/game-development/game-audio/SKILL.md +189 -0
  127. package/kit/.opencode/skills/game-development/game-design/SKILL.md +128 -0
  128. package/kit/.opencode/skills/game-development/mobile-games/SKILL.md +107 -0
  129. package/kit/.opencode/skills/game-development/multiplayer/SKILL.md +131 -0
  130. package/kit/.opencode/skills/game-development/pc-games/SKILL.md +143 -0
  131. package/kit/.opencode/skills/game-development/vr-ar/SKILL.md +122 -0
  132. package/kit/.opencode/skills/game-development/web-games/SKILL.md +149 -0
  133. package/kit/.opencode/skills/geo-fundamentals/SKILL.md +158 -0
  134. package/kit/.opencode/skills/geo-fundamentals/scripts/geo_checker.py +273 -0
  135. package/kit/.opencode/skills/i18n-localization/SKILL.md +156 -0
  136. package/kit/.opencode/skills/i18n-localization/scripts/i18n_checker.py +223 -0
  137. package/kit/.opencode/skills/intelligent-routing/SKILL.md +337 -0
  138. package/kit/.opencode/skills/lint-and-validate/SKILL.md +47 -0
  139. package/kit/.opencode/skills/lint-and-validate/scripts/lint_runner.py +184 -0
  140. package/kit/.opencode/skills/lint-and-validate/scripts/type_coverage.py +245 -0
  141. package/kit/.opencode/skills/mcp-builder/SKILL.md +205 -0
  142. package/kit/.opencode/skills/memory-system/SKILL.md +181 -0
  143. package/kit/.opencode/skills/mobile-design/SKILL.md +396 -0
  144. package/kit/.opencode/skills/mobile-design/decision-trees.md +516 -0
  145. package/kit/.opencode/skills/mobile-design/mobile-backend.md +491 -0
  146. package/kit/.opencode/skills/mobile-design/mobile-color-system.md +420 -0
  147. package/kit/.opencode/skills/mobile-design/mobile-debugging.md +122 -0
  148. package/kit/.opencode/skills/mobile-design/mobile-design-thinking.md +357 -0
  149. package/kit/.opencode/skills/mobile-design/mobile-navigation.md +458 -0
  150. package/kit/.opencode/skills/mobile-design/mobile-performance.md +767 -0
  151. package/kit/.opencode/skills/mobile-design/mobile-testing.md +356 -0
  152. package/kit/.opencode/skills/mobile-design/mobile-typography.md +433 -0
  153. package/kit/.opencode/skills/mobile-design/platform-android.md +666 -0
  154. package/kit/.opencode/skills/mobile-design/platform-ios.md +561 -0
  155. package/kit/.opencode/skills/mobile-design/scripts/mobile_audit.py +670 -0
  156. package/kit/.opencode/skills/mobile-design/touch-psychology.md +537 -0
  157. package/kit/.opencode/skills/nextjs-react-expert/1-async-eliminating-waterfalls.md +351 -0
  158. package/kit/.opencode/skills/nextjs-react-expert/2-bundle-bundle-size-optimization.md +240 -0
  159. package/kit/.opencode/skills/nextjs-react-expert/3-server-server-side-performance.md +490 -0
  160. package/kit/.opencode/skills/nextjs-react-expert/4-client-client-side-data-fetching.md +264 -0
  161. package/kit/.opencode/skills/nextjs-react-expert/5-rerender-re-render-optimization.md +581 -0
  162. package/kit/.opencode/skills/nextjs-react-expert/6-rendering-rendering-performance.md +432 -0
  163. package/kit/.opencode/skills/nextjs-react-expert/7-js-javascript-performance.md +684 -0
  164. package/kit/.opencode/skills/nextjs-react-expert/8-advanced-advanced-patterns.md +150 -0
  165. package/kit/.opencode/skills/nextjs-react-expert/9-cache-components.md +103 -0
  166. package/kit/.opencode/skills/nextjs-react-expert/SKILL.md +293 -0
  167. package/kit/.opencode/skills/nextjs-react-expert/scripts/convert_rules.py +222 -0
  168. package/kit/.opencode/skills/nextjs-react-expert/scripts/react_performance_checker.py +281 -0
  169. package/kit/.opencode/skills/nodejs-best-practices/SKILL.md +336 -0
  170. package/kit/.opencode/skills/parallel-agents/SKILL.md +192 -0
  171. package/kit/.opencode/skills/performance-profiling/SKILL.md +145 -0
  172. package/kit/.opencode/skills/performance-profiling/scripts/bundle_analyzer.py +120 -0
  173. package/kit/.opencode/skills/performance-profiling/scripts/lighthouse_audit.py +108 -0
  174. package/kit/.opencode/skills/plan-writing/SKILL.md +153 -0
  175. package/kit/.opencode/skills/powershell-windows/SKILL.md +169 -0
  176. package/kit/.opencode/skills/python-patterns/SKILL.md +443 -0
  177. package/kit/.opencode/skills/red-team-tactics/SKILL.md +201 -0
  178. package/kit/.opencode/skills/rust-pro/SKILL.md +177 -0
  179. package/kit/.opencode/skills/seo-fundamentals/SKILL.md +131 -0
  180. package/kit/.opencode/skills/seo-fundamentals/scripts/seo_checker.py +219 -0
  181. package/kit/.opencode/skills/server-management/SKILL.md +163 -0
  182. package/kit/.opencode/skills/simplify-code/SKILL.md +131 -0
  183. package/kit/.opencode/skills/skillify/SKILL.md +115 -0
  184. package/kit/.opencode/skills/systematic-debugging/SKILL.md +111 -0
  185. package/kit/.opencode/skills/tailwind-patterns/SKILL.md +271 -0
  186. package/kit/.opencode/skills/tdd-workflow/SKILL.md +151 -0
  187. package/kit/.opencode/skills/testing-patterns/SKILL.md +180 -0
  188. package/kit/.opencode/skills/testing-patterns/scripts/test_runner.py +219 -0
  189. package/kit/.opencode/skills/verify-changes/SKILL.md +127 -0
  190. package/kit/.opencode/skills/vulnerability-scanner/SKILL.md +278 -0
  191. package/kit/.opencode/skills/vulnerability-scanner/checklists.md +124 -0
  192. package/kit/.opencode/skills/vulnerability-scanner/scripts/dependency_analyzer.py +144 -0
  193. package/kit/.opencode/skills/vulnerability-scanner/scripts/security_scan.py +410 -0
  194. package/kit/.opencode/skills/web-design-guidelines/SKILL.md +56 -0
  195. package/kit/.opencode/skills/webapp-testing/SKILL.md +189 -0
  196. package/kit/.opencode/skills/webapp-testing/scripts/playwright_runner.py +123 -0
  197. package/lib/init.js +61 -0
  198. package/package.json +21 -0
@@ -0,0 +1,131 @@
1
+ ---
2
+ name: multiplayer
3
+ description: Multiplayer game development principles. Architecture, networking, synchronization.
4
+ compatibility: opencode
5
+ ---
6
+ # Multiplayer Game Development
7
+
8
+ > Networking architecture and synchronization principles.
9
+
10
+ ---
11
+
12
+ ## 1. Architecture Selection
13
+
14
+ ### Decision Tree
15
+
16
+ ```
17
+ What type of multiplayer?
18
+
19
+ ├── Competitive / Real-time
20
+ │ └── Dedicated Server (authoritative)
21
+
22
+ ├── Cooperative / Casual
23
+ │ └── Host-based (one player is server)
24
+
25
+ ├── Turn-based
26
+ │ └── Client-server (simple)
27
+
28
+ └── Massive (MMO)
29
+ └── Distributed servers
30
+ ```
31
+
32
+ ### Comparison
33
+
34
+ | Architecture | Latency | Cost | Security |
35
+ |--------------|---------|------|----------|
36
+ | **Dedicated** | Low | High | Strong |
37
+ | **P2P** | Variable | Low | Weak |
38
+ | **Host-based** | Medium | Low | Medium |
39
+
40
+ ---
41
+
42
+ ## 2. Synchronization Principles
43
+
44
+ ### State vs Input
45
+
46
+ | Approach | Sync What | Best For |
47
+ |----------|-----------|----------|
48
+ | **State Sync** | Game state | Simple, few objects |
49
+ | **Input Sync** | Player inputs | Action games |
50
+ | **Hybrid** | Both | Most games |
51
+
52
+ ### Lag Compensation
53
+
54
+ | Technique | Purpose |
55
+ |-----------|---------|
56
+ | **Prediction** | Client predicts server |
57
+ | **Interpolation** | Smooth remote players |
58
+ | **Reconciliation** | Fix mispredictions |
59
+ | **Lag compensation** | Rewind for hit detection |
60
+
61
+ ---
62
+
63
+ ## 3. Network Optimization
64
+
65
+ ### Bandwidth Reduction
66
+
67
+ | Technique | Savings |
68
+ |-----------|---------|
69
+ | **Delta compression** | Send only changes |
70
+ | **Quantization** | Reduce precision |
71
+ | **Priority** | Important data first |
72
+ | **Area of interest** | Only nearby entities |
73
+
74
+ ### Update Rates
75
+
76
+ | Type | Rate |
77
+ |------|------|
78
+ | Position | 20-60 Hz |
79
+ | Health | On change |
80
+ | Inventory | On change |
81
+ | Chat | On send |
82
+
83
+ ---
84
+
85
+ ## 4. Security Principles
86
+
87
+ ### Server Authority
88
+
89
+ ```
90
+ Client: "I hit the enemy"
91
+ Server: Validate → did projectile actually hit?
92
+ → was player in valid state?
93
+ → was timing possible?
94
+ ```
95
+
96
+ ### Anti-Cheat
97
+
98
+ | Cheat | Prevention |
99
+ |-------|------------|
100
+ | Speed hack | Server validates movement |
101
+ | Aimbot | Server validates sight line |
102
+ | Item dupe | Server owns inventory |
103
+ | Wall hack | Don't send hidden data |
104
+
105
+ ---
106
+
107
+ ## 5. Matchmaking
108
+
109
+ ### Considerations
110
+
111
+ | Factor | Impact |
112
+ |--------|--------|
113
+ | **Skill** | Fair matches |
114
+ | **Latency** | Playable connection |
115
+ | **Wait time** | Player patience |
116
+ | **Party size** | Group play |
117
+
118
+ ---
119
+
120
+ ## 6. Anti-Patterns
121
+
122
+ | ❌ Don't | ✅ Do |
123
+ |----------|-------|
124
+ | Trust the client | Server is authority |
125
+ | Send everything | Send only necessary |
126
+ | Ignore latency | Design for 100-200ms |
127
+ | Sync exact positions | Interpolate/predict |
128
+
129
+ ---
130
+
131
+ > **Remember:** Never trust the client. The server is the source of truth.
@@ -0,0 +1,143 @@
1
+ ---
2
+ name: pc-games
3
+ description: PC and console game development principles. Engine selection, platform features, optimization strategies.
4
+ compatibility: opencode
5
+ ---
6
+ # PC/Console Game Development
7
+
8
+ > Engine selection and platform-specific principles.
9
+
10
+ ---
11
+
12
+ ## 1. Engine Selection
13
+
14
+ ### Decision Tree
15
+
16
+ ```
17
+ What are you building?
18
+
19
+ ├── 2D Game
20
+ │ ├── Open source important? → Godot
21
+ │ └── Large team/assets? → Unity
22
+
23
+ ├── 3D Game
24
+ │ ├── AAA visual quality? → Unreal
25
+ │ ├── Cross-platform priority? → Unity
26
+ │ └── Indie/open source? → Godot 4
27
+
28
+ └── Specific Needs
29
+ ├── DOTS performance? → Unity
30
+ ├── Nanite/Lumen? → Unreal
31
+ └── Lightweight? → Godot
32
+ ```
33
+
34
+ ### Comparison
35
+
36
+ | Factor | Unity 6 | Godot 4 | Unreal 5 |
37
+ |--------|---------|---------|----------|
38
+ | 2D | Good | Excellent | Limited |
39
+ | 3D | Good | Good | Excellent |
40
+ | Learning | Medium | Easy | Hard |
41
+ | Cost | Revenue share | Free | 5% after $1M |
42
+ | Team | Any | Solo-Medium | Medium-Large |
43
+
44
+ ---
45
+
46
+ ## 2. Platform Features
47
+
48
+ ### Steam Integration
49
+
50
+ | Feature | Purpose |
51
+ |---------|---------|
52
+ | Achievements | Player goals |
53
+ | Cloud Saves | Cross-device progress |
54
+ | Leaderboards | Competition |
55
+ | Workshop | User mods |
56
+ | Rich Presence | Show in-game status |
57
+
58
+ ### Console Requirements
59
+
60
+ | Platform | Certification |
61
+ |----------|--------------|
62
+ | PlayStation | TRC compliance |
63
+ | Xbox | XR compliance |
64
+ | Nintendo | Lotcheck |
65
+
66
+ ---
67
+
68
+ ## 3. Controller Support
69
+
70
+ ### Input Abstraction
71
+
72
+ ```
73
+ Map ACTIONS, not buttons:
74
+ - "confirm" → A (Xbox), Cross (PS), B (Nintendo)
75
+ - "cancel" → B (Xbox), Circle (PS), A (Nintendo)
76
+ ```
77
+
78
+ ### Haptic Feedback
79
+
80
+ | Intensity | Use |
81
+ |-----------|-----|
82
+ | Light | UI feedback |
83
+ | Medium | Impacts |
84
+ | Heavy | Major events |
85
+
86
+ ---
87
+
88
+ ## 4. Performance Optimization
89
+
90
+ ### Profiling First
91
+
92
+ | Engine | Tool |
93
+ |--------|------|
94
+ | Unity | Profiler Window |
95
+ | Godot | Debugger → Profiler |
96
+ | Unreal | Unreal Insights |
97
+
98
+ ### Common Bottlenecks
99
+
100
+ | Bottleneck | Solution |
101
+ |------------|----------|
102
+ | Draw calls | Batching, atlases |
103
+ | GC spikes | Object pooling |
104
+ | Physics | Simpler colliders |
105
+ | Shaders | LOD shaders |
106
+
107
+ ---
108
+
109
+ ## 5. Engine-Specific Principles
110
+
111
+ ### Unity 6
112
+
113
+ - DOTS for performance-critical systems
114
+ - Burst compiler for hot paths
115
+ - Addressables for asset streaming
116
+
117
+ ### Godot 4
118
+
119
+ - GDScript for rapid iteration
120
+ - C# for complex logic
121
+ - Signals for decoupling
122
+
123
+ ### Unreal 5
124
+
125
+ - Blueprint for designers
126
+ - C++ for performance
127
+ - Nanite for high-poly environments
128
+ - Lumen for dynamic lighting
129
+
130
+ ---
131
+
132
+ ## 6. Anti-Patterns
133
+
134
+ | ❌ Don't | ✅ Do |
135
+ |----------|-------|
136
+ | Choose engine by hype | Choose by project needs |
137
+ | Ignore platform guidelines | Study certification requirements |
138
+ | Hardcode input buttons | Abstract to actions |
139
+ | Skip profiling | Profile early and often |
140
+
141
+ ---
142
+
143
+ > **Remember:** Engine is a tool. Master the principles, then adapt to any engine.
@@ -0,0 +1,122 @@
1
+ ---
2
+ name: vr-ar
3
+ description: VR/AR development principles. Comfort, interaction, performance requirements.
4
+ compatibility: opencode
5
+ ---
6
+ # VR/AR Development
7
+
8
+ > Immersive experience principles.
9
+
10
+ ---
11
+
12
+ ## 1. Platform Selection
13
+
14
+ ### VR Platforms
15
+
16
+ | Platform | Use Case |
17
+ |----------|----------|
18
+ | **Quest** | Standalone, wireless |
19
+ | **PCVR** | High fidelity |
20
+ | **PSVR** | Console market |
21
+ | **WebXR** | Browser-based |
22
+
23
+ ### AR Platforms
24
+
25
+ | Platform | Use Case |
26
+ |----------|----------|
27
+ | **ARKit** | iOS devices |
28
+ | **ARCore** | Android devices |
29
+ | **WebXR** | Browser AR |
30
+ | **HoloLens** | Enterprise |
31
+
32
+ ---
33
+
34
+ ## 2. Comfort Principles
35
+
36
+ ### Motion Sickness Prevention
37
+
38
+ | Cause | Solution |
39
+ |-------|----------|
40
+ | **Locomotion** | Teleport, snap turn |
41
+ | **Low FPS** | Maintain 90 FPS |
42
+ | **Camera shake** | Avoid or minimize |
43
+ | **Rapid acceleration** | Gradual movement |
44
+
45
+ ### Comfort Settings
46
+
47
+ - Vignette during movement
48
+ - Snap vs smooth turning
49
+ - Seated vs standing modes
50
+ - Height calibration
51
+
52
+ ---
53
+
54
+ ## 3. Performance Requirements
55
+
56
+ ### Target Metrics
57
+
58
+ | Platform | FPS | Resolution |
59
+ |----------|-----|------------|
60
+ | Quest 2 | 72-90 | 1832x1920 |
61
+ | Quest 3 | 90-120 | 2064x2208 |
62
+ | PCVR | 90 | 2160x2160+ |
63
+ | PSVR2 | 90-120 | 2000x2040 |
64
+
65
+ ### Frame Budget
66
+
67
+ - VR requires consistent frame times
68
+ - Single dropped frame = visible judder
69
+ - 90 FPS = 11.11ms budget
70
+
71
+ ---
72
+
73
+ ## 4. Interaction Principles
74
+
75
+ ### Controller Interaction
76
+
77
+ | Type | Use |
78
+ |------|-----|
79
+ | **Point + click** | UI, distant objects |
80
+ | **Grab** | Manipulation |
81
+ | **Gesture** | Magic, special actions |
82
+ | **Physical** | Throwing, swinging |
83
+
84
+ ### Hand Tracking
85
+
86
+ - More immersive but less precise
87
+ - Good for: social, casual
88
+ - Challenging for: action, precision
89
+
90
+ ---
91
+
92
+ ## 5. Spatial Design
93
+
94
+ ### World Scale
95
+
96
+ - 1 unit = 1 meter (critical)
97
+ - Objects must feel right size
98
+ - Test with real measurements
99
+
100
+ ### Depth Cues
101
+
102
+ | Cue | Importance |
103
+ |-----|------------|
104
+ | Stereo | Primary depth |
105
+ | Motion parallax | Secondary |
106
+ | Shadows | Grounding |
107
+ | Occlusion | Layering |
108
+
109
+ ---
110
+
111
+ ## 6. Anti-Patterns
112
+
113
+ | ❌ Don't | ✅ Do |
114
+ |----------|-------|
115
+ | Move camera without player | Player controls camera |
116
+ | Drop below 90 FPS | Maintain frame rate |
117
+ | Use tiny UI text | Large, readable text |
118
+ | Ignore arm length | Scale to player reach |
119
+
120
+ ---
121
+
122
+ > **Remember:** Comfort is not optional. Sick players don't play.
@@ -0,0 +1,149 @@
1
+ ---
2
+ name: web-games
3
+ description: Web browser game development principles. Framework selection, WebGPU, optimization, PWA.
4
+ compatibility: opencode
5
+ ---
6
+ # Web Browser Game Development
7
+
8
+ > Framework selection and browser-specific principles.
9
+
10
+ ---
11
+
12
+ ## 1. Framework Selection
13
+
14
+ ### Decision Tree
15
+
16
+ ```
17
+ What type of game?
18
+
19
+ ├── 2D Game
20
+ │ ├── Full game engine features? → Phaser
21
+ │ └── Raw rendering power? → PixiJS
22
+
23
+ ├── 3D Game
24
+ │ ├── Full engine (physics, XR)? → Babylon.js
25
+ │ └── Rendering focused? → Three.js
26
+
27
+ └── Hybrid / Canvas
28
+ └── Custom → Raw Canvas/WebGL
29
+ ```
30
+
31
+ ### Comparison
32
+
33
+ | Framework | Type | Best For |
34
+ |-----------|------|----------|
35
+ | **Phaser 4** | 2D | Full game features |
36
+ | **PixiJS 8** | 2D | Rendering, UI |
37
+ | **Three.js** | 3D | Visualizations, lightweight |
38
+ | **Babylon.js 7** | 3D | Full engine, XR |
39
+
40
+ ---
41
+
42
+ ## 2. WebGPU Adoption
43
+
44
+ ### Browser Support
45
+
46
+ | Browser | Support |
47
+ |---------|---------|
48
+ | Chrome | ✅ Since v113 |
49
+ | Edge | ✅ Since v113 |
50
+ | Firefox | ✅ Since v131 |
51
+ | Safari | ✅ Since 18.0 |
52
+ | **Total** | **~73%** global |
53
+
54
+ ### Decision
55
+
56
+ - **New projects**: Use WebGPU with WebGL fallback
57
+ - **Legacy support**: Start with WebGL
58
+ - **Feature detection**: Check `navigator.gpu`
59
+
60
+ ---
61
+
62
+ ## 3. Performance Principles
63
+
64
+ ### Browser Constraints
65
+
66
+ | Constraint | Strategy |
67
+ |------------|----------|
68
+ | No local file access | Asset bundling, CDN |
69
+ | Tab throttling | Pause when hidden |
70
+ | Mobile data limits | Compress assets |
71
+ | Audio autoplay | Require user interaction |
72
+
73
+ ### Optimization Priority
74
+
75
+ 1. **Asset compression** - KTX2, Draco, WebP
76
+ 2. **Lazy loading** - Load on demand
77
+ 3. **Object pooling** - Avoid GC
78
+ 4. **Draw call batching** - Reduce state changes
79
+ 5. **Web Workers** - Offload heavy computation
80
+
81
+ ---
82
+
83
+ ## 4. Asset Strategy
84
+
85
+ ### Compression Formats
86
+
87
+ | Type | Format |
88
+ |------|--------|
89
+ | Textures | KTX2 + Basis Universal |
90
+ | Audio | WebM/Opus (fallback: MP3) |
91
+ | 3D Models | glTF + Draco/Meshopt |
92
+
93
+ ### Loading Strategy
94
+
95
+ | Phase | Load |
96
+ |-------|------|
97
+ | Startup | Core assets, <2MB |
98
+ | Gameplay | Stream on demand |
99
+ | Background | Prefetch next level |
100
+
101
+ ---
102
+
103
+ ## 5. PWA for Games
104
+
105
+ ### Benefits
106
+
107
+ - Offline play
108
+ - Install to home screen
109
+ - Full screen mode
110
+ - Push notifications
111
+
112
+ ### Requirements
113
+
114
+ - Service worker for caching
115
+ - Web app manifest
116
+ - HTTPS
117
+
118
+ ---
119
+
120
+ ## 6. Audio Handling
121
+
122
+ ### Browser Requirements
123
+
124
+ - Audio context requires user interaction
125
+ - Create AudioContext on first click/tap
126
+ - Resume context if suspended
127
+
128
+ ### Best Practices
129
+
130
+ - Use Web Audio API
131
+ - Pool audio sources
132
+ - Preload common sounds
133
+ - Compress with WebM/Opus
134
+
135
+ ---
136
+
137
+ ## 7. Anti-Patterns
138
+
139
+ | ❌ Don't | ✅ Do |
140
+ |----------|-------|
141
+ | Load all assets upfront | Progressive loading |
142
+ | Ignore tab visibility | Pause when hidden |
143
+ | Block on audio load | Lazy load audio |
144
+ | Skip compression | Compress everything |
145
+ | Assume fast connection | Handle slow networks |
146
+
147
+ ---
148
+
149
+ > **Remember:** Browser is the most accessible platform. Respect its constraints.
@@ -0,0 +1,158 @@
1
+ ---
2
+ name: geo-fundamentals
3
+ description: Generative Engine Optimization for AI search engines (ChatGPT, Claude, Perplexity).
4
+ compatibility: opencode
5
+ metadata:
6
+ when_to_use: "\"When optimizing content for AI search engines like ChatGPT, Claude, or Perplexity. Generative Engine Optimization.\""
7
+ version: "1.0.0"
8
+ ---
9
+ # GEO Fundamentals
10
+
11
+ > Optimization for AI-powered search engines.
12
+
13
+ ---
14
+
15
+ ## 1. What is GEO?
16
+
17
+ **GEO** = Generative Engine Optimization
18
+
19
+ | Goal | Platform |
20
+ |------|----------|
21
+ | Be cited in AI responses | ChatGPT, Claude, Perplexity, Gemini |
22
+
23
+ ### SEO vs GEO
24
+
25
+ | Aspect | SEO | GEO |
26
+ |--------|-----|-----|
27
+ | Goal | #1 ranking | AI citations |
28
+ | Platform | Google | AI engines |
29
+ | Metrics | Rankings, CTR | Citation rate |
30
+ | Focus | Keywords | Entities, data |
31
+
32
+ ---
33
+
34
+ ## 2. AI Engine Landscape
35
+
36
+ | Engine | Citation Style | Opportunity |
37
+ |--------|----------------|-------------|
38
+ | **Perplexity** | Numbered [1][2] | Highest citation rate |
39
+ | **ChatGPT** | Inline/footnotes | Custom GPTs |
40
+ | **Claude** | Contextual | Long-form content |
41
+ | **Gemini** | Sources section | SEO crossover |
42
+
43
+ ---
44
+
45
+ ## 3. RAG Retrieval Factors
46
+
47
+ How AI engines select content to cite:
48
+
49
+ | Factor | Weight |
50
+ |--------|--------|
51
+ | Semantic relevance | ~40% |
52
+ | Keyword match | ~20% |
53
+ | Authority signals | ~15% |
54
+ | Freshness | ~10% |
55
+ | Source diversity | ~15% |
56
+
57
+ ---
58
+
59
+ ## 4. Content That Gets Cited
60
+
61
+ | Element | Why It Works |
62
+ |---------|--------------|
63
+ | **Original statistics** | Unique, citable data |
64
+ | **Expert quotes** | Authority transfer |
65
+ | **Clear definitions** | Easy to extract |
66
+ | **Step-by-step guides** | Actionable value |
67
+ | **Comparison tables** | Structured info |
68
+ | **FAQ sections** | Direct answers |
69
+
70
+ ---
71
+
72
+ ## 5. GEO Content Checklist
73
+
74
+ ### Content Elements
75
+
76
+ - [ ] Question-based titles
77
+ - [ ] Summary/TL;DR at top
78
+ - [ ] Original data with sources
79
+ - [ ] Expert quotes (name, title)
80
+ - [ ] FAQ section (3-5 Q&A)
81
+ - [ ] Clear definitions
82
+ - [ ] "Last updated" timestamp
83
+ - [ ] Author with credentials
84
+
85
+ ### Technical Elements
86
+
87
+ - [ ] Article schema with dates
88
+ - [ ] Person schema for author
89
+ - [ ] FAQPage schema
90
+ - [ ] Fast loading (< 2.5s)
91
+ - [ ] Clean HTML structure
92
+
93
+ ---
94
+
95
+ ## 6. Entity Building
96
+
97
+ | Action | Purpose |
98
+ |--------|---------|
99
+ | Google Knowledge Panel | Entity recognition |
100
+ | Wikipedia (if notable) | Authority source |
101
+ | Consistent info across web | Entity consolidation |
102
+ | Industry mentions | Authority signals |
103
+
104
+ ---
105
+
106
+ ## 7. AI Crawler Access
107
+
108
+ ### Key AI User-Agents
109
+
110
+ | Crawler | Engine |
111
+ |---------|--------|
112
+ | GPTBot | ChatGPT/OpenAI |
113
+ | Claude-Web | Claude |
114
+ | PerplexityBot | Perplexity |
115
+ | Googlebot | Gemini (shared) |
116
+
117
+ ### Access Decision
118
+
119
+ | Strategy | When |
120
+ |----------|------|
121
+ | Allow all | Want AI citations |
122
+ | Block GPTBot | Don't want OpenAI training |
123
+ | Selective | Allow some, block others |
124
+
125
+ ---
126
+
127
+ ## 8. Measurement
128
+
129
+ | Metric | How to Track |
130
+ |--------|--------------|
131
+ | AI citations | Manual monitoring |
132
+ | "According to [Brand]" mentions | Search in AI |
133
+ | Competitor citations | Compare share |
134
+ | AI-referred traffic | UTM parameters |
135
+
136
+ ---
137
+
138
+ ## 9. Anti-Patterns
139
+
140
+ | ❌ Don't | ✅ Do |
141
+ |----------|-------|
142
+ | Publish without dates | Add timestamps |
143
+ | Vague attributions | Name sources |
144
+ | Skip author info | Show credentials |
145
+ | Thin content | Comprehensive coverage |
146
+
147
+ ---
148
+
149
+ > **Remember:** AI cites content that's clear, authoritative, and easy to extract. Be the best answer.
150
+
151
+ ---
152
+
153
+ ## Script
154
+
155
+ | Script | Purpose | Command |
156
+ |--------|---------|---------|
157
+ | `.opencode/scripts/geo_checker.py` | GEO audit (AI citation readiness) | `python .opencode/scripts/geo_checker.py <project_path>` |
158
+