[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"skill:01M6JKVDEGG6G5RJ34VE8V5SW1":3,"skill-same:01M6JKVDEGG6G5RJ34VE8V5SW1":95},{"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":30,"linkOnly":31,"markdownContent":32,"markdownBody":33,"frontMatter":34,"refName":38,"commitSha":39,"skillDirectory":40,"forksCount":41,"repositoryHtmlUrl":42,"repositoryHomepageUrl":43,"ownerHtmlUrl":44,"ownerBlogUrl":45,"ownerDescription":6,"updatedAt":46,"install":47,"resources":60},"01M6JKVDEGG6G5RJ34VE8V5SW1","logging-best-practices",null,"Logging best practices focused on wide events (canonical log lines) for powerful debugging and analytics","LongLeo287\u002FOmniClaw","LongLeo287","https:\u002F\u002Favatars.githubusercontent.com\u002Fu\u002F141803367?v=4","01M6JK75C62VCNZKR5BRZ386YV","LongLeo","01M6JK75GQ78TSP1ZPXNKK3MCH",9,"MIT","https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FOmniClaw\u002Fblob\u002Fmain\u002Fecosystem\u002Fskills\u002Fagent_skills\u002Fskills\u002Flogging_best_practices\u002FSKILL.md",[],[19,20,21,22,23,24,25,26,27,28,29],"best practices","logging","logging best practices","analytics","debugging","log","wide events","events","canonical","wide","for","2026-11-10 10:12:30",false,"---\nname: logging-best-practices\ndescription: Logging best practices focused on wide events (canonical log lines) for powerful debugging and analytics\nlicense: MIT\nmetadata:\n  author: boristane\n  version: \"1.0.0\"\n---\n\n# Logging Best Practices Skill\n\nVersion: 1.0.0\n\n## Purpose\n\nThis skill provides guidelines for implementing effective logging in applications. It focuses on **wide events** (also called canonical log lines) - a pattern where you emit a single, context-rich event per request per service, enabling powerful debugging and analytics.\n\n## When to Apply\n\nApply these guidelines when:\n- Writing or reviewing logging code\n- Adding console.log, logger.info, or similar\n- Designing logging strategy for new services\n- Setting up logging infrastructure\n\n## Core Principles\n\n### 1. Wide Events (CRITICAL)\n\nEmit **one context-rich event per request per service**. Instead of scattering log lines throughout your handler, consolidate everything into a single structured event emitted at request completion.\n\n```typescript\nconst wideEvent: Record\u003Cstring, unknown> = {\n  method: 'POST',\n  path: '\u002Fcheckout',\n  requestId: c.get('requestId'),\n  timestamp: new Date().toISOString(),\n};\n\ntry {\n  const user = await getUser(c.get('userId'));\n  wideEvent.user = { id: user.id, subscription: user.subscription };\n\n  const cart = await getCart(user.id);\n  wideEvent.cart = { total_cents: cart.total, item_count: cart.items.length };\n\n  wideEvent.status_code = 200;\n  wideEvent.outcome = 'success';\n  return c.json({ success: true });\n} catch (error) {\n  wideEvent.status_code = 500;\n  wideEvent.outcome = 'error';\n  wideEvent.error = { message: error.message, type: error.name };\n  throw error;\n} finally {\n  wideEvent.duration_ms = Date.now() - startTime;\n  logger.info(wideEvent);\n}\n```\n\n### 2. High Cardinality & Dimensionality (CRITICAL)\n\nInclude fields with high cardinality (user IDs, request IDs - millions of unique values) and high dimensionality (many fields per event). This enables querying by specific users and answering questions you haven't anticipated yet.\n\n### 3. Business Context (CRITICAL)\n\nAlways include business context: user subscription tier, cart value, feature flags, account age. The goal is to know \"a premium customer couldn't complete a $2,499 purchase\" not just \"checkout failed.\"\n\n### 4. Environment Characteristics (CRITICAL)\n\nInclude environment and deployment info in every event: commit hash, service version, region, instance ID. This enables correlating issues with deployments and identifying region-specific problems.\n\n### 5. Single Logger (HIGH)\n\nUse one logger instance configured at startup and import it everywhere. This ensures consistent formatting and automatic environment context.\n\n### 6. Middleware Pattern (HIGH)\n\nUse middleware to handle wide event infrastructure (timing, status, environment, emission). Handlers should only add business context.\n\n### 7. Structure & Consistency (HIGH)\n\n- Use JSON format consistently\n- Maintain consistent field names across services\n- Simplify to two log levels: `info` and `error`\n- Never log unstructured strings\n\n## Anti-Patterns to Avoid\n\n1. **Scattered logs**: Multiple console.log() calls per request\n2. **Multiple loggers**: Different logger instances in different files\n3. **Missing environment context**: No commit hash or deployment info\n4. **Missing business context**: Logging technical details without user\u002Fbusiness data\n5. **Unstructured strings**: `console.log('something happened')` instead of structured data\n6. **Inconsistent schemas**: Different field names across services\n\n## Guidelines\n\n### Wide Events (`rules\u002Fwide-events.md`)\n- Emit one wide event per service hop\n- Include all relevant context\n- Connect events with request ID\n- Emit at request completion in finally block\n\n### Context (`rules\u002Fcontext.md`)\n- Support high cardinality fields (user_id, request_id)\n- Include high dimensionality (many fields)\n- Always include business context\n- Always include environment characteristics (commit_hash, version, region)\n\n### Structure (`rules\u002Fstructure.md`)\n- Use a single logger throughout the codebase\n- Use middleware for consistent wide events\n- Use JSON format\n- Maintain consistent schema\n- Simplify to info and error levels\n- Never log unstructured strings\n\n### Common Pitfalls (`rules\u002Fpitfalls.md`)\n- Avoid multiple log lines per request\n- Design for unknown unknowns\n- Always propagate request IDs across services\n\nReferences:\n- [Logging Sucks](https:\u002F\u002Floggingsucks.com)\n- [Observability Wide Events 101](https:\u002F\u002Fboristane.com\u002Fblog\u002Fobservability-wide-events-101\u002F)\n- [Stripe - Canonical Log Lines](https:\u002F\u002Fstripe.com\u002Fblog\u002Fcanonical-log-lines)\n","# Logging Best Practices Skill\n\nVersion: 1.0.0\n\n## Purpose\n\nThis skill provides guidelines for implementing effective logging in applications. It focuses on **wide events** (also called canonical log lines) - a pattern where you emit a single, context-rich event per request per service, enabling powerful debugging and analytics.\n\n## When to Apply\n\nApply these guidelines when:\n- Writing or reviewing logging code\n- Adding console.log, logger.info, or similar\n- Designing logging strategy for new services\n- Setting up logging infrastructure\n\n## Core Principles\n\n### 1. Wide Events (CRITICAL)\n\nEmit **one context-rich event per request per service**. Instead of scattering log lines throughout your handler, consolidate everything into a single structured event emitted at request completion.\n\n```typescript\nconst wideEvent: Record\u003Cstring, unknown> = {\n  method: 'POST',\n  path: '\u002Fcheckout',\n  requestId: c.get('requestId'),\n  timestamp: new Date().toISOString(),\n};\n\ntry {\n  const user = await getUser(c.get('userId'));\n  wideEvent.user = { id: user.id, subscription: user.subscription };\n\n  const cart = await getCart(user.id);\n  wideEvent.cart = { total_cents: cart.total, item_count: cart.items.length };\n\n  wideEvent.status_code = 200;\n  wideEvent.outcome = 'success';\n  return c.json({ success: true });\n} catch (error) {\n  wideEvent.status_code = 500;\n  wideEvent.outcome = 'error';\n  wideEvent.error = { message: error.message, type: error.name };\n  throw error;\n} finally {\n  wideEvent.duration_ms = Date.now() - startTime;\n  logger.info(wideEvent);\n}\n```\n\n### 2. High Cardinality & Dimensionality (CRITICAL)\n\nInclude fields with high cardinality (user IDs, request IDs - millions of unique values) and high dimensionality (many fields per event). This enables querying by specific users and answering questions you haven't anticipated yet.\n\n### 3. Business Context (CRITICAL)\n\nAlways include business context: user subscription tier, cart value, feature flags, account age. The goal is to know \"a premium customer couldn't complete a $2,499 purchase\" not just \"checkout failed.\"\n\n### 4. Environment Characteristics (CRITICAL)\n\nInclude environment and deployment info in every event: commit hash, service version, region, instance ID. This enables correlating issues with deployments and identifying region-specific problems.\n\n### 5. Single Logger (HIGH)\n\nUse one logger instance configured at startup and import it everywhere. This ensures consistent formatting and automatic environment context.\n\n### 6. Middleware Pattern (HIGH)\n\nUse middleware to handle wide event infrastructure (timing, status, environment, emission). Handlers should only add business context.\n\n### 7. Structure & Consistency (HIGH)\n\n- Use JSON format consistently\n- Maintain consistent field names across services\n- Simplify to two log levels: `info` and `error`\n- Never log unstructured strings\n\n## Anti-Patterns to Avoid\n\n1. **Scattered logs**: Multiple console.log() calls per request\n2. **Multiple loggers**: Different logger instances in different files\n3. **Missing environment context**: No commit hash or deployment info\n4. **Missing business context**: Logging technical details without user\u002Fbusiness data\n5. **Unstructured strings**: `console.log('something happened')` instead of structured data\n6. **Inconsistent schemas**: Different field names across services\n\n## Guidelines\n\n### Wide Events (`rules\u002Fwide-events.md`)\n- Emit one wide event per service hop\n- Include all relevant context\n- Connect events with request ID\n- Emit at request completion in finally block\n\n### Context (`rules\u002Fcontext.md`)\n- Support high cardinality fields (user_id, request_id)\n- Include high dimensionality (many fields)\n- Always include business context\n- Always include environment characteristics (commit_hash, version, region)\n\n### Structure (`rules\u002Fstructure.md`)\n- Use a single logger throughout the codebase\n- Use middleware for consistent wide events\n- Use JSON format\n- Maintain consistent schema\n- Simplify to info and error levels\n- Never log unstructured strings\n\n### Common Pitfalls (`rules\u002Fpitfalls.md`)\n- Avoid multiple log lines per request\n- Design for unknown unknowns\n- Always propagate request IDs across services\n\nReferences:\n- [Logging Sucks](https:\u002F\u002Floggingsucks.com)\n- [Observability Wide Events 101](https:\u002F\u002Fboristane.com\u002Fblog\u002Fobservability-wide-events-101\u002F)\n- [Stripe - Canonical Log Lines](https:\u002F\u002Fstripe.com\u002Fblog\u002Fcanonical-log-lines)\n",{"name":5,"license":15,"metadata":35,"description":7},{"author":36,"version":37},"boristane","1.0.0","main","c173cdffe08e788a99b91928a831b476b8434838","ecosystem\u002Fskills\u002Fagent_skills\u002Fskills\u002Flogging_best_practices",0,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FOmniClaw","https:\u002F\u002Fportfolio-longleo.vercel.app\u002Flabs\u002Fomniclaw.html","https:\u002F\u002Fgithub.com\u002FLongLeo287","https:\u002F\u002Fwww.facebook.com\u002FResourceRookie2023","2026-11-14 08:48:28",{"source":8,"skillName":5,"commands":48,"prompt":58,"zipAvailable":59},[49,52,55],{"tool":50,"command":51},"npx","npx skills add LongLeo287\u002FOmniClaw --skill logging-best-practices",{"tool":53,"command":54},"bunx","bunx skills add LongLeo287\u002FOmniClaw --skill logging-best-practices",{"tool":56,"command":57},"pnpm","pnpm dlx skills add LongLeo287\u002FOmniClaw --skill logging-best-practices","安装技能，技能地址：https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FOmniClaw\u002Fblob\u002Fmain\u002Fecosystem\u002Fskills\u002Fagent_skills\u002Fskills\u002Flogging_best_practices\u002FSKILL.md",true,[61,67,71,75,79,83,87,91],{"path":62,"resourceType":63,"resourceTypeDesc":64,"sizeBytes":65,"sourceHtmlUrl":66},"_DIR_IDENTITY.md","REFERENCE","参考文档",383,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FOmniClaw\u002Fblob\u002Fmain\u002Fecosystem\u002Fskills\u002Fagent_skills\u002Fskills\u002Flogging_best_practices\u002F_DIR_IDENTITY.md",{"path":68,"resourceType":63,"resourceTypeDesc":64,"sizeBytes":69,"sourceHtmlUrl":70},"metadata.json",448,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FOmniClaw\u002Fblob\u002Fmain\u002Fecosystem\u002Fskills\u002Fagent_skills\u002Fskills\u002Flogging_best_practices\u002Fmetadata.json",{"path":72,"resourceType":63,"resourceTypeDesc":64,"sizeBytes":73,"sourceHtmlUrl":74},"README.md",2102,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FOmniClaw\u002Fblob\u002Fmain\u002Fecosystem\u002Fskills\u002Fagent_skills\u002Fskills\u002Flogging_best_practices\u002FREADME.md",{"path":76,"resourceType":63,"resourceTypeDesc":64,"sizeBytes":77,"sourceHtmlUrl":78},"rules\u002F_DIR_IDENTITY.md",344,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FOmniClaw\u002Fblob\u002Fmain\u002Fecosystem\u002Fskills\u002Fagent_skills\u002Fskills\u002Flogging_best_practices\u002Frules\u002F_DIR_IDENTITY.md",{"path":80,"resourceType":63,"resourceTypeDesc":64,"sizeBytes":81,"sourceHtmlUrl":82},"rules\u002Fcontext.md",4806,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FOmniClaw\u002Fblob\u002Fmain\u002Fecosystem\u002Fskills\u002Fagent_skills\u002Fskills\u002Flogging_best_practices\u002Frules\u002Fcontext.md",{"path":84,"resourceType":63,"resourceTypeDesc":64,"sizeBytes":85,"sourceHtmlUrl":86},"rules\u002Fpitfalls.md",3373,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FOmniClaw\u002Fblob\u002Fmain\u002Fecosystem\u002Fskills\u002Fagent_skills\u002Fskills\u002Flogging_best_practices\u002Frules\u002Fpitfalls.md",{"path":88,"resourceType":63,"resourceTypeDesc":64,"sizeBytes":89,"sourceHtmlUrl":90},"rules\u002Fstructure.md",5942,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FOmniClaw\u002Fblob\u002Fmain\u002Fecosystem\u002Fskills\u002Fagent_skills\u002Fskills\u002Flogging_best_practices\u002Frules\u002Fstructure.md",{"path":92,"resourceType":63,"resourceTypeDesc":64,"sizeBytes":93,"sourceHtmlUrl":94},"rules\u002Fwide_events.md",3629,"https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FOmniClaw\u002Fblob\u002Fmain\u002Fecosystem\u002Fskills\u002Fagent_skills\u002Fskills\u002Flogging_best_practices\u002Frules\u002Fwide_events.md",[96,123,142,167,183,206],{"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":30},"01M6JR0KQP4MHT32TN40D9CBFX","UI-UX Pro Max","Advanced UI\u002FUX analysis and generation skills with data-driven patterns. Python scripts (core.py, search.py) for systematic UI pattern extraction, design system generation, and component search from curated data sources.","https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FOmniClaw\u002Fblob\u002Fmain\u002Fecosystem\u002Fui_components\u002Fui_ux_pro_max\u002FSKILL.md",[],[103,104,105,106,107,108,109,110,111,112,113,114,115,116,117,118,119,120,121,122],"ux","ui","ui ux pro max","max","pro","ui ux","design","component","search","analysis","team","rd","ui-ux","active","systematic","scripts","pattern extraction","sources","advanced","data-driven",{"skillNo":124,"name":125,"nameZh":6,"description":126,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":127,"categories":128,"keywords":129,"publishedAt":30},"01M6JR0EF5AEQHP2FSTB57H05P","shadcn-ui","Expert guidance for integrating and building applications with shadcn\u002Fui components, including component discovery, installation, customization, and best practices.","https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FOmniClaw\u002Fblob\u002Fmain\u002Fecosystem\u002Fui_components\u002Fshadcn_ui\u002FSKILL.md",[],[130,104,131,132,110,133,19,134,135,113,136,137,138,116,139,140,141,29],"shadcn","shadcn ui","components","core","applications","discovery","customization","guidance","expert","installation","ui components","with",{"skillNo":143,"name":144,"nameZh":6,"description":145,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":146,"categories":147,"keywords":148,"publishedAt":30},"01M6JR08F51BEN17RHFYX65WVE","zustand_store_ts","Create Zustand stores with TypeScript, subscribeWithSelector middleware, and proper state\u002Faction separation. Use when building React state management, creating global stores, or implementing reactive state patterns with Zustand.","https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FOmniClaw\u002Fblob\u002Fmain\u002Fecosystem\u002Fskills\u002Fzustand_store_ts\u002FSKILL.md",[],[149,150,151,152,153,154,155,156,157,158,159,160,161,162,163,164,141,165,166],"zustand store ts","zustand","store","typescript","microsoft","react","create","state management","state","react state management","management","global","use","patterns","separation","middleware","action","implementing",{"skillNo":168,"name":150,"nameZh":6,"description":169,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":170,"categories":171,"keywords":172,"publishedAt":30},"01M6JR00TDMVAFFCZXZ04AN7Q7","Zustand state management guide. Use when working with store code (src\u002Fstore\u002F**), implementing actions, managing state, or creating slices. Triggers on Zustand store development, state management questions, or action implementation.","https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FOmniClaw\u002Fblob\u002Fmain\u002Fecosystem\u002Fskills\u002Fzustand\u002FSKILL.md",[],[150,173,156,174,157,175,176,159,177,161,178,179,180,151,141,181,182,165,166],"development","code","actions","src","guide","implementation","zustand state","triggers","questions","zustand state management",{"skillNo":184,"name":185,"nameZh":6,"description":186,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":187,"categories":188,"keywords":189,"publishedAt":30},"01M6JQZSWV4KWJP112G6XHEP44","youtube_summarizer","Automatically fetch YouTube video transcripts, generate structured summaries, and send full transcripts to messaging platforms. Detects YouTube URLs and provides metadata, key insights, and downloadable transcripts.","https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FOmniClaw\u002Fblob\u002Fmain\u002Fecosystem\u002Fskills\u002Fyoutube_summarizer\u002FSKILL.md",[],[190,191,192,193,194,195,196,197,198,199,200,201,202,203,204,205],"youtube","youtube summarizer","summarizer","generate","metadata","messaging","Video","fetch","telegram","transcription","summarization","structured","full","insights","transcripts","summaries",{"skillNo":207,"name":208,"nameZh":6,"description":209,"descriptionZh":6,"repositoryFullName":8,"ownerLogin":9,"ownerAvatarUrl":10,"ownerAccountNo":11,"ownerDisplayName":12,"repositoryNo":13,"starsCount":14,"licenseSpdxId":15,"licenseFileUrl":6,"sourceHtmlUrl":210,"categories":211,"keywords":212,"publishedAt":30},"01M6JQZN3QJB6B77JGKJD62DQT","youtube_clipper","YouTube 视频智能剪辑工具。下载视频和字幕，AI 分析生成精细章节（几分钟级别）， 用户选择片段后自动剪辑、翻译字幕为中英双语、烧录字幕到视频，并生成总结文案。 使用场景：当用户需要剪辑 YouTube 视频、生成短视频片段、制作双语字幕版本时。 关键词：视频剪辑、YouTube、字幕翻译、双语字幕、视频下载、clip video","https:\u002F\u002Fgithub.com\u002FLongLeo287\u002FOmniClaw\u002Fblob\u002Fmain\u002Fecosystem\u002Fskills\u002Fyoutube_clipper\u002FSKILL.md",[],[190,213,214,196,215,216,217,218,219,220,221,222,223,224,225,226,227],"clipper","youtube clipper","Bash","下载","视频","生成","关键词","翻译","read","write","clip","总结","工具","文案","sonnet"]