dsh-ecc-skills 0.4.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 (278) hide show
  1. package/LICENSE +22 -0
  2. package/README.md +99 -0
  3. package/cordis.patch.yml +5 -0
  4. package/lib/index.js +195 -0
  5. package/package.json +46 -0
  6. package/skills/accessibility/SKILL.md +147 -0
  7. package/skills/agent-architecture-audit/SKILL.md +257 -0
  8. package/skills/agent-eval/SKILL.md +147 -0
  9. package/skills/agent-harness-construction/SKILL.md +74 -0
  10. package/skills/agent-introspection-debugging/SKILL.md +154 -0
  11. package/skills/agent-payment-x402/SKILL.md +225 -0
  12. package/skills/agent-self-evaluation/SKILL.md +182 -0
  13. package/skills/agent-sort/SKILL.md +216 -0
  14. package/skills/agentic-engineering/SKILL.md +64 -0
  15. package/skills/agentic-os/SKILL.md +388 -0
  16. package/skills/ai-first-engineering/SKILL.md +52 -0
  17. package/skills/ai-regression-testing/SKILL.md +386 -0
  18. package/skills/android-clean-architecture/SKILL.md +340 -0
  19. package/skills/angular-developer/SKILL.md +155 -0
  20. package/skills/api-connector-builder/SKILL.md +121 -0
  21. package/skills/api-design/SKILL.md +524 -0
  22. package/skills/architecture-decision-records/SKILL.md +180 -0
  23. package/skills/article-writing/SKILL.md +80 -0
  24. package/skills/automation-audit-ops/SKILL.md +143 -0
  25. package/skills/autonomous-agent-harness/SKILL.md +274 -0
  26. package/skills/autonomous-loops/SKILL.md +611 -0
  27. package/skills/backend-patterns/SKILL.md +562 -0
  28. package/skills/benchmark/SKILL.md +95 -0
  29. package/skills/benchmark-methodology/SKILL.md +191 -0
  30. package/skills/benchmark-optimization-loop/SKILL.md +71 -0
  31. package/skills/blender-motion-state-inspection/SKILL.md +165 -0
  32. package/skills/blueprint/SKILL.md +106 -0
  33. package/skills/brand-discovery/SKILL.md +145 -0
  34. package/skills/brand-voice/SKILL.md +98 -0
  35. package/skills/browser-qa/SKILL.md +105 -0
  36. package/skills/bun-runtime/SKILL.md +85 -0
  37. package/skills/canary-watch/SKILL.md +108 -0
  38. package/skills/carrier-relationship-management/SKILL.md +212 -0
  39. package/skills/cisco-ios-patterns/SKILL.md +164 -0
  40. package/skills/ck/SKILL.md +148 -0
  41. package/skills/claude-devfleet/SKILL.md +112 -0
  42. package/skills/click-path-audit/SKILL.md +245 -0
  43. package/skills/clickhouse-io/SKILL.md +445 -0
  44. package/skills/code-tour/SKILL.md +254 -0
  45. package/skills/codebase-onboarding/SKILL.md +234 -0
  46. package/skills/codehealth-mcp/SKILL.md +167 -0
  47. package/skills/coding-standards/SKILL.md +551 -0
  48. package/skills/competitive-platform-analysis/SKILL.md +214 -0
  49. package/skills/competitive-report-structure/SKILL.md +162 -0
  50. package/skills/compose-multiplatform-patterns/SKILL.md +300 -0
  51. package/skills/config-gc/SKILL.md +120 -0
  52. package/skills/configure-ecc/SKILL.md +206 -0
  53. package/skills/connections-optimizer/SKILL.md +190 -0
  54. package/skills/content-engine/SKILL.md +132 -0
  55. package/skills/content-hash-cache-pattern/SKILL.md +162 -0
  56. package/skills/context-budget/SKILL.md +136 -0
  57. package/skills/continuous-agent-loop/SKILL.md +46 -0
  58. package/skills/contract-first/SKILL.md +287 -0
  59. package/skills/cost-aware-llm-pipeline/SKILL.md +184 -0
  60. package/skills/cost-tracking/SKILL.md +97 -0
  61. package/skills/council/SKILL.md +204 -0
  62. package/skills/council-multi-model/SKILL.md +167 -0
  63. package/skills/cpp-coding-standards/SKILL.md +724 -0
  64. package/skills/cpp-testing/SKILL.md +325 -0
  65. package/skills/crosspost/SKILL.md +112 -0
  66. package/skills/csharp-testing/SKILL.md +322 -0
  67. package/skills/customer-billing-ops/SKILL.md +141 -0
  68. package/skills/customs-trade-compliance/SKILL.md +263 -0
  69. package/skills/dart-flutter-patterns/SKILL.md +564 -0
  70. package/skills/dashboard-builder/SKILL.md +109 -0
  71. package/skills/data-scraper-agent/SKILL.md +765 -0
  72. package/skills/data-throughput-accelerator/SKILL.md +74 -0
  73. package/skills/database-migrations/SKILL.md +430 -0
  74. package/skills/deep-research/SKILL.md +160 -0
  75. package/skills/defi-amm-security/SKILL.md +167 -0
  76. package/skills/delivery-gate/SKILL.md +126 -0
  77. package/skills/deployment-patterns/SKILL.md +428 -0
  78. package/skills/design-system/SKILL.md +83 -0
  79. package/skills/dev-team/SKILL.md +203 -0
  80. package/skills/django-celery/SKILL.md +458 -0
  81. package/skills/django-patterns/SKILL.md +735 -0
  82. package/skills/django-security/SKILL.md +644 -0
  83. package/skills/django-tdd/SKILL.md +730 -0
  84. package/skills/django-verification/SKILL.md +470 -0
  85. package/skills/dmux-workflows/SKILL.md +192 -0
  86. package/skills/docker-patterns/SKILL.md +520 -0
  87. package/skills/documentation-lookup/SKILL.md +91 -0
  88. package/skills/dotnet-patterns/SKILL.md +322 -0
  89. package/skills/dynamic-workflow-mode/SKILL.md +124 -0
  90. package/skills/e2e-testing/SKILL.md +327 -0
  91. package/skills/ecc-tools-cost-audit/SKILL.md +161 -0
  92. package/skills/email-ops/SKILL.md +122 -0
  93. package/skills/energy-procurement/SKILL.md +228 -0
  94. package/skills/enterprise-agent-ops/SKILL.md +51 -0
  95. package/skills/error-handling/SKILL.md +377 -0
  96. package/skills/eval-harness/SKILL.md +271 -0
  97. package/skills/evm-token-decimals/SKILL.md +131 -0
  98. package/skills/exa-search/SKILL.md +108 -0
  99. package/skills/fal-ai-media/SKILL.md +289 -0
  100. package/skills/fastapi-patterns/SKILL.md +514 -0
  101. package/skills/finance-billing-ops/SKILL.md +128 -0
  102. package/skills/flox-environments/SKILL.md +497 -0
  103. package/skills/flutter-dart-code-review/SKILL.md +436 -0
  104. package/skills/foundation-models-on-device/SKILL.md +243 -0
  105. package/skills/frontend-a11y/SKILL.md +446 -0
  106. package/skills/frontend-design-direction/SKILL.md +93 -0
  107. package/skills/frontend-patterns/SKILL.md +657 -0
  108. package/skills/fsharp-testing/SKILL.md +281 -0
  109. package/skills/gan-style-harness/SKILL.md +279 -0
  110. package/skills/generating-python-installer/SKILL.md +820 -0
  111. package/skills/git-workflow/SKILL.md +716 -0
  112. package/skills/github-ops/SKILL.md +145 -0
  113. package/skills/golang-patterns/SKILL.md +676 -0
  114. package/skills/golang-testing/SKILL.md +721 -0
  115. package/skills/google-workspace-ops/SKILL.md +96 -0
  116. package/skills/growth-log/SKILL.md +128 -0
  117. package/skills/healthcare-cdss-patterns/SKILL.md +246 -0
  118. package/skills/healthcare-emr-patterns/SKILL.md +160 -0
  119. package/skills/healthcare-eval-harness/SKILL.md +208 -0
  120. package/skills/healthcare-phi-compliance/SKILL.md +146 -0
  121. package/skills/hermes-imports/SKILL.md +89 -0
  122. package/skills/hexagonal-architecture/SKILL.md +277 -0
  123. package/skills/hipaa-compliance/SKILL.md +79 -0
  124. package/skills/homelab-network-readiness/SKILL.md +170 -0
  125. package/skills/homelab-network-setup/SKILL.md +130 -0
  126. package/skills/homelab-pihole-dns/SKILL.md +275 -0
  127. package/skills/homelab-vlan-segmentation/SKILL.md +312 -0
  128. package/skills/homelab-wireguard-vpn/SKILL.md +306 -0
  129. package/skills/hookify-rules/SKILL.md +128 -0
  130. package/skills/inherit-legacy-style/SKILL.md +157 -0
  131. package/skills/intent-driven-development/SKILL.md +360 -0
  132. package/skills/inventory-demand-planning/SKILL.md +247 -0
  133. package/skills/investor-materials/SKILL.md +97 -0
  134. package/skills/investor-outreach/SKILL.md +92 -0
  135. package/skills/ios-icon-gen/SKILL.md +158 -0
  136. package/skills/iterative-retrieval/SKILL.md +212 -0
  137. package/skills/ito-baskets/SKILL.md +263 -0
  138. package/skills/ito-compute/SKILL.md +151 -0
  139. package/skills/ito-inference/SKILL.md +119 -0
  140. package/skills/ito-training/SKILL.md +123 -0
  141. package/skills/java-coding-standards/SKILL.md +384 -0
  142. package/skills/jira-integration/SKILL.md +303 -0
  143. package/skills/jpa-patterns/SKILL.md +152 -0
  144. package/skills/knowledge-ops/SKILL.md +155 -0
  145. package/skills/kotlin-coroutines-flows/SKILL.md +285 -0
  146. package/skills/kotlin-exposed-patterns/SKILL.md +720 -0
  147. package/skills/kotlin-ktor-patterns/SKILL.md +690 -0
  148. package/skills/kotlin-patterns/SKILL.md +712 -0
  149. package/skills/kotlin-testing/SKILL.md +825 -0
  150. package/skills/kubernetes-patterns/SKILL.md +756 -0
  151. package/skills/laravel-patterns/SKILL.md +416 -0
  152. package/skills/laravel-plugin-discovery/SKILL.md +230 -0
  153. package/skills/laravel-security/SKILL.md +948 -0
  154. package/skills/laravel-tdd/SKILL.md +675 -0
  155. package/skills/laravel-verification/SKILL.md +180 -0
  156. package/skills/latency-critical-systems/SKILL.md +75 -0
  157. package/skills/lead-intelligence/SKILL.md +322 -0
  158. package/skills/liquid-glass-design/SKILL.md +279 -0
  159. package/skills/living-docs-governance/SKILL.md +137 -0
  160. package/skills/llm-trading-agent-security/SKILL.md +147 -0
  161. package/skills/logistics-exception-management/SKILL.md +222 -0
  162. package/skills/loop-design-check/SKILL.md +143 -0
  163. package/skills/mailtrap-email-integration/SKILL.md +77 -0
  164. package/skills/make-interfaces-feel-better/SKILL.md +152 -0
  165. package/skills/manim-video/SKILL.md +90 -0
  166. package/skills/market-research/SKILL.md +76 -0
  167. package/skills/marketing-campaign/SKILL.md +114 -0
  168. package/skills/mcp-server-patterns/SKILL.md +70 -0
  169. package/skills/messages-ops/SKILL.md +105 -0
  170. package/skills/ml-adoption-playbook/SKILL.md +57 -0
  171. package/skills/mle-workflow/SKILL.md +348 -0
  172. package/skills/motion-advanced/SKILL.md +597 -0
  173. package/skills/motion-foundations/SKILL.md +300 -0
  174. package/skills/motion-patterns/SKILL.md +435 -0
  175. package/skills/motion-ui/SKILL.md +576 -0
  176. package/skills/mysql-patterns/SKILL.md +413 -0
  177. package/skills/nanoclaw-repl/SKILL.md +34 -0
  178. package/skills/nasiko-control-plane/SKILL.md +49 -0
  179. package/skills/nestjs-patterns/SKILL.md +231 -0
  180. package/skills/netmiko-ssh-automation/SKILL.md +174 -0
  181. package/skills/network-bgp-diagnostics/SKILL.md +168 -0
  182. package/skills/network-config-validation/SKILL.md +211 -0
  183. package/skills/network-interface-health/SKILL.md +153 -0
  184. package/skills/nextjs-turbopack/SKILL.md +58 -0
  185. package/skills/nodejs-keccak256/SKILL.md +103 -0
  186. package/skills/nutrient-document-processing/SKILL.md +168 -0
  187. package/skills/nuxt4-patterns/SKILL.md +101 -0
  188. package/skills/opensource-pipeline/SKILL.md +256 -0
  189. package/skills/orch-add-feature/SKILL.md +45 -0
  190. package/skills/orch-build-mvp/SKILL.md +49 -0
  191. package/skills/orch-change-feature/SKILL.md +43 -0
  192. package/skills/orch-fix-defect/SKILL.md +43 -0
  193. package/skills/orch-pipeline/SKILL.md +121 -0
  194. package/skills/orch-refine-code/SKILL.md +44 -0
  195. package/skills/parallel-execution-optimizer/SKILL.md +74 -0
  196. package/skills/perl-patterns/SKILL.md +505 -0
  197. package/skills/perl-security/SKILL.md +504 -0
  198. package/skills/perl-testing/SKILL.md +476 -0
  199. package/skills/plan-canvas/SKILL.md +196 -0
  200. package/skills/plankton-code-quality/SKILL.md +237 -0
  201. package/skills/postgres-patterns/SKILL.md +148 -0
  202. package/skills/prediction-market-oracle-research/SKILL.md +64 -0
  203. package/skills/prediction-market-risk-review/SKILL.md +61 -0
  204. package/skills/prisma-patterns/SKILL.md +401 -0
  205. package/skills/product-capability/SKILL.md +142 -0
  206. package/skills/product-lens/SKILL.md +93 -0
  207. package/skills/production-audit/SKILL.md +207 -0
  208. package/skills/production-scheduling/SKILL.md +238 -0
  209. package/skills/project-flow-ops/SKILL.md +112 -0
  210. package/skills/prompt-optimizer/SKILL.md +398 -0
  211. package/skills/python-patterns/SKILL.md +751 -0
  212. package/skills/python-testing/SKILL.md +817 -0
  213. package/skills/pytorch-patterns/SKILL.md +397 -0
  214. package/skills/quality-nonconformance/SKILL.md +260 -0
  215. package/skills/quarkus-patterns/SKILL.md +723 -0
  216. package/skills/quarkus-security/SKILL.md +468 -0
  217. package/skills/quarkus-tdd/SKILL.md +812 -0
  218. package/skills/quarkus-verification/SKILL.md +481 -0
  219. package/skills/ralphinho-rfc-pipeline/SKILL.md +68 -0
  220. package/skills/react-native-patterns/SKILL.md +326 -0
  221. package/skills/react-patterns/SKILL.md +342 -0
  222. package/skills/react-performance/SKILL.md +575 -0
  223. package/skills/react-testing/SKILL.md +424 -0
  224. package/skills/recsys-pipeline-architect/SKILL.md +115 -0
  225. package/skills/recursive-decision-ledger/SKILL.md +81 -0
  226. package/skills/redis-patterns/SKILL.md +404 -0
  227. package/skills/regex-vs-llm-structured-text/SKILL.md +221 -0
  228. package/skills/remotion-video-creation/SKILL.md +43 -0
  229. package/skills/repo-scan/SKILL.md +170 -0
  230. package/skills/research-ops/SKILL.md +113 -0
  231. package/skills/returns-reverse-logistics/SKILL.md +240 -0
  232. package/skills/rules-distill/SKILL.md +265 -0
  233. package/skills/rust-patterns/SKILL.md +500 -0
  234. package/skills/rust-testing/SKILL.md +501 -0
  235. package/skills/safety-guard/SKILL.md +76 -0
  236. package/skills/santa-method/SKILL.md +307 -0
  237. package/skills/scientific-db-pubmed-database/SKILL.md +176 -0
  238. package/skills/scientific-db-uspto-database/SKILL.md +178 -0
  239. package/skills/scientific-pkg-gget/SKILL.md +167 -0
  240. package/skills/scientific-thinking-literature-review/SKILL.md +193 -0
  241. package/skills/scientific-thinking-scholar-evaluation/SKILL.md +161 -0
  242. package/skills/search-first/SKILL.md +183 -0
  243. package/skills/security-bounty-hunter/SKILL.md +100 -0
  244. package/skills/security-scan/SKILL.md +166 -0
  245. package/skills/seo/SKILL.md +155 -0
  246. package/skills/skill-scout/SKILL.md +141 -0
  247. package/skills/skill-stocktake/SKILL.md +195 -0
  248. package/skills/social-graph-ranker/SKILL.md +155 -0
  249. package/skills/social-publisher/SKILL.md +130 -0
  250. package/skills/springboot-patterns/SKILL.md +315 -0
  251. package/skills/springboot-security/SKILL.md +273 -0
  252. package/skills/springboot-tdd/SKILL.md +159 -0
  253. package/skills/springboot-verification/SKILL.md +232 -0
  254. package/skills/swift-actor-persistence/SKILL.md +144 -0
  255. package/skills/swift-concurrency-6-2/SKILL.md +216 -0
  256. package/skills/swift-protocol-di-testing/SKILL.md +191 -0
  257. package/skills/swiftui-patterns/SKILL.md +259 -0
  258. package/skills/taste/SKILL.md +264 -0
  259. package/skills/tdd-workflow/SKILL.md +583 -0
  260. package/skills/team-agent-orchestration/SKILL.md +111 -0
  261. package/skills/team-builder/SKILL.md +169 -0
  262. package/skills/terminal-opener/SKILL.md +55 -0
  263. package/skills/terminal-ops/SKILL.md +110 -0
  264. package/skills/tinystruct-patterns/SKILL.md +279 -0
  265. package/skills/token-budget-advisor/SKILL.md +134 -0
  266. package/skills/ui-demo/SKILL.md +466 -0
  267. package/skills/ui-to-vue/SKILL.md +135 -0
  268. package/skills/uncloud/SKILL.md +344 -0
  269. package/skills/unified-memory/SKILL.md +170 -0
  270. package/skills/unified-notifications-ops/SKILL.md +188 -0
  271. package/skills/verification-loop/SKILL.md +129 -0
  272. package/skills/video-editing/SKILL.md +311 -0
  273. package/skills/videodb/SKILL.md +375 -0
  274. package/skills/vite-patterns/SKILL.md +450 -0
  275. package/skills/vue-patterns/SKILL.md +471 -0
  276. package/skills/windows-desktop-e2e/SKILL.md +888 -0
  277. package/skills/workspace-surface-audit/SKILL.md +126 -0
  278. package/skills/x-api/SKILL.md +235 -0
