npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

copilot-multi-provider

v0.1.5

Published

Connect Copilot Chat to multiple custom LLM providers — configure API endpoints, track token usage, and monitor spending across providers.

Readme

Copilot Multi-Provider

Connect GitHub Copilot Chat to multiple custom LLM providers — OpenAI-compatible APIs, local models, or any endpoint you choose.

Configure providers with custom endpoints, API keys, model lists, and pricing. Track token usage and cost automatically across all providers.


🌐 Languages


English

Features

  • Multi-Provider Support — Add as many API providers as you want (OpenAI, Anthropic, local LLMs, custom proxies...)
  • Dynamic Settings UI — Add/remove providers with +/- buttons, configure everything in a clean webview panel
  • Auto Model Fetch — Click "Fetch Models" to pull the model list from {baseUrl}/models
  • Token Usage Tracking — Automatically captures input/output/cached tokens from each API call
  • Cost Calculation — Configure per-token pricing (input, output, cache read, cache write) and get real-time cost totals
  • Usage Dashboard — View total tokens, cost, per-provider breakdown, per-model breakdown, and recent usage history
  • Secure Storage — API keys stored in VS Code's SecretStorage, configs and usage in globalState

Requirements

  • VS Code ^1.116.0
  • Node.js >=20
  • GitHub Copilot Chat extension installed

Installation

Quick Install (One Command)

npx copilot-multi-provider

Downloads and installs the latest version automatically. Reload VS Code to activate.

Manual: .vsix Download

  1. Go to GitHub Releases
  2. Download copilot-multi-provider-x.x.x.vsix
  3. In VS Code: Ctrl+Shift+PExtensions: Install from VSIX...
  4. Select the downloaded file

Option 2: Build from Source

git clone https://github.com/sadw1q/copilot-multi-provider.git
cd copilot-multi-provider
npm install
npm run compile
npm run package   # produces copilot-multi-provider-x.x.x.vsix

Then install the .vsix as in Option 1.

Option 3: Development (with debugger)

git clone https://github.com/sadw1q/copilot-multi-provider.git
cd copilot-multi-provider
npm install
npm run compile
# Open in VS Code and press F5

Commands (Ctrl+Shift+P)

| Command | Description | |---------|-------------| | Copilot Multi-Provider: Open Settings | Open the provider configuration panel | | Copilot Multi-Provider: Show Total Usage | View usage dashboard with cost breakdown | | Copilot Multi-Provider: Refresh Models | Re-fetch model lists from all configured providers | | Copilot Multi-Provider: Show Logs | View debug logs |

