One-shot chat completion against DeepSeek's `deepseek-chat` model via the OpenAI-compatible /v1/chat/completions endpoint. Reads DEEPSEEK_API_KEY from the envir
复制下面这句话,粘贴给 Claude Code、Codex、Cursor 等 AI 编程工具,它会读取安装说明并在你确认后完成安装。
请阅读 https://ai.atlankj.com/install/asset/gh-deepseek-chat-4f42ab38d39f ,按照其中的说明把「deepseek-chat」安装到你(当前 AI 工具)中。执行前先告诉我将运行的命令和写入的位置,等我确认。
查看 AI 将读取的安装说明正在读取 GitHub 原文…
内容来自 GitHub 原始文件,由原作者维护。在 GitHub 查看
Wraps DeepSeek's chat/completions endpoint in the same subprocess-invocation
shape as the other ruflo-*-harness skills (see ruflo-metaharness's
harness-score for the reference). No library import on ruflo's boot path.
deepseek-reason instead — same plugin, different model.Implementation: scripts/chat.mjs.
DEEPSEEK_API_KEY from env. If missing, emit
{ status: 'degraded', reason: 'DEEPSEEK_API_KEY is not set', ... }
and exit 0 (ADR-150-style graceful degradation).https://api.deepseek.com/v1/chat/completions with
{ model, messages, temperature?, max_tokens? }. 60s hard timeout.choices[0].message.content and usage counters.--format table prints only the content (for piping); --format json
(default) returns the full envelope.--alert-on-error exits 1 on any degraded/error status (CI-friendly).node plugins/ruflo-deepseek-harness/scripts/chat.mjs \
--prompt "In one sentence: what is HNSW?" \
--temperature 0.2
Sample output:
{
"status": "ok",
"model": "deepseek-chat",
"content": "HNSW is a graph-based approximate nearest neighbor …",
"finishReason": "stop",
"usage": { "promptTokens": 12, "completionTokens": 34, "totalTokens": 46 }
}