omp packages

@lhlyu/pi-kit0.1.7

个人专属的 Pi Coding Agent 工具箱

GitHub Actions Published 5 hours ago MIT ~873 downloads/mo

Untested on omp

This is a pi package. No one has reported whether it works on omp yet. If you try it, add your result below.

Did it work for you?

Result

One report per person. A new report replaces your old one.

Reports 0

No reports yet.

Readme

@lhlyu/pi-kit

个人专属的 Pi Coding Agent 工具箱。

功能

  • 模型自动发现:支持多个 Provider,无需手动维护模型列表。
  • 终端状态栏:展示输出速度(TPS)、首 token 耗时(TTFT)和本轮耗时(TS)。TPS 优先使用服务端用量,无流式用量时显示实时估算;调用结束后显示平均速度,缺失最终用量时保留本轮上次平均值。
⚡️ TPS: 50.0 tok/s 🚀 TTFT: 1.23s ⌛️ TS: 2m35s

安装

需要 Node.js ≥ 22.19.0、Pi Coding Agent ≥ 1.3.0。

pi install npm:@lhlyu/pi-kit

使用

状态栏在交互式终端中自动启用,无需配置。

如需模型自动发现,在 Pi 用户目录的 models.json 中添加 Provider:

{
    "providers": {
        "my-relay": {
            "baseUrl": "https://relay.example.com/v1",
            "apiKey": "$RELAY_API_KEY",
            "api": "openai-completions",
            "discoverModels": true
        }
    }
}

设置 RELAY_API_KEY 环境变量,重启 Pi 或执行 /reload,再通过 /model 选择模型。

更多配置见 模型发现配置。