[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M7B2YB59F3WAK91NE0VHM8M5":3,"skill-same:01M7B2YB59F3WAK91NE0VHM8M5":74},{"skillNo":4,"name":5,"nameZh":6,"description":7,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":16,"categories":17,"keywords":18,"publishedAt":19,"linkOnly":20,"markdownContent":21,"markdownBody":22,"frontMatter":23,"refName":25,"commitSha":26,"skillDirectory":27,"forksCount":28,"repositoryHtmlUrl":29,"repositoryHomepageUrl":6,"ownerHtmlUrl":30,"ownerBlogUrl":31,"ownerDescription":32,"updatedAt":33,"install":34,"resources":47},"01M7B2YB59F3WAK91NE0VHM8M5","hamster-analytics",null,"Analytics tracking patterns for Segment, Mixpanel, and user engagement metrics. Use when implementing event tracking, user properties, or engagement counters.","gethamster\u002Fskills","gethamster","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F215697643?v=4","01M7B2R6PGB3SDZZ71E0WE2S74","Hamster","01M7B2R6Q21HWJRXZZWB78BNDG",4,"MIT","https:\u002F\u002Fgithub.com\u002Fgethamster\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002F.experimental\u002Fhamster-analytics\u002FSKILL.md",[],[],"2026-11-15 14:19:17",false,"---\nname: hamster-analytics\ndescription: \"Analytics tracking patterns for Segment, Mixpanel, and user engagement metrics. Use when implementing event tracking, user properties, or engagement counters.\"\nversion: \"1.1.0\"\n---\n\n# Hamster Analytics Patterns\n\n## Quick Reference\n\n| Task | Pattern | Reference |\n| --- | --- | --- |\n| Track server event (NestJS) | `trackServerEvent('Event Name', props, userId)` | [server-tracking.md](references\u002Fserver-tracking.md) |\n| Track client event | `createAnalyticsTracker(analytics, context)` | [client-tracking.md](references\u002Fclient-tracking.md) |\n| Set account context | `analytics.setAccountId(accountId)` | [group-analytics.md](references\u002Fgroup-analytics.md) |\n| Update user properties | `identifyServerUser(userId, traits)` | [user-traits.md](references\u002Fuser-traits.md) |\n| Mark feature adoption | `UserTraitManager.markFeatureAdoption(userId, 'feature')` | [user-traits.md](references\u002Fuser-traits.md) |\n| Increment engagement | `UserTraitManager.incrementEngagementCounter(userId, 'counter', count)` | [user-traits.md](references\u002Fuser-traits.md) |\n\n## When to Apply\n\n- Adding event tracking to new features\n- Implementing user property updates\n- Adding feature adoption flags or engagement counters\n- Working with Mixpanel Group Analytics (account_id)\n- Implementing session replay privacy controls\n\n## Architecture Overview\n\n**Dual-mode system:**\n\n1. **Server-side** (NestJS): `trackServerEvent()` with `SEGMENT_WRITE_KEY`\n2. **Client-side** (Browser\u002FServer Actions): `createAnalyticsTracker()` with `NEXT_PUBLIC_SEGMENT_WRITE_KEY`\n\n```\n┌─────────────────────────────────────────────────────────────────┐\n│                    Analytics Architecture                        │\n├─────────────────────────────────────────────────────────────────┤\n│ NestJS Services\u002FAPI     →  trackServerEvent()    →  Segment     │\n│ Next.js Server Actions  →  createAnalyticsTracker() → Segment   │\n│ Client Components       →  createAnalyticsTracker() → Segment   │\n│                                                         ↓       │\n│                                                    Mixpanel     │\n│                                                    (+ Session   │\n│                                                     Replay)     │\n└─────────────────────────────────────────────────────────────────┘\n```\n\n## Critical Rules\n\n1. **Always include `account_id`** - Required for Mixpanel Group Analytics\n2. **Use snake_case** for property names: `account_id`, `user_id`, `brief_id`\n3. **Use Title Case** for event names: `'Brief Created'`, `'Task Completed'`\n4. **Never block operations** - Wrap analytics in try-catch\n5. **Add feature adoption** - New features need `has_used_*` flag + engagement counter\n\n## Key Patterns\n\n### Server-Side Tracking (NestJS)\n\n```typescript\nimport { trackServerEvent } from '@kit\u002Fanalytics';\n\ntrackServerEvent(\n  'Task Created',\n  {\n    task_id: task.id,\n    brief_id: briefId,\n    account_id: accountId,  \u002F\u002F REQUIRED for Group Analytics\n    user_id: userId,\n    creation_method: 'ai_generated',\n  },\n  userId,\n);\n```\n\n### Client\u002FServer Action Tracking\n\n```typescript\nimport { analytics, createAnalyticsTracker } from '@kit\u002Fanalytics';\n\nconst tracker = createAnalyticsTracker(analytics, {\n  user_id: user.id,\n  account_id: accountId,\n});\n\nawait tracker.trackBriefCreated({\n  brief_id: brief.id,\n  account_id: accountId,\n  has_initial_content: true,\n});\n```\n\n### New Feature Checklist\n\nWhen adding a new user-facing feature:\n\n- [ ] Add tracking event with `account_id`\n- [ ] Add `has_used_feature` boolean to UserProperties\n- [ ] Add `feature_usage_count` number to UserProperties\n- [ ] Add to `markFeatureAdoption()` union type\n- [ ] Add to `incrementEngagementCounter()` union type\n- [ ] Implement first-time detection\n- [ ] Track milestone event with `time_since_signup_hours`\n\n## References\n\n- [server-tracking.md](references\u002Fserver-tracking.md) - NestJS\u002FAPI tracking patterns\n- [client-tracking.md](references\u002Fclient-tracking.md) - Client and server action tracking\n- [group-analytics.md](references\u002Fgroup-analytics.md) - Mixpanel Group Analytics (account_id)\n- [session-replay.md](references\u002Fsession-replay.md) - Mixpanel Session Replay privacy\n- [user-traits.md](references\u002Fuser-traits.md) - Feature adoption and engagement counters\n- [event-catalog.md](references\u002Fevent-catalog.md) - Event dictionary and user properties\n\n## Key Files\n\n| File | Purpose |\n| --- | --- |\n| `packages\u002Fanalytics\u002Fsrc\u002Fevent-types.ts` | Event dictionary with TypeScript types |\n| `packages\u002Fanalytics\u002Fsrc\u002Fuser-properties.ts` | User trait definitions and enums |\n| `packages\u002Fanalytics\u002Fsrc\u002Fuser-trait-manager.ts` | Feature adoption and engagement |\n| `packages\u002Fanalytics\u002Fsrc\u002Fserver-analytics.ts` | Server-side tracking functions |\n| `packages\u002Fanalytics\u002Fsrc\u002Ftracking-utils.ts` | AnalyticsTracker class |\n","# Hamster Analytics Patterns\n\n## Quick Reference\n\n| Task | Pattern | Reference |\n| --- | --- | --- |\n| Track server event (NestJS) | `trackServerEvent('Event Name', props, userId)` | [server-tracking.md](references\u002Fserver-tracking.md) |\n| Track client event | `createAnalyticsTracker(analytics, context)` | [client-tracking.md](references\u002Fclient-tracking.md) |\n| Set account context | `analytics.setAccountId(accountId)` | [group-analytics.md](references\u002Fgroup-analytics.md) |\n| Update user properties | `identifyServerUser(userId, traits)` | [user-traits.md](references\u002Fuser-traits.md) |\n| Mark feature adoption | `UserTraitManager.markFeatureAdoption(userId, 'feature')` | [user-traits.md](references\u002Fuser-traits.md) |\n| Increment engagement | `UserTraitManager.incrementEngagementCounter(userId, 'counter', count)` | [user-traits.md](references\u002Fuser-traits.md) |\n\n## When to Apply\n\n- Adding event tracking to new features\n- Implementing user property updates\n- Adding feature adoption flags or engagement counters\n- Working with Mixpanel Group Analytics (account_id)\n- Implementing session replay privacy controls\n\n## Architecture Overview\n\n**Dual-mode system:**\n\n1. **Server-side** (NestJS): `trackServerEvent()` with `SEGMENT_WRITE_KEY`\n2. **Client-side** (Browser\u002FServer Actions): `createAnalyticsTracker()` with `NEXT_PUBLIC_SEGMENT_WRITE_KEY`\n\n```\n┌─────────────────────────────────────────────────────────────────┐\n│                    Analytics Architecture                        │\n├─────────────────────────────────────────────────────────────────┤\n│ NestJS Services\u002FAPI     →  trackServerEvent()    →  Segment     │\n│ Next.js Server Actions  →  createAnalyticsTracker() → Segment   │\n│ Client Components       →  createAnalyticsTracker() → Segment   │\n│                                                         ↓       │\n│                                                    Mixpanel     │\n│                                                    (+ Session   │\n│                                                     Replay)     │\n└─────────────────────────────────────────────────────────────────┘\n```\n\n## Critical Rules\n\n1. **Always include `account_id`** - Required for Mixpanel Group Analytics\n2. **Use snake_case** for property names: `account_id`, `user_id`, `brief_id`\n3. **Use Title Case** for event names: `'Brief Created'`, `'Task Completed'`\n4. **Never block operations** - Wrap analytics in try-catch\n5. **Add feature adoption** - New features need `has_used_*` flag + engagement counter\n\n## Key Patterns\n\n### Server-Side Tracking (NestJS)\n\n```typescript\nimport { trackServerEvent } from '@kit\u002Fanalytics';\n\ntrackServerEvent(\n  'Task Created',\n  {\n    task_id: task.id,\n    brief_id: briefId,\n    account_id: accountId,  \u002F\u002F REQUIRED for Group Analytics\n    user_id: userId,\n    creation_method: 'ai_generated',\n  },\n  userId,\n);\n```\n\n### Client\u002FServer Action Tracking\n\n```typescript\nimport { analytics, createAnalyticsTracker } from '@kit\u002Fanalytics';\n\nconst tracker = createAnalyticsTracker(analytics, {\n  user_id: user.id,\n  account_id: accountId,\n});\n\nawait tracker.trackBriefCreated({\n  brief_id: brief.id,\n  account_id: accountId,\n  has_initial_content: true,\n});\n```\n\n### New Feature Checklist\n\nWhen adding a new user-facing feature:\n\n- [ ] Add tracking event with `account_id`\n- [ ] Add `has_used_feature` boolean to UserProperties\n- [ ] Add `feature_usage_count` number to UserProperties\n- [ ] Add to `markFeatureAdoption()` union type\n- [ ] Add to `incrementEngagementCounter()` union type\n- [ ] Implement first-time detection\n- [ ] Track milestone event with `time_since_signup_hours`\n\n## References\n\n- [server-tracking.md](references\u002Fserver-tracking.md) - NestJS\u002FAPI tracking patterns\n- [client-tracking.md](references\u002Fclient-tracking.md) - Client and server action tracking\n- [group-analytics.md](references\u002Fgroup-analytics.md) - Mixpanel Group Analytics (account_id)\n- [session-replay.md](references\u002Fsession-replay.md) - Mixpanel Session Replay privacy\n- [user-traits.md](references\u002Fuser-traits.md) - Feature adoption and engagement counters\n- [event-catalog.md](references\u002Fevent-catalog.md) - Event dictionary and user properties\n\n## Key Files\n\n| File | Purpose |\n| --- | --- |\n| `packages\u002Fanalytics\u002Fsrc\u002Fevent-types.ts` | Event dictionary with TypeScript types |\n| `packages\u002Fanalytics\u002Fsrc\u002Fuser-properties.ts` | User trait definitions and enums |\n| `packages\u002Fanalytics\u002Fsrc\u002Fuser-trait-manager.ts` | Feature adoption and engagement |\n| `packages\u002Fanalytics\u002Fsrc\u002Fserver-analytics.ts` | Server-side tracking functions |\n| `packages\u002Fanalytics\u002Fsrc\u002Ftracking-utils.ts` | AnalyticsTracker class |\n",{"name":5,"version":24,"description":7},"1.1.0","main","fe3bb1476c3ec23d8a366eac0fa8cd9f0852360a","skills\u002F.experimental\u002Fhamster-analytics",0,"https:\u002F\u002Fgithub.com\u002Fgethamster\u002Fskills","https:\u002F\u002Fgithub.com\u002Fgethamster","https:\u002F\u002Ftryhamster.com","We're building the AI-native future of work, unlocking the promised acceleration for your whole team, from idea to impact.","2026-11-05 11:33:33",{"source":8,"skillName":5,"commands":35,"prompt":45,"zipAvailable":46},[36,39,42],{"tool":37,"command":38},"npx","npx skills add gethamster\u002Fskills --skill hamster-analytics",{"tool":40,"command":41},"bunx","bunx skills add gethamster\u002Fskills --skill hamster-analytics",{"tool":43,"command":44},"pnpm","pnpm dlx skills add gethamster\u002Fskills --skill hamster-analytics","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002Fgethamster\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002F.experimental\u002Fhamster-analytics\u002FSKILL.md",true,[48,54,58,62,66,70],{"path":49,"resourceType":50,"resourceTypeDesc":51,"sizeBytes":52,"sourceHtmlUrl":53},"references\u002Fclient-tracking.md","REFERENCE","参考文档",5601,"https:\u002F\u002Fgithub.com\u002Fgethamster\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002F.experimental\u002Fhamster-analytics\u002Freferences\u002Fclient-tracking.md",{"path":55,"resourceType":50,"resourceTypeDesc":51,"sizeBytes":56,"sourceHtmlUrl":57},"references\u002Fevent-catalog.md",6651,"https:\u002F\u002Fgithub.com\u002Fgethamster\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002F.experimental\u002Fhamster-analytics\u002Freferences\u002Fevent-catalog.md",{"path":59,"resourceType":50,"resourceTypeDesc":51,"sizeBytes":60,"sourceHtmlUrl":61},"references\u002Fgroup-analytics.md",5365,"https:\u002F\u002Fgithub.com\u002Fgethamster\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002F.experimental\u002Fhamster-analytics\u002Freferences\u002Fgroup-analytics.md",{"path":63,"resourceType":50,"resourceTypeDesc":51,"sizeBytes":64,"sourceHtmlUrl":65},"references\u002Fserver-tracking.md",4361,"https:\u002F\u002Fgithub.com\u002Fgethamster\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002F.experimental\u002Fhamster-analytics\u002Freferences\u002Fserver-tracking.md",{"path":67,"resourceType":50,"resourceTypeDesc":51,"sizeBytes":68,"sourceHtmlUrl":69},"references\u002Fsession-replay.md",4482,"https:\u002F\u002Fgithub.com\u002Fgethamster\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002F.experimental\u002Fhamster-analytics\u002Freferences\u002Fsession-replay.md",{"path":71,"resourceType":50,"resourceTypeDesc":51,"sizeBytes":72,"sourceHtmlUrl":73},"references\u002Fuser-traits.md",6180,"https:\u002F\u002Fgithub.com\u002Fgethamster\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002F.experimental\u002Fhamster-analytics\u002Freferences\u002Fuser-traits.md",[75,82,89,96,103,110],{"skillNo":76,"name":77,"nameZh":6,"description":78,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":79,"categories":80,"keywords":81,"publishedAt":19},"01M7B5MWYW0KE251276S56KQDZ","writing-waterfall-requirements-documents","Write a waterfall requirements document: elicit, structure and review testable, traceable requirements, then baseline the specification before design.","https:\u002F\u002Fgithub.com\u002Fgethamster\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fwriting-waterfall-requirements-documents\u002FSKILL.md",[],[],{"skillNo":83,"name":84,"nameZh":6,"description":85,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":86,"categories":87,"keywords":88,"publishedAt":19},"01M7B5MRCXWWPKREPB1CHQ7H90","writing-vision-and-values-statements","Write a V2MOM vision a reader can test and a ranked list of values that settles real tradeoffs, so the rest of the document has a clear anchor.","https:\u002F\u002Fgithub.com\u002Fgethamster\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fwriting-vision-and-values-statements\u002FSKILL.md",[],[],{"skillNo":90,"name":91,"nameZh":6,"description":92,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":93,"categories":94,"keywords":95,"publishedAt":19},"01M7B5MKH2CH22YZAHQW3080VQ","writing-system-prompts-for-claude","Write Claude prompts and CLAUDE.md files that supply exact inputs, scope the task, and define done so the first attempt can be checked.","https:\u002F\u002Fgithub.com\u002Fgethamster\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fwriting-system-prompts-for-claude\u002FSKILL.md",[],[],{"skillNo":97,"name":98,"nameZh":6,"description":99,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":100,"categories":101,"keywords":102,"publishedAt":19},"01M7B5ME1Y3X9RNRKP5HKHKACZ","writing-page-specific-website-copy","Website copywriting by page type: write homepage, landing page, pricing page and feature page copy that fits each page's visitor and single job.","https:\u002F\u002Fgithub.com\u002Fgethamster\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fwriting-page-specific-website-copy\u002FSKILL.md",[],[],{"skillNo":104,"name":105,"nameZh":6,"description":106,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":107,"categories":108,"keywords":109,"publishedAt":19},"01M7B5M8MQNM8MN8PYH6BVWJ2B","writing-internal-press-releases","How to write an internal press release: the one-page working backwards press release that opens a PR\u002FFAQ document before anything is built.","https:\u002F\u002Fgithub.com\u002Fgethamster\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fwriting-internal-press-releases\u002FSKILL.md",[],[],{"skillNo":111,"name":112,"nameZh":6,"description":113,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":114,"categories":115,"keywords":116,"publishedAt":19},"01M7B5M3P3YH1XF37R8PWXXSBK","writing-email-sequences-that-sell","Email sequence copywriting for nurture and sales: give each email one job, write clear subject lines, and close with one specific call to action.","https:\u002F\u002Fgithub.com\u002Fgethamster\u002Fskills\u002Fblob\u002Fmain\u002Fskills\u002Fwriting-email-sequences-that-sell\u002FSKILL.md",[],[]]