All demosLog Sentinel

Log Sentinel

Find the incident in a wall of logs.

Examples are free. Bring a key for your own inputs. Get a free key

Performance & cost

This session

Ready to run
Delivery time · median
—
Live model compute
—
Live input tokens
0
Est. cost · USD
$0.00

Bypass examples to measure live inference. Uses your quota.

Measurement details · 0 successful requests
Successful requests
0

Run an example for free to see its measurements.

Model compute is the average per measured request. Delivery time is the median browser time for successful requests, including queue, network, and retries. Cached delivery speed is not inference speed. Model compute can exceed browser time when one request processes many inputs.

Tokens come from response headers. Inference costs use $0.04 per million input tokens, before plan credits. The estimate includes live and recorded tokens at the same rate; cached examples are not charged again. Missing usage is unavailable or a partial total (≥). Demo resets keep these totals; reload to start a new session.

Try it

Start the stream, then hit Inject storm.

Build with the SDKTypeScript · Python · dm1

One request from this demo. Copy it into your app.

Uses your MS_API_KEY and quota. Keep the key on your server.

Install · set your key
npm install @cloudraker/milliseconds
export MS_API_KEY="your-api-key"
example.ts
import { DecisionMachine } from "@cloudraker/milliseconds";

// Run on your server; reads MS_API_KEY from the environment.
const dm = new DecisionMachine();

