Files
ModelTrainEval/scripts
Shaun ZhouandClaude Opus 5 9ead8c0a6e fix(scripts): push_predictions 支持 JWT 个人访问令牌
服务器上的 Label Studio 关闭了旧式 token(jwt_auth_jwtsettings.legacy_api_tokens_enabled=0),
用 authtoken_token 里的 key 直接请求返回 401。个人访问令牌是 JWT refresh token,
要先 POST /api/token/refresh/ 换成 access token 再以 Bearer 发送。

脚本按令牌形态自动区分:三段点分的按 JWT 换取,否则沿用旧式 Token。

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-09-22 12:13:20 +08:00
..