
ascii766164696d/log-mcp
Developer toolsこのページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。 原文を見る
ascii766164696d/log-mcpは、https://github.com/ascii766164696d/log-mcp.からインポートされたMCPサーバー候補です。
概要
ascii766164696d/log-mcpは、https://github.com/ascii766164696d/log-mcp.からインポートされたMCPサーバー候補です。
概要(AI 翻訳)
ログファイル解析のためのMCPサーバー。大型ログファイルを文脈に読み込むことなく効率的に解析できるLLMの能力を提供します。
これはAIのために設計されたツールであって、人間用ではありません。人間はanalyze_errorsや[compare_logsの出力を読みません。クロードは読み、さらに圧縮して平易な英語の答えを人間に伝えます。人間は二つのエンドポイントに触れます:「このログの何が問題ですか?」入力、自然言語の回答です。その間のすべてはAIが自分自身に話しかけているのです。
道具
| 道具 | 説明 |
|---|---|
log_overview |
クイックスキャン:サイズ、ライン数、時間範囲、レベル分布、頭部・尾部サンプル |
search_logs |
正則表現、ログレベル、または時間範囲で検索 |
get_log_segment |
線の範囲または時間範囲でセグメントを抽出する |
analyze_errors |
指紋による誤りの重複脱、周波数カウント、スタック痕跡の抽出 |
log_stats |
体積ヒストグラム、レベル内訳、繰り返しパターンの上部 |
compare_logs |
各ファイル固有のパターンとファイル間の頻度の異常値を見つける |
classify_lines |
ML分類器(TF-IDF → BERT)は、興味深い線をノイズから分離します |
主な特徴
- MLプレフィルター — RustのTF-IDF分類器が1でファイルをスキャンします。
このページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。
README
以下は原文 README の抜粋です。原文を見る。
log-mcp
MCP server for log file analysis. Gives LLMs the ability to efficiently analyze large log files without loading them into context.
Log file (e.g. 705K lines, 67 MB)
│
▼
Rust TF-IDF classifier ─── 1.3M lines/sec ──▶ 70-95% discarded as routine,
│ finds lines that are semantically interesting,
│ also captures lines not explicitly marked as ERROR
│ (grep ERROR: 2 lines, classifier: 92)
▼
BERT-mini (optional) ───── GPU, ~2K lines/sec ─▶ refines interest scores on found lines
│
▼
Python MCP tools ────────── search, compare, group errors
│
▼
LLM (Claude) ───────────── compresses tool output into plain English
This is a tool designed for AI, not humans. No human reads the output of analyze_errors or compare_logs — Claude does, compresses it further, and gives the human a plain English answer. The human touches two endpoints: “what’s wrong with this log?” in, natural language answer out. Everything in between is AI talking to itself.
Tools
| Tool | Description |
|---|---|
log_overview |
Quick scan: size, line count, time range, level distribution, head/tail samples |
search_logs |
Search by regex, log level, and/or time range |
get_log_segment |
Extract a segment by line range or time range |
analyze_errors |
Deduplicate errors by fingerprint, count frequencies, extract stack traces |
log_stats |
Volume histogram, level breakdown, top repeated patterns |
compare_logs |
Find patterns unique to each file and frequency outliers across files |
classify_lines |
ML classifier (TF-IDF → BERT) separates interesting lines from noise |
Key features
- ML pre-filter — a Rust TF-IDF classifier scans files at 1.3M lines/sec, so
analyze_errorsandsearch_logsonly process the 5-30% of lines that matter. Optional BERT-mini re-scores LOOK lines at ~2K lines/sec on Metal GPU for higher precision. Works without parsed log levels — catches errors, security events, hardware faults, and anomalies that don’t have ERROR in them. - Auto-detection of log formats: JSON, standard text (
2024-01-15 10:30:45 ERROR ...), syslog, Spark/Log4j (17/06/08 13:33:49 INFO ...), and tab/pipe-delimited formats (GitHub Actions CI logs) - Normalization collapses variable parts (UUIDs, hex IDs, IPs, numbers) so that messages differing only in IDs or timestamps are grouped as the same pattern
- Content-based error detection falls back to regex heuristics (
fatal:,Permission denied,##[error], etc.) when log files lack standard levels - Prefix-aware comparison distinguishes patterns from different job steps in CI logs
Install
Prerequisites (fresh Mac):
brew install python uv
インストール
This server does not publish a one-line install command.
Open the repository installation guide MCP 初心者?mcpskill.org のガイドから始めましょう →設定
{
"mcpServers": {
"log-mcp": {
"command": "uv",
"args": ["run", "--directory", "/path/to/log-mcp", "log-mcp"]
}
}
}