
ascii766164696d/log-mcp
Developer toolsЭта страница переведена автоматически. Технические детали смотрите в оригинале. Открыть оригинал
ascii766164696d/log-mcp — это кандидат на MCP-сервер, импортированный из https://github.com/ascii766164696d/log-mcp.
Обзор
ascii766164696d/log-mcp — это кандидат на MCP-сервер, импортированный из https://github.com/ascii766164696d/log-mcp.
Обзор (машинный перевод)
MCP-сервер для анализа лог-файлов. Даёт LLM возможность эффективно анализировать большие лог-файлы без загрузки их в контекст.
Это инструмент, разработанный для ИИ, а не для людей. Ни один человек не читает выводы analyze_errors или compare_logs — Клод читает, сжимает его ещё сильнее и даёт человеку простой английский ответ. Человек касается двух конечных точек: «что не так с этим логом?» — «что не так с этим логом?» — ввод, отвечает на естественном языке. Всё, что между ними — это ИИ, разговаривающий сам с собой.
Инструменты
| Инструмент | Описание |
|---|---|
log_overview |
Быстрое сканирование: размер, количество строк, временной диапазон, распределение уровней, образцы головы/хвоста |
search_logs |
Поиск по регулярным выражениям, уровню логарифма и/или временному диапазону |
get_log_segment |
Извлекать сегмент по линейному диапазону или временному диапазону |
analyze_errors |
Удаление ошибок по отпечаткам пальцев, подсчёт частот, извлечение трасс стека |
log_stats |
Гистограмма громкости, разбивка уровней, максимальные повторяющиеся паттерны |
compare_logs |
Найдите закономерности, уникальные для каждого файла, и частотные выбросы между файлами |
classify_lines |
Классификатор ML (TF-IDF → BERT) отделяет интересные линии от шума |
Ключевые особенности
- ML pre-filter — классификатор Rust TF-IDF сканирует файлы на 1.
Эта страница переведена автоматически. Технические детали смотрите в оригинале.
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"]
}
}
}