git404hub

what is hrm-embed fr?

okaybroda/hrm-embed — explained in plain English

Analysis updated 2026-05-18

3PythonAudience · researcherComplexity · 4/5LicenseSetup · moderate

tl;dr

A text-embedding model built on a looping reasoning architecture instead of a standard transformer, aimed at multi-step reasoning search tasks.

vibe map

mindmap
  root((hrm-embed))
    What it does
      Turns text into embeddings
      Uses looping HRM backbone
      Helps multi-hop reasoning search
    Tech stack
      Python
      PyTorch
      Transformers
    Use cases
      Search reasoning-heavy documents
      Reproduce BRIGHT benchmark results
      Rewrite queries before embedding
    Audience
      ML researchers
      Retrieval engineers
    Limitations
      Narrow pretraining knowledge
      Not a sentence-transformers model
      Weaker on knowledge-heavy search

Code map

Detail Auto

An interactive map of this repo's files and how they connect — its source is parsed live in your browser. Click Visualize to build it.

filefunction / class

what do people make with this?

VIBE 1

Generate text embeddings for reasoning-heavy document search.

VIBE 2

Reproduce the BRIGHT benchmark results included in the repo.

VIBE 3

Combine raw and rewritten queries to improve retrieval accuracy.

VIBE 4

Study how a looping HRM backbone compares to a standard transformer for embeddings.

what's the stack?

PythonPyTorchTransformersHRM

how it stacks up fr

okaybroda/hrm-embed0marildo/imago0xdfi/glm-5.2-1m-4x-dgx-spark
Stars333
LanguagePythonPythonPython
Setup difficultymoderateeasyhard
Complexity4/52/55/5
Audienceresearchergeneralresearcher

Figures from each repo's GitHub metadata at analysis time.

how do i run it?

Difficulty · moderate time til it works · 30min

Not compatible with sentence-transformers, requires trust_remote_code and manual pooling of the model's hidden state.

in plain english

HRM-Embed is a research model that turns text into a list of numbers, called an embedding, which can then be used to search for similar or related documents. What makes it unusual is the underlying design. Instead of the typical transformer architecture most embedding models use, it is built on top of a different architecture called HRM, which loops over its own internal state multiple times rather than processing text in a single pass, an approach originally designed for reasoning tasks. The author's idea was that this looping behavior might help with a benchmark called BRIGHT, which tests retrieval that requires several logical steps rather than just matching similar wording. That hypothesis partly held up: the model does better on reasoning heavy searches. However, its accuracy is limited by the fact that its base model was trained on a fairly narrow slice of text, so it lacks broad general knowledge, which hurts it on knowledge heavy searches. The README explains that a plain query alone performs weakly, scoring 18.1 on the benchmark's scoring system, but performance jumps to 34.3 when an AI model first rewrites the query into a clearer form before searching. This rewriting step helps almost every subject area except code search, where it can actually hurt results. The project includes the full evaluation code so results can be reproduced. Using the model requires Python and the transformers library, plus code the author includes to pull the embedding out manually since it does not work with the standard sentence-transformers tool most embedding models use. It was trained entirely on a single consumer graphics card. The model builds on an existing open source HRM text model and is released under the Apache 2.0 license.

prompts (copy fr)

prompt 1
Walk me through installing this and generating my first text embedding.
prompt 2
Explain why query rewriting helps most domains but hurts code retrieval here.
prompt 3
Help me reproduce the BRIGHT benchmark evaluation for one domain.
prompt 4
Show me how pooling the recurrence state z_h differs from a normal embedding model.

Frequently asked questions

what is hrm-embed fr?

A text-embedding model built on a looping reasoning architecture instead of a standard transformer, aimed at multi-step reasoning search tasks.

What language is hrm-embed written in?

Mainly Python. The stack also includes Python, PyTorch, Transformers.

How hard is hrm-embed to set up?

Setup difficulty is rated moderate, with roughly 30min to a first successful run.

Who is hrm-embed for?

Mainly researcher.

peek the repo → explain another one

This repo across BitVibe Labs

double-check against the repo, no cap.