AI EngineerGuide

How to use z.ai - GLM-5-Turbo in Claude Code

by Ashik Nesin Ashik Nesin

Pony Alpha 2 is the latest stealth LLM that is specifically trained for faster response (and I believe the response won’t be as good as GLM-5) but for certain use cases for causal interaction where you want speed more than accuracy it might be useful.

To use Pony Alpha 2 with Claude Code, you just need to configure your env variables in ~/.claude/settings.json or set it in shell before invoking Claude Code

{
   "env": {
    "ANTHROPIC_AUTH_TOKEN": "$ZAI_API_KEY",
    "ANTHROPIC_BASE_URL": "https://api.z.ai/api/anthropic",
    "API_TIMEOUT_MS": "3000000",
    "ANTHROPIC_DEFAULT_HAIKU_MODEL": "glm-5-turbo",
    "ANTHROPIC_DEFAULT_SONNET_MODEL": "glm-5-turbo",
    "ANTHROPIC_DEFAULT_OPUS_MODEL": "glm-5-turbo"
  }
}

Depending on your preference you can use it for ANTHROPIC_DEFAULT_SONNET_MODEL and ANTHROPIC_DEFAULT_OPUS_MODEL model as well but it might not be as good as glm-5

Reference

#Claude-Code #Glm-5-Turbo

Stay Updated

Get the latest AI engineering insights delivered to your inbox.

No spam. Unsubscribe at any time.