“日志分析助手 — 智能解析日志文件,识别异常模式,定位问题根因”

— description from SKILL.md by laolaoshiren
MITAuto-check passedBackend & APIs

Install Log Analyzer

skills CLI
$ npx skills add laolaoshiren/claude-code-skills-zh --skill log-analyzer -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install laolaoshiren/claude-code-skills-zh log-analyzer --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/laolaoshiren/claude-code-skills-zh.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/log-analyzer .claude/skills/log-analyzer && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
log-analyzer
GitHub stars
880
Token cost
~355 tokens
SKILL.md length
87 words
Files
1
Skills in repo
19
Repo updated
First seen
Licence
MIT

At a glance

  • Works in 5 steps: 日志格式识别 → 日志预处理 → 异常模式检测 → …
  • SKILL.md covers 触发条件, 工作流程, 支持的日志来源 and 注意事项
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md

About this skill

Log Analyzer is a skill in laolaoshiren/claude-code-skills-zh (880 stars). Its SKILL.md is about 355 tokens. Licence: MIT.

Workflow steps

5 steps, taken from the step headings in SKILL.md.

  1. 日志格式识别
  2. 日志预处理
  3. 异常模式检测
  4. 关键信息提取
  5. 生成分析报告

What it can do on your machine

Read from SKILL.md and the folder at commit 633f21c. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are markdown).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    No URLs in SKILL.md.

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Log Analyzer loads about 355 tokens when it runs. Until then it costs about 11 tokens; SKILL.md has 87 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~11
When it runs · the whole SKILL.md, loaded when a task matches
~355

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from laolaoshiren/claude-code-skills-zh at commit 633f21c, republished under its MIT licence (© laolaoshiren). 87 words, ~355 tokens.

