Token导航 LogoToken导航

Agent Skill · 研究检索

ollama-skill(Ollama 技能)

ollama-skill 用于查找、检索和筛选相关信息,适合在 OpenClaw 中需要根据关键词、任务场景或来源线索快速定位候选结果时使用。可结合来源仓库、安装命令和原始 README 继续核验具体用法。安装前建议确认权限范围、维护状态,以及是否会触发联网、命令执行或文件读写。

ollama-skill 是研究检索类 Agent Skill,可用宿主为 OpenClaw,通过ClawHub获取,权限为接触敏感数据;许可证为 MIT-0,第三方扫描已通过,按安装量在研究检索类的 73,675 个 Skill 里排第 30,083。

总安装 2,940周安装 125GitHub Stars 公开资料未说明下载 1,030核验 2026-05-01

安装说明

本站只整理中文说明,不托管安装包,也不代用户安装。
GitHub
许可证
MIT-0
版本
1.0.0

安装方式

通过对话安装

复制提示词发给支持本地命令或 Skills 的 AI 助手,先确认命令和权限,再让它执行。

请帮我安装这个 Agent Skill:ollama-skill(Ollama 技能)
来源仓库:https://github.com/waiyannyeinnaing/ollama-skill
安装命令:
openclaw skills install ollama-skill
安装前请先检查当前环境是否支持对应 CLI,并向我确认将要执行的命令、安装目录、联网范围和文件读写权限;确认后再执行。

命令行安装

复制命令到本机终端执行。该命令会通过 OpenClaw 从第三方来源获取 Skill;本站只展示命令,不托管安装包,也不自动执行。

ClawHubOpenClaw
openclaw skills install ollama-skill

这个 Skill 是做什么的

研究检索类 Skill 主要解决「找资料、核对事实、把来源整理清楚」的问题,通常会让助手先检索再总结。

集成 Ollama 到编码代理、IDE 或代理工具中的通用技能模块。支持本地、Docker 及云部署方式,兼容 OpenAI/Anthropic 等主流接口。提供模型选择、推理调用与结果解析的统一封装接口。使用前需配置 API 密钥、模型路径及部署环境参数。注意不同部署模式下资源占用与安全策略的差异。

上手步骤

4 步
  1. 1

    确认自己的宿主工具

    公开资料标注支持 OpenClaw;先确认自己用的是其中之一,再按对应工具的 Skills 目录放置。

  2. 2

    拿到安装命令

    可以直接复制的命令是 openclaw skills install ollama-skill;命令里的占位符换成自己的路径或密钥再执行。

  3. 3

    安装后重启宿主

    命令执行完要完全退出宿主工具再打开,让新装的 Skill 被重新扫描到,否则列表里可能看不到。

  4. 4

    按最小权限试用

    它需要接触敏感数据,先在测试目录或测试账号里跑,确认没问题再放到正式项目。

常见问题

6 条

ollama-skill 怎么安装?

在终端执行 openclaw skills install ollama-skill。装完完全退出宿主工具再打开,让它重新扫描本地 Skill。

ollama-skill 支持哪些 AI 工具?

公开资料标注支持 OpenClaw。其他工具只要能读取本地 Skill 目录,一般也能手动放进去,但要自己确认触发方式是否一致。

ollama-skill 需要什么权限?

权限级别是接触敏感数据。该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

ollama-skill 是免费的吗?

来源标注的许可证是 MIT-0。本站不代收任何费用,也不托管安装包;能否商用、要不要署名,以许可证原文为准。

ollama-skill 用的人多吗?

公开数据是累计安装 2,940 次,近一周安装 125 次,下载 1,030 次。这些数字来自第三方目录统计,只能当作热度参考,不代表质量或安全性。

ollama-skill 安全吗?

第三方扫描结果为通过,但这只覆盖已知的静态检查项,不能替代自己读一遍源码和安装命令。

值得选的地方和要先想清楚的地方

值得选的地方

  • 专注 OpenClaw 一种宿主,触发方式和使用习惯不用来回切换。
  • 许可证明确为 MIT-0,商用和分发边界好判断。
  • 第三方扫描已通过,常见的高风险行为没有命中。

先想清楚的地方

  • 需要接触敏感数据,装到常用环境前要先评估影响面。
  • 第三方目录整理,版本更新和行为细节以来源仓库为准。

适不适合你

更适合

  • 已经在用 OpenClaw,想直接扩展它能力的人。
  • 需要处理研究检索类任务、又不想每次都手写提示词的人。
  • 需要许可证清楚、并且有第三方扫描结果的团队项目。

不太适合

  • 环境里有大量密钥、凭证,不方便给第三方 Skill 读取的人。
  • 需要厂商级技术支持和 SLA 的生产系统。

研究检索类 Skill 对比

