• AI Bootcamp
  • Marketingová Plzeň
  • SEO Pivo
  • Contact
  • [email protected]
  • Personal website
[email protected]
Personal website
SEO, AI and Marketing Blog
Martin Bangho
  • Home
  • GEO & SEO
  • AI
  • Marketing
  • CS
  • EN
  • Home
  • GEO & SEO
  • AI
  • Marketing
  • CS
  • EN
Home GEO & SEO
Muž v modré košili nastavuje modré směrové tyčky v malém podstavci.

Vectors in SEO: embeddings, cosine similarity and TF-IDF

Martin Bangho by Martin Bangho
November 24, 2026
in GEO & SEO
Reading Time: 6 mins read
0
0

You can use vectors in SEO to find topically related pages, suggest internal links or provisionally classify content. They help narrow down the pairs worth reading manually. The resulting score, however, is not Google’s assessment of a page, confirmation of cannibalisation or a percentage measure of content quality.

Do not look for the greatest benefit in rewriting text to achieve higher similarity to a query. Look for it in a better analytical shortlist: which pages to examine, what to check and how to decide whether to add a link, expand the content or leave it as it is.

A vector is a representation. What it was built from matters

In this context, a vector is an ordered sequence of numbers. You can convert text into one in various ways. One is to count word occurrences and weight them using TF-IDF. Another is embeddings: numerical representations produced by a model that has learned to capture relationships between texts. There is no single universal map of meaning.

Further reading

Google AI Overviews: co jsou a co sledovat na vlastním webu

Google AI Overviews: What They Are and What to Track on Your Website

November 24, 2026
Muž v modré košili vkládá modrý kruh do dřevěné vkládačky tvarů.

Search Intent: How to Choose the Right Page for a Query

November 24, 2026
Muž v modré košili vkládá modrý dílek do dřevěného třídicího tácku.

How to measure AI visibility: protocol, sample and metrics

November 25, 2026
Odhad návratnosti investice do SEO

Estimating the return on investment in SEO

November 24, 2026

The chosen model, language, settings and input itself affect the output. A vector from a title is not the same as a vector from the main text. If you include navigation, footers and repeated offers in your analysis, you may start finding template similarity instead of article similarity. For long pages, also check how the tool handles its input limit: whether it truncates text, splits it into sections or combines their representations in some way.

The Sentence Transformers documentation demonstrates semantic similarity by first creating text embeddings and then comparing them using a chosen metric. These two steps are worth keeping separate. The model creates the representation; the metric calculates the relationship between representations. Neither step alone determines whether a reader should move from a particular paragraph to another page.

Cosine similarity: what it measures and what not to read into it

Cosine similarity compares the direction of two nonzero vectors. Mathematically, it is their dot product divided by the product of their lengths. The scikit-learn documentation also provides the definition. The same direction gives a value of 1, perpendicular directions give 0 and opposite directions give −1. The actual range of results depends on the representations used; some tools also convert scores to their own scale.

A simple illustrative example uses manually chosen vectors A = (1, 0), B = (1, 1) and C = (0, 1). These are not embeddings of any real pages. The similarity of A and B is approximately 0.707, while A and C have a similarity of 0. The example explains the geometry of the calculation, not an ability to identify the best page for a particular search.

A value of 0.85 therefore does not mean “85% identical content”, “an 85% probability of a correct link” or “85% of Google’s requirements met”. It is the result of a particular calculation on specific inputs. Changing the model, text segment or preprocessing may also change the candidate ranking.

Do not adopt a universal threshold for duplication or internal linking. First, manually label a sample of relevant and irrelevant pairs from your website and see how the method ranks them. For an initial pilot, a few nearest candidates for each page may be more practical than a rigid rule to “automatically insert a link above this value”.

TF-IDF is a useful baseline, not a recipe for rankings

