@vedmalex/ai-connect 0.10.0 → 0.11.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +7 -7
- package/dist/browser/index.js +483 -242
- package/dist/browser/index.js.map +3 -3
- package/dist/bun/index.js +1114 -390
- package/dist/bun/index.js.map +4 -4
- package/dist/bun/local.js +1110 -390
- package/dist/bun/local.js.map +4 -4
- package/dist/node/index.js +1114 -390
- package/dist/node/index.js.map +4 -4
- package/dist/node/local.js +1110 -390
- package/dist/node/local.js.map +4 -4
- package/dist/types/acp.d.ts.map +1 -1
- package/dist/types/cli.d.ts +8 -0
- package/dist/types/cli.d.ts.map +1 -1
- package/dist/types/client-tools-mcp.d.ts +82 -0
- package/dist/types/client-tools-mcp.d.ts.map +1 -0
- package/dist/types/client-tools-text-protocol.d.ts +70 -0
- package/dist/types/client-tools-text-protocol.d.ts.map +1 -0
- package/dist/types/client.d.ts +20 -0
- package/dist/types/client.d.ts.map +1 -1
- package/dist/types/config.d.ts +8 -1
- package/dist/types/config.d.ts.map +1 -1
- package/dist/types/index.browser.d.ts +2 -2
- package/dist/types/index.browser.d.ts.map +1 -1
- package/dist/types/index.d.ts +2 -2
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/model-reference.d.ts +25 -10
- package/dist/types/model-reference.d.ts.map +1 -1
- package/dist/types/router.d.ts.map +1 -1
- package/dist/types/server.d.ts.map +1 -1
- package/dist/types/types.d.ts +36 -2
- package/dist/types/types.d.ts.map +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -1207,12 +1207,10 @@ ACP routes are treated as harness-owned connections:
|
|
|
1207
1207
|
Tool semantics are intentionally split:
|
|
1208
1208
|
|
|
1209
1209
|
- `api` routes support tool schema passthrough via `parameters.tools`
|
|
1210
|
-
- `api` routes also support client-managed tools through `clientTools`
|
|
1211
|
-
- `clientTools` are executed locally by `ai-connect` after the provider returns tool calls
|
|
1212
1210
|
- `parameters.tools` remains the right path for upstream-managed tool schemas that are not executed by `ai-connect`
|
|
1213
1211
|
- `acp` routes support harness-owned tool execution
|
|
1214
1212
|
- `acp` routes do not currently forward request-defined tool schema from `parameters.tools`
|
|
1215
|
-
- `
|
|
1213
|
+
- client-managed tools (`clientTools`) are executed locally by `ai-connect` and work on **all four transports** (since 0.11.0): natively on `api`, via an in-process loopback MCP bridge on `acp` (`session/new.mcpServers`; the agent must advertise HTTP MCP support), and via a shared text-based round protocol on `cli` / `server`
|
|
1216
1214
|
|
|
1217
1215
|
That distinction is also reflected in route capabilities:
|
|
1218
1216
|
|
|
@@ -1257,11 +1255,13 @@ const result = await client.generate({
|
|
|
1257
1255
|
});
|
|
1258
1256
|
```
|
|
1259
1257
|
|
|
1260
|
-
|
|
1258
|
+
`clientTools` semantics (as of 0.11.0 — see `docs/whats-new-0.11.md` for the full matrix):
|
|
1261
1259
|
|
|
1262
|
-
- `
|
|
1263
|
-
-
|
|
1264
|
-
-
|
|
1260
|
+
- work in both `generate()` and `stream()` (streaming runs a full multi-round tool loop and emits additive `tool-call` / `tool-result` stream events)
|
|
1261
|
+
- combine with `attachments`/image input on `text`-operation requests: round 1 carries the attachments, follow-up rounds rely on message history; routing is capability-gated (`supportsClientToolExecution` AND `supportsImageInput`/`supportsFileUpload`), an incapable route pool fails fast with `unsupported_capability`
|
|
1262
|
+
- `operation: "image"` / `"file"` combined with `clientTools` is rejected up front with `unsupported_capability` (tool-loop semantics exist only for `text`)
|
|
1263
|
+
- built-in local execution on `api` routes covers the built-in handlers (`openai`, `anthropic`, `gemini`); `acp`/`cli`/`server` execute through their transport bridges (see the tool-semantics list above)
|
|
1264
|
+
- per-model capability hints (curated `MODEL_REFERENCE`) can narrow route capabilities per model — e.g. an embeddings model on a vision-capable provider no longer advertises image input in `listCandidateModels()`
|
|
1265
1265
|
|
|
1266
1266
|
### Context and MCP Semantics
|
|
1267
1267
|
|