@losi-ai/ollama
v0.1.0
Published
Ollama (local) adapter for Losi Context Bank. Give local models persistent business context and switch models without losing it.
Maintainers
Readme
@losi-ai/ollama
Local Ollama adapter for Losi Context Bank. Give your local models persistent business context, then switch models without losing it — no cloud, no API key.
npm install @losi-ai/core @losi-ai/ollama ollamaExample
import { LosiContext } from "@losi-ai/core";
import { OllamaAdapter } from "@losi-ai/ollama";
const ctx = new LosiContext({
adapter: new OllamaAdapter({ model: "llama3.2" }),
});
const res = await ctx.complete("What should I prioritize this week?");
console.log(res.content);- Default model:
llama3.2 - Default host:
http://127.0.0.1:11434(override with thehostoption) - No API key required — talks to your local Ollama server
- Supports streaming via
ctx.stream(...)
MIT licensed.