const { result, usage } = await dm.yesNo(
  [
    "[api-gateway] {\"ts\":\"2026-09-17T17:00:00.000Z\",\"level\":\"INFO\",\"svc\":\"api-gateway\",\"msg\":\"request completed\",\"req_id\":\"a217f56cdea4\",\"method\":\"GET\",\"route\":\"/api/v1/users/me\",\"status\":200,\"latency_ms\":54}",
    "[api-gateway] {\"ts\":\"2026-09-17T17:00:00.000Z\",\"level\":\"INFO\",\"svc\":\"api-gateway\",\"msg\":\"request completed\",\"req_id\":\"41e7914d95e3\",\"method\":\"POST\",\"route\":\"/api/v1/orders\",\"status\":201,\"latency_ms\":166}",
    "[api-gateway] {\"ts\":\"2026-09-17T17:00:00.000Z\",\"level\":\"INFO\",\"svc\":\"api-gateway\",\"msg\":\"request completed\",\"req_id\":\"d61d076b07e6\",\"method\":\"GET\",\"route\":\"/api/v1/products/301139\",\"status\":404,\"latency_ms\":7}",
    "[api-gateway] {\"ts\":\"2026-09-17T17:00:00.000Z\",\"level\":\"WARN\",\"svc\":\"api-gateway\",\"msg\":\"rate limit applied to client\",\"client_id\":\"c_2444b2\",\"route\":\"/api/v1/search\",\"status\":429,\"limit\":\"600/min\"}",
    "[api-gateway] {\"ts\":\"2026-09-17T17:00:00.000Z\",\"level\":\"ERROR\",\"svc\":\"api-gateway\",\"msg\":\"client disconnected before response was written (context canceled)\",\"req_id\":\"03a064b0710f\",\"route\":\"/api/v1/users/me\",\"elapsed_ms\":74}",
    "[api-gateway] {\"ts\":\"2026-09-17T17:00:00.000Z\",\"level\":\"ERROR\",\"svc\":\"api-gateway\",\"msg\":\"deprecated endpoint called; sunset 2027-03-01, responding normally\",\"route\":\"/v1/legacy/cart\",\"client_id\":\"c_d8e6aa\",\"status\":200}",
    "[api-gateway] {\"ts\":\"2026-09-17T17:00:00.000Z\",\"level\":\"ERROR\",\"svc\":\"api-gateway\",\"msg\":\"upstream returned 500 for checkout\",\"req_id\":\"40bceed368af\",\"route\":\"/api/v1/checkout\",\"upstream\":\"payments:8080\",\"status\":500,\"latency_ms\":1869}",
    "[api-gateway] {\"ts\":\"2026-09-17T17:00:00.000Z\",\"level\":\"INFO\",\"svc\":\"api-gateway\",\"msg\":\"route latency p95 above SLO\",\"route\":\"/api/v1/search\",\"p95_ms\":3091,\"slo_ms\":400,\"window\":\"5m\"}",
    "[payments] {\"ts\":\"2026-09-17T17:00:00.000Z\",\"level\":\"INFO\",\"svc\":\"payments\",\"msg\":\"charge captured\",\"charge_id\":\"ch_75cee1f7fb907a\",\"provider\":\"stripe\",\"amount_cents\":6650,\"currency\":\"USD\",\"latency_ms\":351}",
    "[payments] {\"ts\":\"2026-09-17T17:00:00.000Z\",\"level\":\"INFO\",\"svc\":\"payments\",\"msg\":\"charge declined by issuer\",\"charge_id\":\"ch_85feb33e843f0f\",\"decline_code\":\"insufficient_funds\"}",
    "[payments] {\"ts\":\"2026-09-17T17:00:00.000Z\",\"level\":\"ERROR\",\"svc\":\"payments\",\"msg\":\"charge attempt 1 failed: provider timeout; retry succeeded on attempt 2\",\"charge_id\":\"ch_95416bbf52151c\",\"attempts\":2,\"total_ms\":1469}",
    "[payments] {\"ts\":\"2026-09-17T17:00:00.000Z\",\"level\":\"INFO\",\"svc\":\"payments\",\"msg\":\"provider response\",\"provider\":\"stripe\",\"status\":200,\"body_bytes\":0,\"parsed\":false,\"charge_id\":\"ch_f3a545f9a17e9f\",\"note\":\"capture state unknown\"}",
    "[payments] {\"ts\":\"2026-09-17T17:00:00.000Z\",\"level\":\"INFO\",\"svc\":\"payments\",\"msg\":\"ledger reconciliation finished\",\"ledger_total_cents\":48213598,\"provider_total_cents\":47886949,\"mismatched_charges\":47}",
    "[payments] 2026-09-17T17:00:00.000Z ERROR [payments] Unhandled exception while capturing charge ch_beed3fe24dbce4: Cannot invoke \"Money.amount()\" because \"captureResult\" is null\njava.lang.NullPointerException: Unhandled exception while capturing charge ch_beed3fe24dbce4: Cannot invoke \"Money.amount()\" because \"captureResult\" is null\n\tat com.acme.payments.capture.CaptureService.capture(CaptureService.java:104)\n\t... 3 more frames",
    "[payments] 2026-09-17T17:00:00.000Z DEBUG [payments] thread dump requested via /debug/stack by ops@acme.example (diagnostic, not an error)\n\tat java.base/jdk.internal.misc.Unsafe.park(Native Method)\n\tat java.base/java.util.concurrent.locks.LockSupport.park(LockSupport.java:371)\n\t... 2 more frames",
    "[auth] ts=2026-09-17T17:00:00.000Z level=info svc=auth event=login.success user=u_daed38 ip=131.95.43.19 method=password mfa=true dur_ms=40",
    "[auth] ts=2026-09-17T17:00:00.000Z level=info svc=auth event=token.refresh user=u_ad4dc3 client=web scope=read:orders dur_ms=13",
    "[auth] ts=2026-09-17T17:00:00.000Z level=warn svc=auth event=login.failed reason=invalid_password user=u_41d93c ip=57.65.69.119 attempt=1 of=5",
    "[auth] ts=2026-09-17T17:00:00.000Z level=info svc=auth event=token.issued client=marketing-dashboard scope=\"admin:* users:write billing:write\" ttl=30d issued_by=svc-automation ip=62.120.171.177",
    "[auth] ts=2026-09-17T17:00:00.000Z level=info svc=auth event=login.summary window=60s ip=71.104.15.177 distinct_users=693 failures=610 successes=5 user_agent=\"python-requests/2.31\"",
    "[auth] ts=2026-09-17T17:00:00.000Z level=error svc=auth event=oidc.discovery.failed issuer=https://login.acme-idp.example err=\"dial tcp: connection refused\" consecutive=46 logins_blocked=true",
    "[k8s] 2026-09-17T17:00:00.000Z Normal Pulled pod/api-gateway-57e07336f-67faf Container image \"registry.acme.example/api-gateway:2026.09.17-2bf0a62\" already present on machine",
    "[k8s] 2026-09-17T17:00:00.000Z Normal Scheduled pod/cron-worker-98c4d97b1-a8466 Successfully assigned prod/cron-worker to node-4",
    "[k8s] 2026-09-17T17:00:00.000Z Normal SuccessfulRescale horizontalpodautoscaler/api-gateway New size: 11; reason: cpu resource utilization (percentage of request) above target",
    "[k8s] 2026-09-17T17:00:00.000Z Warning Unhealthy pod/payments-4bf4bc21f-ec921 Readiness probe failed: HTTP probe failed with statuscode: 503 (container started 2s ago, initialDelaySeconds not reached)",
    "[k8s] 2026-09-17T17:00:00.000Z Normal ScalingReplicaSet deployment/payments Scaled down replica set payments-a5c8b5d5b from 6 to 1 (kubectl scale by user ops-intern@acme.example)",
    "[k8s] 2026-09-17T17:00:00.000Z Warning Evicted pod/postgres-replica-f11e79388-7b395 The node was low on resource: memory. Threshold quantity: 750Mi, available: 233Mi.",
    "[k8s] 2026-09-17T17:00:00.000Z Warning BackOff pod/payments-769a54735-dd80b Back-off restarting failed container payments in pod (last state: OOMKilled, exit code 137, restarts: 8)",
    "[postgres] 2026-09-17 17:00:00.000 UTC [33853] LOG:  duration: 15.677 ms  statement: SELECT id, status FROM orders WHERE user_id = $1 ORDER BY created_at DESC LIMIT 20",
    "[postgres] 2026-09-17 17:00:00.000 UTC [8534] LOG:  checkpoint complete: wrote 3752 buffers (2.8%); write=14.639 s, sync=0.012 s, total=8.872 s",
    "[postgres] 2026-09-17 17:00:00.000 UTC [29020] ERROR:  duplicate key value violates unique constraint \"payments_idempotency_key_key\"  DETAIL:  Key (idempotency_key)=(idem_7ada7519f8) already exists. (idempotent retry, request returned existing charge)",
    "[postgres] 2026-09-17 17:00:00.000 UTC [38982] LOG:  replica-2 replay lag 110 s behind primary (alert threshold 30 s); read replicas serving stale order status"
  ],
  "An on-call engineer should investigate this log line right now.",
  {
    "when_true": "Judge what the line means, not its level. A 5xx on checkout, a provider timeout or an open circuit breaker, a 200 with an empty body on a payment path, a crash in live traffic, a backup of 0 bytes, replication lag, a disk filling up, a certificate expiring soon or credential stuffing all need a look.",
    "when_false": "Judge what the line means, not its level. A request that completed, a charge that was captured or declined, a login or token refresh that worked, a scheduled pod, a checkpoint, a 404, an applied rate limit, an expected canary failure, a retry that worked or a client that hung up needs no look."
  }
).withUsage();

console.log(result);
console.log({ inputTokens: usage.inputTokens, modelMs: usage.inferenceMs });

Under the hood How it works & limitations

API calls/yes-no/rate/classify

How it works

The model judges whether each log entry needs attention, its severity and likely cause. Local rules group related events from the same service into incidents and retain the highest severity.

Demo scope

The logs and incident storm are synthetic. Model judgments can miss incidents or flag harmless events. Fixture-based results describe this sample stream, not a production monitoring guarantee.

Inspired by the work of dabit3.