TF-IDF stands for term frequency – inverse document frequency. In simplified terms, it combines how often a term occurs in a document with how many documents in the selected corpus contain it. Words common across the corpus may therefore receive less distinguishing weight than terms characteristic of a subset. The precise calculation and normalisation vary by implementation; the scikit-learn text feature documentation describes them.

Compared with learned embeddings, this representation has the advantage of traceable word features. You might discover, for example, that a particular technology name connects a group of pages. At the same time, a conventional word-based approach may fail to capture synonyms and contextual meaning. In Czech, you also need to consider inflection, tokenisation and possible lemmatisation, which converts inflected forms to their base form. Preprocessing therefore belongs in the analysis record, not in invisible settings.

As a baseline, TF-IDF can show whether a more complex method actually adds value for your task. If both methods return the same usable pairs, there is no reason to automatically favour the more expensive solution. If embeddings find useful connections without shared words, you have a specific benefit to investigate further.

The analysis does not, however, reveal which terms Google requires or how many times you should add them. A word’s high weight in a corpus of competing pages is a property of your corpus and calculation. It does not prove a universal ranking factor. Adding missing words regardless of reader needs is simply another way to turn an expert article into a checklist of compulsory terms.

Turning similarity into internal link suggestions

A practical workflow starts with a page inventory, not model selection. Identify which URLs should be distinct destinations and which are redirected, duplicate or intended to stay out of the index. Add the main topic, page type and business role. You need to know the meaningful linking destination before ranking its potential sources.

  1. Prepare comparable texts. Extract the main content and headings from every page using the same rule. Retain the original URL, date, text version and whether it came from server HTML or rendered content. Flag empty or incorrectly fetched text as an input error.
  2. Create representations using one consistent method. Record the model and version, language preprocessing, text scope, treatment of long documents and metric. Do not directly mix vectors from incompatible models. Do not send private data to an external service without approval.
  3. Rank candidates and add actual links. Find the nearest pages for each destination URL and compare them with the existing source URL → destination URL map. Filter out self-links and already resolved cases, but retain the original evidence.
  4. Read both the source passage and the destination. Find a place where the reader needs a follow-up explanation. Suggest specific anchor text and verify that the destination page fulfils its promise. If there is no suitable place, reject the candidate or record the need for additional content.
  5. Hand over decisions, not just scores. The output should contain the source URL, exact passage, anchor text, destination URL, rationale, priority, owner and review status. A high number alone is not an implementation brief.

The similarity of A and B is symmetric when calculated in the same way. A link, however, has a direction. Moving from a guide to a related service may make sense; linking from every service page to every similar guide may not. You therefore need to compare specific edges in the link graph, not simply mark a pair as “already linked”.

The Moz article on finding internal links with embeddings demonstrates a useful combination of similarity and an export of existing links. You do not need to copy its tools, historical costs or candidate count. The principle is to combine two different inputs and then verify the actual content.

A hypothetical example: similar topic, different next step

Imagine an enterprise software vendor’s website. It has a data migration guide, a migration service page and an article on choosing a system. Embeddings may place them close together. That does not mean they should all link to one another using the same phrase.

In the guide’s paragraph on assigning responsibilities, a link to the migration service’s scope may help the reader. In the system-selection article, the reader instead needs to understand how migration affects the decision before signing a contract. The same topic therefore leads to a different passage, different anchor text and different reason for linking. This illustrates decision-making, not an evaluated client project.

Check negation, different markets and different product types separately. A text on “when not to use this technology” may be very similar to its sales description, but must not mislead the reader. Two pages about the same system may also legitimately address different intents. Without data on queries, destination URLs and their development over time, do not label this similarity as proven cannibalisation.

Why not tune an article to an imagined Google score?

Your local embeddings do not give you access to a search engine’s internal assessment. Nor does using a company’s public model prove that its production search uses the same model, input and metric. A textbook formula, research paper or mention in a patent does not bridge that gap.

