[MODEL] False positive content filter repeatedly blocks benign Kotlin import declarations
Preflight Checklist
- [x] I have searched existing issues for similar behavior reports
- [x] This report does NOT contain sensitive information (API keys, passwords, etc.)
Type of Behavior Issue
Claude refused a reasonable request
What You Asked Claude to Do
Add a CandidateAvatar composable to CandidatesScreen.kt in a Kotlin Multiplatform / Compose Multiplatform project. The composable loads candidate JPEG photos from bundled resources and renders them in a circular avatar with a fallback to initials. Standard UI code — no sensitive logic.
What Claude Actually Did
- Began writing the response and Kotlin import block
- Mid-response, output was cut off every attempt with:
API Error: {"type":"error","error":{"type":"invalid_request_error","message":"Output blocked by content filtering policy"},"request_id":"req_011CakET6QraP1F1UJ7K2cTf"}
- Claude did not self-report the block — silently ended the response
- Issue repeated on every retry until user explicitly told Claude the output was being blocked
- Only resolved when Claude changed its approach (split edits, different import ordering)
Expected Behavior
Claude should write the import block and composable body without interruption. All content was standard Kotlin/Compose code. Claude should also surface the block error to the user instead of silently failing.
Files Affected
CandidatesScreen.kt (intended edit only)
Permission Mode
Accept Edits was ON (auto-accepting changes)
Can You Reproduce This?
Yes, every time with the same prompt
Steps to Reproduce
- Ask Claude Code to add a Kotlin/Compose composable that imports
org.jetbrains.skia.Image as SkiaImage - Claude begins writing the import block
- Output is blocked mid-response with
"Output blocked by content filtering policy" - Retrying the same task produces the same block repeatedly
Claude Model
Sonnet
Relevant Conversation
Claude response was cut mid-edit with:
API Error: {"type":"error","error":{"details":null,"type":"invalid_request_error","message":"Output blocked by content filtering policy"},"request_id":"req_011CakET6QraP1F1UJ7K2cTf"}
No warning, no explanation. The response just ended. User had to notice and report it manually before Claude acknowledged the issue.
Impact
Medium - Extra work to undo changes
Claude Code Version
2.1.128 (Claude Code)
Platform
Anthropic API
Additional Context
- The blocked response contained Kotlin
importstatements includingorg.jetbrains.skia.Image as SkiaImage— theSkiaImagealias orskiapackage name likely pattern-matched a filter rule unintentionally - No credentials, secrets, or harmful content were present anywhere in the conversation
- Request ID from one occurrence:
req_011CakET6QraP1F1UJ7K2cTf - Two separate bugs here:
- False positive filter on benign Kotlin imports (
org.jetbrains.skia.Image as SkiaImage) - Silent failure — Claude does not surface the block error to the user; task appears to fail with no explanation
This issue has 2 comments on GitHub. Read the full discussion on GitHub ↗