diff --git a/PyPI/setup.cfg b/PyPI/setup.cfg index cf367c1..4f295c8 100644 --- a/PyPI/setup.cfg +++ b/PyPI/setup.cfg @@ -1,7 +1,7 @@ [metadata] # replace with your username: name = guan -version = 0.1.130 +version = 0.1.131 author = guanjihuan author_email = guanjihuan@163.com description = An open source python package diff --git a/PyPI/src/guan.egg-info/PKG-INFO b/PyPI/src/guan.egg-info/PKG-INFO index 72f01e0..6d3effc 100644 --- a/PyPI/src/guan.egg-info/PKG-INFO +++ b/PyPI/src/guan.egg-info/PKG-INFO @@ -1,6 +1,6 @@ Metadata-Version: 2.1 Name: guan -Version: 0.1.130 +Version: 0.1.131 Summary: An open source python package Home-page: https://py.guanjihuan.com Author: guanjihuan diff --git a/PyPI/src/guan/data_processing.py b/PyPI/src/guan/data_processing.py index 1369d28..3d990c3 100644 --- a/PyPI/src/guan/data_processing.py +++ b/PyPI/src/guan/data_processing.py @@ -1,6 +1,6 @@ # Module: data_processing -# AI模型对话 +# AI模型对话(输入长度不能太长,且回答速度有一定限制) def chat(prompt='你好', stream=1, model=1, top_p=0.8, temperature=0.85): import socket import json @@ -20,6 +20,8 @@ def chat(prompt='你好', stream=1, model=1, top_p=0.8, temperature=0.85): print('\n--- Begin Stream Message ---\n') response = '' while True: + if prompt == '': + break try: data = client_socket.recv(1024) if data != b'':