DocView Capture reads the text on every page with an OCR engine. The text is used to separate and classify documents, to find field values, and to make searchable PDFs.
Three engines are available:
| Engine | Where it runs | Cost | Notes |
|---|---|---|---|
| Tesseract (on-premises) | On your own servers | Free | The default. No data leaves your network. |
| DocView OmniRead (on-premises, high accuracy) | On your own servers (a service, or inside the DocView Workers) | Included | More accurate printed text in 50 languages, optional handwriting. Needs the OmniRead service — see DocView OmniRead. |
| Azure AI Document Intelligence | Microsoft Azure | Paid, with your own Azure resource | Also returns key-value pairs and tables. |
| Google Cloud Vision | Google Cloud | Paid, with your own Google project | Document text detection. |
OCR runs on the DocView Workers. The web server also runs OCR for administrators' tests, such as the Test tab and the zone designer.
Choose the engine for a Batch Setup
- Go to Administration › Batch Setups and open the Batch Setup.
- Work on a draft version. Released versions are read-only.
- On the Workflow tab, select the OCR, separation & classification step and choose the OCR engine.
- In OCR languages, type the language codes, separated by commas, for example
eng,deu,fra. - With DocView OmniRead, you can enter a DocView OmniRead pool. Only the OmniRead services of that pool then read this Batch Setup's pages; leave it empty to use any service. See DocView OmniRead.
- Click Save workflow, and release the version when you are ready. See Versions and publishing.
Override the engine for one document class
A document class can use a different engine from the rest of the Batch Setup. For example, most documents use Tesseract, but complex forms use Azure.
- Open the Document classes & fields tab and select the class.
- In OCR engine override, choose the engine. (Batch Setup default) means no override.
- Save.
When a class overrides the engine, its pages are read again with that engine after classification.
Tesseract languages
Tesseract needs a language data file for each language, named <code>.traineddata, for example eng.traineddata for English and deu.traineddata for German. Common codes:
| Code | Language | Code | Language |
|---|---|---|---|
eng |
English | nld |
Dutch |
deu |
German | pol |
Polish |
fra |
French | por |
Portuguese |
spa |
Spanish | swe |
Swedish |
ita |
Italian | dan |
Danish |
The file osd.traineddata is also needed. It detects page orientation for automatic rotation.
What comes with DocView Capture
Release packages and Docker images include English (eng) and orientation data (osd). If you only capture English documents, you do not need to do anything.
Add languages with get-tessdata.ps1
The script tools/get-tessdata.ps1 downloads language files from the official Tesseract repositories (Apache 2.0 licence).
Open PowerShell on the DocView Worker server.
Run the script with every language you need, including English if you still use it:
./tools/get-tessdata.ps1 -Languages eng,deu,fraThe files go to
%ProgramData%\DocViewCapture\tessdata, which is the default Tesseract data folder.osdis always added.Repeat on every DocView Worker server, and on the web server if administrators test OCR there.
Add the codes to the Batch Setup's OCR languages, for example
eng,deu,fra.
The script options are:
| Option | Default | Meaning |
|---|---|---|
-Languages |
eng |
Language codes to download. |
-Destination |
%ProgramData%\DocViewCapture\tessdata |
Where to save the files. |
-Quality |
fast |
fast (recommended for throughput) or best (slower, slightly more accurate). |
Files that are already there are skipped.
Important: DocView Capture uses the data shipped with the program only when the Tesseract data folder has no language files at all. As soon as you add files to that folder, it is used instead. So always download English too if any Batch Setup uses
eng.
Tip: When you build your own release packages,
./tools/publish.ps1 -Languages eng,deu,fraputs those languages into the packages, so new servers have them straight away.
Use a different folder
To keep language files elsewhere, for example on a shared drive:
- Copy the
.traineddatafiles to the folder. - Go to Administration › Settings and set Tesseract data folder to that folder.
- Click Save settings.
Every DocView Worker must be able to read the folder.
Several languages on one page
When you list several languages, Tesseract considers all of them for every page. Only list the languages you really receive: each extra language makes OCR slower and can add recognition mistakes.
Missing language data
If a Batch Setup asks for a language that is not installed, the batch fails in the OCR step with a message such as:
Tesseract language data missing in 'C:\ProgramData\DocViewCapture\tessdata': deu. Run tools/get-tessdata.ps1 -Languages deu or change Settings › Tesseract data folder.
Install the language, then retry the batch in the Batch Manager.
Cloud OCR: Azure and Google
Cloud engines send page images to the cloud provider. You use your own account and pay the provider directly. Check that this meets your data protection rules before you use them.
The keys are stored as encrypted secrets. See Settings.
Azure AI Document Intelligence
DocView Capture uses the prebuilt-layout model, with key-value pairs and tables.
- In the Azure portal, create a Document Intelligence resource.
- Copy its endpoint and one of its keys.
- In DocView Capture, go to Administration › Settings. In Secrets, save:
ocr.azure.endpointwith the endpoint address;ocr.azure.keywith the key.
- Choose Azure AI Document Intelligence as the OCR engine of a Batch Setup or document class.
Key-value pairs from Azure can be used by the cloud key-value extraction method. See Fields and extraction.
Google Cloud Vision
- In Google Cloud, enable the Vision API and create a service account with access to it.
- Download the service account key as JSON.
- In DocView Capture, save the whole JSON as the secret
ocr.google.credentials. - Choose Google Cloud Vision as the OCR engine.
The Batch Setup's OCR languages are passed to Google as language hints.
If a secret is missing, batches fail in the OCR step with a message that names the secret to add.
Note: The DocView Workers must be able to reach the provider over HTTPS. Check your firewall and proxy rules.