Audit and improve web accessibility following WCAG 2.1 guidelines. Use when asked to "improve accessibility", "a11y audit", "WCAG compliance", "screen reader support", "keyboard navigation", or "make accessible".
中文简介正在准备中。当前显示原文说明。
Implement structured logging with JSON formats, log levels (DEBUG, INFO, WARN, ERROR), contextual logging, PII handling, and centralized logging. Use for logging, observability, log levels, structured logs, or debugging.
中文简介正在准备中。当前显示原文说明。
查看安装方法安装前可以查看交给 AI 代理的指令内容。
Comprehensive guide to implementing structured, secure, and performant logging across applications. Covers log levels, structured logging formats, contextual information, PII protection, and centralized logging systems.
After reading the methodology below, read the reference matching your surface's Languages column:
| Language | Reference |
|---|---|
| TypeScript / JavaScript | references/typescript.md |
| Python | references/python.md |
| Go | references/go.md |
| Level | When to Use | Production Default |
|---|---|---|
| DEBUG | Detailed info for debugging — request payloads, intermediate values | OFF |
| INFO | General operational events — user actions, transactions, startup | ON |
| WARN | Potentially harmful — rate limits approaching, retry, deprecations | ON |
| ERROR | Failures the app can recover from — failed request, DB timeout | ON |
| FATAL | Critical failures — the app must stop | ON (triggers alerts) |
Environment rules:
All production logs MUST be structured (JSON format), not free-text. Structured logs enable:
Every log entry must include:
timestamp — ISO 8601 formatlevel — log level stringmessage — human-readable descriptionservice — service nameenvironment — deployment environmentExample output (any language):
{
"timestamp": "2024-01-15T10:30:00.000Z",
"level": "INFO",
"message": "User created",
"service": "user-service",
"environment": "production",
"userId": "abc-123",
"requestId": "req-456"
}
Attach request metadata to every log within a request lifecycle:
In distributed systems, propagate a correlation ID via headers (X-Correlation-Id) so that logs from multiple services can be traced together.
CRITICAL: PII must NEVER appear in plaintext in logs.
| Strategy | When to Use |
|---|---|
Redaction — replace with [REDACTED] | Passwords, API keys, tokens |
Masking — partial reveal (u***r@example.com) | Email, phone, credit card |
| Hashing — one-way hash | When you need to correlate without revealing |
| Omission — don't log the field at all | When the field serves no diagnostic purpose |
Track operation timing for performance monitoring:
Key operations to time:
For distributed systems, aggregate logs to a central system:
| Tool | Type |
|---|---|
| ELK Stack | Elasticsearch + Logstash + Kibana (self-hosted) |
| Grafana + Loki | Lightweight log aggregation (self-hosted) |
| Datadog | Cloud monitoring and logging |
| AWS CloudWatch | AWS-native log management |
| Splunk | Enterprise log management |
For microservice architectures, use OpenTelemetry (or similar) to trace requests across services:
For high-volume services, sample INFO/DEBUG logs to reduce volume:
还没有评价。欢迎分享你的使用感受。
无需登录即可发表。欢迎分享使用感受、提问,或说明在哪些环境下无法运行。
还没有评论。来写第一条吧。
Audit and improve web accessibility following WCAG 2.1 guidelines. Use when asked to "improve accessibility", "a11y audit", "WCAG compliance", "screen reader support", "keyboard navigation", or "make accessible".
中文简介正在准备中。当前显示原文说明。
Structured methodology for adversarial thinking — generating attack scenarios, abuse cases, race conditions, and security edge cases against specs and implementations. Produces spec-level gap items, not code-level fixes.
中文简介正在准备中。当前显示原文说明。
Orchestrate multiple Antigravity skills through guided workflows for SaaS MVP delivery, security audits, AI agent builds, and browser QA.
中文简介正在准备中。当前显示原文说明。
Master REST and GraphQL API design principles to build intuitive, scalable, and maintainable APIs that delight developers. Use when designing new APIs, reviewing API specifications, or establishing API design standards.
中文简介正在准备中。当前显示原文说明。
Manage API versioning and evolution with URL/header/query strategies, deprecation workflows, breaking change classification, sunset headers, and consumer-driven contract testing. Use when designing versioning strategy, deprecating endpoints, or evolving API contracts.
中文简介正在准备中。当前显示原文说明。
Analyzes codebase structure, data flow, module relationships, and key patterns to generate and maintain a living architecture document (ARCHITECTURE.md).
中文简介正在准备中。当前显示原文说明。