Skip to content
06Retrieve

Semantic Retrieval

Load the model to embed this portfolio and search it by meaning.

The retrieval half of RAG, done properly. A sentence-transformer runs locally in your browser and embeds every passage of this portfolio into a 384-dimensional vector. Ask a question in your own words and it is embedded the same way, then ranked by cosine similarity — so a question phrased nothing like the source text still finds it, and the ranking survives synonyms that a keyword search would miss entirely.

  • Sentence embeddings
  • Cosine similarity
  • PCA projection
  • Local inference
Scores are cosine similarity over the full 384-dimensional vectors. The map is a PCA projection down to two axes purely so the space can be looked at — points that appear close really are close, but the reverse is not guaranteed, and no ranking is ever computed from those coordinates. This is the retrieval half of RAG: the part that decides what a language model would have been shown.