clother

clother

Configure and launch multiple Claude Code–compatible LLM providers from one CLI, switching profiles instantly with simple clother-* commands.

Stars: 112

Visit
 screenshot

Clother is a command-line tool that allows users to switch between different Claude Code providers instantly. It provides launchers for various cloud, open router, China endpoints, local, and custom providers, enabling users to configure, list profiles, test connectivity, check installation status, and uninstall. Users can also change the default model for each provider and troubleshoot common issues. Clother simplifies the management of API keys and installation directories, supporting macOS, Linux, and Windows (WSL) platforms. It is designed to streamline the workflow of interacting with different AI models and services.

README:

Clother

  ____ _       _   _
 / ___| | ___ | |_| |__   ___ _ __
| |   | |/ _ \| __| '_ \ / _ \ '__|
| |___| | (_) | |_| | | |  __/ |
 \____|_|\___/ \__|_| |_|\___|_|

One CLI to switch between Claude Code providers instantly.

License: MIT Shell Platform

Installation

# 1. Install Claude Code CLI
curl -fsSL https://claude.ai/install.sh | bash

# 2. Install Clother
curl -fsSL https://raw.githubusercontent.com/jolehuit/clother/main/clother.sh | bash

Quick Start

clother-native                          # Use your Claude Pro/Team subscription
clother-zai                             # Z.AI (GLM-5)
clother-ollama --model qwen3-coder      # Local with Ollama
clother config                          # Configure providers

Providers

Cloud

Command Provider Model API Key
clother-native Anthropic Claude Your subscription
clother-zai Z.AI GLM-5 z.ai
clother-minimax MiniMax MiniMax-M2.1 minimax.io
clother-kimi Kimi kimi-k2.5 kimi.com
clother-moonshot Moonshot AI kimi-k2.5 moonshot.ai
clother-deepseek DeepSeek deepseek-chat deepseek.com
clother-mimo Xiaomi MiMo mimo-v2-flash xiaomimimo.com

OpenRouter (100+ Models)

Access Grok, Gemini, Mistral and more via openrouter.ai.

clother config openrouter               # Set API key + add models
clother-or-kimi-k2                      # Use it

For non-Claude models, use the :exacto variant (e.g. moonshotai/kimi-k2-0905:exacto).

China Endpoints

Command Endpoint
clother-zai-cn open.bigmodel.cn
clother-minimax-cn api.minimaxi.com
clother-ve ark.cn-beijing.volces.com

Local (No API Key)

Command Provider Port Setup
clother-ollama Ollama 11434 ollama.com
clother-lmstudio LM Studio 1234 lmstudio.ai
clother-llamacpp llama.cpp 8000 github.com/ggml-org/llama.cpp
# Ollama
ollama pull qwen3-coder && ollama serve
clother-ollama --model qwen3-coder

# LM Studio
clother-lmstudio --model <model>

# llama.cpp
./llama-server --model model.gguf --port 8000 --jinja
clother-llamacpp --model <model>

Custom

clother config                          # Choose "custom"
clother-myprovider                      # Ready

Commands

Command Description
clother config [provider] Configure provider
clother list List profiles
clother test Test connectivity
clother status Installation status
clother uninstall Remove everything

Changing the Default Model

Each provider launcher comes with a default model (e.g. glm-5 for Z.AI). You can override it in several ways:

# One-time: use --model flag
clother-zai --model glm-4.7

# Permanent: set ANTHROPIC_MODEL in your shell profile (.zshrc / .bashrc)
export ANTHROPIC_MODEL="glm-4.7"
clother-zai

# Or edit the launcher directly
nano ~/bin/clother-zai    # Replace the model name on all relevant lines

Tip: The --model flag is passed directly to Claude CLI and takes priority over everything else.

How It Works

Clother creates launcher scripts that set environment variables:

# clother-zai does:
export ANTHROPIC_BASE_URL="https://api.z.ai/api/anthropic"
export ANTHROPIC_AUTH_TOKEN="$ZAI_API_KEY"
exec claude "$@"

API keys stored in ~/.local/share/clother/secrets.env (chmod 600).

Install Directory

By default, Clother installs launchers to:

  • macOS: ~/bin
  • Linux: ~/.local/bin (XDG standard)

You can override this with --bin-dir or the CLOTHER_BIN environment variable:

# Using --bin-dir flag
curl -fsSL https://raw.githubusercontent.com/jolehuit/clother/main/clother.sh | bash -s -- --bin-dir ~/.local/bin

# Using environment variable
export CLOTHER_BIN="$HOME/.local/bin"
curl -fsSL https://raw.githubusercontent.com/jolehuit/clother/main/clother.sh | bash

Make sure the chosen directory is in your PATH.

Troubleshooting

Problem Solution
claude: command not found Install Claude CLI first
clother: command not found Add your bin directory to PATH (see Install Directory)
API key not set Run clother config

Platform Support

macOS (zsh/bash) • Linux (zsh/bash) • Windows (WSL)

Contributors

License

MIT © jolehuit

For Tasks:

Click tags to check more tools for each tasks

For Jobs:

Alternative AI tools for clother

Similar Open Source Tools

For similar tasks

For similar jobs