The LLM Supply Chain Is Bigger Than Your requirements.txt
Most engineering teams already know how to think about software supply-chain risk for libraries: pin versions, verify checksums, scan for CVEs, prefer maintained packages. The AI stack quietly added a second supply chain that often sits outside those controls: model weights, tokenizers, adapters, system prompts packaged as “skills,” browser plugins, and tool servers.
If you would not curl | bash an unknown installer on a laptop, you should not silently load an unknown model or tool into a system that can reach production data.
What counts as a dependency now
| Component | Typical trust mistake | Better default |
|---|---|---|
| Base model weights | Download from a random mirror | Pinned revision from a verified org + checksum |
| Fine-tunes / LoRA adapters | Drop into prod because eval loss looks fine | Eval for safety + behavior, not just accuracy |
| Tokenizers / chat templates | Assume they are inert config | Review diffs; templates can change tool calling |
| Python/JS packages around the model | Same as any dependency | Lockfile + audit + allowlist |
| IDE / agent plugins | One-click install | Least privilege, code review, org allowlist |
| MCP / tool servers | Connect because the demo worked | Scoped credentials, network egress controls |
Attack patterns I keep seeing
- Typosquat and hallucinated packages suggested by assistants and installed without a registry check.
- Poisoned adapters that behave normally on public benchmarks and misbehave on trigger phrases.
- Prompt-level malware in “helpful” skill files that instruct an agent to weaken auth or disable logging.
- Model hosts that change bits under a mutable tag like
latest, so yesterday's eval is not today's artifact.
A hardening baseline
- Inventory. List every model ID, adapter, tokenizer, plugin, and tool endpoint your products call. If it is not inventoried, it is not supported.
- Pin. Use immutable digests or commit hashes, not floating tags.
- Verify. Checksums or signatures where available; private mirrors for production pulls.
- Scan. Run the same dependency scanners you use for apps on the AI service repos, plus secret scanning on prompts and notebooks.
- Isolate. Load untrusted models and tools in sandboxes first. Production credentials never meet internet-downloaded weights on first contact.
- Re-eval on change. Any model or adapter bump is a release: regression tests, safety checks, and a rollback plan.
Where ownership should sit
Platform or security engineering should own the allowlist and the private model registry. Product teams should not each invent their own download script. The same change-management path you use for a new production library should apply to a new production model.
AI did not invent supply-chain risk. It just made large opaque binaries and natural-language programs part of everyday shipping. Put them on the bill of materials, and treat updates like the production changes they are.