6 个同类
Skill总安装GitHub 星权限许可证扫描
find-skills

寻找技能 · Codex、Claude

31,199,81316,486操作浏览器MIT有提醒
self-improving-agent

自我改进 Agent · OpenClaw

16,464,0023,396接触敏感数据MIT-0通过
soultrace

灵魂追踪 · Codex、Claude

7,588,94412需要联网未明确有提醒
self-improving

自我完善 · OpenClaw

6,829,2841,046需要联网MIT-0通过
microsoft-foundry

微软代工厂 · Codex、Claude

6,614,144764调用外部服务未明确有提醒
ollama-skill

Ollama 技能 · 本页

2,940—接触敏感数据MIT-0通过

按安装量取同分类前几名;数字来自第三方目录统计,只作热度参考,不代表质量结论。

SKILL.md 原文

name
ollama-skill
description
Use when user wants to integrate Ollama into coding agents, IDEs, or agent harnesses. Supports local/on-prem/Docker deployment, Ollama Cloud, OpenAI/Anthropic-compatible endpoints, streaming, structured outputs, embeddings, tool calling, and web search.

Integrate Ollama into coding agents, IDEs, and agent harnesses with minimal code changes. Supports local/on-prem/Docker deployment, Ollama Cloud, and OpenAI/Anthropic-compatible endpoints. Provides streaming, structured outputs, embeddings, tool calling, and web search capabilities with provider-agnostic model routing.

FieldValue
Identifierollama-skill
Version1.0.0
AuthorWai Yan Nyein Naing
Categoryai-ml
Installs0
Rating0 / 5 (0 ratings)
LicenseMIT

GitHub: WaiYanNyeinNaing/ollama-skill — ⭐ 0 | Forks: 0


Skill Overview

Ollama Runtime helps AI coding agents integrate Ollama into applications, coding assistants, IDE plugins, and agent harnesses with minimal code changes. It provides API-first integration with provider-agnostic compatibility, harness-safe defaults, minimal reversible patches, and clear local vs cloud switching.

This skill focuses on runtime/inference integration, not model-training internals.

Use this skill when

  • Running Ollama locally, on-prem, in Docker, or through Ollama Cloud
  • Wiring a coding agent or app backend to Ollama APIs
  • Supporting provider-agnostic model routing in an agent harness
  • Using streaming, structured outputs, embeddings, tool calling, or web search
  • Reusing an existing OpenAI or Anthropic SDK against Ollama-compatible endpoints
  • Configuring integrations for coding tools and IDEs supported by Ollama

Do not use this skill when

  • Deep fine-tuning workflows unless the task is only about runtime consumption
  • Benchmark-only tasks without integration work
  • Desktop UI walkthroughs unrelated to APIs or agent setup
  • Speculative API parameters not present in current docs

Core capabilities

  • Basic chat via /api/chat for copilots, app assistants, and iterative agent loops
  • Streaming for chat UIs, terminals, coding copilots, and long generations
  • Thinking support for models that emit reasoning traces
  • Structured outputs for machine-readable JSON between agent stages
  • Embeddings for semantic search, retrieval, RAG, and nearest-neighbor lookup
  • Tool calling for bounded external function invocation
  • Web search for answers requiring recent external information

Supported integration targets

  • Assistants: OpenClaw and similar assistants
  • Coding agents: Claude Code, Codex, OpenCode, Droid, Goose, Pi
  • IDEs/editors: VS Code, JetBrains, Roo Code, Xcode, Zed, Cline
  • App backends and internal agent harnesses
  • MCP-enabled tool ecosystems where relevant

After Installing

  1. Read SKILL.md inside the installed directory
  2. Follow its instructions to complete the user's task
  3. Come back and rate / comment on the skill (see below)

Core Facts

DeploymentAPI Base URLAuth Required
Localhttp://localhost:11434/apiNo
Dockerhttp://localhost:11434/apiNo
Direct Cloudhttps://ollama.com/apiYes (API key)
  • OpenAI-compatible clients: http://localhost:11434/v1/
  • Anthropic-compatible clients: http://localhost:11434
  • REST API streaming is enabled by default for certain endpoints
  • SDK streaming is disabled by default unless stream=True / stream: true is set

Quick Start

1. Set Environment Variables

# Local / on-prem / Docker
export OLLAMA_HOST=http://localhost:11434
export OLLAMA_API_BASE=http://localhost:11434/api
export OLLAMA_MODEL=qwen3-coder
export OLLAMA_EMBED_MODEL=embeddinggemma

# Direct cloud API (optional)
export OLLAMA_API_KEY=your_api_key

2. Basic Chat Example (Python)

import requests
import os

OLLAMA_API_BASE = os.getenv("OLLAMA_API_BASE", "http://localhost:11434/api")
MODEL = os.getenv("OLLAMA_MODEL", "qwen3-coder")

