How to attach files to AI chats and get actually useful answers

Format-by-format guidance for PDFs, docs, code, and screenshots — what each model handles well and the prompts that get real answers instead of summaries.

Marcie Ellis avatar
Marcie Ellis
Content Marketer
2 min read
a paper clip attached to a stylised chat bubble

You uploaded a PDF and asked "what does this say?" — you got a summary you didn't need. The fix isn't a better tool; it's a different way of attaching. This guide walks through the four file types you'll actually upload (PDF, docx, code, screenshots), what each model does with them, and the prompts that get useful work back instead of generic summaries.

PDFs

What models do under the hood: Native PDF support means the model reads the text layer directly (no OCR needed for normal PDFs). Scanned PDFs (images of pages) are silently OCR'd — quality varies wildly.

Best model: Claude 4.7 for long PDFs (50+ pages); GPT-5 or Gemini for shorter ones.

The prompt that works:

I've uploaded a PDF: <one-sentence description of what it is>.
I want you to <specific job>, not summarize the whole thing.

For your answer:
- Quote the page number with every claim.
- If you find a contradiction within the document, flag it.
- If something is missing that you'd expect from a document of this type, name it.

The "quote the page number" line is the single biggest improvement you can make to PDF prompts. Without it, models confabulate freely. With it, they cite (and you can verify).

docx and Google Docs

What models do: Most tools convert docx to text behind the scenes, which preserves the words but loses tracked-changes, comments, and styled formatting. Tables sometimes survive; complex layouts usually don't.

Best model: Either Claude or GPT — both handle clean docx well.

The prompt that works:

I've uploaded a document. Here's what I need:

1. Read the whole thing once.
2. Tell me what it's trying to do and who it's for.
3. Tell me where the argument loses force, in order of severity.

Don't rewrite. Don't add new points. Just diagnose.

If you want edits, attach the doc AND paste the actual paragraph you want edited in the chat. Two-modal context (the file for background, the snippet for focus) produces better edits than asking the model to find the paragraph itself.

Code files

What models do: Read code as text. Modern models handle syntax across all major languages without translation. Multi-file projects are trickier — most tools attach files individually, so the model sees them as separate artifacts rather than a connected codebase.

Best model: Claude 4.7 for whole-file refactors; GPT-5 for function-level work. (Detailed in Claude 4.7 vs GPT-5.)

The prompt that works:

Attached: <filename>.

Don't review this for style. Find:
- Bugs (anything that wouldn't work as the author intended)
- Footguns (anything that works but invites future bugs)
- Missing tests (anything important without coverage)

Skip the parts of the code that look fine. Quote the line you're flagging.

The "skip the parts that look fine" line cuts the noise dramatically. Without it, models pad reviews with stylistic notes you didn't ask for.

Screenshots

What models do: Vision-capable models (GPT-5, Claude 4.7, Gemini 2.5 Pro) all handle screenshots; quality differs by content type. UI screenshots, tables, and diagrams have different sweet spots.

Best model: Gemini 2.5 Pro for text-in-image and tables; Claude 4.7 for diagrams. (See vision prompts that work for the specifics.)

The prompt that works:

Attached: a screenshot of <what it is>.

I want you to <specific job>. Don't describe what's in the image
generally; focus on <the specific element>.

Don't ask "what does this show?" — that produces a description of the whole image. Ask for the specific job, and the description-of-context comes free.

Mixing files in one conversation

When you attach multiple files, name them in your prompt so the model can reference them:

Attached:
- spec.pdf (the original product spec)
- pr-1234.diff (the implementation diff)
- failing-test-output.txt (what's broken)

Compare what spec.pdf says about <feature> against what pr-1234.diff
actually does, and explain why failing-test-output.txt is failing.

This is where multi-model platforms earn their keep: oran.chat keeps the attachment context across model switches, so you can upload to Claude (for the long PDF), switch to GPT-5 for the diff analysis, and the files remain available.

The portable system prompt and file work

If you use the portable system prompt, add a section that says "when files are attached, quote source explicitly". That makes citation discipline a default instead of something you have to remember on each turn.

More practical workflows in Playbooks.