@@ -0,0 +1,340 @@
1
+ ---
2
+ name: android-clean-architecture
3
+ description: Clean Architecture patterns for Android and Kotlin Multiplatform projects — module structure, dependency rules, UseCases, Repositories, and data layer patterns. Use when structuring modules, layers, or data flow in an Android or KMP project.
4
+ metadata:
5
+ origin: ECC
6
+ ---
7
+
8
+ # Android Clean Architecture
9
+
10
+ Clean Architecture patterns for Android and KMP projects. Covers module boundaries, dependency inversion, UseCase/Repository patterns, and data layer design with Room, SQLDelight, and Ktor.
11
+
12
+ ## When to Activate
13
+
14
+ - Structuring Android or KMP project modules
15
+ - Implementing UseCases, Repositories, or DataSources
16
+ - Designing data flow between layers (domain, data, presentation)
17
+ - Setting up dependency injection with Koin or Hilt
18
+ - Working with Room, SQLDelight, or Ktor in a layered architecture
19
+
20
+ ## Module Structure
21
+
22
+ ### Recommended Layout
23
+
24
+ ```
25
+ project/
26
+ ├── app/ # Android entry point, DI wiring, Application class
27
+ ├── core/ # Shared utilities, base classes, error types
28
+ ├── domain/ # UseCases, domain models, repository interfaces (pure Kotlin)
29
+ ├── data/ # Repository implementations, DataSources, DB, network
30
+ ├── presentation/ # Screens, ViewModels, UI models, navigation
31
+ ├── design-system/ # Reusable Compose components, theme, typography
32
+ └── feature/ # Feature modules (optional, for larger projects)
33
+ ├── auth/
34
+ ├── settings/
35
+ └── profile/
36
+ ```
37
+
38
+ ### Dependency Rules
39
+
40
+ ```
41
+ app → presentation, domain, data, core
42
+ presentation → domain, design-system, core
43
+ data → domain, core
44
+ domain → core (or no dependencies)
45
+ core → (nothing)
46
+ ```
47
+
48
+ **Critical**: `domain` must NEVER depend on `data`, `presentation`, or any framework. It contains pure Kotlin only.
49
+
50
+ ## Domain Layer
51
+
52
+ ### UseCase Pattern
53
+
54
+ Each UseCase represents one business operation. Use `operator fun invoke` for clean call sites:
55
+
56
+ ```kotlin
57
+ class GetItemsByCategoryUseCase(
58
+ private val repository: ItemRepository
59
+ ) {
60
+ suspend operator fun invoke(category: String): Result<List<Item>> {
61
+ return repository.getItemsByCategory(category)
62
+ }
63
+ }
64
+
65
+ // Flow-based UseCase for reactive streams
66
+ class ObserveUserProgressUseCase(
67
+ private val repository: UserRepository
68
+ ) {
69
+ operator fun invoke(userId: String): Flow<UserProgress> {
70
+ return repository.observeProgress(userId)
71
+ }
72
+ }
73
+ ```
74
+
75
+ ### Domain Models
76
+
77
+ Domain models are plain Kotlin data classes — no framework annotations:
78
+
79
+ ```kotlin
80
+ data class Item(
81
+ val id: String,
82
+ val title: String,
83
+ val description: String,
84
+ val tags: List<String>,
85
+ val status: Status,
86
+ val category: String
87
+ )
88
+
89
+ enum class Status { DRAFT, ACTIVE, ARCHIVED }
90
+ ```
91
+
92
+ ### Repository Interfaces
93
+
94
+ Defined in domain, implemented in data:
95
+
96
+ ```kotlin
97
+ interface ItemRepository {
98
+ suspend fun getItemsByCategory(category: String): Result<List<Item>>
99
+ suspend fun saveItem(item: Item): Result<Unit>
100
+ fun observeItems(): Flow<List<Item>>
101
+ }
102
+ ```
103
+
104
+ ## Data Layer
105
+
106
+ ### Repository Implementation
107
+
108
+ Coordinates between local and remote data sources:
109
+
110
+ ```kotlin
111
+ class ItemRepositoryImpl(
112
+ private val localDataSource: ItemLocalDataSource,
113
+ private val remoteDataSource: ItemRemoteDataSource
114
+ ) : ItemRepository {
115
+
116
+ override suspend fun getItemsByCategory(category: String): Result<List<Item>> {
117
+ return runCatching {
118
+ val remote = remoteDataSource.fetchItems(category)
119
+ localDataSource.insertItems(remote.map { it.toEntity() })
120
+ localDataSource.getItemsByCategory(category).map { it.toDomain() }
121
+ }
122
+ }
123
+
124
+ override suspend fun saveItem(item: Item): Result<Unit> {
125
+ return runCatching {
126
+ localDataSource.insertItems(listOf(item.toEntity()))
127
+ }
128
+ }
129
+
130
+ override fun observeItems(): Flow<List<Item>> {
131
+ return localDataSource.observeAll().map { entities ->
132
+ entities.map { it.toDomain() }
133
+ }
134
+ }
135
+ }
136
+ ```
137
+
138
+ ### Mapper Pattern
139
+
140
+ Keep mappers as extension functions near the data models:
141
+
142
+ ```kotlin
143
+ // In data layer
144
+ fun ItemEntity.toDomain() = Item(
145
+ id = id,
146
+ title = title,
147
+ description = description,
148
+ tags = tags.split("|"),
149
+ status = Status.valueOf(status),
150
+ category = category
151
+ )
152
+
153
+ fun ItemDto.toEntity() = ItemEntity(
154
+ id = id,
155
+ title = title,
156
+ description = description,
157
+ tags = tags.joinToString("|"),
158
+ status = status,
159
+ category = category
160
+ )
161
+ ```
162
+
163
+ ### Room Database (Android)
164
+
165
+ ```kotlin
166
+ @Entity(tableName = "items")
167
+ data class ItemEntity(
168
+ @PrimaryKey val id: String,
169
+ val title: String,
170
+ val description: String,
171
+ val tags: String,
172
+ val status: String,
173
+ val category: String
174
+ )
175
+
176
+ @Dao
177
+ interface ItemDao {
178
+ @Query("SELECT * FROM items WHERE category = :category")
179
+ suspend fun getByCategory(category: String): List<ItemEntity>
180
+
181
+ @Upsert
182
+ suspend fun upsert(items: List<ItemEntity>)
183
+
184
+ @Query("SELECT * FROM items")
185
+ fun observeAll(): Flow<List<ItemEntity>>
186
+ }
187
+ ```
188
+
189
+ ### SQLDelight (KMP)
190
+
191
+ ```sql
192
+ -- Item.sq
193
+ CREATE TABLE ItemEntity (
194
+ id TEXT NOT NULL PRIMARY KEY,
195
+ title TEXT NOT NULL,
196
+ description TEXT NOT NULL,
197
+ tags TEXT NOT NULL,
198
+ status TEXT NOT NULL,
199
+ category TEXT NOT NULL
200
+ );
201
+
202
+ getByCategory:
203
+ SELECT * FROM ItemEntity WHERE category = ?;
204
+
205
+ upsert:
206
+ INSERT OR REPLACE INTO ItemEntity (id, title, description, tags, status, category)
207
+ VALUES (?, ?, ?, ?, ?, ?);
208
+
209
+ observeAll:
210
+ SELECT * FROM ItemEntity;
211
+ ```
212
+
213
+ ### Ktor Network Client (KMP)
214
+
215
+ ```kotlin
216
+ class ItemRemoteDataSource(private val client: HttpClient) {
217
+
218
+ suspend fun fetchItems(category: String): List<ItemDto> {
219
+ return client.get("api/items") {
220
+ parameter("category", category)
221
+ }.body()
222
+ }
223
+ }
224
+
225
+ // HttpClient setup with content negotiation
226
+ val httpClient = HttpClient {
227
+ install(ContentNegotiation) { json(Json { ignoreUnknownKeys = true }) }
228
+ install(Logging) { level = LogLevel.HEADERS }
229
+ defaultRequest { url("https://api.example.com/") }
230
+ }
231
+ ```
232
+
233
+ ## Dependency Injection
234
+
235
+ ### Koin (KMP-friendly)
236
+
237
+ ```kotlin
238
+ // Domain module
239
+ val domainModule = module {
240
+ factory { GetItemsByCategoryUseCase(get()) }
241
+ factory { ObserveUserProgressUseCase(get()) }
242
+ }
243
+
244
+ // Data module
245
+ val dataModule = module {
246
+ single<ItemRepository> { ItemRepositoryImpl(get(), get()) }
247
+ single { ItemLocalDataSource(get()) }
248
+ single { ItemRemoteDataSource(get()) }
249
+ }
250
+
251
+ // Presentation module
252
+ val presentationModule = module {
253
+ viewModelOf(::ItemListViewModel)
254
+ viewModelOf(::DashboardViewModel)
255
+ }
256
+ ```
257
+
258
+ ### Hilt (Android-only)
259
+
260
+ ```kotlin
261
+ @Module
262
+ @InstallIn(SingletonComponent::class)
263
+ abstract class RepositoryModule {
264
+ @Binds
265
+ abstract fun bindItemRepository(impl: ItemRepositoryImpl): ItemRepository
266
+ }
267
+
268
+ @HiltViewModel
269
+ class ItemListViewModel @Inject constructor(
270
+ private val getItems: GetItemsByCategoryUseCase
271
+ ) : ViewModel()
272
+ ```
273
+
274
+ ## Error Handling
275
+
276
+ ### Result/Try Pattern
277
+
278
+ Use `Result<T>` or a custom sealed type for error propagation:
279
+
280
+ ```kotlin
281
+ sealed interface Try<out T> {
282
+ data class Success<T>(val value: T) : Try<T>
283
+ data class Failure(val error: AppError) : Try<Nothing>
284
+ }
285
+
286
+ sealed interface AppError {
287
+ data class Network(val message: String) : AppError
288
+ data class Database(val message: String) : AppError
289
+ data object Unauthorized : AppError
290
+ }
291
+
292
+ // In ViewModel — map to UI state
293
+ viewModelScope.launch {
294
+ when (val result = getItems(category)) {
295
+ is Try.Success -> _state.update { it.copy(items = result.value, isLoading = false) }
296
+ is Try.Failure -> _state.update { it.copy(error = result.error.toMessage(), isLoading = false) }
297
+ }
298
+ }
299
+ ```
300
+
301
+ ## Convention Plugins (Gradle)
302
+
303
+ For KMP projects, use convention plugins to reduce build file duplication:
304
+
305
+ ```kotlin
306
+ // build-logic/src/main/kotlin/kmp-library.gradle.kts
307
+ plugins {
308
+ id("org.jetbrains.kotlin.multiplatform")
309
+ }
310
+
311
+ kotlin {
312
+ androidTarget()
313
+ iosX64(); iosArm64(); iosSimulatorArm64()
314
+ sourceSets {
315
+ commonMain.dependencies { /* shared deps */ }
316
+ commonTest.dependencies { implementation(kotlin("test")) }
317
+ }
318
+ }
319
+ ```
320
+
321
+ Apply in modules:
322
+
323
+ ```kotlin
324
+ // domain/build.gradle.kts
325
+ plugins { id("kmp-library") }
326
+ ```
327
+
328
+ ## Anti-Patterns to Avoid
329
+
330
+ - Importing Android framework classes in `domain` — keep it pure Kotlin
331
+ - Exposing database entities or DTOs to the UI layer — always map to domain models
332
+ - Putting business logic in ViewModels — extract to UseCases
333
+ - Using `GlobalScope` or unstructured coroutines — use `viewModelScope` or structured concurrency
334
+ - Fat repository implementations — split into focused DataSources
335
+ - Circular module dependencies — if A depends on B, B must not depend on A
336
+
337
+ ## References
338
+
339
+ See skill: `compose-multiplatform-patterns` for UI patterns.
340
+ See skill: `kotlin-coroutines-flows` for async patterns.
@@ -0,0 +1,155 @@
1
+ ---
2
+ name: angular-developer
3
+ description: Generates Angular code and provides architectural guidance. Trigger when creating projects, components, or services, or for best practices on reactivity (signals, linkedSignal, resource), forms, dependency injection, routing, SSR, accessibility (ARIA), animations, styling (component styles, Tailwind CSS), testing, or CLI tooling.
4
+ metadata:
5
+ origin: ECC
6
+ ---
7
+
8
+ # Angular Developer Guidelines
9
+
10
+ ## When to Activate
11
+
12
+ - Working in any Angular project or codebase
13
+ - Creating or scaffolding a new Angular project, application, or library
14
+ - Generating components, services, directives, pipes, guards, or resolvers
15
+ - Implementing reactivity with Angular Signals, `linkedSignal`, or `resource`
16
+ - Working with Angular forms (signal forms, reactive forms, or template-driven)
17
+ - Setting up dependency injection, routing, lazy loading, or route guards
18
+ - Adding accessibility (ARIA), animations, or component styling
19
+ - Writing or debugging Angular-specific tests (unit, component harness, E2E)
20
+ - Configuring Angular CLI tooling or the Angular MCP server
21
+
22
+ 1. Always analyze the project's Angular version before providing guidance, as best practices and available features can vary significantly between versions. If creating a new project with Angular CLI, do not specify a version unless prompted by the user.
23
+
24
+ 2. When generating code, follow Angular's style guide and best practices for maintainability and performance. Use the Angular CLI for scaffolding components, services, directives, pipes, and routes to ensure consistency.
25
+
26
+ 3. Once you finish generating code, run `ng build` to ensure there are no build errors. If there are errors, analyze the error messages and fix them before proceeding. Do not skip this step, as it is critical for ensuring the generated code is correct and functional.
27
+
28
+ ## Creating New Projects
29
+
30
+ If no guidelines are provided by the user, use these defaults when creating a new Angular project:
31
+
32
+ 1. Use the latest stable version of Angular unless the user specifies otherwise.
33
+ 2. Prefer Signal Forms for new projects only when the target Angular version supports them. [Find out more](references/signal-forms.md).
34
+
35
+ **Execution Rules for `ng new`:**
36
+ When asked to create a new Angular project, you must determine the correct execution command by following these strict steps:
37
+
38
+ **Step 1: Check for an explicit user version.**
39
+
40
+ - **IF** the user requests a specific version (e.g., Angular 15), bypass local installations and strictly use `npx`.
41
+ - **Command:** `npx @angular/cli@<requested_version> new <project-name>`
42
+
43
+ **Step 2: Check for an existing Angular installation.**
44
+
45
+ - **IF** no specific version is requested, run `ng version` in the terminal to check if the Angular CLI is already installed on the system.
46
+ - **IF** the command succeeds and returns an installed version, use the local/global installation directly.
47
+ - **Command:** `ng new <project-name>`
48
+
49
+ **Step 3: Fallback to Latest.**
50
+
51
+ - **IF** no specific version is requested AND the `ng version` command fails (indicating no Angular installation exists), you must use `npx` to fetch the latest version.
52
+ - **Command:** `npx @angular/cli@latest new <project-name>`
53
+
54
+ ## Components
55
+
56
+ When working with Angular components, consult the following references based on the task:
57
+
58
+ - **Fundamentals**: Anatomy, metadata, core concepts, and template control flow (@if, @for, @switch). Read [components.md](references/components.md)
59
+ - **Inputs**: Signal-based inputs, transforms, and model inputs. Read [inputs.md](references/inputs.md)
60
+ - **Outputs**: Signal-based outputs and custom event best practices. Read [outputs.md](references/outputs.md)
61
+ - **Host Elements**: Host bindings and attribute injection. Read [host-elements.md](references/host-elements.md)
62
+
63
+ If you require deeper documentation not found in the references above, read the documentation at `https://angular.dev/guide/components`.
64
+
65
+ ## Reactivity and Data Management
66
+
67
+ When managing state and data reactivity, use Angular Signals and consult the following references:
68
+
69
+ - **Signals Overview**: Core signal concepts (`signal`, `computed`), reactive contexts, and `untracked`. Read [signals-overview.md](references/signals-overview.md)
70
+ - **Dependent State (`linkedSignal`)**: Creating writable state linked to source signals. Read [linked-signal.md](references/linked-signal.md)
71
+ - **Async Reactivity (`resource`)**: Fetching asynchronous data directly into signal state. Read [resource.md](references/resource.md)
72
+ - **Side Effects (`effect`)**: Logging, third-party DOM manipulation (`afterRenderEffect`), and when NOT to use effects. Read [effects.md](references/effects.md)
73
+
74
+ ## Forms
75
+
76
+ In most cases for new apps, **prefer signal forms**. When making a forms decision, analyze the project and consider the following guidelines:
77
+
78
+ - If the application version supports Signal Forms and this is a new form, **prefer signal forms**.
79
+ - For older applications or existing forms, match the application's current form strategy.
80
+
81
+ - **Signal Forms**: Use signals for form state management. Read [signal-forms.md](references/signal-forms.md)
82
+ - **Template-driven forms**: Use for simple forms. Read [template-driven-forms.md](references/template-driven-forms.md)
83
+ - **Reactive forms**: Use for complex forms. Read [reactive-forms.md](references/reactive-forms.md)
84
+
85
+ ## Dependency Injection
86
+
87
+ When implementing dependency injection in Angular, follow these guidelines:
88
+
89
+ - **Fundamentals**: Overview of Dependency Injection, services, and the `inject()` function. Read [di-fundamentals.md](references/di-fundamentals.md)
90
+ - **Creating and Using Services**: Creating services, the `providedIn: 'root'` option, and injecting into components or other services. Read [creating-services.md](references/creating-services.md)
91
+ - **Defining Dependency Providers**: Automatic vs manual provision, `InjectionToken`, `useClass`, `useValue`, `useFactory`, and scopes. Read [defining-providers.md](references/defining-providers.md)
92
+ - **Injection Context**: Where `inject()` is allowed, `runInInjectionContext`, and `assertInInjectionContext`. Read [injection-context.md](references/injection-context.md)
93
+ - **Hierarchical Injectors**: The `EnvironmentInjector` vs `ElementInjector`, resolution rules, modifiers (`optional`, `skipSelf`), and `providers` vs `viewProviders`. Read [hierarchical-injectors.md](references/hierarchical-injectors.md)
94
+
95
+ ## Angular Aria
96
+
97
+ When building accessible custom components for any of the following patterns: Accordion, Listbox, Combobox, Menu, Tabs, Toolbar, Tree, Grid, consult the following reference:
98
+
99
+ - **Angular Aria Components**: Building headless, accessible components (Accordion, Listbox, Combobox, Menu, Tabs, Toolbar, Tree, Grid) and styling ARIA attributes. Read [angular-aria.md](references/angular-aria.md)
100
+
101
+ ## Routing
102
+
103
+ When implementing navigation in Angular, consult the following references:
104
+
105
+ - **Define Routes**: URL paths, static vs dynamic segments, wildcards, and redirects. Read [define-routes.md](references/define-routes.md)
106
+ - **Route Loading Strategies**: Eager vs lazy loading, and context-aware loading. Read [loading-strategies.md](references/loading-strategies.md)
107
+ - **Show Routes with Outlets**: Using `<router-outlet>`, nested outlets, and named outlets. Read [show-routes-with-outlets.md](references/show-routes-with-outlets.md)
108
+ - **Navigate to Routes**: Declarative navigation with `RouterLink` and programmatic navigation with `Router`. Read [navigate-to-routes.md](references/navigate-to-routes.md)
109
+ - **Control Route Access with Guards**: Implementing `CanActivate`, `CanMatch`, and other guards for security. Read [route-guards.md](references/route-guards.md)
110
+ - **Data Resolvers**: Pre-fetching data before route activation with `ResolveFn`. Read [data-resolvers.md](references/data-resolvers.md)
111
+ - **Router Lifecycle and Events**: Chronological order of navigation events and debugging. Read [router-lifecycle.md](references/router-lifecycle.md)
112
+ - **Rendering Strategies**: CSR, SSG (Prerendering), and SSR with hydration. Read [rendering-strategies.md](references/rendering-strategies.md)
113
+ - **Route Transition Animations**: Enabling and customizing the View Transitions API. Read [route-animations.md](references/route-animations.md)
114
+
115
+ If you require deeper documentation or more context, visit the [official Angular Routing guide](https://angular.dev/guide/routing).
116
+
117
+ ## Styling and Animations
118
+
119
+ When implementing styling and animations in Angular, consult the following references:
120
+
121
+ - **Using Tailwind CSS with Angular**: Integrating Tailwind CSS into Angular projects. Read [tailwind-css.md](references/tailwind-css.md)
122
+ - **Angular Animations**: Using native CSS (recommended) or the legacy DSL for dynamic effects. Read [angular-animations.md](references/angular-animations.md)
123
+ - **Styling components**: Best practices for component styles and encapsulation. Read [component-styling.md](references/component-styling.md)
124
+
125
+ ## Testing
126
+
127
+ When writing or updating tests, consult the following references based on the task:
128
+
129
+ - **Fundamentals**: Best practices for unit testing, async patterns, and `TestBed`. Read [testing-fundamentals.md](references/testing-fundamentals.md)
130
+ - **Component Harnesses**: Standard patterns for robust component interaction. Read [component-harnesses.md](references/component-harnesses.md)
131
+ - **Router Testing**: Using `RouterTestingHarness` for reliable navigation tests. Read [router-testing.md](references/router-testing.md)
132
+ - **End-to-End (E2E) Testing**: Best practices for E2E tests with Cypress or Playwright. Read [e2e-testing.md](references/e2e-testing.md)
133
+
134
+ ## Tooling
135
+
136
+ When working with Angular tooling, consult the following references:
137
+
138
+ - **Angular CLI**: Creating applications, generating code (components, routes, services), serving, and building. Read [cli.md](references/cli.md)
139
+ - **Angular MCP Server**: Available tools, configuration, and experimental features. Read [mcp.md](references/mcp.md)
140
+
141
+ ## Anti-Patterns
142
+
143
+ - Using `null` or `undefined` as initial signal form field values — use `''`, `0`, or `[]` instead
144
+ - Accessing form field state flags without calling the field first: `form.field.valid()` — use `form.field().valid()`
145
+ - Starting new forms with older form APIs when the target Angular version supports Signal Forms
146
+ - Setting `min`, `max`, `value`, `disabled`, or `readonly` HTML attributes on `[formField]` inputs — define these as schema rules instead
147
+ - Calling `inject()` outside an injection context — use `runInInjectionContext` when needed
148
+ - Using `effect()` for derived state that should use `computed()`
149
+ - Referencing `$parent.$index` in nested `@for` loops — Angular does not support `$parent`; use `let outerIdx = $index` instead
150
+
151
+ ## Related Skills
152
+
153
+ - `tdd-workflow` — test-driven development workflow applicable to Angular components and services
154
+ - `security-review` — security checklist for web applications including Angular-specific concerns
155
+ - `frontend-patterns` — general frontend patterns for context on React/Next.js approaches
@@ -0,0 +1,121 @@
1
+ ---
2
+ name: api-connector-builder
3
+ description: Build a new API connector or provider by matching the target repo's existing integration pattern exactly. Use when adding one more integration without inventing a second architecture.
4
+ metadata:
5
+ version: "1.0.0"
6
+ origin: ECC direct-port adaptation
7
+ ---
8
+
9
+ # API Connector Builder
10
+
11
+ Use this when the job is to add a repo-native integration surface, not just a generic HTTP client.
12
+
13
+ The point is to match the host repository's pattern:
14
+
15
+ - connector layout
16
+ - config schema
17
+ - auth model
18
+ - error handling
19
+ - test style
20
+ - registration/discovery wiring
21
+
22
+ ## When to Use
23
+
24
+ - "Build a Jira connector for this project"
25
+ - "Add a Slack provider following the existing pattern"
26
+ - "Create a new integration for this API"
27
+ - "Build a plugin that matches the repo's connector style"
28
+
29
+ ## Guardrails
30
+
31
+ - do not invent a new integration architecture when the repo already has one
32
+ - do not start from vendor docs alone; start from existing in-repo connectors first
33
+ - do not stop at transport code if the repo expects registry wiring, tests, and docs
34
+ - do not cargo-cult old connectors if the repo has a newer current pattern
35
+
36
+ ## Workflow
37
+
38
+ ### 1. Learn the house style
39
+
40
+ Inspect at least 2 existing connectors/providers and map:
41
+
42
+ - file layout
43
+ - abstraction boundaries
44
+ - config model
45
+ - retry / pagination conventions
46
+ - registry hooks
47
+ - test fixtures and naming
48
+
49
+ ### 2. Narrow the target integration
50
+
51
+ Define only the surface the repo actually needs:
52
+
53
+ - auth flow
54
+ - key entities
55
+ - core read/write operations
56
+ - pagination and rate limits
57
+ - webhook or polling model
58
+
59
+ ### 3. Build in repo-native layers
60
+
61
+ Typical slices:
62
+
63
+ - config/schema
64
+ - client/transport
65
+ - mapping layer
66
+ - connector/provider entrypoint
67
+ - registration
68
+ - tests
69
+
70
+ ### 4. Validate against the source pattern
71
+
72
+ The new connector should look obvious in the codebase, not imported from a different ecosystem.
73
+
74
+ ## Reference Shapes
75
+
76
+ ### Provider-style
77
+
78
+ ```text
79
+ providers/
80
+ existing_provider/
81
+ __init__.py
82
+ provider.py
83
+ config.py
84
+ ```
85
+
86
+ ### Connector-style
87
+
88
+ ```text
89
+ integrations/
90
+ existing/
91
+ client.py
92
+ models.py
93
+ connector.py
94
+ ```
95
+
96
+ ### TypeScript plugin-style
97
+
98
+ ```text
99
+ src/integrations/
100
+ existing/
101
+ index.ts
102
+ client.ts
103
+ types.ts
104
+ test.ts
105
+ ```
106
+
107
+ ## Quality Checklist
108
+
109
+ - [ ] matches an existing in-repo integration pattern
110
+ - [ ] config validation exists
111
+ - [ ] auth and error handling are explicit
112
+ - [ ] pagination/retry behavior follows repo norms
113
+ - [ ] registry/discovery wiring is complete
114
+ - [ ] tests mirror the host repo's style
115
+ - [ ] docs/examples are updated if expected by the repo
116
+
117
+ ## Related Skills
118
+
119
+ - `backend-patterns`
120
+ - `mcp-server-patterns`
121
+ - `github-ops`