{"id":31862,"date":"2026-10-19T12:41:38","date_gmt":"2026-10-19T10:41:38","guid":{"rendered":"https:\/\/wordlift.io\/blog\/en\/?p=31862"},"modified":"2026-10-19T12:41:41","modified_gmt":"2026-10-19T10:41:41","slug":"first-hit-wikidata-search","status":"publish","type":"post","link":"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/","title":{"rendered":"Why first-hit Wikidata search breaks AI agents"},"content":{"rendered":"\n<p>A lot of AI agents identify things the same way: <a target=\"_blank\" rel=\"noreferrer noopener\" href=\"https:\/\/www.wikidata.org\/w\/api.php?action=help&amp;modules=wbsearchentities\">search Wikidata<\/a> for the name, take the first result, move on. It is one line of code and it usually works. We measured how often it does not, and what happens when it fails.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"the-one-line-identity-step\">The one-line identity step<\/h2>\n\n\n\n<p>Here is the pattern, in some form, in many agent tools and RAG pipelines:<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>hits = requests.get(\"https:\/\/www.wikidata.org\/w\/api.php\", params={\n    \"action\": \"wbsearchentities\", \"search\": name,\n    \"language\": \"en\", \"type\": \"item\", \"format\": \"json\"}).json()&#91;\"search\"]\nentity_id = hits&#91;0]&#91;\"id\"] if hits else None<\/code><\/pre>\n\n\n\n<p><code>wbsearchentities<\/code> is a good search box. It matches labels and aliases and ranks the results. It never sees the sentence the name came from, so the first hit is the most likely meaning of the name in general, not in your text.<\/p>\n\n\n\n<p>Try it on this sentence:<\/p>\n\n\n\n<blockquote class=\"wp-block-quote is-layout-flow wp-block-quote-is-layout-flow\">\n<p>Orange reported higher mobile revenue this quarter.<\/p>\n<\/blockquote>\n\n\n\n<p>The first hit for &#8220;Orange&#8221; is <a target=\"_blank\" rel=\"noreferrer noopener\" href=\"https:\/\/www.wikidata.org\/wiki\/Q187796\">Q187796<\/a>, a commune in Vaucluse, France. The company is <a target=\"_blank\" rel=\"noreferrer noopener\" href=\"https:\/\/www.wikidata.org\/wiki\/Q1431486\">Q1431486<\/a>. An agent that takes the first hit now believes a town in Provence publishes quarterly results.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"how-often-it-goes-wrong\">How often it goes wrong<\/h2>\n\n\n\n<p>We ran the six gold sets from the <a target=\"_blank\" rel=\"noreferrer noopener\" href=\"https:\/\/github.com\/wordlift\/content-analysis\">resolve() repository<\/a>: 126 short sentences in English, Italian, French, German, Spanish and Portuguese, with 351 marked names and the correct <a class=\"wl-entity-page-link\"  href=\"https:\/\/wordlift.io\/blog\/en\/entity\/wikidata-2\/\" data-id=\"http:\/\/data.wordlift.io\/wl0216\/entity\/wikidata-2;http:\/\/www.wikidata.org\/entity\/Q2013\" >Wikidata<\/a> ID for each. We gave the same names to the first-hit lookup and to <a target=\"_blank\" rel=\"noreferrer noopener\" href=\"https:\/\/wordlift.io\/resolve\/\">resolve()<\/a>, our entity resolution API, which reads the sentence before it decides. These are our own development sets, not held-out test data, so they favour resolve(); the first-hit errors below do not depend on that.<\/p>\n\n\n\n<style>\n.wl-tw{margin:1.5em 0 2em;overflow-x:auto;-webkit-overflow-scrolling:touch}\n.wl-tw table.wl-t{border-collapse:collapse;width:100%;min-width:var(--wl-min,640px);margin:0;border:0;font-size:15px;line-height:1.4;font-variant-numeric:tabular-nums}\n.wl-t th,.wl-t td{border:0;border-bottom:1px solid #e3e3df;padding:10px 12px;text-align:left;vertical-align:top;word-break:normal;overflow-wrap:normal;hyphens:none;background:transparent}\n.wl-t thead th{border-bottom:2px solid #1a1a1a;font-weight:600;font-size:14px;color:#55554f;vertical-align:bottom;white-space:nowrap}\n.wl-t tbody th{font-weight:600;color:#1a1a1a;white-space:nowrap}\n.wl-t .n{text-align:right;white-space:nowrap}\n.wl-t .m{color:#6b6b66;font-size:13px}\n.wl-t .best{font-weight:700;color:#1a1a1a}\n.wl-t tr.us th,.wl-t tr.us td{background:#eef4fc}\n.wl-t thead th.us{color:#2878d4}\n.wl-t td.us{background:#eef4fc}\n.wl-t tbody th:first-child,.wl-t thead th:first-child{position:sticky;left:0;background:#f5f5f3;z-index:1}\n.wl-t tr.us th:first-child{background:#e3edfa}\n.wl-t code{font-size:.9em;background:#ececea;padding:1px 4px;border-radius:3px}\n.wl-note{font-size:13px;color:#6b6b66;margin:.4em 0 0}\n@media (max-width:640px){.wl-t th,.wl-t td{padding:8px 9px;font-size:14px}}\n<\/style>\n\n<figure class=\"wl-chart\" style=\"margin:2em 0;max-width:760px\">\n<svg id=\"wl-firsthit-outcomes\" viewBox=\"0 0 760 220\" width=\"100%\" role=\"img\" aria-labelledby=\"wl-firsthit-outcomes-t wl-firsthit-outcomes-d\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"font-family:system-ui,-apple-system,'Segoe UI',Roboto,Helvetica,Arial,sans-serif;height:auto;display:block\"><title id=\"wl-firsthit-outcomes-t\">Taking the first hit: 61 wrong links in 351 names, against 23 for resolve()<\/title><desc id=\"wl-firsthit-outcomes-d\">Wikidata search, first hit: 288 right, 61 wrong, 2 no answer, out of 351; resolve(): 321 right, 23 wrong, 7 no answer, out of 351<\/desc><rect width=\"760\" height=\"220\" fill=\"#fff\"\/><text x=\"16.0\" y=\"28.0\" fill=\"#1A1A1A\" font-size=\"16\" text-anchor=\"start\" font-weight=\"600\">Taking the first hit: 61 wrong links in 351 names, against 23 for resolve()<\/text><text x=\"16.0\" y=\"50.0\" fill=\"#5F5F5A\" font-size=\"12\" text-anchor=\"start\" font-weight=\"400\">Six development sets, six languages; each name has one correct Wikidata ID<\/text><rect x=\"16\" y=\"62\" width=\"10\" height=\"10\" fill=\"#C3C3B7\"\/><text x=\"30.0\" y=\"71.0\" fill=\"#5F5F5A\" font-size=\"12\" text-anchor=\"start\" font-weight=\"400\">right<\/text><rect x=\"76\" y=\"62\" width=\"10\" height=\"10\" fill=\"#E38A88\"\/><text x=\"90.0\" y=\"71.0\" fill=\"#5F5F5A\" font-size=\"12\" text-anchor=\"start\" font-weight=\"400\">wrong ID<\/text><rect x=\"160\" y=\"62\" width=\"10\" height=\"10\" fill=\"#ECECE6\"\/><text x=\"174.0\" y=\"71.0\" fill=\"#5F5F5A\" font-size=\"12\" text-anchor=\"start\" font-weight=\"400\">no answer<\/text><text x=\"190.0\" y=\"113.0\" fill=\"#1A1A1A\" font-size=\"12\" text-anchor=\"end\" font-weight=\"400\">Wikidata search, first hit<\/text><rect x=\"200\" y=\"96\" width=\"328.2\" height=\"26\" fill=\"#C3C3B7\"><title>Wikidata search, first hit: 288 right of 351<\/title><\/rect><rect x=\"528.2\" y=\"96\" width=\"69.5\" height=\"26\" fill=\"#E38A88\"><title>Wikidata search, first hit: 61 wrong IDs<\/title><\/rect><rect x=\"597.7\" y=\"96\" width=\"2.3\" height=\"26\" fill=\"#ECECE6\"><title>Wikidata search, first hit: 2 no answer<\/title><\/rect><text x=\"610.0\" y=\"113.0\" fill=\"#1A1A1A\" font-size=\"12\" text-anchor=\"start\" font-weight=\"400\">61 wrong \u00b7 288 right<\/text><text x=\"190.0\" y=\"157.0\" fill=\"#1A1A1A\" font-size=\"12\" text-anchor=\"end\" font-weight=\"400\">resolve()<\/text><rect x=\"200\" y=\"140\" width=\"365.8\" height=\"26\" fill=\"#2878D4\"><title>resolve(): 321 right of 351<\/title><\/rect><rect x=\"565.8\" y=\"140\" width=\"26.2\" height=\"26\" fill=\"#E38A88\"><title>resolve(): 23 wrong IDs<\/title><\/rect><rect x=\"592.0\" y=\"140\" width=\"8.0\" height=\"26\" fill=\"#ECECE6\"><title>resolve(): 7 no answer<\/title><\/rect><text x=\"610.0\" y=\"157.0\" fill=\"#1A1A1A\" font-size=\"12\" text-anchor=\"start\" font-weight=\"600\">23 wrong \u00b7 321 right<\/text><text x=\"16.0\" y=\"206.0\" fill=\"#5F5F5A\" font-size=\"11\" text-anchor=\"start\" font-weight=\"400\">These are resolve()&#x27;s own development sets, so they favour it; the first-hit errors do not depend on that.<\/text><\/svg>\n<figcaption style=\"font-size:13px;color:#5F5F5A;margin-top:.4em\">resolve() development sets, 126 sentences, 351 names. WordLift run of 19 October 2026.<\/figcaption>\n<\/figure>\n\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><tbody><tr><th><\/th><th>Correct<\/th><th>Wrong<\/th><th>No answer<\/th><th>F1<\/th><\/tr><tr><td>Wikidata search, first hit<\/td><td>288<\/td><td>61<\/td><td>2<\/td><td>82.3<\/td><\/tr><tr><td>resolve()<\/td><td>321<\/td><td>23<\/td><td>7<\/td><td>92.4<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p>The first hit is right 82% of the time. That is why the pattern survives: most names in most sentences have one obvious meaning. The trouble is the other 18%, and where it lands.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"what-the-61-errors-look-like\">What the 61 errors look like<\/h2>\n\n\n\n<p>Almost every error is a famous meaning beating the right one:<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><thead><tr><th scope=\"col\">System<\/th><th scope=\"col\">Correct<\/th><th scope=\"col\">Wrong<\/th><th scope=\"col\">No answer<\/th><th scope=\"col\">F1<\/th><\/tr><\/thead><tbody><tr><th scope=\"row\">Wikidata search, first hit<\/th><td>288<\/td><td>61<\/td><td>2<\/td><td>82.3<\/td><\/tr><tr><th scope=\"row\">resolve()<\/th><td>321<\/td><td>23<\/td><td>7<\/td><td>92.4<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p>French was the hardest language for the first hit (70.3 F1): rivers came back as departments and communes, the Louvre as a metro station.<\/p>\n\n\n\n<figure class=\"wl-chart\" style=\"margin:2em 0;max-width:760px\">\n<svg id=\"wl-firsthit-f1-language\" viewBox=\"0 0 760 370\" width=\"100%\" role=\"img\" aria-labelledby=\"wl-firsthit-f1-language-t wl-firsthit-f1-language-d\" xmlns=\"http:\/\/www.w3.org\/2000\/svg\" style=\"font-family:system-ui,-apple-system,'Segoe UI',Roboto,Helvetica,Arial,sans-serif;height:auto;display:block\"><title id=\"wl-firsthit-f1-language-t\">The first hit is weakest in French; resolve() is ahead in all six languages<\/title><desc id=\"wl-firsthit-f1-language-d\">English: first hit 81.4, resolve() 93.5; Italian: first hit 81.8, resolve() 88.6; French: first hit 70.3, resolve() 91.4; German: first hit 89.9, resolve() 94.4; Spanish: first hit 83.3, resolve() 90.5; Portuguese: first hit 84.3, resolve() 93.3<\/desc><rect width=\"760\" height=\"370\" fill=\"#fff\"\/><text x=\"16.0\" y=\"28.0\" fill=\"#1A1A1A\" font-size=\"16\" text-anchor=\"start\" font-weight=\"600\">The first hit is weakest in French; resolve() is ahead in all six languages<\/text><text x=\"16.0\" y=\"50.0\" fill=\"#5F5F5A\" font-size=\"12\" text-anchor=\"start\" font-weight=\"400\">F1 in percent on the development sets; the axis starts at 60<\/text><circle cx=\"22\" cy=\"74\" r=\"5\" fill=\"#55554F\"\/><text x=\"32.0\" y=\"78.0\" fill=\"#5F5F5A\" font-size=\"12\" text-anchor=\"start\" font-weight=\"400\">Wikidata search, first hit<\/text><circle cx=\"212\" cy=\"74\" r=\"5\" fill=\"#2878D4\"\/><text x=\"222.0\" y=\"78.0\" fill=\"#5F5F5A\" font-size=\"12\" text-anchor=\"start\" font-weight=\"400\">resolve()<\/text><line x1=\"140.0\" x2=\"140.0\" y1=\"94\" y2=\"314\" stroke=\"#E6E6E2\"\/><text x=\"140.0\" y=\"332.0\" fill=\"#5F5F5A\" font-size=\"12\" text-anchor=\"middle\" font-weight=\"400\">60<\/text><line x1=\"280.0\" x2=\"280.0\" y1=\"94\" y2=\"314\" stroke=\"#E6E6E2\"\/><text x=\"280.0\" y=\"332.0\" fill=\"#5F5F5A\" font-size=\"12\" text-anchor=\"middle\" font-weight=\"400\">70<\/text><line x1=\"420.0\" x2=\"420.0\" y1=\"94\" y2=\"314\" stroke=\"#E6E6E2\"\/><text x=\"420.0\" y=\"332.0\" fill=\"#5F5F5A\" font-size=\"12\" text-anchor=\"middle\" font-weight=\"400\">80<\/text><line x1=\"560.0\" x2=\"560.0\" y1=\"94\" y2=\"314\" stroke=\"#E6E6E2\"\/><text x=\"560.0\" y=\"332.0\" fill=\"#5F5F5A\" font-size=\"12\" text-anchor=\"middle\" font-weight=\"400\">90<\/text><line x1=\"700.0\" x2=\"700.0\" y1=\"94\" y2=\"314\" stroke=\"#E6E6E2\"\/><text x=\"700.0\" y=\"332.0\" fill=\"#5F5F5A\" font-size=\"12\" text-anchor=\"middle\" font-weight=\"400\">100<\/text><text x=\"126.0\" y=\"108.0\" fill=\"#1A1A1A\" font-size=\"12\" text-anchor=\"end\" font-weight=\"400\">English<\/text><line x1=\"439.6\" x2=\"609.0\" y1=\"104\" y2=\"104\" stroke=\"#C3C3B7\" stroke-width=\"3\"\/><circle cx=\"439.6\" cy=\"104\" r=\"6\" fill=\"#55554F\"><title>English, first hit: F1 81.4<\/title><\/circle><circle cx=\"609.0\" cy=\"104\" r=\"6\" fill=\"#2878D4\"><title>English, resolve(): F1 93.5<\/title><\/circle><text x=\"427.6\" y=\"108.0\" fill=\"#5F5F5A\" font-size=\"12\" text-anchor=\"end\" font-weight=\"400\">81.4<\/text><text x=\"621.0\" y=\"108.0\" fill=\"#1A1A1A\" font-size=\"12\" text-anchor=\"start\" font-weight=\"600\">93.5<\/text><text x=\"126.0\" y=\"146.0\" fill=\"#1A1A1A\" font-size=\"12\" text-anchor=\"end\" font-weight=\"400\">Italian<\/text><line x1=\"445.2\" x2=\"540.4\" y1=\"142\" y2=\"142\" stroke=\"#C3C3B7\" stroke-width=\"3\"\/><circle cx=\"445.2\" cy=\"142\" r=\"6\" fill=\"#55554F\"><title>Italian, first hit: F1 81.8<\/title><\/circle><circle cx=\"540.4\" cy=\"142\" r=\"6\" fill=\"#2878D4\"><title>Italian, resolve(): F1 88.6<\/title><\/circle><text x=\"433.2\" y=\"146.0\" fill=\"#5F5F5A\" font-size=\"12\" text-anchor=\"end\" font-weight=\"400\">81.8<\/text><text x=\"552.4\" y=\"146.0\" fill=\"#1A1A1A\" font-size=\"12\" text-anchor=\"start\" font-weight=\"600\">88.6<\/text><text x=\"126.0\" y=\"184.0\" fill=\"#1A1A1A\" font-size=\"12\" text-anchor=\"end\" font-weight=\"400\">French<\/text><line x1=\"284.2\" x2=\"579.6\" y1=\"180\" y2=\"180\" stroke=\"#C3C3B7\" stroke-width=\"3\"\/><circle cx=\"284.2\" cy=\"180\" r=\"6\" fill=\"#55554F\"><title>French, first hit: F1 70.3<\/title><\/circle><circle cx=\"579.6\" cy=\"180\" r=\"6\" fill=\"#2878D4\"><title>French, resolve(): F1 91.4<\/title><\/circle><text x=\"272.2\" y=\"184.0\" fill=\"#5F5F5A\" font-size=\"12\" text-anchor=\"end\" font-weight=\"400\">70.3<\/text><text x=\"591.6\" y=\"184.0\" fill=\"#1A1A1A\" font-size=\"12\" text-anchor=\"start\" font-weight=\"600\">91.4<\/text><text x=\"126.0\" y=\"222.0\" fill=\"#1A1A1A\" font-size=\"12\" text-anchor=\"end\" font-weight=\"400\">German<\/text><line x1=\"558.6\" x2=\"621.6\" y1=\"218\" y2=\"218\" stroke=\"#C3C3B7\" stroke-width=\"3\"\/><circle cx=\"558.6\" cy=\"218\" r=\"6\" fill=\"#55554F\"><title>German, first hit: F1 89.9<\/title><\/circle><circle cx=\"621.6\" cy=\"218\" r=\"6\" fill=\"#2878D4\"><title>German, resolve(): F1 94.4<\/title><\/circle><text x=\"546.6\" y=\"222.0\" fill=\"#5F5F5A\" font-size=\"12\" text-anchor=\"end\" font-weight=\"400\">89.9<\/text><text x=\"633.6\" y=\"222.0\" fill=\"#1A1A1A\" font-size=\"12\" text-anchor=\"start\" font-weight=\"600\">94.4<\/text><text x=\"126.0\" y=\"260.0\" fill=\"#1A1A1A\" font-size=\"12\" text-anchor=\"end\" font-weight=\"400\">Spanish<\/text><line x1=\"466.2\" x2=\"567.0\" y1=\"256\" y2=\"256\" stroke=\"#C3C3B7\" stroke-width=\"3\"\/><circle cx=\"466.2\" cy=\"256\" r=\"6\" fill=\"#55554F\"><title>Spanish, first hit: F1 83.3<\/title><\/circle><circle cx=\"567.0\" cy=\"256\" r=\"6\" fill=\"#2878D4\"><title>Spanish, resolve(): F1 90.5<\/title><\/circle><text x=\"454.2\" y=\"260.0\" fill=\"#5F5F5A\" font-size=\"12\" text-anchor=\"end\" font-weight=\"400\">83.3<\/text><text x=\"579.0\" y=\"260.0\" fill=\"#1A1A1A\" font-size=\"12\" text-anchor=\"start\" font-weight=\"600\">90.5<\/text><text x=\"126.0\" y=\"298.0\" fill=\"#1A1A1A\" font-size=\"12\" text-anchor=\"end\" font-weight=\"400\">Portuguese<\/text><line x1=\"480.2\" x2=\"606.2\" y1=\"294\" y2=\"294\" stroke=\"#C3C3B7\" stroke-width=\"3\"\/><circle cx=\"480.2\" cy=\"294\" r=\"6\" fill=\"#55554F\"><title>Portuguese, first hit: F1 84.3<\/title><\/circle><circle cx=\"606.2\" cy=\"294\" r=\"6\" fill=\"#2878D4\"><title>Portuguese, resolve(): F1 93.3<\/title><\/circle><text x=\"468.2\" y=\"298.0\" fill=\"#5F5F5A\" font-size=\"12\" text-anchor=\"end\" font-weight=\"400\">84.3<\/text><text x=\"618.2\" y=\"298.0\" fill=\"#1A1A1A\" font-size=\"12\" text-anchor=\"start\" font-weight=\"600\">93.3<\/text><text x=\"16.0\" y=\"356.0\" fill=\"#5F5F5A\" font-size=\"11\" text-anchor=\"start\" font-weight=\"400\">37 to 100 names per language: differences of a few points within one language are noise.<\/text><\/svg>\n<figcaption style=\"font-size:13px;color:#5F5F5A;margin-top:.4em\">resolve() development sets, 126 sentences, 351 names. WordLift run of 19 October 2026.<\/figcaption>\n<\/figure>\n\n\n\n\n<h2 class=\"wp-block-heading\" id=\"why-a-wrong-id-is-worse-than-no-id\">Why a wrong ID is worse than no ID<\/h2>\n\n\n\n<p>Nothing crashes when an agent picks the wrong Liverpool. The wrong ID is stored. It ships in the <a target=\"_blank\" rel=\"noreferrer noopener\" href=\"https:\/\/wordlift.io\/blog\/en\/linked-data-agentic-search\/\">JSON-LD<\/a> on a page, lands in a <a target=\"_blank\" rel=\"noreferrer noopener\" href=\"https:\/\/wordlift.io\/blog\/en\/entity\/knowledge-graph\/\">knowledge graph<\/a>, and gets recalled from the <a target=\"_blank\" rel=\"noreferrer noopener\" href=\"https:\/\/wordlift.io\/blog\/en\/generative-engine-optimization\/\">agent&#8217;s memory<\/a> next week. Every system downstream repeats it, and nobody notices, because a plausible wrong answer looks exactly like a right one.<\/p>\n\n\n\n<p>That is why the useful property is not only being right more often. It is being able to say &#8220;I can&#8217;t tell&#8221;. A search box always returns a first hit. Across 351 names, the first-hit lookup declined twice, both times because no label matched the exact name (&#8220;Fighting Temeraire&#8221;, &#8220;Z\u00fcrcher Flughafen&#8221;), not because it doubted the answer.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"what-reading-the-sentence-fixes-and-what-it-does-not\">What reading the sentence fixes, and what it does not<\/h2>\n\n\n\n<p>resolve() got 39 of the first hit&#8217;s 61 wrong answers right. Nearly all are cases where the sentence clearly points away from the famous meaning: a football score, a river with countries around it, planets in orbit.<\/p>\n\n\n\n<p>It is not free of errors. On 8 names the first hit was right and resolve() was not: 6 wrong answers, most of them a place one level off, and 2 refusals:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>&#8220;Liverpool is a city in the north west of England&#8221; came back with England as the United Kingdom.<\/li>\n\n\n\n<li>&#8220;La Juventus ha battuto il Milan allo Stadium di Torino&#8221; came back with Torino as the football club, not the city.<\/li>\n\n\n\n<li>&#8220;Oscar Niemeyer projetou a Catedral de Bras\u00edlia no Distrito Federal&#8221; came back as Mexico City.<\/li>\n<\/ul>\n\n\n\n<p>22 names beat both, among them &#8220;Jordan won six championships with the Chicago Bulls&#8221; and &#8220;Mozart&#8221; in a German sentence about Salzburg. And resolve() declined 7 times, which is either a missed answer or a saved mistake depending on the name.<\/p>\n\n\n\n<p>These are our own gold sets and they are small, 37 to 100 names per language, so treat differences of a few points within one language as noise. The sets, the scoring rule and the harness are open. <a target=\"_blank\" rel=\"noreferrer noopener\" href=\"https:\/\/github.com\/wordlift\/content-analysis\">Run them yourself<\/a>, and send us corrections: at least one of our gold labels is debatable.<\/p>\n\n\n\n<h2 class=\"wp-block-heading\" id=\"what-to-do-instead-of-taking-the-first-hit\">What to do instead of taking the first hit<\/h2>\n\n\n\n<p>In order of effort:<\/p>\n\n\n\n<ol class=\"wp-block-list\">\n<li><strong>Pass the type.<\/strong> If you know the mention is a person or a football club, filter candidates by type before choosing. It should remove the given-name and family-name errors above (Shakira here; Turner and Aida in the full results).<\/li>\n\n\n\n<li><strong>Read the sentence.<\/strong> Score the candidates against the context, not just the label.<\/li>\n\n\n\n<li><strong>Allow &#8220;no&#8221;.<\/strong> Give your agent a way to receive &#8220;unresolved&#8221; and do something sensible: ask, flag, or leave the name unlinked. Never let it create a record because the lookup came back empty or unsure.<\/li>\n<\/ol>\n\n\n\n<p>resolve() does all three in one call. It returns a stable Wikidata ID or your own ID, or <code>unresolved<\/code> with a reason, and it can check your own <a class=\"wl-entity-page-link\" title=\"Content\" href=\"https:\/\/wordlift.io\/blog\/en\/entity\/knowledge-graph\/\" data-id=\"http:\/\/data.wordlift.io\/wl0216\/entity\/knowledge_graph;https:\/\/www.wikidata.org\/wiki\/Q33002955\" >knowledge graph<\/a> before Wikidata.<\/p>\n\n\n\n<pre class=\"wp-block-code\"><code>r = requests.post(f\"https:\/\/api.wordlift.io\/accounts\/{ACCOUNT}\/resolve\",\n    headers={\"Authorization\": f\"Key {WL_KEY}\"},\n    json={\"text\": \"Orange reported higher mobile revenue this quarter.\", \"language\": \"en\"})<\/code><\/pre>\n\n\n\n<p>Try the three agent demos on your own text, no sign-up: <a target=\"_blank\" rel=\"noreferrer noopener\" href=\"https:\/\/wordlift.io\/resolve\/demos\/\">wordlift.io\/resolve\/demos<\/a>. How resolve() compares with other entity linking APIs on a public benchmark: <a target=\"_blank\" rel=\"noreferrer noopener\" href=\"https:\/\/wordlift.io\/blog\/en\/entity-linking-apis-compared\/\">Entity linking APIs compared<\/a>.<\/p>\n\n\n","protected":false},"excerpt":{"rendered":"<p>Many AI agents identify things by searching Wikidata and taking the first hit. We measured it on 351 names in six languages: it\u2019s right 82% of the time, and the other 18% is a famous meaning beating the right one. Orange becomes a town, Liverpool the city, Java the language.<\/p>\n","protected":false},"author":6,"featured_media":31866,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"_acf_changed":false,"wl_entities_gutenberg":"","_wlpage_enable":"","footnotes":""},"categories":[8],"tags":[],"wl_entity_type":[30],"coauthors":[4226],"class_list":["post-31862","post","type-post","status-publish","format-standard","has-post-thumbnail","hentry","category-seo","wl_entity_type-article"],"acf":[],"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v22.6 - https:\/\/yoast.com\/wordpress\/plugins\/seo\/ -->\n<title>Why first-hit Wikidata search breaks AI agents - WordLift Blog<\/title>\n<meta name=\"description\" content=\"Many AI agents identify things by searching Wikidata and taking the first hit. We measured it on 351 names in six languages: it\u2019s right 82% of the time, and the other 18% is a famous meaning beating the right one. Orange becomes a town, Liverpool the city, Java the language.\" \/>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Why first-hit Wikidata search breaks AI agents - WordLift Blog\" \/>\n<meta property=\"og:description\" content=\"Many AI agents identify things by searching Wikidata and taking the first hit. We measured it on 351 names in six languages: it\u2019s right 82% of the time, and the other 18% is a famous meaning beating the right one. Orange becomes a town, Liverpool the city, Java the language.\" \/>\n<meta property=\"og:url\" content=\"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/\" \/>\n<meta property=\"og:site_name\" content=\"WordLift Blog\" \/>\n<meta property=\"article:published_time\" content=\"2026-10-19T10:41:38+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2026-10-19T10:41:41+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/wordlift.io\/blog\/en\/wp-content\/uploads\/sites\/3\/2026\/10\/featured-first-hit-wikidata-search2x-1.png\" \/>\n\t<meta property=\"og:image:width\" content=\"2400\" \/>\n\t<meta property=\"og:image:height\" content=\"1260\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"Andrea Volpini\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"Andrea Volpini\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"6 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\/\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/#article\",\"isPartOf\":{\"@id\":\"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/\"},\"author\":{\"name\":\"Andrea Volpini\",\"@id\":\"https:\/\/wordlift.io\/blog\/en\/#\/schema\/person\/574352082cc71dab8d164410f1cabe0a\"},\"headline\":\"Why first-hit Wikidata search breaks AI agents\",\"datePublished\":\"2026-10-19T10:41:38+00:00\",\"dateModified\":\"2026-10-19T10:41:41+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/\"},\"wordCount\":1093,\"publisher\":{\"@id\":\"https:\/\/wordlift.io\/blog\/en\/#organization\"},\"image\":{\"@id\":\"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/wordlift.io\/blog\/en\/wp-content\/uploads\/sites\/3\/2026\/10\/featured-first-hit-wikidata-search2x-1.png\",\"articleSection\":[\"seo\"],\"inLanguage\":\"en-US\"},{\"@type\":\"WebPage\",\"@id\":\"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/\",\"url\":\"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/\",\"name\":\"Why first-hit Wikidata search breaks AI agents - WordLift Blog\",\"isPartOf\":{\"@id\":\"https:\/\/wordlift.io\/blog\/en\/#website\"},\"primaryImageOfPage\":{\"@id\":\"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/#primaryimage\"},\"image\":{\"@id\":\"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/#primaryimage\"},\"thumbnailUrl\":\"https:\/\/wordlift.io\/blog\/en\/wp-content\/uploads\/sites\/3\/2026\/10\/featured-first-hit-wikidata-search2x-1.png\",\"datePublished\":\"2026-10-19T10:41:38+00:00\",\"dateModified\":\"2026-10-19T10:41:41+00:00\",\"description\":\"Many AI agents identify things by searching Wikidata and taking the first hit. We measured it on 351 names in six languages: it\u2019s right 82% of the time, and the other 18% is a famous meaning beating the right one. Orange becomes a town, Liverpool the city, Java the language.\",\"breadcrumb\":{\"@id\":\"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/\"]}]},{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/#primaryimage\",\"url\":\"https:\/\/wordlift.io\/blog\/en\/wp-content\/uploads\/sites\/3\/2026\/10\/featured-first-hit-wikidata-search2x-1.png\",\"contentUrl\":\"https:\/\/wordlift.io\/blog\/en\/wp-content\/uploads\/sites\/3\/2026\/10\/featured-first-hit-wikidata-search2x-1.png\",\"width\":2400,\"height\":1260,\"caption\":\"Why first-hit Wikidata search breaks AI agents\"},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Blog\",\"item\":\"https:\/\/wordlift.io\/blog\/en\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Why first-hit Wikidata search breaks AI agents\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\/\/wordlift.io\/blog\/en\/#website\",\"url\":\"https:\/\/wordlift.io\/blog\/en\/\",\"name\":\"WordLift Blog\",\"description\":\"AI-Powered SEO\",\"publisher\":{\"@id\":\"https:\/\/wordlift.io\/blog\/en\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\/\/wordlift.io\/blog\/en\/?s={search_term_string}\"},\"query-input\":\"required name=search_term_string\"}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\/\/wordlift.io\/blog\/en\/#organization\",\"name\":\"WordLift\",\"url\":\"https:\/\/wordlift.io\/blog\/en\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/wordlift.io\/blog\/en\/#\/schema\/logo\/image\/\",\"url\":\"https:\/\/mk0wordliftblog7j5te.kinstacdn.com\/wp-content\/uploads\/sites\/3\/2017\/04\/logo-1.png\",\"contentUrl\":\"https:\/\/mk0wordliftblog7j5te.kinstacdn.com\/wp-content\/uploads\/sites\/3\/2017\/04\/logo-1.png\",\"width\":152,\"height\":40,\"caption\":\"WordLift\"},\"image\":{\"@id\":\"https:\/\/wordlift.io\/blog\/en\/#\/schema\/logo\/image\/\"}},{\"@type\":\"Person\",\"@id\":\"https:\/\/wordlift.io\/blog\/en\/#\/schema\/person\/574352082cc71dab8d164410f1cabe0a\",\"name\":\"Andrea Volpini\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\/\/wordlift.io\/blog\/en\/#\/schema\/person\/image\/466a1652833e48ca11c81b363eba7c25\",\"url\":\"https:\/\/secure.gravatar.com\/avatar\/6b9d3d311b50a8749201fe4b318907a8?s=96&d=mm&r=pg\",\"contentUrl\":\"https:\/\/secure.gravatar.com\/avatar\/6b9d3d311b50a8749201fe4b318907a8?s=96&d=mm&r=pg\",\"caption\":\"Andrea Volpini\"}}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Why first-hit Wikidata search breaks AI agents - WordLift Blog","description":"Many AI agents identify things by searching Wikidata and taking the first hit. We measured it on 351 names in six languages: it\u2019s right 82% of the time, and the other 18% is a famous meaning beating the right one. Orange becomes a town, Liverpool the city, Java the language.","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/","og_locale":"en_US","og_type":"article","og_title":"Why first-hit Wikidata search breaks AI agents - WordLift Blog","og_description":"Many AI agents identify things by searching Wikidata and taking the first hit. We measured it on 351 names in six languages: it\u2019s right 82% of the time, and the other 18% is a famous meaning beating the right one. Orange becomes a town, Liverpool the city, Java the language.","og_url":"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/","og_site_name":"WordLift Blog","article_published_time":"2026-10-19T10:41:38+00:00","article_modified_time":"2026-10-19T10:41:41+00:00","og_image":[{"width":2400,"height":1260,"url":"https:\/\/wordlift.io\/blog\/en\/wp-content\/uploads\/sites\/3\/2026\/10\/featured-first-hit-wikidata-search2x-1.png","type":"image\/png"}],"author":"Andrea Volpini","twitter_card":"summary_large_image","twitter_misc":{"Written by":"Andrea Volpini","Est. reading time":"6 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/#article","isPartOf":{"@id":"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/"},"author":{"name":"Andrea Volpini","@id":"https:\/\/wordlift.io\/blog\/en\/#\/schema\/person\/574352082cc71dab8d164410f1cabe0a"},"headline":"Why first-hit Wikidata search breaks AI agents","datePublished":"2026-10-19T10:41:38+00:00","dateModified":"2026-10-19T10:41:41+00:00","mainEntityOfPage":{"@id":"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/"},"wordCount":1093,"publisher":{"@id":"https:\/\/wordlift.io\/blog\/en\/#organization"},"image":{"@id":"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/#primaryimage"},"thumbnailUrl":"https:\/\/wordlift.io\/blog\/en\/wp-content\/uploads\/sites\/3\/2026\/10\/featured-first-hit-wikidata-search2x-1.png","articleSection":["seo"],"inLanguage":"en-US"},{"@type":"WebPage","@id":"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/","url":"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/","name":"Why first-hit Wikidata search breaks AI agents - WordLift Blog","isPartOf":{"@id":"https:\/\/wordlift.io\/blog\/en\/#website"},"primaryImageOfPage":{"@id":"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/#primaryimage"},"image":{"@id":"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/#primaryimage"},"thumbnailUrl":"https:\/\/wordlift.io\/blog\/en\/wp-content\/uploads\/sites\/3\/2026\/10\/featured-first-hit-wikidata-search2x-1.png","datePublished":"2026-10-19T10:41:38+00:00","dateModified":"2026-10-19T10:41:41+00:00","description":"Many AI agents identify things by searching Wikidata and taking the first hit. We measured it on 351 names in six languages: it\u2019s right 82% of the time, and the other 18% is a famous meaning beating the right one. Orange becomes a town, Liverpool the city, Java the language.","breadcrumb":{"@id":"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/"]}]},{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/#primaryimage","url":"https:\/\/wordlift.io\/blog\/en\/wp-content\/uploads\/sites\/3\/2026\/10\/featured-first-hit-wikidata-search2x-1.png","contentUrl":"https:\/\/wordlift.io\/blog\/en\/wp-content\/uploads\/sites\/3\/2026\/10\/featured-first-hit-wikidata-search2x-1.png","width":2400,"height":1260,"caption":"Why first-hit Wikidata search breaks AI agents"},{"@type":"BreadcrumbList","@id":"https:\/\/wordlift.io\/blog\/en\/first-hit-wikidata-search\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Blog","item":"https:\/\/wordlift.io\/blog\/en\/"},{"@type":"ListItem","position":2,"name":"Why first-hit Wikidata search breaks AI agents"}]},{"@type":"WebSite","@id":"https:\/\/wordlift.io\/blog\/en\/#website","url":"https:\/\/wordlift.io\/blog\/en\/","name":"WordLift Blog","description":"AI-Powered SEO","publisher":{"@id":"https:\/\/wordlift.io\/blog\/en\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/wordlift.io\/blog\/en\/?s={search_term_string}"},"query-input":"required name=search_term_string"}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/wordlift.io\/blog\/en\/#organization","name":"WordLift","url":"https:\/\/wordlift.io\/blog\/en\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/wordlift.io\/blog\/en\/#\/schema\/logo\/image\/","url":"https:\/\/mk0wordliftblog7j5te.kinstacdn.com\/wp-content\/uploads\/sites\/3\/2017\/04\/logo-1.png","contentUrl":"https:\/\/mk0wordliftblog7j5te.kinstacdn.com\/wp-content\/uploads\/sites\/3\/2017\/04\/logo-1.png","width":152,"height":40,"caption":"WordLift"},"image":{"@id":"https:\/\/wordlift.io\/blog\/en\/#\/schema\/logo\/image\/"}},{"@type":"Person","@id":"https:\/\/wordlift.io\/blog\/en\/#\/schema\/person\/574352082cc71dab8d164410f1cabe0a","name":"Andrea Volpini","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/wordlift.io\/blog\/en\/#\/schema\/person\/image\/466a1652833e48ca11c81b363eba7c25","url":"https:\/\/secure.gravatar.com\/avatar\/6b9d3d311b50a8749201fe4b318907a8?s=96&d=mm&r=pg","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/6b9d3d311b50a8749201fe4b318907a8?s=96&d=mm&r=pg","caption":"Andrea Volpini"}}]}},"_wl_alt_label":[],"wl:entity_url":"http:\/\/data.wordlift.io\/wl0216\/post\/why-first-hit-wikidata-search-breaks-ai-agents-31862","_links":{"self":[{"href":"https:\/\/wordlift.io\/blog\/en\/wp-json\/wp\/v2\/posts\/31862"}],"collection":[{"href":"https:\/\/wordlift.io\/blog\/en\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/wordlift.io\/blog\/en\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/wordlift.io\/blog\/en\/wp-json\/wp\/v2\/users\/6"}],"replies":[{"embeddable":true,"href":"https:\/\/wordlift.io\/blog\/en\/wp-json\/wp\/v2\/comments?post=31862"}],"version-history":[{"count":5,"href":"https:\/\/wordlift.io\/blog\/en\/wp-json\/wp\/v2\/posts\/31862\/revisions"}],"predecessor-version":[{"id":31868,"href":"https:\/\/wordlift.io\/blog\/en\/wp-json\/wp\/v2\/posts\/31862\/revisions\/31868"}],"wp:featuredmedia":[{"embeddable":true,"href":"https:\/\/wordlift.io\/blog\/en\/wp-json\/wp\/v2\/media\/31866"}],"wp:attachment":[{"href":"https:\/\/wordlift.io\/blog\/en\/wp-json\/wp\/v2\/media?parent=31862"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/wordlift.io\/blog\/en\/wp-json\/wp\/v2\/categories?post=31862"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/wordlift.io\/blog\/en\/wp-json\/wp\/v2\/tags?post=31862"},{"taxonomy":"wl_entity_type","embeddable":true,"href":"https:\/\/wordlift.io\/blog\/en\/wp-json\/wp\/v2\/wl_entity_type?post=31862"},{"taxonomy":"author","embeddable":true,"href":"https:\/\/wordlift.io\/blog\/en\/wp-json\/wp\/v2\/coauthors?post=31862"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}