Skip to content

How to use Zhipu AI GLM-4.5 #1870

@xiatiandegaga

Description

@xiatiandegaga

1:the version is 0.26.0
2:env file: the name of key of Zhipu is OPENAI_API_KEY?

OPENAI_API_KEY=3ac6dc63f6ea482c9a12f17f353e4b71xxxUxxx

3:config

type: llm
provider: litellm_llm
models:

  • api_base: https://open.bigmodel.cn/api/paas/v4/
    model: openai/glm-4.5
    alias: default
    timeout: 900
    kwargs:
    n: 1
    temperature: 0.1
    top_p: 0.8
    extra_body:
    chat_template_kwargs:
    enable_thinking: false
    allowed_openai_params: ["extra_body"] # Force LiteLLM to allow extra_body

type: embedder
provider: litellm_embedder
models:

  • model: embedding-3
    alias: default
    timeout: 120

only change the embedder as the embedding-3 of Zhipu,because I don‘t have the key of openai

Image

Failed to create asking task.

Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions