Image-Text-to-Text
RKLLM
GGUF
rknn
rockchip
rk3588
rk1820
intern-decision
multimodal
decision
npu
conversational
Instructions to use wardner/Intern_Decision-0.8B with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- RKLLM
How to use wardner/Intern_Decision-0.8B with RKLLM:
# No code snippets available yet for this library. # To use this model, check the repository files and the library's documentation. # Want to help? PRs adding snippets are welcome at: # https://github.com/huggingface/huggingface.js
- Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- llama.cpp
How to use wardner/Intern_Decision-0.8B with llama.cpp:
Install (macOS, Linux)
curl -LsSf https://llama.app/install.sh | sh # Start a local OpenAI-compatible server with a web UI: llama serve -hf wardner/Intern_Decision-0.8B # Run inference directly in the terminal: llama cli -hf wardner/Intern_Decision-0.8B
Install from WinGet (Windows)
winget install llama.cpp # Start a local OpenAI-compatible server with a web UI: llama serve -hf wardner/Intern_Decision-0.8B # Run inference directly in the terminal: llama cli -hf wardner/Intern_Decision-0.8B
Build from source code
git clone https://github.com/ggml-org/llama.cpp.git cd llama.cpp cmake -B build cmake --build build -j --target llama-app # Start a local OpenAI-compatible server with a web UI: ./build/bin/llama serve -hf wardner/Intern_Decision-0.8B # Run inference directly in the terminal: ./build/bin/llama cli -hf wardner/Intern_Decision-0.8B
Use Docker
docker model run hf.co/wardner/Intern_Decision-0.8B
- Llama new
- LM Studio
- Jan
- vLLM
How to use wardner/Intern_Decision-0.8B with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "wardner/Intern_Decision-0.8B" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "wardner/Intern_Decision-0.8B", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'Use Docker
docker model run hf.co/wardner/Intern_Decision-0.8B
- Ollama
How to use wardner/Intern_Decision-0.8B with Ollama:
ollama run hf.co/wardner/Intern_Decision-0.8B
- Unsloth Desktop
- Pi
How to use wardner/Intern_Decision-0.8B with Pi:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf wardner/Intern_Decision-0.8B
Configure the model in Pi
# Install Pi: npm install -g @earendil-works/pi-coding-agent # Add to ~/.pi/agent/models.json: { "providers": { "llama-cpp": { "baseUrl": "http://localhost:9931/v1", "api": "openai-completions", "apiKey": "none", "models": [ { "id": "wardner/Intern_Decision-0.8B" } ] } } }Run Pi
# Start Pi in your project directory: pi
- Docker Model Runner
How to use wardner/Intern_Decision-0.8B with Docker Model Runner:
docker model run hf.co/wardner/Intern_Decision-0.8B
- Lemonade
How to use wardner/Intern_Decision-0.8B with Lemonade:
Pull the model
# Download Lemonade from https://lemonade-server.ai/ lemonade pull wardner/Intern_Decision-0.8B
Run and chat with the model
lemonade run user.Intern_Decision-0.8B-{{QUANT_TAG}}List all available models
lemonade list
- Hermes Agent
How to use wardner/Intern_Decision-0.8B with Hermes Agent:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf wardner/Intern_Decision-0.8B
Configure Hermes
# Install Hermes: curl -fsSL https://hermes-agent.nousresearch.com/install.sh | bash hermes setup # Point Hermes at the local server: hermes config set model.provider custom hermes config set model.base_url http://127.0.0.1:9931/v1 hermes config set model.default wardner/Intern_Decision-0.8B
Run Hermes
hermes
- Atomic Chat
- OpenClaw
How to use wardner/Intern_Decision-0.8B with OpenClaw:
Start the llama.cpp server
# Install llama.cpp: brew install llama.cpp # Start a local OpenAI-compatible server: llama serve -hf wardner/Intern_Decision-0.8B
Configure OpenClaw
# Install OpenClaw: npm install -g openclaw@latest # Register the local server and set it as the default model: openclaw onboard --non-interactive --mode local \ --auth-choice custom-api-key \ --custom-base-url http://127.0.0.1:9931/v1 \ --custom-model-id "wardner/Intern_Decision-0.8B" \ --custom-provider-id llama-cpp \ --custom-compatibility openai \ --custom-text-input \ --accept-risk \ --skip-health
Run OpenClaw
openclaw agent --local --agent main --message "Hello from Hugging Face"
|
Download README.md from wardner/Intern_Decision-0.8B: direct link, hf CLI and curl.
- Browser
- Download file 5.91 kB
-
https://huggingface.co/wardner/Intern_Decision-0.8B/resolve/main/README.md
- Command line
-
hf download hf://wardner/Intern_Decision-0.8B/README.md
-
curl -L -o README.md https://huggingface.co/wardner/Intern_Decision-0.8B/resolve/main/README.md
5.91 kB
| base_model: internlm/Intern-Decision-0.8B | |
| license: apache-2.0 | |
| library_name: rkllm | |
| pipeline_tag: image-text-to-text | |
| tags: | |
| - rknn | |
| - rockchip | |
| - rk3588 | |
| - rk1820 | |
| - intern-decision | |
| - multimodal | |
| - decision | |
| - npu | |
| # Intern-Decision-0.8B — Rockchip RKNN 部署包 | |
| [Intern-Decision-0.8B](https://huggingface.co/internlm/Intern-Decision-0.8B) 的 **RKNN 导出**, | |
| 供 Rockchip 协处理器(RK1820 / RK3588)上的 NPU 推理使用。 | |
| 上游是原始权重;**本仓库只包含 RKNN 量化导出后的运行期文件**,不能直接用 | |
| `transformers` 加载,需要通过下面的 `wdnai` SDK 加载。 | |
| > 💡 体积约为 4B 版的 **1/4**,速度更快、显存占用更低,可与其它模型同卡共驻。 | |
| > 两者**规格完全一致**(同一个 tokenizer、同一套控制 token、同一套 prompt 协议), | |
| > 迁移时只需换目录和 factory。 | |
| --- | |
| ## ⚠️ 这不是对话模型 | |
| Intern-Decision **不生成文本**。它对任务里的每个「决策字段」输出 **62 个候选符号** | |
| (`A-Z` + `a-z` + `0-9`)的 logits,由 CPU 侧换算成选项概率: | |
| | 字段类型 | 语义 | 输出 | | |
| |---|---|---| | |
| | `choice` | 选一项 | 选项概率(**归一化**,合计为 1) | | |
| | `score` | 打分 | 概率加权评分 | | |
| | `noul` | 是否 | 肯定概率(**不归一化**,各项独立) | | |
| 调用方必须传**任务配置**(`task=`)。答案形如 `{"category": "account", "urgency": 0.7676}`, | |
| 完整概率 / logits 随文本附件一起回传。 | |
| --- | |
| ## 文件说明 | |
| | 文件 | 大小 | 说明 | | |
| |---|---|---| | |
| | `Intern-Decision-0.8B-llm.rknn` | 15.8 MB | LLM 计算图 | | |
| | `Intern-Decision-0.8B-llm.weight` | 293.5 MB | LLM 权重 | | |
| | `Intern-Decision-0.8B-llm.embed.bin` | 485.0 MB | LLM embedding 表(词表 248320) | | |
| | `Intern-Decision-0.8B-llm.tokenizer.gguf` | 10.4 MB | GGUF 预分词器 | | |
| | `Intern-Decision-0.8B-vision.rknn` | 3.1 MB | 视觉编码器计算图(384×384) | | |
| | `Intern-Decision-0.8B-vision.weight` | 202.1 MB | 视觉编码器权重 | | |
| | `intern-decision-0.8b.json` | 3.2 KB | 模型清单(`wdnai` SDK 用) | | |
| | `Intern-Decision-0.8B-llm_report/model_report.html` | 192.6 KB | LLM 转换报告(RKNX 可视化) | | |
| | `Intern-Decision-0.8B-vision_report/model_report.html` | 83.2 KB | 视觉转换报告 | | |
| > 权重走 **Git LFS**;`intern-decision-0.8b.json` 与两份转换报告是**普通文本**, | |
| > 可在 Hub 网页上直接预览。克隆后记得 `git lfs pull`。 | |
| --- | |
| ## 使用 | |
| ### 1. 放置目录 | |
| 默认目录 `/userdata/models/Intern_Decision-0.8B`,也可以用环境变量指定: | |
| ```bash | |
| export WDNAI_INTERN_DECISION_0_8B_DIR=/path/to/Intern_Decision-0.8B | |
| ``` | |
| ### 2. 加载 | |
| ```python | |
| from wdnai.model import SystemLanguageModel | |
| spec = SystemLanguageModel.intern_decision_0_8b() | |
| session = spec.session() # LLM + 视觉编码器常驻,约 900 MB 显存 | |
| ``` | |
| ### 3. 下决策任务 | |
| ```python | |
| from wdnai.decision import parse_decision_task | |
| task = parse_decision_task({ | |
| "questions": { | |
| "广告": {"type": "noul", "criteria": {"no": "没有广告", "yes": "含广告"}}, | |
| "诈骗": {"type": "noul", "criteria": {"no": "没有诈骗", "yes": "含诈骗"}}, | |
| } | |
| }) | |
| text, attachments = session.run_prompt( | |
| prompt="限时优惠,加微信领红包", | |
| attachment=[image], # 可选 | |
| task=task, | |
| ) | |
| ``` | |
| --- | |
| ## 部署注意事项 | |
| - ⚠️ **每个字段必须换一次 LLM session**:模型有 linear-attention 层,递归状态跨调用 | |
| 残留,`keep_history=0` 只清 KV cache 不清递归状态 ⇒ 每个字段都要 | |
| `recreate_llm_session()`。官方 C++ 参考实现同理(每字段 | |
| `rknn3_session_init/destroy`)。 | |
| - ⚠️ **prompt 里的 ChatML 标记是「写进文本」的,不是 chat template**:导出模型的 | |
| `chat_template` 是空的,C 侧必须保持 `set_chat_template("", "", "")`。 | |
| - ⚠️ **控制 token 必须是单 token**:`<decision>`=248077、`<think>`=248068、`</think>`=248069。 | |
| ByteLevel 预分词器会把 `<decision>` 拆开,所以 SDK 在**本模型的 tokenizer 实例上** | |
| 单独注册(不动 Qwen 全局 tokenizer);追加时必须**合并**而不是替换 | |
| `additional_special_tokens`(替换会把 Qwen 的 `<|vision_start|>` / `<|image_pad|>` 踢掉 | |
| → C 库定位不到图片占位区 → 图文 prompt 少喂 6 个 token)。 | |
| - ⚠️ **预分词正则按 GGUF 的 `tokenizer.ggml.pre` 选**,不要用 ByteLevel 自带的 | |
| GPT-2 正则,否则 token id 整体错位。 | |
| - ⚠️ **概率校准温度随 embedding 宽度变化**:本模型 embedding 宽度 **1024** | |
| (4B 是 2560)⇒ 温度 **2.747760550703**(4B 是 1.99241824)。温度是**运行时** | |
| 从 RKNN 内嵌的 `LLM_CONFIG` 读出 `embedding_dim` 再查表得到的,代码里没有写死。 | |
| - ⚠️ **视觉模型常驻**:spec 打开 `keep_vision_resident` ⇒ 带图请求没有首次加载的 | |
| 等待,显存占用稳定可预期。 | |
| - ✅ **与 4B 版完全同规格**:同一个 qwen35 tokenizer(vocab 248320、eos 248046), | |
| 控制 token id 完全一致 ⇒ prompt 协议、视觉预处理(整幅拉伸 resize 384×384 + | |
| RGA 缩放)全部照搬 4B。 | |
| - ✅ **可与其它模型同卡共驻**:显存占用低,适合与翻译等模型共用一张协卡。 | |
| - ⚠️ **显存 900 MB 与初始化 30 秒是估算值**(按 4B 的实测口径外推),本模型尚未 | |
| 逐项实测;4B 的 3200 MB / 60 秒是实测口径。 | |
| --- | |
| ## License | |
| Apache-2.0 —— 与上游 [internlm/Intern-Decision-0.8B](https://huggingface.co/internlm/Intern-Decision-0.8B) | |
| 一致。上游同时提供两份 Apache-2.0(上海人工智能实验室 / Alibaba Cloud), | |
| 本仓库原样保留,见 [`LICENSE`](LICENSE) 与 [`LICENSE-QWEN`](LICENSE-QWEN)。 | |
| 本仓库的 RKNN 导出由 `wdnai` / `wardner` 工具链生成。溯源信息见 [`NOTICE`](NOTICE)。 | |