Compare commits
8
Commits
4eeace6ce3
..
main
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
4fdaa0ca9d | ||
|
|
9798a41745 | ||
|
|
46b8d7e888 | ||
|
|
0460305327 | ||
|
|
c4bb02a7a2 | ||
|
|
f295cb8535 | ||
|
|
55e2764480 | ||
|
|
cb23c502aa |
No files matched your search
+59
-12
@@ -1,30 +1,77 @@
|
|||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
## [0.0.1] - 2026-11-06
|
<!-- markdownlint-configure-file { "MD024": { "siblings_only": true } } -->
|
||||||
|
|
||||||
Initial development release. Not yet functional for chat.
|
All notable changes to this project will be documented in this file.
|
||||||
|
|
||||||
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
|
||||||
|
and this project adheres to
|
||||||
|
[Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
||||||
|
|
||||||
|
## [Unreleased]
|
||||||
|
|
||||||
|
## [0.2.2] - 2026-11-06
|
||||||
|
|
||||||
|
### Fixed
|
||||||
|
|
||||||
|
- Correct the publisher in package.json.
|
||||||
|
|
||||||
|
## [0.2.1] - 2026-11-06
|
||||||
|
|
||||||
|
### Fixed
|
||||||
|
|
||||||
|
- Correct instructions for setting the API key in README.
|
||||||
|
|
||||||
|
## [0.2.0] - 2026-11-06
|
||||||
|
|
||||||
### Added
|
### Added
|
||||||
|
|
||||||
|
- "Inference Coop: Set API Key" and "Inference Coop: Sign Out" commands.
|
||||||
|
- Model list caching with `onDidChangeLanguageModelChatInformation`, so the
|
||||||
|
picker refreshes when models change instead of requiring a restart.
|
||||||
|
|
||||||
|
### Changed
|
||||||
|
|
||||||
|
- **Breaking:** the API key is now stored in VS Code `SecretStorage` instead
|
||||||
|
of the `inferenceCoop.apiKey` setting. Run "Inference Coop: Set API Key"
|
||||||
|
once after upgrading; the gateway base URL is now the only setting.
|
||||||
|
|
||||||
|
### Fixed
|
||||||
|
|
||||||
|
- Models intermittently missing from the Copilot Chat model picker when the
|
||||||
|
provider's initial model fetch lost a race with chat activation.
|
||||||
|
|
||||||
|
## [0.1.0] - 2026-11-06
|
||||||
|
|
||||||
|
First release usable for chat.
|
||||||
|
|
||||||
|
### Added
|
||||||
|
|
||||||
|
- Streaming chat responses via `provideLanguageModelChatResponse`, with
|
||||||
|
text streamed to the UI as it arrives.
|
||||||
|
- Tool calling: tool schemas are sent to the gateway, streamed tool-call
|
||||||
|
fragments are reassembled, and tool results are translated back into the
|
||||||
|
conversation. Verified end to end in agent mode against
|
||||||
|
`tinfoil/gpt-oss-120b`.
|
||||||
- Extension scaffold with esbuild build pipeline and ESLint/tsc checks.
|
- Extension scaffold with esbuild build pipeline and ESLint/tsc checks.
|
||||||
- Registration of a `LanguageModelChatProvider` under the `inference-coop`
|
- Registration of a `LanguageModelChatProvider` under the `inference-coop`
|
||||||
vendor, discoverable via `contributes.languageModelChatProviders`.
|
vendor, discoverable via `contributes.languageModelChatProviders`.
|
||||||
- Model discovery: fetches `GET https://gateway.inference.coop/v1/models`
|
- Model discovery: fetches `GET https://gateway.inference.coop/v1/models`
|
||||||
and filters to chat-capable models, excluding image-generation and
|
and filters to chat-capable models, excluding image-generation and
|
||||||
audio endpoints.
|
audio endpoints.
|
||||||
- `inferenceCoop.apiKey` setting (plain text, temporarily).
|
|
||||||
- "Inference Coop" output channel logging provider activation, model
|
- "Inference Coop" output channel logging provider activation, model
|
||||||
enumeration, and HTTP status codes.
|
enumeration, and HTTP status codes.
|
||||||
|
|
||||||
### Known issues
|
### Changed
|
||||||
|
|
||||||
- Models appear in the Language Models panel but not in the Copilot Chat
|
- Adopted the Apache License 2.0.
|
||||||
model picker. Under investigation; suspected upstream VS Code issue.
|
|
||||||
- `provideLanguageModelChatResponse` sends a streaming request but has not
|
|
||||||
been verified end to end from the chat UI.
|
|
||||||
- No tool calling, image input, or token counting (returns 0).
|
|
||||||
- API key is stored in settings rather than `SecretStorage`.
|
|
||||||
|
|
||||||
### Not yet published
|
## [0.0.1] - 2026-11-06
|
||||||
|
|
||||||
- No Marketplace publisher registered; installed from a local `.vsix`.
|
Initial development release. Not functional for chat.
|
||||||
|
|
||||||
|
[Unreleased]: https://git.inference.coop/evanp/inference-coop-copilot/compare/v0.2.2...HEAD
|
||||||
|
[0.2.2]: https://git.inference.coop/evanp/inference-coop-copilot/compare/v0.2.1...v0.2.2
|
||||||
|
[0.2.1]: https://git.inference.coop/evanp/inference-coop-copilot/compare/v0.2.0...v0.2.1
|
||||||
|
[0.2.0]: https://git.inference.coop/evanp/inference-coop-copilot/compare/v0.1.0...v0.2.0
|
||||||
|
[0.1.0]: https://git.inference.coop/evanp/inference-coop-copilot/releases/tag/v0.1.0
|
||||||
@@ -1,14 +1,37 @@
|
|||||||
# Inference Coop (unofficial)
|
# Inference Coop for Copilot Chat (unofficial)
|
||||||
|
|
||||||
Community-built model provider for [inference.coop](https://inference.coop),
|
Community-built model provider for [inference.coop](https://inference.coop),
|
||||||
usable in GitHub Copilot Chat. Not affiliated with or endorsed by the
|
usable in GitHub Copilot Chat. Not affiliated with or endorsed by the
|
||||||
Inference Cooperative.
|
Inference Cooperative.
|
||||||
|
|
||||||
|
## Requirements
|
||||||
|
|
||||||
|
- VS Code 1.145 or newer
|
||||||
|
- GitHub Copilot Chat, installed and signed in
|
||||||
|
- A co-op membership and API key
|
||||||
|
|
||||||
|
Copilot Business/Enterprise: your administrator must leave "Bring Your Own
|
||||||
|
Language Model Key" enabled, or these models will not appear.
|
||||||
|
|
||||||
## Setup
|
## Setup
|
||||||
|
|
||||||
1. Set `inferenceCoop.apiKey` in your settings to your co-op API key.
|
1. Run **Inference Coop: Set API Key** from the Command Palette and paste
|
||||||
2. Open Copilot Chat and pick an `inference-coop/…` model.
|
your co-op key. It is stored in VS Code's secret storage, not in settings.
|
||||||
|
2. Open Copilot Chat, click the model name, and pick an `inference-coop/…`
|
||||||
|
model. Tool calling works, so agent mode is usable.
|
||||||
|
|
||||||
## Status
|
To use a different gateway, set `inferenceCoop.baseUrl`. To sign out, run
|
||||||
|
**Inference Coop: Sign Out**.
|
||||||
|
|
||||||
Early development. Text chat only so far; tool calling is not implemented.
|
## Limitations
|
||||||
|
|
||||||
|
- No image input; models are advertised as text-and-tools only.
|
||||||
|
- Token counts are estimated rather than computed with a real tokenizer, so
|
||||||
|
context budgeting is approximate.
|
||||||
|
- No inline code completions. Copilot does not support third-party providers
|
||||||
|
for completions; this extension only adds chat models.
|
||||||
|
- Unofficial client. Report extension bugs here, not to the co-op.
|
||||||
|
|
||||||
|
## License
|
||||||
|
|
||||||
|
Apache-2.0. See [LICENSE](LICENSE) and [NOTICE](NOTICE).
|
||||||
Generated
+2
-2
@@ -1,12 +1,12 @@
|
|||||||
{
|
{
|
||||||
"name": "inference-coop-copilot",
|
"name": "inference-coop-copilot",
|
||||||
"version": "0.1.0",
|
"version": "0.2.2",
|
||||||
"lockfileVersion": 3,
|
"lockfileVersion": 3,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"packages": {
|
"packages": {
|
||||||
"": {
|
"": {
|
||||||
"name": "inference-coop-copilot",
|
"name": "inference-coop-copilot",
|
||||||
"version": "0.1.0",
|
"version": "0.2.2",
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"@types/mocha": "^10.0.10",
|
"@types/mocha": "^10.0.10",
|
||||||
"@types/node": "24.x",
|
"@types/node": "24.x",
|
||||||
|
|||||||
+2
-2
@@ -2,11 +2,11 @@
|
|||||||
"name": "inference-coop-copilot",
|
"name": "inference-coop-copilot",
|
||||||
"displayName": "inference-coop-copilot",
|
"displayName": "inference-coop-copilot",
|
||||||
"description": "Inference.coop models for Copilot Chat (unofficial)",
|
"description": "Inference.coop models for Copilot Chat (unofficial)",
|
||||||
"version": "0.1.0",
|
"version": "0.2.2",
|
||||||
"engines": {
|
"engines": {
|
||||||
"vscode": "^1.145.0"
|
"vscode": "^1.145.0"
|
||||||
},
|
},
|
||||||
"publisher": "inference-coop",
|
"publisher": "evanp",
|
||||||
"repository": {
|
"repository": {
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://git.inference.coop/evanp/inference-coop-copilot.git"
|
"url": "https://git.inference.coop/evanp/inference-coop-copilot.git"
|
||||||
|
|||||||
+34
-1
@@ -109,6 +109,19 @@ export function activate(context: vscode.ExtensionContext) {
|
|||||||
body.tool_choice = "auto";
|
body.tool_choice = "auto";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (token.isCancellationRequested) {
|
||||||
|
out.appendLine(" request cancelled before it started");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
|
// Abort the request as soon as the user cancels, so a cancelled chat
|
||||||
|
// stops generating (and stops billing) server-side.
|
||||||
|
const abort = new AbortController();
|
||||||
|
const cancelSubscription = token.onCancellationRequested(() =>
|
||||||
|
abort.abort(),
|
||||||
|
);
|
||||||
|
|
||||||
|
try {
|
||||||
const res = await fetch(`${BASE_URL}/chat/completions`, {
|
const res = await fetch(`${BASE_URL}/chat/completions`, {
|
||||||
method: "POST",
|
method: "POST",
|
||||||
headers: {
|
headers: {
|
||||||
@@ -116,7 +129,7 @@ export function activate(context: vscode.ExtensionContext) {
|
|||||||
"Content-Type": "application/json",
|
"Content-Type": "application/json",
|
||||||
},
|
},
|
||||||
body: JSON.stringify(body),
|
body: JSON.stringify(body),
|
||||||
signal: token.isCancellationRequested ? AbortSignal.abort() : undefined,
|
signal: abort.signal,
|
||||||
});
|
});
|
||||||
out.appendLine(` /chat/completions status: ${res.status}`);
|
out.appendLine(` /chat/completions status: ${res.status}`);
|
||||||
if (!res.ok || !res.body) {
|
if (!res.ok || !res.body) {
|
||||||
@@ -157,6 +170,11 @@ export function activate(context: vscode.ExtensionContext) {
|
|||||||
};
|
};
|
||||||
|
|
||||||
while (true) {
|
while (true) {
|
||||||
|
if (token.isCancellationRequested) {
|
||||||
|
out.appendLine(" cancelled mid-stream; aborting request");
|
||||||
|
abort.abort(); // close the connection so the gateway stops generating
|
||||||
|
return;
|
||||||
|
}
|
||||||
const { done, value } = await reader.read();
|
const { done, value } = await reader.read();
|
||||||
if (done) {
|
if (done) {
|
||||||
break;
|
break;
|
||||||
@@ -221,6 +239,21 @@ export function activate(context: vscode.ExtensionContext) {
|
|||||||
flushTools();
|
flushTools();
|
||||||
}
|
}
|
||||||
out.appendLine(` stream ended, ${textChunks} text chunks`);
|
out.appendLine(` stream ended, ${textChunks} text chunks`);
|
||||||
|
} catch (e) {
|
||||||
|
// A cancellation aborts fetch (before headers) or the pending stream
|
||||||
|
// read (mid-response) - both surface as AbortError. That is the user
|
||||||
|
// pressing stop, not a failure: stop quietly instead of erroring.
|
||||||
|
if (
|
||||||
|
token.isCancellationRequested ||
|
||||||
|
(e instanceof Error && e.name === "AbortError")
|
||||||
|
) {
|
||||||
|
out.appendLine(" stream aborted after cancellation");
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
throw e;
|
||||||
|
} finally {
|
||||||
|
cancelSubscription.dispose();
|
||||||
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
async provideTokenCount() {
|
async provideTokenCount() {
|
||||||
|
|||||||
Reference in new issue
Block a user