response = requests.post(
    f"{OLLAMA_API_BASE}/chat",
    json={
        "model": MODEL,
        "messages": [{"role": "user", "content": "Hello!"}],
        "stream": False
    }
)
print(response.json()["message"]["content"])

3. Run the Example

# Clone and setup
git clone https://github.com/WaiYanNyeinNaing/ollama-skill.git
cd ollama-skill
cp .env.example .env
pip install -r requirements.txt

# Run example
python examples/python_native_chat.py

Implementation Guide

Decision Policy

Choose local/on-prem when:

  • Data must stay on-device or inside the internal network
  • The coding agent is colocated with the model host
  • Low-latency tool usage matters
  • The user already has Ollama or Docker available

Choose cloud when:

  • Local hardware is insufficient
  • The user wants larger models quickly
  • Hosted inference is acceptable
  • The app needs a remote Ollama host

Choose compatibility mode when:

  • The codebase already uses OpenAI SDK patterns
  • The codebase already uses Anthropic SDK patterns
  • The user wants minimal migration cost

Implementation Workflow

When integrating Ollama into an app or coding agent, follow this order:

  1. Identify deployment mode: local, local+cloud models, or direct cloud API
  2. Add config surface via environment variables
  3. Implement one basic chat path first
  4. Choose streaming vs non-streaming explicitly
  5. Add structured outputs if downstream parsing is required
  6. Add tool calling if actions are required
  7. Add embeddings if retrieval is required
  8. Add web search only when freshness matters
  9. Use compatibility mode only if it reduces migration cost
  10. Document switching rules clearly

Capability Details

Basic Chat

Use /api/chat for chat-style interactions and coding agents.

import requests

response = requests.post(
    "http://localhost:11434/api/chat",
    json={
        "model": "qwen3-coder",
        "messages": [
            {"role": "system", "content": "You are a helpful coding assistant."},
            {"role": "user", "content": "Write a Python function to reverse a string."}
        ],
        "stream": False
    }
)
result = response.json()
print(result["message"]["content"])

Streaming

Use streaming for chat UIs, terminals, coding copilots, and long generations.

import requests

response = requests.post(
    "http://localhost:11434/api/chat",
    json={
        "model": "qwen3-coder",
        "messages": [{"role": "user", "content": "Write a long story..."}],
        "stream": True
    },
    stream=True
)

for line in response.iter_lines():
    if line:
        chunk = line.decode('utf-8')
        # Parse NDJSON chunks

Rules:

  • REST API responses may stream NDJSON
  • SDKs require explicit stream enablement
  • Streamed chunks may contain content, thinking, or tool_calls

Structured Outputs

Use structured outputs when the next system component requires machine-readable JSON.

import requests

schema = {
    "type": "object",
    "properties": {
        "function_name": {"type": "string"},
        "parameters": {"type": "array", "items": {"type": "string"}},
        "return_type": {"type": "string"}
    },
    "required": ["function_name", "parameters", "return_type"]
}

response = requests.post(
    "http://localhost:11434/api/chat",
    json={
        "model": "qwen3-coder",
        "messages": [{"role": "user", "content": "Analyze this function..."}],
        "stream": False,
        "format": schema
    }
)

Rules:

  • Prefer stream: false
  • Use format: "json" for plain JSON
  • Use a JSON schema in format when shape matters
  • Validate returned data before trusting it
  • Fail closed on parse errors

Embeddings

Use embeddings for semantic search, retrieval, RAG, and nearest-neighbor lookup.

import requests

response = requests.post(
    "http://localhost:11434/api/embed",
    json={
        "model": "embeddinggemma",
        "input": "The quick brown fox jumps over the lazy dog."
    }
)
embeddings = response.json()["embeddings"]

Tool Calling

Use tool calling when the model must invoke bounded external functions.

tools = [
    {
        "type": "function",
        "function": {
            "name": "get_weather",
            "description": "Get current weather for a location",
            "parameters": {
                "type": "object",
                "properties": {
                    "location": {"type": "string"}
                },
                "required": ["location"]
            }
        }
    }
]

response = requests.post(
    "http://localhost:11434/api/chat",
    json={
        "model": "qwen3-coder",
        "messages": [{"role": "user", "content": "What's the weather in Tokyo?"}],
        "tools": tools,
        "stream": False
    }
)

Rules:

  • Expose only minimum required tools
  • Validate all tool arguments
  • Return tool results back into the conversation
  • Keep tools typed and explicit
  • Prefer parallel tool calling only when your executor can safely handle it

Web Search

Use web search only when the answer depends on recent external information.

Rules:

  • Gate behind explicit freshness need
  • Budget for larger context windows for search agents
  • Avoid for stable internal coding tasks
  • Keep API key handling separate from local runtime config

