本文へ移動
cccskills
無料GitHub で公開

query-finelog

Query Finelog logs and telemetry for Iris tasks, workers, profiles, training, vLLM, and cross-cluster forwarding. Use for schema discovery, SQL, memory or CPU summaries, hub-versus-regional comparisons, counter semantics, and query-performance diagnosis.

インストール方法を見る

含まれるファイル(1)

  • SKILL.md4.5 KB

SKILL.md(原文)

インストールする前に、エージェントに与えられる指示の中身を確認できます。

Query Finelog

Read lib/finelog/OPS.md for access and query behavior. Read lib/iris/OPS.md under Stats Namespaces for Iris namespace meanings.

Discover before querying; do not assert remembered columns:

uv run finelog namespaces <deployment>
uv run finelog schema <deployment> <namespace>
uv run finelog query <deployment> --format table <<'SQL'
<bounded SQL using schema-confirmed columns>
SQL

finelog query reads SQL from stdin when the positional SQL argument is omitted.

Use marin for the federated view and a regional deployment for peer-local truth or recent rows that may not have forwarded. Preserve cluster and full process/label identity until after per-series delta calculations.

Bound the native time key. Keep telemetry_v1.timestamp_ms predicates numeric. Treat current snapshots as values, imported Prometheus counters as cumulative snapshots with LAG and reset handling, and native Rigging counters as deltas to SUM directly.

Never reset or change a shared namespace during diagnosis. Return the deployment, namespace, time window, query, series semantics, and any forwarding or retention caveat.

Examples

Confirm every schema before adapting an example. Angle-bracket values are placeholders.

Iris task memory by half-hour

Adapted from Echo wiki 230. The dashboard task ID includes the final task index. Select or group by attempt_id after retries.

SELECT date_bin(INTERVAL '30 minutes', ts,
                TIMESTAMP '1970-01-01 00:00:00') AS bucket_start_utc,
       count(*) AS samples,
       round(min(memory_mb) / 1024.0, 1) AS min_gib,
       round(median(memory_mb) / 1024.0, 1) AS median_gib,
       round(max(memory_mb) / 1024.0, 1) AS max_gib,
       round(max(memory_peak_mb) / 1024.0, 1) AS attempt_peak_gib
FROM "iris.task"
WHERE task_id = '/user/job/task'
  AND attempt_id = 0
GROUP BY bucket_start_utc
ORDER BY bucket_start_utc

memory_mb is sampled current memory; memory_peak_mb is the attempt's cumulative peak. Values are MiB despite the names. count(*) exposes partial buckets and gaps. Query the regional deployment if recent hub rows appear incomplete.

Missing federated logs

Use the exact attempt-suffixed log key on both stores:

-- marin hub
SELECT seq, epoch_ms, source, data, cluster
FROM "log"
WHERE key = '/user/job/task:0' AND cluster = 'cw-us-east-08a'
ORDER BY seq;

-- cw-us-east-08a regional deployment
SELECT seq, epoch_ms, source, data
FROM "log"
WHERE key = '/user/job/task:0'
ORDER BY seq;

Regional rows with a missing or shorter hub result mean forwarding delay. Runtime task logs with no regional rows point to shipper or regional ingest. Iris job describe remains the liveness source.

Native delta counter

Native rigging.telemetry.counter(...).add(...) rows are already increments:

SELECT sum(value)
FROM "telemetry_v1.<semantic_scope>"
WHERE name = 'requests_completed'
  AND timestamp_ms >= <start_ms>
  AND timestamp_ms < <end_ms>

Imported cumulative counter

Imported vLLM counters carry source_temporality = 'cumulative_snapshot'. Scan one 60-second scrape before the visible window, preserve the complete series identity, and discard reset intervals.

WITH base AS (
  SELECT COALESCE(NULLIF(cluster, ''), 'local') AS origin_cluster,
         service, name, resource_attributes_json, attributes_json,
         timestamp_ms, seq, value
  FROM "telemetry_v1.vllm"
  WHERE service = 'vllm'
    AND name = 'generation_tokens_total'
    AND json_get(attributes_json, 'source_temporality') = 'cumulative_snapshot'
    AND timestamp_ms >= <start_ms - 60000>
    AND timestamp_ms < <end_ms>
), samples AS (
  SELECT *, lag(value) OVER (
    PARTITION BY origin_cluster, service, name,
                 resource_attributes_json, attributes_json
    ORDER BY timestamp_ms, seq) AS previous_value
  FROM base
), deltas AS (
  SELECT *, CASE WHEN previous_value IS NULL OR value < previous_value
                 THEN NULL ELSE value - previous_value END AS delta
  FROM samples
)
SELECT date_bin(INTERVAL '5 minutes', to_timestamp_millis(timestamp_ms)) AS bucket,
       sum(delta) AS generated_tokens
FROM deltas
WHERE timestamp_ms >= <start_ms>
GROUP BY bucket
ORDER BY bucket

レビュー

まだレビューはありません。使ってみた感想をお寄せください。

同じリポジトリのスキル

概要と使いどころ

Run an explicitly requested Zephyr control/treatment benchmark on the same pre-normalized sample and compare Finelog stage metrics.

日本語の概要は準備中です。原文の説明を表示しています。

marin-community/marin3,9452026年10月13日 更新

Register a named Hugging Face dataset for Marin by inspecting its schema and adding the appropriate experiments/datasets module.

日本語の概要は準備中です。原文の説明を表示しています。

marin-community/marin3,9452026年10月13日 更新

add-grant

無料

Implement a fully specified request for a GCP IAM resource grant or Cloud Run IAP viewer in marin-iac.

日本語の概要は準備中です。原文の説明を表示しています。

marin-community/marin3,9452026年10月13日 更新

Add or change a named Pallas/Mosaic kernel, including its reference implementation, correctness tests, wrapper, or requested tuning.

日本語の概要は準備中です。原文の説明を表示しています。

marin-community/marin3,9452026年10月13日 更新

Archive explicitly named legacy experiment files by publishing a dated tag and canonical issue breadcrumbs.

日本語の概要は準備中です。原文の説明を表示しています。

marin-community/marin3,9452026年10月13日 更新

Launch or continuously monitor a specified Zephyr pipeline on Iris only when asked to babysit it; restart only after explicit approval.

日本語の概要は準備中です。原文の説明を表示しています。

marin-community/marin3,9452026年10月13日 更新

marin-community のスキルをすべて見る

このスキルの問題を報告する