ollama-local

ollama-local is a skill for Claude Code from ArieGoldkin/claude-forge. It costs 40 tokens per session (1,334 once invoked), scanned C, original, MIT.

A guide to running language models locally with Ollama, a tool that serves models on your own computer. It covers model selection, LangChain connections, local embeddings, and performance settings.

In plain words
What is it for?
Use it to install and serve local reasoning, coding, general-purpose, or embedding models, connect them to LangChain, and tune local inference.
Why use it?
It helps you develop or run AI features without sending requests to a hosted model service, which can support offline work, privacy, or lower usage costs.

Skill for Claude Code

Written for Claude Code: paths in frontmatter. Also seen: built for aider.

Part of the atk plugin — 16 skills, 25 commands, 1 agent, 1 hook shipped together

Good fit Use it to install and serve local reasoning, coding, general-purpose, or embedding models, connect them to LangChain, and tune local inference.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/ariegoldkin/claude-forge/ollama-local
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add ArieGoldkin/claude-forge --skill ollama-local
Clone the repo
git clone --depth 1 https://github.com/ArieGoldkin/claude-forge

Made for: Claude Code.

Or install atk, the plugin that ships this one along with the rest of its 16 skills, 25 commands, 1 agent, 1 hook.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for ollama-local

README.md
[![agentmods](https://agentmods.dev/badge/skills/ariegoldkin/claude-forge/ollama-local/github.svg)](https://agentmods.dev/skills/ariegoldkin/claude-forge/ollama-local)
Your own site
<a href="https://agentmods.dev/skills/ariegoldkin/claude-forge/ollama-local"><img src="https://agentmods.dev/badge/skills/ariegoldkin/claude-forge/ollama-local/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for ollama-local

Your own site · 80×15
<a href="https://agentmods.dev/skills/ariegoldkin/claude-forge/ollama-local"><img src="https://agentmods.dev/badge/skills/ariegoldkin/claude-forge/ollama-local.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 40 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 1,334 The whole file, excluding the scripts and references it only reads on demand.
Security scan C 2 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00040 $0.01334
Opus 5 $0.00020 $0.00667
Sonnet 5 $0.00008 $0.00267
Haiku 4.5 $0.00004 $0.00133

Measured 10d ago against content hash bb3aeb798daf, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-10, from the pricing page.

Security

Grade C, and why

ollama-local scanned grade C with 2 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 10d ago.

The scan reads SKILL.md. This mod also ships 1 executable file (templates/ollama-provider-template.py), listed below but not scanned — reading those needs a real analyzer, not pattern matching.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Downloads and executes remote codehighSupply chain

curl | sh runs whatever the server returns today, which is not necessarily what it returned when this was reviewed.

curl -fsSL https://ollama.ai/install.sh | sh

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

curl -fsSL https://ollama.ai/install.sh | sh
plugins/ai-toolkit/skills/ollama-local/SKILL.md · 190 lines

How it starts

The opening of the file, as written. The whole thing — 190 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Ollama Local Inference

Run LLMs locally for cost savings, privacy, and offline development.

Quick Start

# Install Ollama
curl -fsSL https://ollama.ai/install.sh | sh

# Pull models
ollama pull deepseek-r1:70b      # Reasoning (GPT-4 level)
ollama pull qwen2.5-coder:32b    # Coding
ollama pull nomic-embed-text     # Embeddings

# Start server
ollama serve
Task Model Size Notes
Reasoning deepseek-r1:70b ~42GB GPT-4 level
Coding qwen2.5-coder:32b ~35GB 73.7% Aider benchmark
Embeddings nomic-embed-text ~0.5GB 768 dims, fast
General llama3.2:70b ~40GB Good all-around

LangChain Integration

from langchain_ollama import ChatOllama, OllamaEmbeddings

# Chat model
llm = ChatOllama(
    model="deepseek-r1:70b",
    base_url="http://localhost:11434",
    temperature=0.0,
    num_ctx=32768,      # Context window
    keep_alive="5m",    # Keep model loaded
)

# Embeddings
embeddings = OllamaEmbeddings(
    model="nomic-embed-text",
    base_url="http://localhost:11434",
)

# Generate
response = await llm.ainvoke("Explain async/await")
vector = await embeddings.aembed_query("search text")

Tool Calling with Ollama

from langchain_core.tools import tool

@tool
def search_docs(query: str) -> str:
    """Search the document database."""
    return f"Found results for: {query}"

# Bind tools
llm_with_tools = llm.bind_tools([search_docs])
response = await llm_with_tools.ainvoke("Search for Python patterns")

Structured Output

from pydantic import BaseModel, Field

class CodeAnalysis(BaseModel):
    language: str = Field(description="Programming language")
    complexity: int = Field(ge=1, le=10)
    issues: list[str] = Field(description="Found issues")

structured_llm = llm.with_structured_output(CodeAnalysis)
result = await structured_llm.ainvoke("Analyze this code: ...")
# result is typed CodeAnalysis object

Read the full file on GitHub · 190 lines

Files

What ships with it

2 files beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 10d ago First seen · 190 lines · 40 tokens per session scan C bb3aeb798daf

Subscribe to this mod's changes

ollama-local is a skill published in the GitHub repository ArieGoldkin/claude-forge (6 stars, last pushed 1mo ago), licensed MIT. It adds 40 tokens to every session and 1,334 once invoked, about $0.0002 per session on Opus 5. A static security scan graded it C with 2 findings (downloads and executes remote code, makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.

Related

Other skills, from other repositories

spark-environment-setup

Set up a working ML training/inference environment on NVIDIA DGX Spark (GB10, aarch64, CUDA 13). Use when installing PyTorch/Unsloth/TRL/vLLM on DGX Spark, hitting libcudart or wheel-ABI errors on aarch64, or choosing between NGC containers and bare pip installs.

wshobson/agents · 76 tokens

spark-memory-thermal-ops

Manage unified memory and thermals during long-running ML jobs on NVIDIA DGX Spark. Use when planning memory headroom for a training run on GB10, when a job OOMs on unified memory, or when monitoring temperature and power during multi-hour training.

wshobson/agents · 59 tokens

spark-training-gotchas

Preflight and diagnose the ten known failure modes for ML training on NVIDIA DGX Spark. Use when a training run on DGX Spark fails to start, OOMs below the 128GB limit, slows down mid-run, or before any multi-hour training job on GB10.

wshobson/agents · 63 tokens

langchain

Framework for building LLM-powered applications with agents, chains, and RAG. Supports multiple providers (OpenAI, Anthropic, Google), 500+ integrations, ReAct agents, tool calling, memory management, and vector store retrieval. Use for building chatbots, question-answering systems, autonomous agents, or RAG…

davila7/claude-code-templates · 79 tokens

llamaindex

Data framework for building LLM applications with RAG. Specializes in document ingestion (300+ connectors), indexing, and querying. Features vector indices, query engines, agents, and multi-modal support. Use for document Q&A, chatbots, knowledge retrieval, or building RAG pipelines. Best for data-centric LLM…

davila7/claude-code-templates · 70 tokens

sglang

Fast structured generation and serving for LLMs with RadixAttention prefix caching. Use for JSON/regex outputs, constrained decoding, agentic workflows with tool calls, or when you need 5× faster inference than vLLM with prefix sharing. Powers 300,000+ GPUs at xAI, AMD, NVIDIA, and LinkedIn.

davila7/claude-code-templates · 72 tokens