Borrowing it
Nothing to install: this file belongs to cacr92/WeReply. Take a copy, put it at the same path in your own repository, and replace the rules that are about this project with yours.
curl -O https://raw.githubusercontent.com/cacr92/WeReply/main/.claude/skills/deepseek-integration/SKILL.mdgit clone --depth 1 https://github.com/cacr92/WeReplyWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/cacr92/wereply/deepseek-integration)<a href="https://agentmods.dev/skills/cacr92/wereply/deepseek-integration"><img src="https://agentmods.dev/badge/skills/cacr92/wereply/deepseek-integration/github.svg" alt="Measured on agentmods" height="20"></a>Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.
<a href="https://agentmods.dev/skills/cacr92/wereply/deepseek-integration"><img src="https://agentmods.dev/badge/skills/cacr92/wereply/deepseek-integration.svg" alt="Reviewed on agentmods" width="80" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00112 | $0.04123 |
| Opus 5 | $0.00056 | $0.02062 |
| Sonnet 5 | $0.00022 | $0.00825 |
| Haiku 4.5 | $0.00011 | $0.00412 |
Grade A, and why
deepseek-integration scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 9d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 678 lines — stays where its author put it; the contents beside it link to each section on GitHub.
DeepSeek Integration Skill
Expert guidance for integrating DeepSeek API with reqwest HTTP client, streaming responses, and error handling.
Overview
WeReply uses DeepSeek API to generate reply suggestions:
- HTTP Client: reqwest with connection pooling
- API Endpoint:
https://api.deepseek.com/v1/chat/completions - Authentication: API key via Bearer token
- Response Format: JSON (non-streaming) or Server-Sent Events (streaming)
- Configuration: API key stored in system keychain
HTTP Client Configuration
Reqwest Client Setup
use reqwest::{Client, ClientBuilder};
use std::time::Duration;
use std::sync::Arc;
pub struct DeepSeekClient {
client: Arc<Client>,
api_key: String,
api_endpoint: String,
}
impl DeepSeekClient {
pub fn new(api_key: String) -> anyhow::Result<Self> {
let client = ClientBuilder::new()
.pool_max_idle_per_host(10) // 连接池最大空闲连接数
.timeout(Duration::from_secs(30)) // 请求超时30秒
.connect_timeout(Duration::from_secs(10)) // 连接超时10秒
.build()?;
Ok(Self {
client: Arc::new(client),
api_key,
api_endpoint: "https://api.deepseek.com/v1/chat/completions".to_string(),
})
}
pub fn with_custom_endpoint(mut self, endpoint: String) -> Self {
self.api_endpoint = endpoint;
self
}
}
Connection Pooling Best Practices
// ✓ 共享 Client 实例(连接池复用)
pub struct AppState {
deepseek_client: Arc<DeepSeekClient>,
}
// ✗ 每次创建新 Client(无连接池复用)
pub async fn bad_example() {
let client = DeepSeekClient::new(api_key).unwrap(); // 不要这样做
}
API Request Pattern
Basic Request/Response
use serde::{Deserialize, Serialize};
#[derive(Serialize)]
pub struct ChatCompletionRequest {
model: String,
messages: Vec<ChatMessage>,
#[serde(skip_serializing_if = "Option::is_none")]
temperature: Option<f32>,
#[serde(skip_serializing_if = "Option::is_none")]
max_tokens: Option<u32>,
#[serde(skip_serializing_if = "Option::is_none")]
stream: Option<bool>,
}
#[derive(Serialize, Deserialize)]
pub struct ChatMessage {
role: String, // "system", "user", "assistant"
content: String,
}
#[derive(Deserialize)]
pub struct ChatCompletionResponse {
id: String,
model: String,
choices: Vec<ChatChoice>,
usage: Usage,
}
#[derive(Deserialize)]
pub struct ChatChoice {
index: u32,
message: ChatMessage,
finish_reason: String,
}
#[derive(Deserialize)]
pub struct Usage {
prompt_tokens: u32,
completion_tokens: u32,
total_tokens: u32,
}
What ships with it
1 file beside SKILL.md in the same directory: the scripts, references and assets a skill reads on demand. Not counted in the per-session cost; read them before you install if any of them is executable.
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 9d ago First seen · 678 lines · 112 tokens per session scan A de6cbb725840
deepseek-integration is a skill published in the GitHub repository cacr92/WeReply (6 stars, last pushed 7mo ago), licensed MIT. It adds 112 tokens to every session and 4,123 once invoked, about $0.0006 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
gemini-api-dev
Use this skill when writing code that calls the Gemini API for text generation, multi-turn chat, multimodal understanding, image generation, video generation, streaming responses, background research tasks, function calling, structured output, or migrating from the old generateContent API. Covers SDK usage and best…
anthropic-claude-development
Expert guidance for Anthropic Claude API development including Messages API, tool use, prompt engineering, and building production applications with Claude models.
cloudflare-workers-ai
Cloudflare Workers AI for serverless GPU inference. Use for LLMs, text/image generation, embeddings, or encountering AIERROR, rate limits, token exceeded errors.
openrouter-ai-models-guide
Guide to OpenRouter — the unified API for 200+ AI models from OpenAI, Anthropic, Google, Meta, Mistral, and more. Covers model selection, pricing, routing strategies, fallback chains, and integration with SperaxOS for optimal model usage per task.
LLM
Implement large language model (LLM) chat completions using the z-ai-web-dev-sdk. Use this skill when the user needs to build conversational AI applications, chatbots, AI assistants, or any text generation features. Supports multi-turn conversations, system prompts, and context management.
laravel:ai-sdk
Build AI features with the first-party Laravel AI SDK (Laravel 13+); agents, embeddings, images, audio, and tool calling with provider-agnostic APIs.