🎩 You're Invited:Meet the Socket team at Black Hat in Las Vegas, August 3-6.RSVP
Sign In

@llmintel/cli

Package Overview
Dependencies
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@llmintel/cli

Fail your CI build when it references retired or soon-to-be-retired AI models. The LLMIntel lifecycle gate.

latest
Source
npmnpm
Version
0.2.0
Version published
Maintainers
1
Created
Source

@llmintel/cli

Fail your CI build when it references retired or soon-to-be-retired AI models.

llmintel check scans your code/config for referenced model ids (and/or takes explicit ids), looks up their lifecycle state via the LLMIntel API, and exits non-zero when any referenced model is retired or past its retirement date — so you migrate on your schedule, not the provider's shutoff date.

Install

No install required — run it with npx:

npx @llmintel/cli@latest check src config

Or add it as a dev dependency:

npm install --save-dev @llmintel/cli

Authenticate

Create an API key from your dashboard and expose it as an environment variable:

export LLMINTEL_API_KEY="mc_live_..."

Usage

# Scan files/directories for referenced model ids and gate on lifecycle state:
llmintel check src config

# Check explicit ids/aliases without scanning:
llmintel check --models "gpt-4o,claude-3-opus-20240229"

# Use a config file:
llmintel check --config llmintel.json

Options

FlagDescription
-m, --models <a,b,c>Explicit model ids/aliases to check (repeatable)
-c, --config <file>JSON config: { "models": [...], "paths": [...], "warnDays": 90 }
--api-url <url>API base URL (env LLMINTEL_API_URL, default https://llmintel.vercel.app)
--api-key <key>API key (env LLMINTEL_API_KEY)
--warn-days <n>Warn when a model retires within this many days (default 90)
--fail-on-warnTreat warnings (deprecated / retiring soon) as build failures
--fail-on-unknownTreat references LLMIntel does not track as build failures
--no-policyIgnore your account's central policy; use only the flags above
--optimizeAlso print advisory cheaper/faster model suggestions (paid; never fails the build)
--jsonMachine-readable JSON output
-q, --quietOnly print failures

Central gate policy

By default check fails only on retired (or past-due) models — free forever. On a paid plan you can configure a stricter policy once in your dashboard and every pipeline picks it up automatically: fail on deprecated/retiring, set the warn window, and fail on untracked references.

check fetches this policy on each run and uses it as the baseline. Explicit local flags (--warn-days, --fail-on-unknown) override it; pass --no-policy to ignore it entirely. Free accounts are always clamped to the retired-only gate regardless of any saved policy.

Auto-watch your codebase (sync)

llmintel sync discovers the models your code references — the same scan as check — and registers them as your account's watched set server-side. Combined with push alerts (webhook / Slack / PagerDuty), this gives you "fire and forget" coverage: run sync in CI on merge to main, and you'll be notified the moment a model you actually use is deprecated or retired, with no watchlist to curate by hand.

# Replace your watched set with whatever your code references now:
llmintel sync src config

# Preview the diff without writing anything:
llmintel sync src config --dry-run

# Only add models; never remove ones you watch elsewhere:
llmintel sync src config --no-prune

sync requires a paid plan with auto-watch enabled and an API key linked to an account. It prints the diff of added / removed / unchanged watches plus any unresolved references.

Exit codes

CodeMeaning
0All referenced models healthy
1One or more errors (retired / past due), or warnings with --fail-on-warn
2Usage / configuration error
3API or network error

GitHub Actions

A composite action ships alongside the CLI:

- uses: hivemindunit/llmintel-cli/packages/cli@main
  with:
    api-key: ${{ secrets.LLMINTEL_API_KEY }}
    paths: "src config"
    warn-days: "90"

License

MIT

Keywords

ai

FAQs

Package last updated on 30 Jun 2026

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts