Skip to content

docs: document Model Armor file and document scanning - #498

Merged
mateo-berri merged 1 commit into
mainfrom
litellm_model_armor_file_scanning_docs
Jul 7, 2026
Merged

docs: document Model Armor file and document scanning#498
mateo-berri merged 1 commit into
mainfrom
litellm_model_armor_file_scanning_docs

Conversation

@mateo-berri

@mateo-berri mateo-berri commented Jul 7, 2026

Copy link
Copy Markdown
Collaborator

BerriAI/litellm#31655 wired document and file attachment scanning into the Model Armor guardrail and it ships in v1.92.0. The behavior is fail closed, so inline documents that previously passed through unscanned can now be blocked with a 400, and a customer is already asking exactly how document links, oversized files, and masking behave with the fix

This adds a Document and File Scanning section to the Model Armor page covering which content blocks and document types are scanned, that a finding on a document always blocks even with mask_request_content enabled, and a table of the unscannable cases (file_id and remote URL references, documents over the 4 MB limit, more than 10 attachments per request, undecodable base64, scan errors) with the default fail-closed behavior versus fail_on_error: false. The fail_on_error param description now links to the new section


Note

Low Risk
Documentation-only changes with no runtime or config behavior modifications.

Overview
Documents v1.92.0 Model Armor behavior for inline document attachments on the Model Armor guardrail page.

Adds a Document and File Scanning section: pre_call / during_call byte API scanning for OpenAI file and Anthropic document blocks; supported document types vs pass-through (e.g. images); example payloads; HTTP 400 on policy matches; and that masking does not apply to documents. A follow-on subsection tables fail-closed cases (remote/file_id refs, 4 MB limit, >10 attachments, bad base64, API errors) versus behavior when fail_on_error: false, with a sample block error body.

The fail_on_error param blurb now calls out unscannable attachments and links to the new section.

Reviewed by Cursor Bugbot for commit 5694108. Bugbot is set up for automated code reviews on this repo. Configure here.

@vercel

vercel Bot commented Jul 7, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
litellm Ready Ready Preview, Comment Jul 7, 2026 3:04am

Request Review

@mateo-berri

Copy link
Copy Markdown
Collaborator Author

bugbot run

@cursor cursor Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Bugbot reviewed your changes and found no new issues!

Comment @cursor review or bugbot run to trigger another review on this PR

Reviewed by Cursor Bugbot for commit 5694108. Configure here.

@mateo-berri
mateo-berri merged commit 5dfd764 into main Jul 7, 2026
4 checks passed
@mateo-berri
mateo-berri deleted the litellm_model_armor_file_scanning_docs branch July 7, 2026 03:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant