CLI
一個小巧的命令列用戶端,讓你從終端機與工作區對話——支援串流回覆、互動式 session,以及 stdin 管線。它對接 OpenAI 相容端點,因此只需要一個工作區 API key。
安裝
CLI 隨附於 nexevo-ai 儲存庫。從 checkout 出發,以模組方式執行:
bash
python -m cli --help
# optional: a shorter alias for the examples below
alias nexevo='python -m cli'設定
一次性儲存你的工作區 API key(寫入 ~/.nexevo/config.json,僅檔案擁有者可讀):
bash
nexevo config set api_key sk-ws-...
nexevo config show # api_key is masked環境變數會覆寫已儲存的設定:NEXEVO_API_KEY、NEXEVO_BASE_URL(預設 https://nexevo.ai/v1)、NEXEVO_MODEL。
Chat
bash
# one-shot
nexevo chat "Summarize our Q2 results."
# interactive session (keeps the conversation; empty line or Ctrl-D to exit)
nexevo chat
# pipe stdin
git diff | nexevo chat "Review this change."
# pin a specific model (default is nexevo-auto → the router picks)
nexevo chat --model nexevo-auto "Draft a release note."回覆會逐 token 串流輸出。路由、計費與 BYOK 與其他所有 Nexevo 呼叫相同——CLI 只是 OpenAI 相容 API 上的一個輕量用戶端。