Leveraging Weblate’s Translation Memory and Fuzzy Matching for Consistent Translations
Weblate’s translation memory automatically suggests fuzzy matches for repetitive strings, cutting translator effort while preserving consistency.
31 Jul 2025, 12:54 UTC

Why translators waste time on repetitive strings
In large localization projects, the same source phrase can appear dozens or hundreds of times. Each occurrence forces a translator to type the same wording again, which creates inconsistency and adds manual effort.
The built‑in solution: Weblate’s translation memory
Weblate stores every approved translation as a TM entry. When a new source string is submitted, the system computes a similarity score – typically using Levenshtein distance – against all stored source strings. The highest‑scoring match is shown as a fuzzy suggestion with a percentage indicating how close it is to the new text.
How the matching works
1. Entry creation: After a translator accepts a string, Weblate records the source and target pair in the translation memory.
2. Indexing: The source text is indexed so that future queries can locate relevant entries quickly. In versions prior to 4.0 the index lives in the default database; version 4.0+ can use Xapian or Whoosh for faster look‑ups.
3. Similarity calculation: When a new string arrives, Weblate retrieves candidate entries, ranks them by distance, and returns the best match.
Worked example
Assume the phrase Save has already been translated as Сохранить. A new string Save changes is submitted. Weblate finds a fuzzy match with 85 % similarity and pre‑fills the target field with Сохранить изменения. The translator only needs to verify or edit the suggestion, saving time compared to translating from scratch.
Trade‑off and limitation
Fuzzy matches are not perfect. Subtle changes in wording can lead to an inaccurate suggestion, so translators must review each hint. If the TM contains outdated entries, the same error can propagate. Additionally, early‑stage projects with few approved strings see limited suggestions until the memory grows.
Practical steps to get the most out of TM
- Enable the translation memory in the project settings (Project → Translation memory → “Enable TM”).
- Set a sensible fuzzy‑match threshold – many teams use 70 % as a baseline.
- Regularly review and prune stale entries to keep suggestions accurate.
- Train translators to treat suggestions as starting points, not final answers.
Verification checklist
Log into the Weblate admin UI, go to Project → Translation memory, click “Test fuzzy match”, enter a source string and observe the suggested translation and match percentage.
From a shell, run weblate shell and execute:
from weblate.trans.memory import get_tm_suggestions
print(get_tm_suggestions('myproject','mycomponent','Save changes')) to retrieve TM suggestions programmatically.
Compare latency between Weblate 3.19 (database‑only TM) and Weblate 4.4 (Xapian backend) by timing the same query; Xapian typically returns results in under 50 ms versus several hundred ms on large databases.
0 replies
A thoughtful contribution can make all the difference. Be the first to share one.