<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: krunal solanki</title>
    <description>The latest articles on DEV Community by krunal solanki (@krunal_solanki_f19a805b67).</description>
    <link>https://dev.to/krunal_solanki_f19a805b67</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F1970390%2Fd068b58b-8525-46e5-84eb-6e20aefaaa6b.jpg</url>
      <title>DEV Community: krunal solanki</title>
      <link>https://dev.to/krunal_solanki_f19a805b67</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/krunal_solanki_f19a805b67"/>
    <language>en</language>
    <item>
      <title>I tested 9 name-matching methods on the OFAC sanctions list. Here's what I found.</title>
      <dc:creator>krunal solanki</dc:creator>
      <pubDate>Fri, 20 Nov 2026 18:48:57 +0000</pubDate>
      <link>https://dev.to/krunal_solanki_f19a805b67/how-fuzzy-name-matching-against-the-ofac-sanctions-list-actually-works-9fl</link>
      <guid>https://dev.to/krunal_solanki_f19a805b67/how-fuzzy-name-matching-against-the-ofac-sanctions-list-actually-works-9fl</guid>
      <description>&lt;p&gt;If you've ever built customer onboarding for a bank, a lender, a title company or a payments app, you've had to answer one question: &lt;strong&gt;is this person on the OFAC sanctions list?&lt;/strong&gt;&lt;/p&gt;

&lt;p&gt;The list is public. The hard part is the name. Customers type "Aymen Zawahri"; the list says "AL ZAWAHIRI, Dr. Ayman". An exact match misses it. A loose fuzzy match flags half your customers named John. And when a compliance analyst asks &lt;em&gt;why&lt;/em&gt; a name was flagged, "the library returned 0.87" is not an answer.&lt;/p&gt;

&lt;p&gt;I spent ten years building title and mortgage systems, including OFAC screening. This post walks through how I approached name matching in &lt;a href="https://github.com/krunalsolanki/ofac-match" rel="noopener noreferrer"&gt;OfacMatch&lt;/a&gt;, an open-source screener, with the real numbers at each step. The ideas apply whatever language or library you use.&lt;/p&gt;

&lt;h2&gt;
  
  
  Why exact matching fails
&lt;/h2&gt;

&lt;p&gt;The Specially Designated Nationals (SDN) list has about 19,500 entries and many more aliases. Real names arrive with:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Spelling and transliteration differences:&lt;/strong&gt; Mohammed, Muhammad, Mohamed&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Different order:&lt;/strong&gt; "DOE, John" on the list, "John Doe" in your form&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Titles and particles:&lt;/strong&gt; "Dr.", "AL", "BIN"&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Typos:&lt;/strong&gt; a missing or swapped letter&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Extra or missing parts:&lt;/strong&gt; a middle name the list doesn't have&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Company suffixes:&lt;/strong&gt; "EXAMPLE TRADING CO., LTD." versus "Example Trading LLC"&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;On my held-out test set, exact matching after cleaning up case and punctuation found only &lt;strong&gt;35%&lt;/strong&gt; of realistic variations of listed names. So you need fuzzy matching, and then you need to keep it from flagging everyone.&lt;/p&gt;

&lt;h2&gt;
  
  
  Step 1: normalize both names the same way
&lt;/h2&gt;

&lt;p&gt;Before comparing anything, both names go through the same cleanup:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Step&lt;/th&gt;
&lt;th&gt;Example&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Remove accents&lt;/td&gt;
&lt;td&gt;José Müller → JOSE MULLER&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Upper case&lt;/td&gt;
&lt;td&gt;al-Zawahiri → AL-ZAWAHIRI&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Drop apostrophes&lt;/td&gt;
&lt;td&gt;O'Neil → ONEIL&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Other punctuation becomes a space&lt;/td&gt;
&lt;td&gt;AL-ZAWAHIRI → AL ZAWAHIRI&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Remove honorifics&lt;/td&gt;
&lt;td&gt;Dr. Ayman → AYMAN&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Turn &lt;code&gt;LAST, First&lt;/code&gt; around (people)&lt;/td&gt;
&lt;td&gt;AL ZAWAHIRI, Ayman → AYMAN AL ZAWAHIRI&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Drop legal forms (companies only)&lt;/td&gt;
&lt;td&gt;EXAMPLE TRADING CO., LTD. → EXAMPLE TRADING&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Two details matter. Legal forms are removed for companies only, never for people. And legal forms are matched even with a one-letter typo ("COMPALY"), because real data is messy.&lt;/p&gt;

