WOLBΛRG

Example — Providers

Mix OpenAI embeddings, Ollama LLM, and BM25 keyword search.

import {
  Wolbarg, sqlite, openaiEmbedding, ollamaLlm, bm25,
} from "wolbarg";

const ctx = new Wolbarg({
  organization: "demo",
  storage: sqlite("./memory.db"),
  embedding: openaiEmbedding({
    apiKey: process.env.OPENAI_API_KEY!,
    model: "text-embedding-3-small",
  }),
  llm: ollamaLlm({ apiKey: "ollama", model: "llama3.2" }),
  keywordSearch: bm25(),
});

On this page