跳到正文
cccskills
免费在 GitHub 公开

cli-anything-ollama

Manage Ollama models and run text generation, chat, and embeddings, which represent text as numerical vectors, through command-line requests. Check server status, inspect model details, and receive structured JSON output for agent workflows.

中文简介正在准备中。当前显示英语简介。

原文查看原文说明

Command-line interface for Ollama - Local LLM inference and model management via Ollama REST API. Designed for AI agents and power users who need to manage models, generate text, chat, and create embeddings without a GUI.

查看安装方法

适用场景

  • Download models and inspect their details
  • Generate text or chat with a chosen model
  • Convert text into numerical vectors
  • Check server status and loaded models

包含的文件(1)

  • SKILL.md4.7 KB

SKILL.md(原文)

安装前可以查看交给 AI 代理的指令内容。

cli-anything-ollama

Local LLM inference and model management via the Ollama REST API. Designed for AI agents and power users who need to manage models, generate text, chat, and create embeddings without a GUI.

Installation

This CLI is installed as part of the cli-anything-ollama package:

pip install cli-anything-ollama

Prerequisites:

  • Python 3.10+
  • Ollama must be installed and running (ollama serve)

Usage

Basic Commands

# Show help
cli-anything-ollama --help

# Start interactive REPL mode
cli-anything-ollama

# List available models
cli-anything-ollama model list

# Run with JSON output (for agent consumption)
cli-anything-ollama --json model list

REPL Mode

When invoked without a subcommand, the CLI enters an interactive REPL session:

cli-anything-ollama
# Enter commands interactively with tab-completion and history

Command Groups

Model

Model management commands.

CommandDescription
listList locally available models
showShow model details (parameters, template, license)
pullDownload a model from the Ollama library
rmDelete a model from local storage
copyCopy a model to a new name
psList models currently loaded in memory

Generate

Text generation and chat commands.

CommandDescription
textGenerate text from a prompt
chatSend a chat completion request

Embed

Embedding generation commands.

CommandDescription
textGenerate embeddings for text

Server

Server status and info commands.

CommandDescription
statusCheck if Ollama server is running
versionShow Ollama server version

Session

Session state commands.

CommandDescription
statusShow current session state
historyShow chat history for current session

Examples

List and Pull Models

# List available models
cli-anything-ollama model list

# Pull a model
cli-anything-ollama model pull llama3.2

# Show model details
cli-anything-ollama model show llama3.2

Generate Text

# Stream text (default)
cli-anything-ollama generate text --model llama3.2 --prompt "Explain quantum computing in one sentence"

# Non-streaming with JSON output (for agents)
cli-anything-ollama --json generate text --model llama3.2 --prompt "Hello" --no-stream

Chat

# Single-turn chat
cli-anything-ollama generate chat --model llama3.2 --message "user:What is Python?"

# Multi-turn chat
cli-anything-ollama generate chat --model llama3.2 \
  --message "user:What is Python?" \
  --message "user:How does it compare to JavaScript?"

# Chat from JSON file
cli-anything-ollama generate chat --model llama3.2 --file messages.json

Embeddings

cli-anything-ollama embed text --model nomic-embed-text --input "Hello world"
cli-anything-ollama embed text --model nomic-embed-text --input "Hello" --input "World"

Interactive REPL Session

Start an interactive session for exploratory use.

cli-anything-ollama
# Enter commands interactively
# Use 'help' to see available commands

Connect to Remote Host

cli-anything-ollama --host http://192.168.1.100:11434 model list

State Management

The CLI maintains lightweight session state:

  • Current host URL: Configurable via --host
  • Chat history: Tracked for multi-turn conversations in REPL
  • Last used model: Shown in REPL prompt

Output Formats

All commands support dual output modes:

  • Human-readable (default): Tables, colors, formatted text
  • Machine-readable (--json flag): Structured JSON for agent consumption
# Human output
cli-anything-ollama model list

# JSON output for agents
cli-anything-ollama --json model list

For AI Agents

When using this CLI programmatically:

  1. Always use --json flag for parseable output
  2. Check return codes - 0 for success, non-zero for errors
  3. Parse stderr for error messages on failure
  4. Use --no-stream for generate/chat to get complete responses
  5. Verify Ollama is running with server status before other commands

More Information

  • Full documentation: See README.md in the package
  • Test coverage: See TEST.md in the package
  • Methodology: See HARNESS.md in the cli-anything-plugin

Version

1.0.1

评价

还没有评价。欢迎分享你的使用感受。

评论

无需登录即可发表。欢迎分享使用感受、提问,或说明在哪些环境下无法运行。

还没有评论。来写第一条吧。

提交后会立即公开。请勿填写邮箱、电话等个人信息。URL 最多 2 个。

0 / 1000 字

此表单受 reCAPTCHA 保护,适用 Google 的隐私权政策和服务条款。

同一仓库的技能

Use Reasonix to build or improve a Python command-line interface for existing software. The workflow covers source analysis, interactive commands, JSON output, tests, documentation, and installation checks using the software’s own backend where possible.

中文简介正在准备中。当前显示英语简介。

  • Build command-line access to a GUI application
  • Add missing features to an existing command-line interface
  • Test commands against the actual software backend
HKUDS/CLI-Anything5.5万2026年9月22日 更新

Use Codex to build Python command-line tools for applications with graphical interfaces. Analyze source code, add commands, test against the actual software, validate packaging and documentation, and discover tools already generated or installed.

中文简介正在准备中。当前显示英语简介。

  • Build a command-line tool from application source code
  • Extend an existing tool with more commands
  • Test behavior against the actual application
HKUDS/CLI-Anything5.5万2026年9月22日 更新

Build and improve Python command interfaces for GUI applications with OpenClaw. The skill guides source analysis, command design, testing, and packaging, including interactive sessions and structured JSON output for agents.

中文简介正在准备中。当前显示英语简介。

  • Build a command interface for a GUI application
  • Add missing commands to an existing interface
  • Test workflows against the actual application
HKUDS/CLI-Anything5.5万2026年9月22日 更新

Inspect and edit 3MF files for 3D printing. Detect cylindrical holes, change their diameters, repair mesh issues, and compare files while preserving BambuStudio and PrusaSlicer metadata when repacking the edited file.

中文简介正在准备中。当前显示英语简介。

  • Detect cylindrical holes and check their diameters
  • Resize selected holes to a target diameter
  • Repair degenerate faces and duplicate vertices
HKUDS/CLI-Anything5.5万2026年9月22日 更新

Manage AdGuard Home network filtering from the command line. Update blocklists, register devices, configure DNS rules that map names to addresses, and inspect query logs and statistics through the AdGuard Home REST API.

中文简介正在准备中。当前显示英语简介。

  • Adding and refreshing ad-blocking filter lists
  • Mapping local domain names to IP addresses
  • Registering devices and managing fixed address assignments
HKUDS/CLI-Anything5.5万2026年9月22日 更新

Generate slides, documents, websites, and diagrams from natural language prompts through AnyGen OpenAPI. Manage reference uploads, check generation progress, and download finished files using commands with structured output for AI agents.

中文简介正在准备中。当前显示英语简介。

  • Generate slides or documents from written instructions
  • Upload reference files for a generation task
  • Check generation progress and download finished files
HKUDS/CLI-Anything5.5万2026年9月22日 更新

查看 HKUDS 的全部技能

报告此技能的问题