&lt;h2&gt;
  
  
  Step 2: OFAC already tells you how its own tool scores
&lt;/h2&gt;

&lt;p&gt;OFAC publishes how its &lt;a href="https://sanctionssearch.ofac.treas.gov/" rel="noopener noreferrer"&gt;Sanctions List Search&lt;/a&gt; scores names, in &lt;a href="https://ofac.treasury.gov/faqs/topic/1636" rel="noopener noreferrer"&gt;its FAQ&lt;/a&gt;. It uses two techniques and reports the higher score:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;
&lt;strong&gt;Whole name:&lt;/strong&gt; &lt;a href="https://en.wikipedia.org/wiki/Jaro%E2%80%93Winkler_distance" rel="noopener noreferrer"&gt;Jaro-Winkler similarity&lt;/a&gt; of the full strings.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Name parts:&lt;/strong&gt; compare each part of the name separately, using Jaro-Winkler plus &lt;a href="https://en.wikipedia.org/wiki/Soundex" rel="noopener noreferrer"&gt;Soundex&lt;/a&gt; for parts that sound alike.&lt;/li&gt;
&lt;/ol&gt;

&lt;p&gt;OfacMatch uses the same two techniques and the same 0 to 100 scale, so its scores read the way analysts are used to. (It doesn't reproduce OFAC's tool exactly: for example, it applies the Jaro-Winkler prefix bonus only when the base score is above 0.7, as in Winkler's original definition. I haven't yet measured how often the two agree.)&lt;/p&gt;

&lt;h2&gt;
  
  
  Step 3: score the name parts
&lt;/h2&gt;