In her article on the risks of optimising for vector search, Marie Haynes highlights the difference between appealing to machines and being genuinely useful. Her explanation of possible subsequent ranking changes is an author’s hypothesis, not a verified law governing every edit. A firmer basis for editorial decisions is the audience’s specific needs and Google’s helpful content guidance.

After approved link insertion, first verify actual href values, destination availability and the accuracy of the passage on mobile and desktop. Only then monitor subsequent behaviour and search performance under comparable conditions. Higher average similarity is not the outcome of an SEO project, and a traffic change alone does not prove the effect of one link.

Start with a small group of important pages and manually assess which suggestions were actually usable and why you rejected the others. If you do not yet know which gaps take priority, see SEO gap analysis. Vectors should improve the evidence for a decision, not make it for you.

Need to find meaningful connections between pages?

I can help you choose a suitable analytical approach and turn similarity suggestions into content priorities or internal link briefs. Tell me which content problem you need to solve. We will choose the tools and scope of analysis based on the brief.

Tags: AnalysisTheory
Previous Post

JavaScript and SEO: from page loading to indexing

Next Post

AI personas: roles, boundaries and assistant stability

Martin Bangho

Martin Bangho

I’m Martin Bangho. I’ve worked in digital marketing and built websites since 2015. These days I help companies with SEO and with getting found in AI search. I question things, and I’m picky about the details, but I’m an optimist. I believe marketing can be honest and still make money for a business. When I’m not working on marketing or running my business, you’ll probably find me at the gym, at a hip-hop gig or out with friends. On this blog I write about questions that come up with clients, what I test myself and what I make of the results. Hermes, my AI assistant, helps me write. I bring the notes, the results and my own take. Hermes helps me structure the article, catch grammar mistakes and get back to the point when I’ve gone off on my third tangent in the middle of a sentence. I review and edit every article myself before it goes out, so it says exactly what I mean.

Related articles

Martin Bangho in a white shirt examines two sheets with blue and grey website layouts using a magnifying glass at a wooden desk.
GEO & SEO

Buying a website: how much of its organic traffic is valuable to you?

November 25, 2026
Martin Bangho compares blue and sand-coloured folding-chair models with their matching photo cards.
GEO & SEO

Visual discoverability: connecting images to the right product and location

November 25, 2026
Jak vybrat copywritera?
GEO & SEO

How to Choose a Copywriter

November 24, 2026
SEO GAP Analýza
GEO & SEO

SEO GAP Analysis

November 24, 2026
Next Post
Muž v bílé košili drží prázdný dřevěný rám a ukazuje na jeho vnitřní plochu.

AI personas: roles, boundaries and assistant stability

Odebírat
Upozornit na
0 Komentáře
Nejstarší
Nejnovější Nejlépe hodnocené

Martin Bangho

SEO Consultant & AI Strategist

I use data to build marketing plans with people across a business, from sales and development to content. The aim is to strengthen the brand and help it compete.

Tags

Analysis B2B B2C Brand E-commerce Event reports Google Guide Hermes Off-page SEO On-page SEO SaaS Technical SEO Theory Tools User Experience Websites

Latest posts

  • Buying a website: how much of its organic traffic is valuable to you?
  • Visual discoverability: connecting images to the right product and location
  • How to Choose a Copywriter
  • SEO GAP Analysis
  • How to Create a Content Calendar
  • Home
  • GEO & SEO
  • AI
  • Marketing
  • CS
  • EN

© 2025 Martin Bangho – SEO Consultant & AI Strategist

Welcome Back!

Login to your account below

Forgotten Password?

Retrieve your password

Please enter your username or email address to reset your password.

Log In
  • Home
  • GEO & SEO
  • AI
  • Marketing
  • CS
  • EN
[email protected]

© 2025 Martin Bangho – SEO Consultant & AI Strategist

This website uses cookies. By continuing to use it, you agree to their use. Read our privacy and cookie policy (in Czech).