Setup

  1. Install the extension
  2. Ctrl+Shift+PCopilot Multi-Provider: Open Settings
  3. Click + to add a provider
  4. Fill in:
    • Provider Name — Display name
    • Base URL — API endpoint (e.g. https://api.openai.com/v1)
    • API Key — Your API key (stored securely)
    • Pricing — Per-token rates for cost tracking
  5. Click Fetch Models to load available models
  6. Click Save Provider
  7. The provider's models now appear in the Copilot Chat model picker as Provider Name — Model Name

Pricing Configuration

| Field | Description | |-------|-------------| | Input $ | Cost per input token | | Output $ | Cost per output token | | Cache Read $ | Cost per cached read token (prompt caching) | | Cache Write $ | Cost per cache write token |

Pricing is per-token. For reference, OpenAI GPT-4o is approximately:

  • Input: $0.0000025 per token ($2.50 / 1M tokens)
  • Output: $0.00001 per token ($10 / 1M tokens)
  • Cache Read: $0.00000125 per token ($1.25 / 1M tokens)

How It Works

Copilot Chat → selects model
        ↓
CopilotMultiProvider (LanguageModelChatProvider)
        ├─ Routes to correct provider's API
        ├─ Streams response via SSE
        ├─ Captures usage from final chunk
        └─ Records to tracker → calculates cost

License

MIT


한국어

기능

  • 다중 Provider 지원 — 여러 API 제공자를 동시에 등록 (OpenAI, Anthropic, 로컬 LLM, 프록시 등)
  • 동적 설정 UI+/- 버튼으로 Provider를 추가/삭제하고 Webview에서 모든 설정 관리
  • 모델 자동 불러오기 — "Fetch Models" 버튼으로 {baseUrl}/models에서 모델 목록 자동 수집
  • 토큰 사용량 자동 추적 — 매 API 호출 시 input/output/cache 토큰을 자동으로 캡쳐
  • 비용 계산 — 토큰당 가격 (입력/출력/캐시 읽기/캐시 쓰기) 설정 → 실시간 총 비용 확인
  • 사용량 대시보드 — 총 토큰, 총 비용, Provider별/모델별 분석, 최근 사용 기록
  • 보안 저장 — API 키는 VS Code SecretStorage에, 설정과 사용량은 globalState에 저장

요구사항

  • VS Code ^1.116.0
  • Node.js >=20
  • GitHub Copilot Chat 확장 설치 필수

설치 방법

빠른 설치 (명령어 하나)

npx copilot-multi-provider

최신 버전을 자동으로 다운로드하고 설치합니다. VS Code를 새로고침하면 적용됩니다.

수동: .vsix 다운로드

  1. GitHub Releases 에서 copilot-multi-provider-x.x.x.vsix 다운로드
  2. VS Code에서 Ctrl+Shift+PExtensions: Install from VSIX...
  3. 다운로드한 파일 선택

방법 2: 소스에서 빌드

git clone https://github.com/sadw1q/copilot-multi-provider.git
cd copilot-multi-provider
npm install
npm run compile
npm run package   # copilot-multi-provider-x.x.x.vsix 생성됨

생성된 .vsix 파일을 방법 1처럼 설치.

방법 3: 개발 모드 (디버거 포함)

git clone https://github.com/sadw1q/copilot-multi-provider.git
cd copilot-multi-provider
npm install
npm run compile
# VS Code에서 열고 F5

명령어 (Ctrl+Shift+P)

| 명령어 | 설명 | |--------|------| | Copilot Multi-Provider: Open Settings | Provider 설정 패널 열기 | | Copilot Multi-Provider: Show Total Usage | 사용량 대시보드 보기 | | Copilot Multi-Provider: Refresh Models | 모든 Provider의 모델 목록 새로고침 | | Copilot Multi-Provider: Show Logs | 디버그 로그 보기 |

설정 방법

  1. 확장 프로그램 설치
  2. Ctrl+Shift+PCopilot Multi-Provider: Open Settings
  3. + 버튼 클릭해서 Provider 추가
  4. 항목 입력:
    • Provider Name — 표시 이름
    • Base URL — API 엔드포인트 (예: https://api.openai.com/v1)
    • API Key — API 키 (안전하게 저장됨)
    • Pricing — 토큰당 가격 (비용 추적용)
  5. Fetch Models 클릭해서 모델 목록 불러오기
  6. Save Provider 클릭
  7. Copilot Chat 모델 선택기에 Provider명 — 모델명 형식으로 표시됨

가격 설정

| 필드 | 설명 | |------|------| | Input $ | 입력 토큰당 가격 | | Output $ | 출력 토큰당 가격 | | Cache Read $ | 캐시 읽기 토큰당 가격 (CR) | | Cache Write $ | 캐시 쓰기 토큰당 가격 (CW) |


日本語

機能

  • マルチプロバイダー対応 — 複数のAPIプロバイダーを同時登録(OpenAI、Anthropic、ローカルLLM、プロキシなど)
  • 動的設定UI+/- ボタンでプロバイダーを追加/削除、Webviewですべての設定を管理
  • モデル自動取得 — "Fetch Models" ボタンで {baseUrl}/models からモデル一覧を自動取得
  • トークン使用量の自動追跡 — 毎回のAPI呼び出しで input/output/cache トークンを自動キャプチャ
  • コスト計算 — トークン単価(入力/出力/キャッシュ読み取り/キャッシュ書き込み)を設定し、リアルタイムで総コストを確認
  • 使用量ダッシュボード — 総トークン数、総コスト、プロバイダー別/モデル別の内訳、最近の使用履歴
  • 安全な保存 — APIキーはVS Codeの SecretStorage に、設定と使用量は globalState に保存

要件

  • VS Code ^1.116.0
  • Node.js >=20
  • GitHub Copilot Chat 拡張機能が必要

インストール

クイックインストール(コマンド一つ)

npx copilot-multi-provider

最新バージョンを自動ダウンロード&インストール。VS Codeを再読み込みで有効化。

手動: .vsix をダウンロード

  1. GitHub Releases から copilot-multi-provider-x.x.x.vsix をダウンロード
  2. VS Codeで Ctrl+Shift+PExtensions: Install from VSIX...
  3. ダウンロードしたファイルを選択

方法 2: ソースからビルド

git clone https://github.com/sadw1q/copilot-multi-provider.git
cd copilot-multi-provider
npm install
npm run compile
npm run package   # copilot-multi-provider-x.x.x.vsix が生成される

生成された .vsix を方法1と同様にインストール。

方法 3: 開発モード(デバッガー付き)

git clone https://github.com/sadw1q/copilot-multi-provider.git
cd copilot-multi-provider
npm install
npm run compile
# VS Codeで開いて F5

コマンド (Ctrl+Shift+P)

| コマンド | 説明 | |----------|------| | Copilot Multi-Provider: Open Settings | プロバイダー設定パネルを開く | | Copilot Multi-Provider: Show Total Usage | 使用量ダッシュボードを表示 | | Copilot Multi-Provider: Refresh Models | 全プロバイダーのモデル一覧を更新 | | Copilot Multi-Provider: Show Logs | デバッグログを表示 |


中文

功能

  • 多提供商支持 — 同时注册多个 API 提供商(OpenAI、Anthropic、本地 LLM、代理等)
  • 动态设置界面 — 使用 +/- 按钮添加/删除提供商,在 Webview 中管理所有设置
  • 自动获取模型 — 点击 "Fetch Models" 从 {baseUrl}/models 自动获取模型列表
  • 自动追踪 Token 用量 — 每次 API 调用自动捕获 input/output/cache token
  • 费用计算 — 配置每 token 价格(输入/输出/缓存读取/缓存写入),实时查看总费用
  • 用量仪表板 — 总 Token、总费用、按提供商/模型分类、最近使用记录
  • 安全存储 — API 密钥存储在 VS Code SecretStorage,配置和用量存储在 globalState

系统要求

  • VS Code ^1.116.0
  • Node.js >=20
  • 需要安装 GitHub Copilot Chat 扩展

安装方法

快速安装(一条命令)

npx copilot-multi-provider

(未发布到 npm 时)

npx github:sadw1q/copilot-multi-provider

GitHub Releases 下载 copilot-multi-provider-x.x.x.vsix 2. 在 VS Code 中按 Ctrl+Shift+PExtensions: Install from VSIX... 3. 选择下载的文件

方式 2: 从源码构建

git clone https://github.com/sadw1q/copilot-multi-provider.git
cd copilot-multi-provider
npm install
npm run compile
npm run package   # 生成 copilot-multi-provider-x.x.x.vsix

然后按方式 1 安装 .vsix

方式 3: 开发模式(含调试器)

git clone https://github.com/sadw1q/copilot-multi-provider.git
cd copilot-multi-provider
npm install
npm run compile
# 在 VS Code 中打开并按 F5

命令 (Ctrl+Shift+P)

| 命令 | 说明 | |------|------| | Copilot Multi-Provider: Open Settings | 打开提供商配置面板 | | Copilot Multi-Provider: Show Total Usage | 查看用量仪表板 | | Copilot Multi-Provider: Refresh Models | 刷新所有提供商的模型列表 | | Copilot Multi-Provider: Show Logs | 查看调试日志 |