LLM redis中介的客户端程序
Project description
llm_client_redis
功能
llm_client_redis
介绍
整合多种llm 的api接入,使用 redis 作为消息队列,实现多客户端并发调用 llm 服务。本项目是调用部分,还有另一个项目专门用于接收 redis 消息, 实现与 llm 的通信,并将返回结果给 redis,
软件架构
软件架构说明
安装教程
- xxxx
- xxxx
- xxxx
使用说明
1. python api 调用
llm_client_redis.llm_client.py
一次获取所有回答内容,等待出现相应的时间会较长
from src.llm_client_redis import LLMClientRedis
from langchain_core.messages import BaseMessage, SystemMessage, HumanMessage
from typing import List
llm_client_redis: LLMClientRedis = LLMClientRedis(llm_json_path="../config/llm_resources.json",
config_path="../config/config.ini")
model: str = "home_qwen3:32b"
messages: List[BaseMessage] = [SystemMessage("你是一个好助手"), HumanMessage("你好")]
data = llm_client_redis.request(messages=messages, model=model)
print(data)
2. cmd 调用
chat-session
参与贡献
- Fork 本仓库
- 新建 Feat_xxx 分支
- 提交代码
- 新建 Pull Request
特技
- 使用 Readme_XXX.md 来支持不同的语言,例如 Readme_en.md, Readme_zh.md
- Gitee 官方博客 blog.gitee.com
- 你可以 https://gitee.com/explore 这个地址来了解 Gitee 上的优秀开源项目
- GVP 全称是 Gitee 最有价值开源项目,是综合评定出的优秀开源项目
- Gitee 官方提供的使用手册 https://gitee.com/help
- Gitee 封面人物是一档用来展示 Gitee 会员风采的栏目 https://gitee.com/gitee-stars/
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
llm_client_redis-0.1.0.tar.gz
(20.3 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file llm_client_redis-0.1.0.tar.gz.
File metadata
- Download URL: llm_client_redis-0.1.0.tar.gz
- Upload date:
- Size: 20.3 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.9.23
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
e6f6df03d3bf4171dcc626cb4a05e2714b29124133a8b268f91277ddea4986a7
|
|
| MD5 |
aee9d8c74f54989134e9a4a32d083f4e
|
|
| BLAKE2b-256 |
44af8dba04c4efe83abc0b417b040e04eee0ede5d468a1bac97626792eaad656
|
File details
Details for the file llm_client_redis-0.1.0-py3-none-any.whl.
File metadata
- Download URL: llm_client_redis-0.1.0-py3-none-any.whl
- Upload date:
- Size: 26.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.9.23
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
f2a715b5e80e703882afc98354d44e1ab0b6b21b9f92435ba495a9fca9c74978
|
|
| MD5 |
20f9e04d0033fefef50be1b223a086b0
|
|
| BLAKE2b-256 |
406f85d049b38c75ac070c760faddf616d23aac50fd614c3d027db9403c9eeb5
|