ModelScope微调的时候有以下日志,要怎么解决? [ERROR:swift] Authentication token does not exist, failed to access model qwen/Qwen1___5-14B-Chat which may not exist or may be private. Please login first.
根据您提供的日志信息,[ERROR:swift] Authentication token does not exist, failed to access model qwen/Qwen1___5-14B-Chat which may not exist or may be private. Please login first.
,可以判断问题的核心是认证令牌缺失或未正确配置,导致无法访问指定的模型。以下是解决该问题的详细步骤和分析:
qwen/Qwen1___5-14B-Chat
可能不存在或为私有模型。qwen/Qwen1___5-14B-Chat
是否存在。Authentication token does not exist
,说明微调任务未正确加载认证令牌。export DASHSCOPE_API_KEY=<您的API Token>
import os
os.environ['DASHSCOPE_API_KEY'] = '<您的API Token>'
curl --location 'https://dashscope.aliyuncs.com/api/v1/fine-tunes' \
--header 'Authorization: Bearer ${DASHSCOPE_API_KEY}' \
--header 'Content-Type: application/json'
curl --location 'https://dashscope.aliyuncs.com/api/v1/user/profile' \
--header 'Authorization: Bearer ${DASHSCOPE_API_KEY}'
qwen/Qwen1___5-14B-Chat
,可能存在拼写错误或路径不匹配的问题。_
或连字符 -
),请确保其格式正确。file_id
。batch_size
、learning_rate
等。dashscope fine_tunes.call -m qwen-turbo -t '<替换为训练数据集的file_id1>' '<替换为训练数据集的file_id2>' \
--mode sft -b 16 -e 1 -l 1.6e-5 \
--hyper_parameters split=0.9 warmup_ratio=0.0 eval_steps=1
dashscope fine_tunes.stream -j <替换为您的微调任务 id>
curl --location 'https://dashscope.aliyuncs.com/api/v1/fine-tunes/<替换为您的微调任务 id>/logs?offset=0&line=1000' \
--header 'Authorization: Bearer ${DASHSCOPE_API_KEY}' \
--header 'Content-Type: application/json'
通过以上步骤,您可以逐步排查并解决 [ERROR:swift] Authentication token does not exist
的问题。核心在于确保认证令牌正确配置、模型路径无误以及微调任务依赖完整。如果问题仍未解决,建议联系阿里云技术支持团队获取进一步帮助。
ModelScope旨在打造下一代开源的模型即服务共享平台,为泛AI开发者提供灵活、易用、低成本的一站式模型服务产品,让模型应用更简单!欢迎加入技术交流群:微信公众号:魔搭ModelScope社区,钉钉群号:44837352