个人聊天机器人-ChatGLM2-6B

本文讲述了在使用HuggingFaceChatGLM2-6B时遇到的错误,如命名规范问题和配置文件位置,详细描述了解决步骤,包括检查路径和加载checkpoint,最终成功实现聊天机器人的使用。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

#1、首先学习,按照步骤执行https://nuly9zxzf1.feishu.cn/docx/HOmzdmST9oc43gxjTF0c7PAAnnb

#2、执行过程中,报错raise HFValidationError(
huggingface_hub.utils.validators.HFValidationError: Repo id must use alphanumeric chars or ‘-’, '', ‘.’, ‘–’ and ‘…’ are forbidden, ‘-’ and ‘.’ cannot start or end the name, max length is 96: ‘\gemini\data-2’.,检查发现’data-2‘输入有问题,切换英文重新输入

#3、继续报错OSError: /gemini/data-2 does not appear to have a file named config.json. Checkout ‘https://huggingface.co//gemini/data-2/None’ for available files.,解决办法其实文件是在"/gemini/data-2/chatglm2-6b"文件夹中,再次修改路径

#4,执行python ChatGLM2-6B/cli_demo.py,Loading checkpoint shards: 100%。

#5,这样就可以愉快的使用个人聊天机器人啦。在这里插入图片描述

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值