Downloads · 30 days
52
18% of all-time downloads
leeroy-jankins/boogr
boogr is a feature extraction model from leeroy-jankins. Use it when you need embeddings to search or compare text. It is set up for sentence-transformers. The card lists the license as mit.
<img src="assets/Booger.png" width="600"/
Downloads · 30 days
52
18% of all-time downloads
All-time downloads
288
Public
Repo size
375 MB
Likes
0
Public
Click a slice to open those files.
.gguf329 MB · 97%
From the Hugging Face model README
Boogr is derived from Google's Emeddinggemma.
The upstream model family is designed for dense retrieval and text embedding tasks such as:
Within Chonky, Boogr is the lightweight local English embedding option and is best suited for:
Chonky supports both hosted and local embedding workflows. Boogr exists to give Chonky users a fully local, low-friction embedding path that avoids dependence on hosted provider APIs for common semantic-search tasks.
Boogr is especially useful when you want:
Boogr is derived from:
Boogr is a 300M parameter, state-of-the-art for its size, open embedding model from Google, built from Gemma 3 (with T5Gemma initialization) and the same research and technology used to create Gemini models. EmbeddingGemma produces vector representations of text, making it well-suited for search and retrieval tasks, including classification, clustering, and semantic similarity search. This model was trained with data in 100+ spoken languages.
The small size and on-device focus makes it possible to deploy in environments with limited resources such as mobile phones, laptops, or desktops, democratizing access to state of the art AI models and helping foster innovation for everyone.
Input:
Output:
These model weights are designed to be used with Sentence Transformers, using the Gemma 3 implementation from Hugging Face Transformers as the backbone.
First install the Sentence Transformers library:
pip install -U sentence-transformers
Then you can load this model and run inference.
from sentence_transformers import SentenceTransformer
# Download from the 🤗 Hub
model = SentenceTransformer("google/embeddinggemma-300m")
# Run inference with queries and documents
query = "Which planet is known as the Red Planet?"
documents = [
"Venus is often called Earth's twin because of its similar size and proximity.",
"Mars, known for its reddish appearance, is often referred to as the Red Planet.",
"Jupiter, the largest planet in our solar system, has a prominent red spot.",
"Saturn, famous for its rings, is sometimes mistaken for the Red Planet."
]
query_embeddings = model.encode_query(query)
document_embeddings = model.encode_document(documents)
print(query_embeddings.shape, document_embeddings.shape)
# (768,) (4, 768)
# Compute similarities to determine a ranking
similarities = model.similarity(query_embeddings, document_embeddings)
print(similarities)
# tensor([[0.3011, 0.6359, 0.4930, 0.4889]])
EmbeddingGemma was trained using the latest generation of Tensor Processing Unit (TPU) hardware (TPUv5e), for more details refer to the Gemma 3 model card.
Training was done using JAX and ML Pathways. For more details refer to the Gemma 3 model card.
The model was evaluated against a large collection of different datasets and metrics to cover different aspects of text understanding.
Note: QAT models are evaluated after quantization
* Mixed Precision refers to per-channel quantization with int4 for embeddings, feedforward, and projection layers, and int8 for attention (e4_a8_f4_p4).
EmbeddingGemma can generate optimized embeddings for various use cases—such as document retrieval, question answering, and fact verification—or for specific input types—either a query or a document—using prompts that are prepended to the input strings.
Query prompts follow the form task: {task description} | query: where the task description varies by the use case, with the default task description being search result. Document-style prompts follow the form title: {title | "none"} | text: where the title is either none (the default) or the actual title of the document. Note that providing a title, if available, will improve model performance for document prompts but may require manual formatting.
Use the following prompts based on your use case and input data type. These may already be available in the EmbeddingGemma configuration in your modeling framework of choice.
<table> <thead> <tr> <th><br> <strong>Use Case (task type enum)</strong></th> <th><br> <strong>Descriptions</strong></th> <th><br> <strong>Recommended Prompt</strong></th> </tr> </thead> <tbody> <tr> <td><br> Retrieval (Query)</td> <td rowspan="4"><br> Used to generate embeddings that are optimized for document search or information retrieval</td> <td><br> task: search result | query: {content}</td> </tr> <tr> <td><br> Retrieval (Document)</td> <td><br> title: {title | "none"} | text: {content}</td> </tr> <tr> <td><br> Question Answering</td> <td><br> task: question answering | query: {content}</td> </tr> <tr> <td><br> Fact Verification</td> <td><br> task: fact checking | query: {content}</td> </tr> <tr> <td><br> Classification</td> <td><br> Used to generate embeddings that are optimized to classify texts according to preset labels</td> <td><br> task: classification | query: {content}</td> </tr> <tr> <td><br> Clustering</td> <td><br> Used to generate embeddings that are optimized to cluster texts based on their similarities</td> <td><br> task: clustering | query: {content}</td> </tr> <tr> <td><br> Semantic Similarity</td> <td><br> Used to generate embeddings that are optimized to assess text similarity. This is not intended for retrieval use cases.</td> <td><br> task: sentence similarity | query: {content}</td> </tr> <tr> <td><br> Code Retrieval</td> <td><br> Used to retrieve a code block based on a natural language query, such as <em>sort an array</em> or <em>reverse a linked list</em>. Embeddings of the code blocks are computed using retrieval_document.</td> <td><br> task: code retrieval | query: {content}</td> </tr> </tbody> </table>These models have certain limitations that users should be aware of.
Open embedding models have a wide range of applications across various industries and domains. The following list of potential uses is not comprehensive. The purpose of this list is to provide contextual information about the possible use-cases that the model creators considered as part of model training and development.
Semantic Similarity: Embeddings optimized to assess text similarity, such as recommendation systems and duplicate detection
Classification: Embeddings optimized to classify texts according to preset labels, such as sentiment analysis and spam detection
Clustering: Embeddings optimized to cluster texts based on their similarities, such as document organization, market research, and anomaly detection
Retrieval
Question Answering: Embeddings for questions in a question-answering system, optimized for finding documents that answer the question, such as chatbox.
Fact Verification: Embeddings for statements that need to be verified, optimized for retrieving documents that contain evidence supporting or refuting the statement, such as automated fact-checking systems.
Training Data
Language Ambiguity and Nuance