npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@graphorin/embedder-ollama

v0.8.0

Published

First-class opt-in alternative to @graphorin/embedder-transformersjs for the Graphorin framework. Wraps the local Ollama HTTP API to produce dense embeddings via models such as `nomic-embed-text` (768-dim, multilingual default), `mxbai-embed-large` (1024-

Readme

@graphorin/embedder-ollama

First-class opt-in alternative embedder for the Graphorin framework.

@graphorin/embedder-ollama wraps the local Ollama HTTP API to produce dense embeddings without the bundled-model overhead of @graphorin/embedder-transformersjs. The package ships known output dimensions for ten common Ollama embedding models out of the box (KNOWN_OLLAMA_MODEL_DIMS); any other model works too by passing an explicit dim:

| Model | Dim | Notes | |---|---:|---| | nomic-embed-text (default) | 768 | Multilingual; the de-facto Ollama default. | | mxbai-embed-large | 1024 | Strong English; competitive with cloud peers. | | snowflake-arctic-embed | 1024 | Strong English. | | snowflake-arctic-embed2 | 1024 | Multilingual successor to arctic-embed. | | bge-m3 | 1024 | Multilingual; same family also ships via the transformers.js adapter. | | bge-large | 1024 | Strong English. | | embeddinggemma | 768 | Multilingual (Google). | | paraphrase-multilingual | 768 | Multilingual paraphrase family. | | all-minilm | 384 | Compact English. | | granite-embedding | 384 | Compact (IBM). |

Multi-size models (e.g. tags whose dimension depends on the :0.6b / :4b / :8b variant) are deliberately omitted from the known-dims map so an ambiguous bind fails loudly instead of baking a wrong width.

Install

pnpm add @graphorin/embedder-ollama

The package has no native peers. It uses the standard fetch API to talk to a running Ollama instance (default http://127.0.0.1:11434).

Quick start

import { createOllamaEmbedder } from '@graphorin/embedder-ollama';

const embedder = createOllamaEmbedder({
  model: 'nomic-embed-text',
  baseUrl: 'http://127.0.0.1:11434',
});

const [vec] = await embedder.embed(['Loves espresso.']);
console.log(embedder.id(), embedder.dim(), vec.length);

Trust + privacy

The embedder itself performs no trust classification - it is a thin client for whatever baseUrl you give it, and it never talks to anything else. Point it at a loopback Ollama (http://127.0.0.1:11434, the default) and embeddings never leave the machine. Trust classification and sensitivity gating for LLM traffic live one layer up, in @graphorin/provider's LocalProviderTrust classifier; apply the same judgement before pointing this embedder at a remote host.

Versioning of embedder_id

The canonical id includes the Ollama model digest discovered via POST /api/show at construction time. A model upgrade in the same Ollama instance produces a different digest - and therefore a different embedder_id. The default lock-on-first policy in @graphorin/store-sqlite then fires the same migration path the existing transformersjs swap takes.

License

MIT © 2026 Oleksiy Stepurenko.


Project Graphorin · v0.8.0 · MIT License · © 2026 Oleksiy Stepurenko · https://github.com/o-stepper/graphorin