https://help.aliyun.com/zh/dashscope/developer-reference/api-details
- 开通DashScope并创建API-KEY
- 申请通义千问模型API权限,点此申请
- create a Jupyter Notebook Deployment (CPU)
kubectl apply -f notebook.yaml
- wait deployment ready
kubectl get po |grep notebook
# NAME READY STATUS RESTARTS AGE
# notebook-d68d854c9-ptvtp 1/1 Running 0 8m5s
- connect to the Jupyter Notebook
Run the following command to port-forward:
kubectl port-forward -n <namespace> service/notebook-svc 8888:8888
And then open the console using the following URL:
http://localhost:8888
- 创建Notebook,参考tongyi.ipynb调用通义千问API。