Typed request compression ran before every Catty request (routine pre-turn and every step) and replaced image/file parts with a text placeholder, so attached images never reached the model.
preserveAttachments now keeps image attachments on the routine pre-turn and step paths. Non-image files stay placeholders (chat providers reject e.g. text/plain; the model reads them via list_attachments/read_attachment). The explicit 413 retry still trades attachments for placeholders.
Verified in the real Electron app: image reaches the provider as image_url (fake OpenAI-compatible server and DeepSeek deepseek-flash, which described the test image correctly); text-file turns still succeed via attachment tools; request prefix stability across turns unchanged vs main (DeepSeek cache hits ~98% on follow-up turns).
Fixes#3764
Co-authored-by: yangfan <1413737839@qq.com>