Definition
Caverphone 2
Caverphone 2 is a phonetic algorithm that converts names into ten-character codes using ordered spelling and sound-transformation rules. It was developed through New Zealand’s Caversham Project and helps identify potential name variations, with the digit 1 used to pad shorter codes.
Key Takeaways
- Caverphone 2 produces one ten-character phonetic code per input.
- The digit 1 pads shorter codes; it does not represent a sound or confidence score.
- Caverphone 2 changes the original algorithm’s rules as well as its code length.
- Different names, such as Glen and Colin, can share the same code.
- Handle empty inputs explicitly and compare other identifying fields before linking records.
Caverphone 2 Calculator
Compare two names using Caverphone 2, a phonetic algorithm designed for English-language names.
These values produce the same Caverphone 2 code.
Caverphone 2 transforms names into a fixed-length phonetic key, helping identify spelling variations that sound similar.
WinPure AdaptiveMatch™ can combine Caverphone 2 with other phonetic and fuzzy algorithms, thresholds and field-level rules to improve matching accuracy.
What Is Caverphone 2?
Caverphone 2 is a phonetic matching algorithm that converts text into a code representing an approximation of its pronunciation. It helps identify names that may sound alike despite being spelled differently.
Developed through the Caversham Project at the University of Otago in New Zealand, Caverphone 2 is a revised version of the original Caverphone algorithm. It applies an ordered set of spelling and sound-transformation rules to produce a ten-character code, using the digit 1 to pad shorter results.
Unlike Levenshtein distance, which counts character edits, Caverphone 2 compares names through their phonetic encodings. Names that produce the same code can be considered potential matches for further investigation.
Different names can receive the same encoding. The examples and limitations below explain how to interpret code agreement.
How Does Caverphone 2 Work?
Caverphone 2 applies an ordered sequence of replacement rules to simplify a name into a phonetic code. The order matters because the output of one rule can affect a later transformation.
The process has four main stages:
- Prepare the text: convert it to lowercase and remove characters outside a–z. This means accented characters need careful handling before encoding.
- Apply pronunciation rules: transform recognised letter patterns, handle certain silent letters and endings, and simplify vowels and consonants.
- Remove temporary markers: discard markers used during processing, leaving the final phonetic representation.
- Create a ten-character code: pad shorter results with the digit 1 and truncate longer results to ten characters.
For example, the rules can map different consonants to the same representation, such as V to F and D to T. Repeated consonants in specified groups are also reduced. These transformations allow some differently spelled names to produce the same code.
A matching system then compares the completed codes to identify agreement under Caverphone 2’s rules.
Caverphone 2 Codes and Padding
Caverphone 2 produces a ten-character code. After applying its transformation rules, it pads shorter results with the digit 1. If the phonetic representation exceeds ten characters, only the first ten are retained.
The padding digits complete the fixed-length format. They do not represent additional sounds, missing information or a confidence score. A code with more padding is not automatically a weaker match.
Why Does the Fixed Length Matter?
A consistent code length makes encodings straightforward to store and compare. However, different names can collapse to the same representation, and truncation can discard distinctions beyond the tenth character.
Unlike branching algorithms such as Daitch-Mokotoff Soundex, Caverphone 2 returns one code per input. It does not generate separate primary and alternate codes.
Empty or Unsupported Input
In implementations such as Apache Commons Codec, an empty input or text that leaves no letters after filtering produces 1111111111. That result should not be treated as evidence that two missing or unsupported values identify the same person.
Handle empty and missing values explicitly before using phonetic equality in a record-matching rule.
Caverphone 2 Examples
The following examples show how Caverphone 2 maps names to ten-character codes. Some differently spelled names share a code, while others produce different results.
| Name | Compared name | Caverphone 2 codes | Code agreement |
|---|---|---|---|
| Glen | Glenn | Both KLN1111111 | Same code |
| Colin | Collin | Both KLN1111111 | Same code |
| Dan | Dann | Both TN11111111 | Same code |
| Peter | Stevenson | PTA1111111 / STFNSN1111 | Different codes |
Worked Example: Glen and Glenn
For both names, the rules remove the internal vowel and convert G to K. The repeated N in Glenn is reduced, leaving the same phonetic representation: KLN.
Seven padding digits complete the ten-character code:
KLN + 1111111 = KLN1111111
The shared code makes Glen and Glenn candidates for further comparison. However, Colin also produces KLN1111111, illustrating how distinct names can collapse to the same encoding.
These examples follow the Apache Commons Codec Caverphone 2 tests.
Glen and Glenn both produce KLN1111111: the phonetic representation KLN followed by seven padding digits.
Caverphone 1 vs Caverphone 2
Caverphone 2 revises the original algorithm’s transformation rules and increases the code length from six to ten characters. It is not simply Caverphone 1 with extra padding: changes to the rules can also change the phonetic representation.
| Feature | Caverphone 1 | Caverphone 2 |
|---|---|---|
| Code length | 6 characters | 10 characters |
| Padding | Digit 1 | Digit 1 |
| Transformation rules | Original rule set | Revised handling of patterns, vowels and endings |
| Codes per input | One | One |
Caverphone 2 includes changes such as removing a final E before later transformations and revising the treatment of Y and certain word endings. These differences can affect which names receive the same code.
Use the same algorithm version for both values in a comparison. Existing Caverphone 1 codes should be regenerated from the original names when moving to Caverphone 2, rather than extended with additional padding.
The longer code does not guarantee better record-matching accuracy. Test representative names and review both useful matches and phonetic collisions before choosing a version.
Caverphone 2 vs Soundex and Double Metaphone
Caverphone 2, Soundex and Double Metaphone all encode text phonetically, but they use different rules. A pair of names may share a code under one algorithm and produce different codes under another.
| Feature | Caverphone 2 | Standard Soundex | Double Metaphone |
|---|---|---|---|
| Output format | Ten-character code, padded with 1s | First letter followed by three digits | Phonetic symbols, such as SM0 or XMT |
| Alternative codes | One code per input | One code per input | Can produce primary and alternate codes |
| Approach | Ordered text-transformation rules | Consonant sound groups with the first letter retained | Context-sensitive pronunciation rules |
| Background | Developed for name matching through New Zealand’s Caversham Project | Widely used for English-language surname indexing | Developed to handle a range of pronunciation patterns and name origins |
Code length alone does not indicate accuracy. Caverphone 2’s ten-character output includes padding, while Double Metaphone’s alternate code provides another encoding that a matching system may or may not compare.
Choose an algorithm by testing genuine name variations and unrelated names from your dataset. Assess both missed matches and false matches.
When Is Caverphone 2 Useful?
Caverphone 2 is useful when names may have different spellings that its pronunciation rules map to the same code. Its origins in New Zealand name matching make it worth evaluating for English-language datasets, but performance should be tested against the names you actually hold.
Common applications include:
- Name searches: returning potential candidates when the entered spelling differs from the stored name.
- Customer deduplication: contributing phonetic evidence when names vary across records.
- Record linkage: finding possible connections between datasets without relying on exact name agreement.
- Historical research: exploring name variations in records created by different people or at different times.
Caverphone 2 is most helpful when its transformations capture the variations present in your data. It does not understand nicknames or translate names.
Limitations and False Matches
Caverphone 2 simplifies names into phonetic codes, so distinct names can receive the same encoding. For example, Glen, Glenn and Colin all produce KLN1111111. Code agreement therefore needs supporting evidence.
- Phonetic collisions: different names can collapse to the same code, creating potential false matches.
- Limited pronunciation coverage: its rules cannot represent every language, regional accent or naming tradition reliably.
- Input filtering can discard information: the standard rules remove characters outside a–z. Accented and non-Latin names require careful preparation to avoid losing meaningful characters.
- Empty values can share a code: inputs with no retained letters may produce
1111111111. This should not count as identifying evidence. - Truncation can hide differences: phonetic representations longer than ten characters lose anything beyond that limit.
- Some genuine variations remain unmatched: nicknames, name changes and spelling errors may produce different codes.
A shared code does not express a similarity percentage or the probability that two records belong to the same person. Padding digits also provide no measure of confidence.
Test known matches and non-matches from your dataset, handle missing values explicitly, and compare other identifying fields before consolidating records.
Why a Phonetic Code Shouldn’t Decide a Match Alone
A Caverphone 2 code describes the result of its sound-transformation rules. It does not include the other details that distinguish one person from another.
Consider two records containing Glen Smith and Colin Smith. Glen and Colin both encode as KLN1111111, so comparing the given-name codes and surnames could flag the records as a potential match.
Glen and Colin share a Caverphone 2 code, but conflicting identifying details require further assessment.
The remaining fields help assess that candidate:
- Consistent contact details: agreement on an email address or other identifying information can strengthen the case for review.
- Conflicting dates of birth: the records may describe different people, although data-entry errors should also be considered.
- A shared address: the records could belong to members of the same household rather than one person.
- Missing identifying details: there may be insufficient evidence to reach a reliable decision.
A wider matching rule considers phonetic agreement alongside character similarity and other relevant fields. Uncertain cases should remain available for review before records are consolidated.
Using Caverphone 2 in AdaptiveMatch™
AdaptiveMatch™ applies matching algorithms to individual columns in WinPure Clean & Match Enterprise. Caverphone 2 can be used for name fields where its phonetic rules help identify spelling variations.
A matching rule could combine:
- Given name: Caverphone 2 to identify potential phonetic agreement.
- Surname: Jaro-Winkler to assess character similarity.
- Address: WinPureFuzzy™ to compare textual variations.
- Email: exact matching to check agreement on the email value.
AdaptiveMatch™ analyses each column and recommends a matching configuration, while allowing users to review and adjust the algorithms, weights and thresholds. This combines phonetic name evidence with other relevant comparisons, helping users assess potential duplicates within the context of the whole rule.
Go beyond a phonetic name match
Compare names alongside addresses, emails and other identifying fields in WinPure Clean & Match Enterprise. Try it free for 30 days—no credit card required.
Frequently Asked Questions
Caverphone 2 is a phonetic algorithm that converts text into a ten-character code using pronunciation-related transformation rules. It was developed through the Caversham Project at the University of Otago in New Zealand.
Caverphone 2 revises the transformation rules and increases the code length from six to ten characters. Its codes should be generated from the original text rather than created by adding padding to Caverphone 1 codes.
The digit 1 pads shorter phonetic representations to ten characters. Padding does not represent extra sounds or indicate the confidence of a match.
No. It produces one code per input, rather than branching into alternative encodings or returning primary and alternate codes.
No. Distinct names can share a code. Glen and Colin, for example, both produce KLN1111111. Other identifying fields should contribute to the record-matching decision.
No algorithm is universally best. Test genuine variations and unrelated names from your dataset, then compare missed matches and false matches before choosing.
The standard rules remove characters outside a–z, so information can be lost. Consider appropriate character normalisation or transliteration before encoding, and test the results against representative names.
In implementations such as Apache Commons Codec, empty inputs or text with no retained letters produce this all-padding code. It should not be treated as evidence that two records identify the same person.
No. It produces a phonetic code. Equal codes indicate agreement under the algorithm’s rules, not a probability that the records represent the same person.
Share this article