Compatibility Modes

Native Ollama

Prefer native Ollama SDK/API when:

  • Starting a fresh integration
  • You want direct access to Ollama-native features
  • You want the clearest local/cloud switch logic

OpenAI-Compatible

Prefer when:

  • The project already uses openai SDK
  • A base URL swap is cheaper than a rewrite
  • The harness already expects /v1/chat/completions
from openai import OpenAI

client = OpenAI(
    base_url="http://localhost:11434/v1/",
    api_key="ollama"  # Required but ignored locally
)

response = client.chat.completions.create(
    model="qwen3-coder",
    messages=[{"role": "user", "content": "Hello!"}]
)

Anthropic-Compatible

Prefer when:

  • The project already uses anthropic SDK
  • The coding agent or harness expects Anthropic message APIs
  • Claude Code–style local integration is desired
from anthropic import Anthropic

client = Anthropic(
    base_url="http://localhost:11434",
    api_key="ollama"  # Required but ignored locally
)

response = client.messages.create(
    model="qwen3-coder",
    max_tokens=1024,
    messages=[{"role": "user", "content": "Hello!"}]
)

Docker Deployment

Use Docker for repeatable local or server deployment.

CPU baseline:

docker run -d -v ollama:/root/.ollama -p 11434:11434 --name ollama ollama/ollama

With Docker Compose:

docker compose up -d

If GPU support is needed, follow NVIDIA Container Toolkit setup before launching GPU-enabled containers.


Error Handling

Always:

  • Check HTTP status codes
  • Parse error bodies
  • Log model + endpoint + deployment mode
  • Distinguish stream-start errors from mid-stream errors
  • Retry only transient failures
  • Surface JSON/schema failures clearly

Common statuses to handle:

StatusMeaning
400Bad request
404Model not found
429Rate limit
500Internal error
502Upstream/cloud reachability issues

Implementation Patterns

Pattern A: Local Native Ollama

Best for internal tools, local copilots, private workflows.

Pattern B: Local Ollama + Cloud-Backed Models

Best bridge pattern when the user wants local tools with larger hosted models.

Pattern C: Direct Cloud API

Best for hosted backends or when the app should treat Ollama as a remote provider.

Pattern D: Compatibility Adapter

Best when the codebase already depends on OpenAI or Anthropic SDKs.


Coding-Agent and Harness Defaults

For agent systems, default to:

  • Native /api/chat unless an existing provider SDK already dominates the codebase
  • stream=false for planner/executor boundaries
  • Structured JSON between internal agent stages
  • Small typed tool schemas
  • Explicit error propagation
  • Model name isolated in config
  • Provider switch handled in one adapter layer

Recommended adapter boundary:

  • send_chat()
  • embed_texts()
  • invoke_tools()
  • search_web()
  • healthcheck()

Examples Reference

ExampleDescription
python_native_chat.pyBasic chat via native Ollama API
python_streaming_chat.pyStreaming responses
python_embeddings.pyGenerate embeddings
python_structured.pyJSON structured output
python_openai_compat.pyOpenAI SDK compatibility
python_anthropic_compat.pyAnthropic SDK compatibility
python_cloud_direct.pyDirect cloud API usage
javascript_chat.mjsNode.js chat example
javascript_structured.mjsNode.js structured output
curl_chat.shShell/curl example

Output Contract

When applying this skill, produce:

  • Minimal code changes
  • Config additions
  • At least one runnable example
  • Concise docs for local/cloud switching
  • Clear assumptions
  • No secret leakage

Anti-Patterns

Do not:

  • Hardcode API keys
  • Assume every model supports thinking or tool calling
  • Stream strict JSON unless the caller can reconstruct it safely
  • Mix local and cloud auth assumptions without documenting them
  • Expose unrestricted shell execution through tools unless explicitly intended
  • Add unnecessary wrapper layers when a base URL swap is sufficient

Definition of Done

The task is done when:

  • Ollama integration path is implemented or clearly documented
  • Base URL and auth mode are correct
  • Chosen capability matches the user need
  • Examples run with minimal edits
  • Provider switch logic is explicit
  • Errors are handled clearly
  • Docs are concise and harness-friendly

MIT License

Copyright (c) 2026 Dr.Wai Yan Nyein Naing

Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:

The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

平台分布

OpenClaw

92.7%
按下载量换算955

安全审计

VirusTotal

通过

ClawScan

通过

Static analysis

通过

权限和风险

接触敏感数据

该 Skill 可能接触密钥、Token、环境变量或敏感配置,应进入高风险复核队列,默认不自动发布。

安装前确认

本站仅展示第三方公开信息,不托管安装包,不提供自动安装或运行环境。安装前应自行审查源码、依赖和命令行为。目前只有一个公开来源,建议同时核对源仓库。

继续浏览同类 Skills