&lt;p&gt;Here's the name-parts method on a real pair: searched &lt;strong&gt;Aymen Zawahri&lt;/strong&gt;, listed &lt;strong&gt;AL ZAWAHIRI, Dr. Ayman&lt;/strong&gt;.&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Compare every searched part with every listed part using Jaro-Winkler.&lt;/li&gt;
&lt;li&gt;If two parts share a Soundex code, raise the score halfway toward 1: &lt;code&gt;(similarity + 1) / 2&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Pair parts greedily from the best pair down; each listed part is used once.&lt;/li&gt;
&lt;li&gt;Average the pair scores, &lt;strong&gt;weighted by the length of each searched part&lt;/strong&gt;, so a short particle like "AL" counts less than "ZAWAHIRI".&lt;/li&gt;
&lt;/ol&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Searched part&lt;/th&gt;
&lt;th&gt;Paired with&lt;/th&gt;
&lt;th&gt;Jaro-Winkler&lt;/th&gt;
&lt;th&gt;Sounds alike?&lt;/th&gt;
&lt;th&gt;Part score&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;AYMEN&lt;/td&gt;
&lt;td&gt;AYMAN&lt;/td&gt;
&lt;td&gt;0.907&lt;/td&gt;
&lt;td&gt;yes (A550)&lt;/td&gt;
&lt;td&gt;0.953&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;ZAWAHRI&lt;/td&gt;
&lt;td&gt;ZAWAHIRI&lt;/td&gt;
&lt;td&gt;0.946&lt;/td&gt;
&lt;td&gt;yes (Z600)&lt;/td&gt;
&lt;td&gt;0.973&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Weighted average: (0.953 × 5 + 0.973 × 7) / 12 = 0.965. A small coverage adjustment (5% of the score depends on how much of the listed name was matched; "AL" wasn't) brings it to &lt;strong&gt;95.8&lt;/strong&gt;.&lt;/p&gt;

&lt;p&gt;The whole-name Jaro-Winkler score for the same pair is only &lt;strong&gt;84.5&lt;/strong&gt;, because "AL" sits in the middle of the listed string. Taking the higher of the two gives 95.8. That's why the two-technique approach works: each one covers the other's blind spots.&lt;/p&gt;

&lt;h2&gt;
  
  
  Step 4: the false-positive trap, and a guard
&lt;/h2&gt;

&lt;p&gt;"Take the higher of the two" has a problem. Try &lt;strong&gt;John Smith&lt;/strong&gt; against a listed &lt;strong&gt;John Numbi&lt;/strong&gt;:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;&lt;/th&gt;
&lt;th&gt;Score&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Whole name (Jaro-Winkler)&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;88.0&lt;/strong&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Name parts: JOHN ↔ JOHN&lt;/td&gt;
&lt;td&gt;1.000&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Name parts: SMITH ↔ NUMBI&lt;/td&gt;
&lt;td&gt;0.467&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Name parts total&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;70.4&lt;/strong&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Jaro-Winkler rewards a long shared prefix, and "JOHN " is a long shared prefix. So the whole-name score says 88, above a typical threshold of 85, for two names that only share a first name.&lt;/p&gt;

&lt;p&gt;The fix is one rule:&lt;/p&gt;

&lt;blockquote&gt;
&lt;p&gt;The whole-name score can only raise the result when &lt;strong&gt;every&lt;/strong&gt; searched part pairs with a listed part scoring at least 0.70.&lt;/p&gt;
&lt;/blockquote&gt;

&lt;p&gt;SMITH ↔ NUMBI scores 0.467, so the whole-name score doesn't count, and the pair scores 70.4: not an alert.&lt;/p&gt;

&lt;p&gt;On held-out ordinary names (common first names and surnames from many cultures), this guard cut alerts at a threshold of 85 from &lt;strong&gt;53.0% to 37.5%&lt;/strong&gt; for two-part names, and from &lt;strong&gt;30.5% to 10.3%&lt;/strong&gt; for three-part names. Recall on listed-name variations stayed at 100%.&lt;/p&gt;

&lt;h2&gt;
  
  
  Step 5: explain every score
&lt;/h2&gt;

&lt;p&gt;Every score should come with its reasoning: which name or alias it hit, which technique won, and how each part paired. For the first example, that's the table in Step 3. A reviewer can read it and decide in seconds, and it goes straight into the audit record.&lt;/p&gt;

&lt;p&gt;A score also isn't an identity check. "Ivan Hernandez" scores 100 against a listed "HERNANDEZ, Ivan" even if they're different people. So OfacMatch also takes an optional birth year and country, and &lt;strong&gt;flags&lt;/strong&gt; a match whose listed birth year or country disagrees, rather than hiding it. That decision belongs to a person.&lt;/p&gt;

&lt;h2&gt;
  
  
  How I tested it
&lt;/h2&gt;

&lt;p&gt;Tuning a matcher on the same names you test it on tells you nothing. So I split the work:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Development set:&lt;/strong&gt; used while building and tuning.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Held-out set&lt;/strong&gt; (a different random seed, entries and ordinary names never used in development): used once, for the numbers below.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;The held-out set has 4,235 variations of 600 listed people and companies (typos, swapped letters, transliterations, reordering, missing middle names, changed company suffixes), plus 3,000 ordinary names for measuring false alerts. Results at a threshold of 85:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;100%&lt;/strong&gt; of the 4,235 variations found&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;99.6%&lt;/strong&gt; of 2,160 harder variations found (wrong first letter like Kassim → Qassim, two wrong letters, nicknames like Aleksandr → Sasha, an initial instead of a first name, an extra middle name)&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;37.5%&lt;/strong&gt; of two-part ordinary names and &lt;strong&gt;10.3%&lt;/strong&gt; of three-part names raise an alert that a person must clear&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;I also compared eight standard methods on the same data: exact match, Levenshtein, Jaro-Winkler alone, RapidFuzz's token sort and token set ratios, Soundex parts, Monge-Elkan, and trigram TF-IDF. Different methods' scores mean different things, so the fair comparison fixes the alert rate and measures recall:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Method&lt;/th&gt;
&lt;th&gt;Recall when ≤ 1% of ordinary names alert&lt;/th&gt;
&lt;th&gt;Recall when ≤ 5% alert&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;Jaro-Winkler (whole name)&lt;/td&gt;
&lt;td&gt;82.7%&lt;/td&gt;
&lt;td&gt;85.4%&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Levenshtein&lt;/td&gt;
&lt;td&gt;85.5%&lt;/td&gt;
&lt;td&gt;86.9%&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Trigram TF-IDF cosine&lt;/td&gt;
&lt;td&gt;93.3%&lt;/td&gt;
&lt;td&gt;97.6%&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Token sort ratio&lt;/td&gt;
&lt;td&gt;95.2%&lt;/td&gt;
&lt;td&gt;96.7%&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;Token set ratio&lt;/td&gt;
&lt;td&gt;&lt;strong&gt;99.9%&lt;/strong&gt;&lt;/td&gt;
&lt;td&gt;100.0%&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;OfacMatch (default)&lt;/td&gt;
&lt;td&gt;99.2%&lt;/td&gt;
&lt;td&gt;100.0%&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Token set ratio slightly beats OfacMatch at the strictest alert rate. It's a strong, simple baseline, and if you're building your own matcher it's a good place to start. What it doesn't give you is OFAC's 0-100 scale or a part-by-part explanation an analyst can check.&lt;/p&gt;

&lt;p&gt;Full tables, the protocol and the code are in the repo, and there's a &lt;a href="https://doi.org/10.5281/zenodo.23930926" rel="noopener noreferrer"&gt;paper&lt;/a&gt; with the details.&lt;/p&gt;

&lt;h2&gt;
  
  
  Picking a threshold from data
&lt;/h2&gt;

&lt;p&gt;There's no regulator-approved threshold. OFAC won't recommend one, and "set it to 85" isn't a policy. What you can do is measure the trade-off on data and write down why you chose your number. Here's the trade-off for OfacMatch on the held-out set:&lt;/p&gt;

&lt;div class="table-wrapper-paragraph"&gt;&lt;table&gt;
&lt;thead&gt;
&lt;tr&gt;
&lt;th&gt;Threshold&lt;/th&gt;
&lt;th&gt;Variations found&lt;/th&gt;
&lt;th&gt;Harder variations found&lt;/th&gt;
&lt;th&gt;Two-part ordinary names alerting&lt;/th&gt;
&lt;th&gt;Three-part ordinary names alerting&lt;/th&gt;
&lt;/tr&gt;
&lt;/thead&gt;
&lt;tbody&gt;
&lt;tr&gt;
&lt;td&gt;80&lt;/td&gt;
&lt;td&gt;100.0%&lt;/td&gt;
&lt;td&gt;99.9%&lt;/td&gt;
&lt;td&gt;75.7%&lt;/td&gt;
&lt;td&gt;51.0%&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;85&lt;/td&gt;
&lt;td&gt;100.0%&lt;/td&gt;
&lt;td&gt;99.6%&lt;/td&gt;
&lt;td&gt;37.5%&lt;/td&gt;
&lt;td&gt;10.3%&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;90&lt;/td&gt;
&lt;td&gt;100.0%&lt;/td&gt;
&lt;td&gt;98.4%&lt;/td&gt;
&lt;td&gt;10.2%&lt;/td&gt;
&lt;td&gt;2.2%&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;95&lt;/td&gt;
&lt;td&gt;99.6%&lt;/td&gt;
&lt;td&gt;83.4%&lt;/td&gt;
&lt;td&gt;2.1%&lt;/td&gt;
&lt;td&gt;0.0%&lt;/td&gt;
&lt;/tr&gt;
&lt;/tbody&gt;
&lt;/table&gt;&lt;/div&gt;

&lt;p&gt;Three things stand out:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Short names drive the alerts.&lt;/strong&gt; At 85, a two-part name is more than three times as likely to alert as a three-part name. A single global threshold treats them the same; collecting a birth year for every customer is what separates "Daniel Perez" from a listed "PEREZ ROJAS, Daniel".&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Between 85 and 90, alerts drop by about three quarters&lt;/strong&gt; while recall on ordinary variations holds. The cost is on the harder cases (99.6% → 98.4%), such as nicknames.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;At 95, nickname-style variations are mostly missed&lt;/strong&gt; (42% found). A high threshold looks efficient until someone types "Sasha" instead of "Aleksandr".&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Your customers aren't my test set, so run the same kind of test on your own names. A missing birth year should never count against a match; it only means you have less to clear it with.&lt;/p&gt;

&lt;h2&gt;
  
  
  Try it
&lt;/h2&gt;

&lt;p&gt;The fastest way is the browser page, which runs entirely client-side: &lt;a href="https://krunalsolanki.github.io/ofac-match/" rel="noopener noreferrer"&gt;krunalsolanki.github.io/ofac-match&lt;/a&gt;. Screen one name or a CSV of up to 10,000, and download an audit file.&lt;/p&gt;

&lt;p&gt;From Python, run the self-hosted API and use the client:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;docker run -p 8080:8080 ghcr.io/krunalsolanki/ofacmatch-api
pip install ofacmatch
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;





&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight python"&gt;&lt;code&gt;&lt;span class="k"&gt;from&lt;/span&gt; &lt;span class="n"&gt;ofacmatch&lt;/span&gt; &lt;span class="k"&gt;import&lt;/span&gt; &lt;span class="nc"&gt;Client&lt;/span&gt;

&lt;span class="n"&gt;client&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="nc"&gt;Client&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;"http://localhost:8080"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="n"&gt;result&lt;/span&gt; &lt;span class="o"&gt;=&lt;/span&gt; &lt;span class="n"&gt;client&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;screen&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;"Aymen Zawahri"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="n"&gt;year_of_birth&lt;/span&gt;&lt;span class="o"&gt;=&lt;/span&gt;&lt;span class="mi"&gt;1951&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;span class="k"&gt;for&lt;/span&gt; &lt;span class="k"&gt;match&lt;/span&gt; &lt;span class="k"&gt;in&lt;/span&gt; &lt;span class="n"&gt;result&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="s2"&gt;"matches"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;:&lt;/span&gt;
    &lt;span class="k"&gt;print&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="k"&gt;match&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="s2"&gt;"score"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="k"&gt;match&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="s2"&gt;"listedName"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="k"&gt;match&lt;/span&gt;&lt;span class="p"&gt;[&lt;/span&gt;&lt;span class="s2"&gt;"explanation"&lt;/span&gt;&lt;span class="p"&gt;]&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;

&lt;span class="c1"&gt;# How two names score, part by part&lt;/span&gt;
&lt;span class="k"&gt;print&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="n"&gt;client&lt;/span&gt;&lt;span class="p"&gt;.&lt;/span&gt;&lt;span class="nf"&gt;compare&lt;/span&gt;&lt;span class="p"&gt;(&lt;/span&gt;&lt;span class="s2"&gt;"John Smith"&lt;/span&gt;&lt;span class="p"&gt;,&lt;/span&gt; &lt;span class="s2"&gt;"John Numbi"&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;&lt;span class="p"&gt;)&lt;/span&gt;
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;From .NET:&lt;br&gt;
&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight shell"&gt;&lt;code&gt;dotnet add package OfacMatch
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;



&lt;p&gt;There's also an MCP server, so AI assistants like Claude can screen names and explain the results.&lt;/p&gt;

&lt;h2&gt;
  
  
  Limits
&lt;/h2&gt;

&lt;ul&gt;
&lt;li&gt;It checks the &lt;strong&gt;SDN list only&lt;/strong&gt;, not every US or international list.&lt;/li&gt;
&lt;li&gt;A person must review every potential match. A score measures how alike two names are written, not whether two records are the same party.&lt;/li&gt;
&lt;li&gt;It's a screening aid, not legal advice. Pick your threshold from your own risk assessment.&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;It's free and open source (Apache-2.0): &lt;a href="https://github.com/krunalsolanki/ofac-match" rel="noopener noreferrer"&gt;github.com/krunalsolanki/ofac-match&lt;/a&gt;. I'd especially like to hear about name variations that score badly; open an issue with the pair and I'll look at it.&lt;/p&gt;

</description>
      <category>python</category>
      <category>dotnet</category>
      <category>opensource</category>
      <category>fintech</category>
    </item>
  </channel>
</rss>
