v2.0.2
大家好啊,在吸收了大家的反馈(需要debug模式)和我个人使用下,现在发布2.0.2版本。
本次更新的主要内容是:新增 zcode-proxy serve debug 来显示你每次的请求体, 例如
(base) PS D:\zcodeplus> zcode-proxy serve debug
=== zcode-proxy DEBUG MODE ===
config file: config.yaml
server: 0.0.0.0:8080
proxy api key: open (no client auth)
provider: bigmodel
plan: coding-plan
identity: appVersion=3.1.2 sourceTitle=cli referer=https://zcode.z.ai
anthropic base: https://open.bigmodel.cn/api/anthropic
openai base: https://open.bigmodel.cn/api/coding/paas/v4
credential: YOUR_A...HERE (17 chars)
models (6): glm-5.1, glm-5, glm-4.7, glm-4.6, glm-4.5, glm-5.2
log level: info
===============================
zcode-proxy listening on http://0.0.0.0:8080
provider: bigmodel
plan: coding-plan
auth mode: oauth
models: 6 available
debug: ON
#001 debug: translated OpenAI→Anthropic (bytes=2434)
#001 debug: body transformed (upstreamFormat=anthropic, startPlan=false, bytes=2539)
#001 debug: → POST https://open.bigmodel.cn/api/anthropic/v1/messages
#001 debug: accept-encoding=gzip anthropic-version=2023-06-01 content-type=application/json http-referer=https://zcode.z.ai user-agent=ZCode/3.1.2 x-api-key=********** x-query-id=query_a639a4a4-3247-4ca6-b360-13d0ee83d7ed x-request-id=b77dc672-b419-40c5-99ab-fe804481bc75 x-session-id=c794d413-dc02-4f5b-98c2-20753d861430 x-title=Z Code@cli x-zcode-agent=glm x-zcode-app-version=3.1.2 x-zcode-trace-id=e2c3f004-3860-495b-9ff0-c7e58189184f
#001 debug: body preview: {"model":"glm-5.2","messages":[{"role":"user","content":"Generate a title for this conversation:\n"},{"role":"user","content":[{"type":"text","text":"How does anthropic models handle toolcalls, espcia…(2538 bytes total)
| # | Time | Fmt | Model | Mode | Stat | TTFB | Tok | tok/s | Total |
|------|------------|-----|-------------|--------|------|---------|-------|--------|---------|
| #001 | 22:38:55 | OAI | glm-5.2 | stream | 200 | 2622ms | 8 | 2.9 | 2771ms |
并且修复了OAI->ANT格式下产生的tool_call翻译错误问题
建议代码工作的同学们尽快下载