d.xpath('//*[@text="设置"]')d(resourceId="com.example:id/button")d(className="android.widget.Button")d(description="搜索")d.xpath('//android.widget.Button[@text="确定"]')bash展开代码pip install -U huggingface_hub
bash展开代码export HF_ENDPOINT=https://hf-mirror.com
建议写入 ~/.bashrc 或 ~/.zshrc 永久生效:
bash展开代码echo 'export HF_ENDPOINT=https://hf-mirror.com' >> ~/.bashrc
source ~/.bashrc
安装uv:
bash展开代码# 使用官方安装脚本(推荐)
curl -LsSf https://astral.sh/uv/install.sh | sh
source $HOME/.local/bin/env
# 这样也可以:
pip install uv
# win的powershell安装:
powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"
创建虚拟环境,指定D:\python_envs\py313为环境安装目录:
部署:
bash展开代码# 使用vLLM启动
python -m vllm.entrypoints.openai.api_server \
--model /mnt/jfs6/model/UI-TARS-72B-DPO \
--served-model-name ui-tars \
--host 0.0.0.0 \
--port 8000 \
--trust-remote-code \
--max-model-len 8192 \
--gpu-memory-utilization 0.9 \
--tensor-parallel-size 8
Model Context Protocol(MCP)是 Anthropic 推出的开放标准协议,旨在标准化 AI 应用与外部工具、数据源和系统之间的连接方式。就像 USB 标准统一了计算机外设接口一样,MCP 试图解决 AI 集成中的"M×N 问题"——将 M 个不同的 AI 应用与 N 个不同工具的集成从 M×N 个独立实现简化为 M+N 个标准化实现。
在 MCP 架构中,传输层(Transport)是实现客户端与服务器通信的基础。本文将深入探讨 MCP 的四种主要传输类型及其应用场景。
确保所有 tmux 进程已终止:
bash展开代码sudo pkill -f tmux
https://forum.cursor.com/t/ctrl-c-will-not-copy/70657
edit keybindings.json to add:
mkdir -p ~/.cursor/User
bash展开代码[
{
"key": "ctrl+c",
"command": "workbench.action.terminal.copySelection",
"when": "terminalFocus && terminalProcessSupported && terminalTextSelected"
},
{
"key": "ctrl+shift+c",
"command": "workbench.action.terminal.sendSequence",
"args": { "text": "\\u0003" },
"when": "terminalFocus"
}
]
访问 Node.js 官方网站 (https://nodejs.org) 。通常,官网会直接推荐最新的长期支持 (LTS) 版本,这个版本更稳定,非常适合大多数用户。直接点击页面上的推荐版本进行下载即可。
分别输入以下两条命令并执行:
node -v:此命令会显示已安装的 Node.js 的版本号。npm -v:此命令会显示 npm(Node Package Manager)的版本号,它通常随 Node.js 一同自动安装。
如果两个命令都返回了版本号(例如 v18.17.0 和 9.6.7),就说明安装成功了。