llm-zai
LLM CLI plugin for Z.AI / GLM models, including the GLM Coding Plan endpoint.
Installation
llm install llm-zai
Set your API key:
export ZAI_API_KEY="your-zai-api-key"
Or use:
llm keys set zai
Usage
# Basic model invocation
llm -m glm-5.1 "hello"
llm -m glm-5.2 "welcome message"
llm -m glm-5 "generic response"
# Use the Coding Plan endpoint with any GLM model (e.g., --coding flag)
llm -m glm-5.1 --coding "implement a binary search in rust"
llm -m glm-5.2-coding "review this repo"
# Vision models
llm -m glm-5v-turbo "describe this image" -a image.png
# Long‑context / agent models
llm -m autoglm-phone-multilingual "converse about my project"
Options
You can configure the chat behavior via options:
--thinking-type: enabled or disabled (controls whether reasoning is kept)--effort: max or high effort for supported models (e.g., glm-5.2, glm-5.1-coding)--coding: use the GLM Coding Plan endpoint (--coding trueor--coding false)--clear-thinking: preserve reasoning history across turns (true) or clear it (false)
Models
The plugin registers the following GLM models on Z.AI's OpenAI-compatible endpoints:
Chat models
glm-5.2glm-5.1glm-5glm-5-turboglm-ocrglm-5v-turbo
Coding plan variants (use --coding flag)
glm-5.2-coding→glm-5.2glm-5.1-coding→glm-5.1
Long‑context / agent models
autoglm-phone-multilingualglm-4-32b-0414-128k
Vision models
glm-5v-turboglm-ocr
Listing registered models
llm zai models
License
Apache-2.0
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
llm_zai-0.2.1.tar.gz
(14.0 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file llm_zai-0.2.1.tar.gz.
File metadata
- Download URL: llm_zai-0.2.1.tar.gz
- Upload date:
- Size: 14.0 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d85f769a88e9fd3a6b59d6ec71b5f2e524fc2cf610cb181f3ce64cd026fec150
|
|
| MD5 |
06d68269c5c8343b626059983bbaad20
|
|
| BLAKE2b-256 |
6d4b57e526278de5f1d0d3507b9b29e405d1a59e257ce68ebd9f6d3852d8961e
|
File details
Details for the file llm_zai-0.2.1-py3-none-any.whl.
File metadata
- Download URL: llm_zai-0.2.1-py3-none-any.whl
- Upload date:
- Size: 8.3 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.2.0 CPython/3.14.6
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
fc8476394d7a979f68d792e99574258733c3b586c2ef914e53ea1aa339b5e12c
|
|
| MD5 |
e8ebae81e2b0bbc86834cbdeb04d72ed
|
|
| BLAKE2b-256 |
23d96831fea755fdec7b335d4170ad4effb8b3455b54806b1101830abbaa606c
|