Auto-Matching Correspondents and Types
Essal Office can automatically assign a correspondent and document type to new documents as they are processed. This works through matching rules — a set of conditions you configure on each correspondent and document type that Essal Office evaluates every time a new document arrives.
How Matching Works
After a document is uploaded and its text is extracted by OCR, Essal Office evaluates all active matching rules in order. The first rule that matches the document's content wins and the corresponding correspondent or type is assigned automatically.
This happens in the background — by the time the document appears in your list, the metadata may already be filled in.
Matching Algorithms
Each correspondent and document type has a matching algorithm setting. The options are:
- Algorithm: **None**
- How it works: Auto-matching is disabled. Assign this correspondent or type manually.
- Algorithm: **Any word**
- How it works: Matches if any of the words in the pattern appear in the document text
- Algorithm: **All words**
- How it works: Matches only if every word in the pattern appears in the document text
- Algorithm: **Exact match**
- How it works: Matches only if the exact phrase appears word-for-word
- Algorithm: **Regular expression**
- How it works: Matches using a regex pattern — powerful but requires technical knowledge
- Algorithm: **Fuzzy match**
- How it works: Matches even with minor spelling differences — useful for OCR errors
- Algorithm: **Automatic**
- How it works: Essal Office learns from your manual assignments and develops its own matching logic
Choosing the Right Algorithm
For most users, start with Exact match or Any word:
- Use Exact match when a correspondent's name is distinctive and unlikely to appear elsewhere (e.g.
Acme Supplies Ltd.) - Use Any word when the pattern needs flexibility (e.g.
bank statementmatching documents that say eitherbankorstatementin various combinations) - Use Fuzzy match when your scanner produces slight OCR errors and exact matching fails
- Use Automatic once you have assigned a correspondent or type to 10 or more documents manually — Essal Office will learn the pattern and take over
Tip: The Automatic algorithm improves over time. Assign metdata manually for a few weeks before switching to Automatic for reliable results.
Configuring a Matching Rule
- Go to Management > Correspondents (or Document Types)
- Open the correspondent or type you want to configure
- Set the Matching algorithm
- Enter the Match pattern — the word, phrase, or expression to look for
- Enable Is insensitive if you want matching to ignore uppercase/lowercase differences
- Click Save
Testing Your Rules
The best way to test matching is to upload a sample document and see whether the correspondent and type are filled in automatically. If they are not:
- Check that the pattern text actually appears in the document's extracted content (open the document and look at the Content tab)
- Verify there is no typo in your pattern
- Try switching from Exact match to Any word or Fuzzy match
Understanding Matching Priority
Essal Office evaluates rules in order. If two rules could both match the same document, the one with a higher specificity wins. When using Automatic, Essal Office handles prioritisation internally.
If you find conflicts — for example a document being assigned the wrong correspondent — review all rules that could match the document's content, and narrow the most common rule's pattern to avoid false matches.