We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
python3.11 daiban系统
No response
`tools = [
{ "name": "base_info", "description": """查询指定影城的基础信息,包括影院开业时间、影厅数量、今年票房、排名、排座、历年票房表现等等一切影城维度的数据""", "parameters": { "type": "object", "properties": { "business_date_start": { "description": "要查询的开始时间,格式为'yyyymmdd'的八位数字,非必传,可以为空", "type": 'int' }, "business_date_end": { "description": "要查询的结束时间,格式为'yyyymmdd'的八位数字,非必传,可以为空", "type": 'int' }, "cinema_code": { "description": "筛选的影城编码,非必传,可以为空", "type": 'str' }, "cinema_name": { "description": "筛选的影城名称,非必传,可以为空", 'type': 'int' }, "hasService": { "description": "是否包含服务费,包含为1,不包含为0,非必传,默认为1", "type": 'str' }, "periodTime": { "description": "时段 1:全天 2:黄金场,非必传,默认为1", "type": 'str' }, }, "required": ['business_date_start', 'business_date_end', 'cinema_code', 'cinema_name', 'hasService', 'periodTime'] } }, ] system_info = { "role": "system", "content": "Answer the following questions as best as you can. You have access to the following tools:", "tools": tools } messages = [system_info] messages.append({"role": "system", "content": "不要假设或猜测传入函数的参数值。如果用户的描述不明确,请要求用户提供必要信息"}) messages.append({"role": "system", "content": "不要假设或猜测函数的返回值。如果无法理解返回值的含义,请将返回值完整展示给用户,并告诉用户无法理解,如果函数没有返回任何值,请告诉用户函数调用没有结果"}) messages.append({"role": "system", "content": "如果用户提供的信息不足以调用函数,请告诉用户需要的信息"}) messages.append({"role": "system", "content": "如果用户提供的信息没有涉及非必传参数,请使用默认值调用函数,并告诉用户已使用默认值"}) from transformers import AutoTokenizer, AutoModel tokenizer = AutoTokenizer.from_pretrained(model_path, trust_remote_code=True) model = AutoModel.from_pretrained(model_path, trust_remote_code=True, ) model = model.eval() history = messages # response, history = model.chat(tokenizer, '查询2024年影城编码为31081501的影院全国排名', history=messages) for response, history in model.stream_chat (tokenizer, '查询2024年影城编码为31081501的影院全国排名', history=history): # response, history = model.chat(tokenizer, response, history=history) print(response)`
错误信息为:
期待修复
The text was updated successfully, but these errors were encountered:
No branches or pull requests
System Info / 系統信息
python3.11 daiban系统
Who can help? / 谁可以帮助到您?
No response
Information / 问题信息
Reproduction / 复现过程
`tools = [
错误信息为:
![image](https://private-user-images.githubusercontent.com/81559046/403233613-4907152f-723e-4dae-bbf2-0bc3e55a0055.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3MzkyNzkxMTksIm5iZiI6MTczOTI3ODgxOSwicGF0aCI6Ii84MTU1OTA0Ni80MDMyMzM2MTMtNDkwNzE1MmYtNzIzZS00ZGFlLWJiZjItMGJjM2U1NWEwMDU1LnBuZz9YLUFtei1BbGdvcml0aG09QVdTNC1ITUFDLVNIQTI1NiZYLUFtei1DcmVkZW50aWFsPUFLSUFWQ09EWUxTQTUzUFFLNFpBJTJGMjAyNTAyMTElMkZ1cy1lYXN0LTElMkZzMyUyRmF3czRfcmVxdWVzdCZYLUFtei1EYXRlPTIwMjUwMjExVDEzMDAxOVomWC1BbXotRXhwaXJlcz0zMDAmWC1BbXotU2lnbmF0dXJlPTE5MTJjNWVjZmI0MzhkOWZiNGQwN2U4OGFkMTAzM2M1NmQ5OGMwZjc0ZDZmY2QxNGVhYTJmODg5YjhjMDdmYjgmWC1BbXotU2lnbmVkSGVhZGVycz1ob3N0In0.7dtdJv1lRG_Z4vwr6hrkc114TIdLdTjbjoOPqt5PrO8)
Expected behavior / 期待表现
期待修复
The text was updated successfully, but these errors were encountered: