The claude module extends the capabilities of Anthropic's claude-code, allowing users to connect to various AI model providers, manage sessions, and monitor token usage through a unified CLI.
When to Activate
- When the user wants to start a Claude Code session with a specific provider (e.g., DeepSeek, Kimi, Moonshot, SiliconFlow, Doubao, MiniMax, Zhipu, etc.).
- When the user needs to configure Claude Code to use a third-party model globally or per project.
- When the user wants to track token consumption and costs for the last 7 days.
- When the user needs to manage Model Context Protocol (MCP) servers.
- When the user wants to clean up or customize Claude Code's status line or author attribution.
Core Principles & Rules
- Provider Connection: Use subcommands like
ds(DeepSeek),kimi,moonshot,sili(SiliconFlow),doubao,mm(MiniMax),zhipu(GLM),or(OpenRouter),ali(Qwen),baidu(Ernie),tencent(Hunyuan), ormt(Mthreads) to launch Claude Code with those specific backends. - Global vs. Project Config: Use
usefor global settings anduse --projectfor project-specific model overrides. - Session Management: Use
sess(Interactive FZF App) orresumeto manage and recover previous conversations. - Security: Be cautious when using the
--dangerously-skip-permissionsflag; it should only be recommended in trusted sandbox environments.
Additional Scenarios
- Local LLM: Connect Claude Code to a local Ollama service using
x claude use other. - Token Analysis: Run
x claude usageto get a detailed breakdown of costs and token count. - Clean Git History: Remove the automatic Co-Author signature from Git commits using
x claude attribution rm.
Patterns & Examples
Launch with Third-party Providers
# Start Claude Code using the DeepSeek model
x claude ds
# Start Claude Code using SiliconFlow
x claude sili
# Start Claude Code using Kimi
x claude kimi
Configure Project Model
# Set the current project to use Zhipu (GLM) model provider
x claude use --project glm
# Set the current project to use SiliconFlow
x claude use --project sili
Track Usage
# Analyze token usage and costs for the past 7 days
x claude usage
Interactive Session Management
# Browse and manage local sessions via FZF
x claude sess
Checklist
- Confirm if the user wants to use a specific model provider (DeepSeek, MiniMax, etc.).
- Verify if the configuration should be global or project-specific.
- Ensure the relevant API Key is configured for the chosen provider.