II.2 What a "document" is: formats and file types
A PDF is not one thing
Two PDFs can look identical and behave nothing alike.
- Maya's contract, exported from Word. Click a sentence: it highlights. Press search: it finds "indemnity". The words are text.
- Maya's scan of the same contract, from a copier. Click a sentence: nothing. Search: nothing. Every page is just a photograph of text.
Both are "a PDF". To an app, they are different materials. A great deal of this book's advice ("run Searchable first", "extract before you flatten") is really advice about which material you are holding.
The three kinds of PDF
| Kind | How to recognise it | What works | What does not |
|---|---|---|---|
| Text-based (born digital) | You can select and search words | Everything: extract, search, AI apps, convert to Word | Nothing special |
| Scanned / image-only | You cannot select a word; pages are pictures | Organize, compress, deskew, OCR, Searchable, sign | Extract Text, Search (unless it recognises first), Parser text, most AI apps |
| Mixed | Some pages selectable, some not | Treat per page; run Searchable to make it uniform | Text-only tools miss the picture pages |
A quick test: open the file and try to select a word. If you cannot, it is a scan.
A fourth case exists: a searchable scan. This is a scan plus an invisible text layer, produced by Searchable. It looks like a scan and behaves like a text PDF. It is also a recognised estimate, so wrong words can hide inside (quality model).
Other things you will feed in
| Format family | Examples | Typical way into the apps |
|---|---|---|
| Office | Word (DOC, DOCX), Excel (XLS, XLSX), PowerPoint (PPTX) | Merger or Converter turn them into PDF |
| Images | JPG, PNG, BMP, TIFF, GIF, WebP | Merger, Converter, OCR Image, Collage |
| Web and markup | HTML, SVG, Markdown, XML | Converter; SVG Maker produces SVG |
| E-books and print | EPUB, MOBI, DJVU, XPS, PostScript | Converter or Merger, to PDF |
| Archives | ZIP, RAR, 7z, TAR, TAR.GZ, TAR.BZ2 | Merger and Converter convert the supported files inside |
| Plain text | TXT, Markdown, CSV | AI Illustrator, Unwatermark, AI apps |
| Certificates | .pfx |
Sign |
| Code | .NET DLL/EXE, NuGet name, GitHub repository | Part XI |
What each family accepts and produces
This is the short form; the full table is Appendix A.
| Family | Takes | Gives |
|---|---|---|
| Organize | PDF (Merger: many formats and archives) | PDF (Splitter: several PDFs) |
| Add & Structure | PDF; Add Table also an Excel file; Collage images; Illustrator TXT or PDF | |
| Protect & Prove | PDF (Unlock: PDF only on the web) and a .pfx for signing |
PDF, or a report or verdict on screen |
| Shrink & Repair | PDF; Unwatermark also text | PDF; Recovery adds a report; Unwatermark also cleaned text |
| Extract & Search | PDF or images; Resume Analyzer takes PDF or DOC | TXT, PNG, CSV, ZIP, a marked PDF, or PDF/Word/Excel/PowerPoint (Searchable) |
| Convert & Create | Dozens of formats (Converter); a sentence (SVG Maker, Chat) | Word, Excel, PowerPoint, HTML, images, PDF/A, PDF; SVG |
| AI understand | PDF (Checklist and Cheat Sheet also from a topic) | Mostly PDF; PDF Knowledge Base gives a Markdown ZIP; answers appear on screen |
| AI for developers | Repository, assembly, URL, a chat message | CSV, SQLite, ZIP, pull request, diagrams |
Three things that catch people out
Pictures are the end of the road for text. A PDF turned into JPG or PNG looks perfect and cannot be searched. Do the text work first.
Encrypted input is refused. Merger refuses encrypted Word or DJVU files. Converter has the same problem with password-protected inputs. Remove the password first (Unlock is PDF-only on the web; Office files can be unlocked with a command-line plugin, see CLI).
A format is not a promise of fidelity. Word is a different way of flowing text from PDF. Excel stores cells, not page pictures. Converter lists what each target keeps and loses.
Output naming
Results are new files, usually named after your input with a suffix or a new extension. Examples from the chapters: …_optimized.pdf, …_cheat_sheet, a ZIP named Compressed_documents, a ZIP named Converted_<from>_to_<to>. See II.3.
Try it
Take any PDF you own. Try to select a word, then run it through Extract Text. If you get an empty file, you have just met a scan, and you know your next step.