一键导入
loki-logs-analyzer
Analyze logs to investigate errors and exceptions
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
菜单
Analyze logs to investigate errors and exceptions
用 Codex 或 Claude 帮你安装 复制这段 Prompt,粘贴到 Codex、Claude 或其他助手里,让它检查 Skill 页面并帮你完成安装。
基于 SOC 职业分类
Detect code-improvement catalog violations in recent PR files and guide small stacked commits/branches.
Mentor for Exercism exercises: hints while solving, code review and improvement suggestions when asked. Use when solving Exercism challenges, mentions exercism-mode or exercism-mentor, or asks for help on https://exercism.org/tracks/typescript or any Exercism track.
Review pull requests using the tools available in the current environment. Works with GitHub or Bitbucket, MCP tools or CLI tools, and local git diffs. Produces actionable review findings, optional human-inspection callouts, and optional PR comments including both an overall review comment and inline file/line comments when posting is requested.
Create a concise, visual technical HTML walkthrough for a pull request by combining PR code changes with Specs/OpenSpec/design artifacts. Use when the user asks to explain what changed in a PR, generate a PR walkthrough, produce architecture/design documentation for a PR, summarize a spec-backed implementation, or create visual delta docs with Mermaid diagrams. Prefer this skill over a normal PR review when the user wants understanding, onboarding, or design explanation rather than defect findings.
Launch parallel agent sessions in the current cmux workspace from a list of input items. Use when the user wants to script cmux, keep the current pane on the left, create a right-side vertical stack with one pane per item, run Codex, Claude Code, Cursor Agent, or Rovo Dev over a list, trigger a custom skill or prompt for each item, or monitor parallel agent runs in cmux. If the user has not clearly specified an agent, ask which agent to use before spawning panes.
Break a feature definition markdown file into independently-grabbable OpenSpec changes organized by feature capability, then scaffold each one via OpenSpec Propose. Use when the user wants to convert a feature file into OpenSpec changes, create spec-driven change proposals from a feature definition, or split a medium/small feature into sequenced OpenSpec work items. Assume the feature file is passed as input; if it is not provided, ask the user for the feature file before proceeding.
| name | loki-logs-analyzer |
| description | Analyze logs to investigate errors and exceptions |
| Tool | Purpose |
|---|---|
mcp__loki__loki_label_names | List available Loki labels for scoping queries. |
mcp__loki__loki_label_values | Get values for a label, such as job, service, namespace, or container. |
mcp__loki__loki_query | Run a LogQL query over a time range and return matching log entries. |
{job="tribe-web-app"} |= "error"
{job="tribe-web-app"} |= "exception"
{job="tribe-web-app"} |~ "(?i)error|exception|failed|timeout|refused"
{job="tribe-web-app"} | json | level="error"
{job="tribe-web-app"} | json | request_id="<request_id>"
{job="tribe-web-app"} | json | route="/attendees/search" | status >= 400
Use |= for substring grep, |~ for regex grep, and | json when logs are structured JSON.
Find log labels — Use loki_label_names, then loki_label_values for likely scoping labels such as job, service, namespace, container, app, or pod.
Query recent errors — Use loki_query for the last 30 minutes unless the user specifies another range. Start with broad grep patterns like error, exception, failed, timeout, refused, and HTTP status strings such as 4, 5, status=4, or status_code.
Narrow the query — Add labels and structured filters for the affected service, route, endpoint, request ID, status code, user-visible error, or dependency name.
Correlate log entries — Group related messages by timestamp, request ID, route, dependency, and error message. Look for the first error in each request flow, not only the final failure response.
Explain the issue — Summarize the important log lines, the pattern they show, and the likely root cause. Include concrete timestamps, labels, routes, status codes, and request IDs when available.