Download SKILL.mdSave it as .claude/skills/log-analyzer/SKILL.md (or your agent's skills folder).
name
log-analyzer
description
日志分析助手 — 智能解析日志文件,识别异常模式,定位问题根因

📋 log-analyzer — 日志分析助手

触发条件

当用户要求以下操作时激活此技能:

  • 分析应用日志文件(.log, .txt, journalctl 输出等)
  • 排查线上问题和异常
  • 从日志中提取统计信息
  • 生成日志分析报告

工作流程

1. 日志格式识别

自动检测日志格式:

  • 结构化: JSON logs, Logfmt
  • 常见格式: Nginx/Apache access log, Spring Boot, Django, Rails
  • 系统日志: syslog, journalctl, Windows Event Log
  • 自定义格式: 根据正则提取字段
2. 日志预处理
  • 按时间范围过滤(如「最近 1 小时」「今天」)
  • 按日志级别筛选(ERROR, WARN, INFO, DEBUG)
  • 按来源/模块/服务过滤
  • 去重和聚合相似错误
3. 异常模式检测
  • 错误聚类: 将相似错误归为一组,避免重复分析
  • 频率分析: 识别高频错误和突发异常
  • 时间关联: 发现错误是否与特定事件(部署、流量高峰)相关
  • 因果链追踪: 从根因错误到最终表现
4. 关键信息提取
  • 错误堆栈分析(定位源码位置)
  • HTTP 状态码分布(4xx/5xx 比例)
  • 响应时间统计(P50/P95/P99)
  • 内存/CPU 异常指标
5. 生成分析报告
markdown
## 📊 日志分析报告

### 概览
- 时间范围: 2024-01-15 10:00 ~ 12:00
- 总日志量: 12,847 条
- 错误数: 234 (1.8%)
- 警告数: 567 (4.4%)

### Top 5 异常
| 排名 | 错误类型 | 次数 | 首次出现 | 最近出现 |
|------|---------|------|---------|---------|
| 1 | NullPointerException | 89 | 10:15 | 11:42 |
| 2 | ConnectionTimeout | 67 | 10:23 | 11:58 |

### 根因分析
最可能的原因:数据库连接池耗尽(线索:连续出现 ConnectionTimeout 后跟大量 NullPointerException)

### 建议
1. 检查数据库连接池配置(当前可能 maxActive 太小)
2. 排查是否存在连接泄漏
3. 添加连接池监控告警

支持的日志来源

  • 文件系统日志(*.log)
  • Docker/Kubernetes 容器日志
  • journalctl 系统日志
  • AWS CloudWatch / GCP Logging
  • ELK Stack (Elasticsearch 查询结果)
  • 应用直接输出的文本

注意事项

  • 敏感信息脱敏(密码、token、手机号等)
  • 大文件分块处理,避免内存溢出
  • 时区统一处理
  • 不要臆造日志中不存在的信息

© laolaoshiren, MIT. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in skills/log-analyzer of laolaoshiren/claude-code-skills-zh.

Open the folder on GitHubat commit 633f21c

Compare with similar skills

Log Analyzer next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Log Analyzer compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Log Analyzer this skilllaolaoshiren/claude-code-skills-zh880—~355Automated safety check: PassMIT
Mintlify APImacro-inc/macro4.6k2 repos~333Automated safety check: PassMIT
Rtvi Vlm Perf TestingNVIDIA-AI-Blueprints/video-search-and-summarization1.9k—~8.6kAutomated safety check: NotesApache-2.0
Frappe Ops Website DeployImpertio-Studio/Frappe_Claude_Skill_Package189—~2.5kAutomated safety check: PassMIT
Noodle Usewilfredinni/noodle367—~8.5kAutomated safety check: NotesApache-2.0
Supercheck Feature Implementationsupercheck-io/supercheck215—~1.1kAutomated safety check: PassAGPL-3.0

Similar skills

  • Mintlify API

    macro-inc/macro

    Interact with the Mintlify REST API to manage deployments, trigger builds, and query documentation site metadata programmatically.

    4.6k GitHub starsUsed in 2 repos~333 tokens
    Backend & APIsAuto-check passed
  • Rtvi Vlm Perf Testing

    NVIDIA-AI-Blueprints/video-search-and-summarization

    Plan, run, and diagnose reproducible RT-VLM GPU performance canaries and benchmarks.

    1.9k GitHub stars~8.6k tokensUpdated today
    Backend & APIsAuto-check: notes
  • Frappe Ops Website Deploy

    Impertio-Studio/Frappe_Claude_Skill_Package

    Deploy HTML/CSS websites to ERPNext/Frappe (v15/v16) as Web Pages via the REST API.

    189 GitHub stars~2.5k tokensUpdated 22 days ago
    Backend & APIsAuto-check passed
  • Noodle Use

    wilfredinni/noodle

    Teach agents to create, organize, maintain, evaluate, import, convert, and automate noodle terminal REST client collections using supported CLI commands plus YAML and dotenv files.

    367 GitHub stars~8.5k tokensUpdated today
    Backend & APIsAuto-check: notes
  • Supercheck Feature Implementation

    supercheck-io/supercheck

    Implement a new or changed Supercheck feature end to end across schema, auth/RBAC, services, routes/actions, UI, queues/workers, CLI/recorder, tests, docs, and deployment contracts.

    215 GitHub stars~1.1k tokensUpdated yesterday
    Backend & APIsAuto-check passed
  • Flow Nexus Platform

    ruvnet/agentic-flow

    Comprehensive Flow Nexus platform management - authentication, sandboxes, app deployment, payments, and challenges

    818 GitHub starsUsed in 4 repos~6.4k tokens
    Backend & APIsAuto-check passed

More from laolaoshiren/claude-code-skills-zh

All 19 skills in this repo
  • API Tester

    laolaoshiren/claude-code-skills-zh

    依据真实 OpenAPI、路由实现和现有测试生成并验证 API 测试。用于用户要求测试接口、补集成测试、验证 API 契约、生成回归用例或排查接口兼容性时;区分“生成测试”和“执行请求”的授权,不猜测状态码、响应结构或 SLA,不在未确认环境中发送写请求。

    880 GitHub stars~614 tokensUpdated 5 days ago
    Auto-check passed
  • Dep Auditor

    laolaoshiren/claude-code-skills-zh

    审计 Node.js、Python、Go、Rust、JVM、Ruby 项目的依赖漏洞、版本健康度与许可证事实;当用户要求检查 package.json、lockfile、requirements、go.mod、Cargo.toml、pom.xml、Gemfile.lock,或生成不改依赖的中文审计报告时使用

    880 GitHub stars~895 tokensUpdated 5 days ago
    Auto-check passed
  • Eslint Fix

    laolaoshiren/claude-code-skills-zh

    安全诊断并修复 ESLint error、warning 和配置兼容问题。用于用户要求运行 lint、解释 ESLint 报错、限定范围自动修复或迁移 ESLint 配置时;优先使用项目锁定的包管理器与版本,先预检再修改,不自动下载最新版或批量改写无关源码。

    880 GitHub stars~436 tokensUpdated 5 days ago
    Auto-check passed
  • Git Workflow

    laolaoshiren/claude-code-skills-zh

    安全处理 Git 状态检查、提交信息、commit、分支、push、PR 和 rebase。用于用户要求检查改动、生成或创建提交、管理分支、推送、发起 PR 或整理历史时;严格区分每个动作的授权,并保护工作树中已有和无关的修改。

    880 GitHub stars~513 tokensUpdated 5 days ago
    Auto-check passed
  • GitHub Actions Gen

    laolaoshiren/claude-code-skills-zh

    分析真实项目并生成或修订安全、可验证的 GitHub Actions workflow;当用户要求创建 CI、测试矩阵、构建、Release、部署、缓存、Secrets、OIDC、PR 自动化或排查 workflow 配置时使用

    880 GitHub stars~1.1k tokensUpdated 5 days ago
    Auto-check: notes
  • Skill Curator

    laolaoshiren/claude-code-skills-zh

    中文 Skill 收录评估器。用于核验 GitHub 上的 Claude Code、Codex、Agent Skills、Plugin、MCP、CLI 或 Agent 工作流是否值得加入精选列表;检查真实资产、安装方式、活跃度、重复项和安全边界,并生成分类、中文描述与可追溯证据。

    880 GitHub stars~756 tokensUpdated 5 days ago
    Auto-check passed

Questions about Log Analyzer

How do I install Log Analyzer in Claude Code?

Run `npx skills add laolaoshiren/claude-code-skills-zh --skill log-analyzer -a claude-code`. Or copy the skill folder (skills/log-analyzer in laolaoshiren/claude-code-skills-zh) into .claude/skills/log-analyzer in your project. Claude Code loads it when a task matches its description.

How do I install Log Analyzer in Codex?

Run `npx skills add laolaoshiren/claude-code-skills-zh --skill log-analyzer -a codex`. Or copy the skill folder (skills/log-analyzer in laolaoshiren/claude-code-skills-zh) into .agents/skills/log-analyzer in your project. Codex loads it when a task matches its description.

Can I use Log Analyzer in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add laolaoshiren/claude-code-skills-zh --skill log-analyzer -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/log-analyzer, .gemini/skills/log-analyzer, .github/skills/log-analyzer and .opencode/skills/log-analyzer in your project.

What does Log Analyzer need to run?

SKILL.md names no scripts, command-line tools or credentials: Log Analyzer is instructions for the agent only.

Does Log Analyzer access the network?

SKILL.md contains no URLs. Any network use would come from the scripts or tools the agent runs. This is read from the text; nothing was executed.

Is Log Analyzer safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Log Analyzer use?

Log Analyzer is published under the MIT licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Log Analyzer use?

About 355 tokens (SKILL.md is roughly 1.4k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Log Analyzer?

Skills that share tags, products or a category with Log Analyzer: Mintlify API (macro-inc/macro, 4.6k stars), Rtvi Vlm Perf Testing (NVIDIA-AI-Blueprints/video-search-and-summarization, 1.9k stars), Frappe Ops Website Deploy (Impertio-Studio/Frappe_Claude_Skill_Package, 189 stars) and Noodle Use (wilfredinni/noodle, 367 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Log Analyzer?

laolaoshiren (a GitHub user) maintains it in laolaoshiren/claude-code-skills-zh, which has 880 GitHub stars. The repository holds 19 skills in this directory. The repository was last updated on October 5, 2026.

Source: laolaoshiren/claude-code-skills-zh on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.