Skip to content

Commit

Permalink
Merge pull request #135 from Soulter/doc-sync-cn
Browse files Browse the repository at this point in the history
  • Loading branch information
Soulter authored Oct 31, 2023
2 parents c1c031a + 59e8d76 commit f43737c
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 10 deletions.
10 changes: 5 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,11 @@ English | [简体中文](README_cn.md)

Unofficial HuggingChat Python API, extensible for chatbots etc.

[![PyPi](https://img.shields.io/pypi/v/hugchat.svg?style=for-the-badge&logo=pypi&logoColor=white)](https://pypi.python.org/pypi/hugchat)
[![Support_Platform](https://img.shields.io/badge/3.6+-%234ea94b.svg?style=for-the-badge&logo=python&logoColor=white)](https://pypi.python.org/pypi/hugchat)
[![DownloadsPW](https://img.shields.io/pypi/dw/hugchat?style=for-the-badge&logo=download&logoColor=white)](https://pypi.python.org/pypi/hugchat)
[![Status](https://img.shields.io/badge/status-operational-%234ea94b.svg?style=for-the-badge&logo=ok&logoColor=white)](https://pypi.python.org/pypi/hugchat)
[![Downloads](https://static.pepy.tech/badge/hugchat?style=for-the-badge&logo=download&logoColor=white)](https://www.pepy.tech/projects/hugchat)
[![PyPi](https://img.shields.io/pypi/v/hugchat.svg?logo=pypi&logoColor=white)](https://pypi.python.org/pypi/hugchat)
[![Support_Platform](https://img.shields.io/badge/3.6+-%234ea94b.svg?logo=python&logoColor=white)](https://pypi.python.org/pypi/hugchat)
[![DownloadsPW](https://img.shields.io/pypi/dw/hugchat?logo=download&logoColor=white)](https://pypi.python.org/pypi/hugchat)
[![Status](https://img.shields.io/badge/status-operational-%234ea94b.svg?logo=ok&logoColor=white)](https://pypi.python.org/pypi/hugchat)
[![Downloads](https://static.pepy.tech/badge/hugchat?logo=download&logoColor=white)](https://www.pepy.tech/projects/hugchat)


> **Note**
Expand Down
22 changes: 17 additions & 5 deletions README_cn.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,16 @@

为聊天机器人等程序打造的非官方的 HuggingChat Python API。

[![PyPi](https://img.shields.io/pypi/v/hugchat.svg)](https://pypi.python.org/pypi/hugchat)
[![Support_Platform](https://img.shields.io/pypi/pyversions/hugchat)](https://pypi.python.org/pypi/hugchat)
[![Downloads](https://static.pepy.tech/badge/hugchat)](https://pypi.python.org/pypi/hugchat)

> **Note**
[![PyPi](https://img.shields.io/pypi/v/hugchat.svg?logo=pypi&logoColor=white)](https://pypi.python.org/pypi/hugchat)
[![Support_Platform](https://img.shields.io/badge/3.6+-%234ea94b.svg?logo=python&logoColor=white)](https://pypi.python.org/pypi/hugchat)
[![DownloadsPW](https://img.shields.io/pypi/dw/hugchat?logo=download&logoColor=white)](https://pypi.python.org/pypi/hugchat)
[![Status](https://img.shields.io/badge/status-operational-%234ea94b.svg?logo=ok&logoColor=white)](https://pypi.python.org/pypi/hugchat)
[![Downloads](https://static.pepy.tech/badge/hugchat?logo=download&logoColor=white)](https://www.pepy.tech/projects/hugchat)

> **Note**
>
> 某些较新的版本可能包含不向后兼容的更新,建议在出现问题时查看此 README 或 issues。
>
> 近期更新
> - 联网搜索
> - 上下文记忆
Expand All @@ -28,6 +33,7 @@ pip3 install hugchat

### API

以下展示了本库的常见用法,您不一定需要全部使用,可以根据需要添加或删除一些 :)

```py
from hugchat import hugchat
Expand Down Expand Up @@ -80,6 +86,12 @@ models = chatbot.get_available_llm_models()
# 切换模型
chatbot.switch_llm(0) # 切换到第一个模型
chatbot.switch_llm(1) # 切换到第二个模型

# 从服务器获取所有回话列表
chatbot.get_remote_conversations(replace_conversation_list=True)

# [慎用]删除所有回话
chatbot.delete_all_conversations()
```


Expand Down

0 comments on commit f43737c

Please sign in to comment.