normalize zai provider to opencode in model listing
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -78,10 +78,11 @@ export async function listPiModels(): Promise<ModelInfo[]> {
|
|||||||
const thinking = extractCol(line, 4);
|
const thinking = extractCol(line, 4);
|
||||||
const images = extractCol(line, 5);
|
const images = extractCol(line, 5);
|
||||||
|
|
||||||
|
const normalizedProvider = provider === 'zai' ? 'opencode' : provider;
|
||||||
models.push({
|
models.push({
|
||||||
id: `${provider}/${model}`,
|
id: `${provider}/${model}`,
|
||||||
name: model,
|
name: model,
|
||||||
provider,
|
provider: normalizedProvider,
|
||||||
contextWindow: parseSize(context),
|
contextWindow: parseSize(context),
|
||||||
maxTokens: parseSize(maxOut),
|
maxTokens: parseSize(maxOut),
|
||||||
reasoning: thinking === 'yes',
|
reasoning: thinking === 'yes',
|
||||||
|
|||||||
Reference in New Issue
Block a user