Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(model): Support Gitee models #2257

Merged
merged 3 commits into from
Dec 31, 2024
Merged

feat(model): Support Gitee models #2257

merged 3 commits into from
Dec 31, 2024

Conversation

Aries-ckt
Copy link
Collaborator

Description

Close #2231

https://ai.gitee.com/docs/getting-started/intro

How Has This Been Tested?

  1. Using Gitee proxyllm in DB-GPT webserver
# .env
LLM_MODEL=gitee_proxyllm
GITEE_MODEL_VERSION=Qwen2.5-72B-Instruct
GITEE_API_BASE=https://ai.gitee.com/v1
GITEE_API_KEY={your-gitee-api-key}
  1. Using GiteeLLMClient
    Create python file test_gitee_proxyllm.py
import asyncio

from dbgpt.core import ModelRequest
from dbgpt.model.proxy import GiteeLLMClient

client = GiteeLLMClient(
    model_alias="Qwen2.5-72B-Instruct"
)
print(
    asyncio.run(
        client.generate(
            ModelRequest._build("Qwen2.5-72B-Instruct", "Hi!")
        )
    )
)

Snapshots:

Include snapshots for easier review.

Checklist:

  • My code follows the style guidelines of this project
  • I have already rebased the commits and make the commit message conform to the project standard.
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have made corresponding changes to the documentation
  • Any dependent changes have been merged and published in downstream modules

@github-actions github-actions bot added enhancement New feature or request model Module: model labels Dec 27, 2024
Copy link
Collaborator

@fangyinc fangyinc left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

Copy link
Collaborator

@csunny csunny left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

r+

@csunny csunny merged commit 576da34 into main Dec 31, 2024
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request model Module: model
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Feature] Use Gitee AI Model API ?
3 participants