Skip to main content

jishu-hub

安全传输 CLI:在已授权设备上上传/下载数据集、标注数据,以及拉取评测报告。


在其他机器上的使用流程

每台新机器都要由根超管批准一次。密钥在本机生成,不能把旧机器的 ~/.jishu 整包拷过去当「换机」。

0. 目标机取机器码 → 根超管录入

无一次性注册码。设备准入由超管按「用户 + 机器码」批准。

  1. 在目标机器安装 CLI 后执行:
jishu device-code

将 64 位机器码发给管理员(工单 / 消息)。

  1. 根超管在 后台管理 → 用户列表 点「录入机器」:粘贴机器码、选填备注 → 批准。
  2. 管理员告知 Hub 网关地址(侧信道,勿写入公开文档)。

设备与批准吊销在 后台管理 → 设备/Hub。

1. 目标机器:环境

  • Python ≥ 3.10
  • 能访问 Hub 网关(HTTPS;生产环境通常要求客户端证书 / mTLS,由网关终止)
  • 安装 CLI:
pip install jishu-hub

# 开发安装
# pip install -e /path/to/data_management/cli

可选:固定网关环境变量:

export JISHU_API_URL="https://<hub-host>"   # Linux/macOS
# Windows PowerShell: $env:JISHU_API_URL="https://<hub-host>"

2. 登录(首次自动激活本机)

管理员已录入本机机器码后:

jishu login --gateway https://<hub-host> --username <平台用户名>
# 会提示密码;首次会自动 claim 设备证书,之后只需 login

成功后本机会生成:

位置 内容
~/.jishu/(或 JISHU_HOME) 网关、device_id、证书指纹等
本机密钥材料 私钥 + 设备证书(私钥不出机)

验证:

jishu whoami

3. 常用命令

# 上传到已有版本
jishu dataset upload ./my_data --id <dataset-id> --version <ver>

# 可选:写入版本下子目录(--dir 后为相对路径)
jishu dataset upload ./my_data --id <dataset-id> --version <ver> --dir <subdir>

# 版本尚不存在时需加 --create
jishu dataset upload ./my_data --id <dataset-id> --version <ver> --create

# 整版本下载
jishu dataset download --id <dataset-id> --version <ver> --out ./download

# 只下载指定文件(逗号分隔相对路径)
jishu dataset download --id <dataset-id> --version <ver> --file path/a.jpg,path/b.jpg --out ./download

jishu label upload <标注目录> --project <id>
jishu eval reports list

--file 与 --paths 同义。

上传/下载权限由平台账号 ACL 决定,与网页一致。

4. 换机 / 吊销

  • 换机:新机 device-code → 超管重新录入 → 新机 login
  • 吊销:超管在 设备/Hub 吊销批准或设备后,该机无法再 login / 传输

Metadata

Release files for jishu-hub 0.2.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for jishu-hub 0.2.1
File Size Uploaded Provenance Actions
jishu_hub-0.2.1.tar.gz 16.8 kB Without provenance Details for jishu_hub-0.2.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for jishu-hub 0.2.1
File Interpreter ABI Platform Actions
jishu_hub-0.2.1-py3-none-any.whl Python 3 none any Details for jishu_hub-0.2.1-py3-none-any.whl

Total release size: 35.4 kB

Release files / jishu_hub-0.2.1.tar.gz

Download URL jishu_hub-0.2.1.tar.gz
Size 16.8 kB
Tags Source
SHA-256 checksum
How to use checksums
66be4a706ba4e74b0d0506f82a49ac32306d3e45488ff979778531bd8466138c
BLAKE2b-256 checksum
How to use checksums
164e191e84cd2272c26a1f6c2bcb1b1527415355452b53a7502fceb4c702d077
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.7

Release files / jishu_hub-0.2.1-py3-none-any.whl

Download URL jishu_hub-0.2.1-py3-none-any.whl
Size 18.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
6c312a84249963d463923044deb05b0fafb45801ae83befcf080dfb07804d53b
BLAKE2b-256 checksum
How to use checksums
40380600c0ea877b8c82ee1fbe81122eadede197a771d621f01e48aff144ab36
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.11.7

Security for jishu-hub 0.2.1

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page