You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/ConnectorCatalogue.md
+131Lines changed: 131 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -137,6 +137,52 @@ pools:
137
137
| **AWS Bedrock** | `provider.aws.bedrock.v1` | Managed AI service with access to multiple foundation model providers. | Claude Sonnet 4, Claude 3.5 Haiku, Llama 3.1, Mistral Large, Amazon Nova Pro/Lite, Titan Embed, Stable Diffusion XL | No free tier; $200 new-account credit (all AWS, 6-month expiry) | [docs.aws.amazon.com/bedrock](https://docs.aws.amazon.com/bedrock) |
Local model servers expose OpenAI-compatible REST APIs, so each connector extends `OpenAICompatibleProvider` with different defaults. No API key is required — authentication is disabled by default. All local providers are **Node.js only** (`RuntimeEnvironment.NODE_ONLY`).
143
+
144
+
| Provider | ID | Default URL | Env Var | Default Models | Description |
**Auto-detection:** Local providers are detected via host environment variables (e.g., `OLLAMA_HOST=http://myserver:11434`). Unlike cloud providers, no API key env var is needed — the presence of the host variable alone enables the provider.
152
+
153
+
**Configuration:**
154
+
155
+
All local providers share the same configuration parameters inherited from `OpenAICompatibleProvider`:
156
+
157
+
| Parameter | Type | Description |
158
+
| --- | --- | --- |
159
+
| `base_url` | string | Server URL. Defaults to localhost (see table above). |
160
+
| `api_key` | string | API key for authentication. Default: `""`(no auth). |
161
+
| `models` | list | Model catalogue. Ollama ships defaults; others are empty (user-loaded). |
162
+
| `capabilities` | list | Capability paths. Default: `["generation.text-generation.chat-completion"]`. |
Non-AI web services can be wrapped as provider connectors using the same interface, gaining rotation, quota management, and failover. These services are accessed through virtual model names and routed through capability pools like any other model.
@@ -189,6 +235,10 @@ Non-AI web services can be wrapped as provider connectors using the same interfa
@@ -199,6 +249,35 @@ Non-AI web services can be wrapped as provider connectors using the same interfa
199
249
200
250
Both classes expose the same provider interface and the same protected hooks for subclassing. See [cdk/BaseClasses.md](cdk/BaseClasses.html#browserbAseprovider) for details and [guides/BrowserUsage.md](guides/BrowserUsage.html) for browser setup.
201
251
252
+
### Runtime Environment Metadata
253
+
254
+
Every TypeScript connector class declares a `static readonly RUNTIME` property indicating browser/Node.js compatibility. This enables build-time tree-shaking and runtime compatibility checks.
255
+
256
+
```typescript
257
+
import { RuntimeEnvironment } from '@modelmesh/core';
| `'universal'` | `RuntimeEnvironment.UNIVERSAL` | Any JavaScript runtime | MemoryStorage, MemorySecretStore, BrowserBaseProvider, all rotation policies, ConsoleObservability |
270
+
271
+
**Runtime Guard** (`detectRuntime()`, `assertRuntimeCompatible()`): Detects the current environment at runtime and throws a descriptive error if a connector is used in an incompatible environment. Available from `@modelmesh/core`:
272
+
273
+
```typescript
274
+
import { detectRuntime, assertRuntimeCompatible } from '@modelmesh/core';
275
+
276
+
const runtime = detectRuntime(); // 'node' or 'browser'
// Throws: "Connector modelmesh.localstorage.v1 requires browser environment but running in node"
279
+
```
280
+
202
281
### Audio Namespace
203
282
204
283
ElevenLabs (`elevenlabs.tts.v1`), Azure Speech (`azure.tts.v1`), and AssemblyAI (`assemblyai.stt.v1`) are accessible through the MeshClient audio namespace, which follows the OpenAI SDK audio pattern:
| **`secret-store.modelmesh.memory-secrets.v1`** | Holds secrets in an in-memory dictionary. Ideal for testing, scripting, and user-provided keys. Supports runtime add/remove via SecretManagement interface. | Built-in | - |
256
335
| **`secret-store.modelmesh.encrypted-file.v1`** | AES-256-GCM encrypted JSON file. Secrets are decrypted at initialization using a passphrase (PBKDF2) or raw key. Supports save/load round-trips. | Built-in | - |
257
336
| **`secret-store.modelmesh.keyring.v1`** | Resolves secrets from the OS keyring (macOS Keychain, Windows Credential Locker, Linux Secret Service). | Built-in | - |
Stores secrets in the browser's localStorage. Supports the full `SecretManagement` interface (`set`, `delete`, `list`). Secrets persist across page reloads and browser restarts. **Warning:** localStorage is not encrypted — secrets are visible in browser DevTools. Suitable for user-provided API keys in personal tools; not recommended for shared production deployments.
Data is serialized as base64-encoded JSON. Persists across page reloads and browser restarts. Subject to the browser's localStorage quota (~5-10 MB per origin). Requires `RuntimeEnvironment.BROWSER_ONLY`.
Natively async storage using the browser's IndexedDB API. Stores binary data directly as `Uint8Array` (no base64 overhead). No practical size limit. Recommended for browser apps with large state. Connection is lazily initialized on first use; call `close()` to release the connection.
528
+
529
+
---
530
+
531
+
### Browser Storage Deployment Patterns
532
+
533
+
| Scenario | Recommended Store | Reason |
534
+
| --- | --- | --- |
535
+
| Browser SPA, small state | `modelmesh.localstorage.v1` | Persistent, simple, synchronous-feel API |
536
+
| Browser SPA, large state | `modelmesh.indexeddb.v1` | No size limit, native binary support |
537
+
| Tab-scoped state | `modelmesh.sessionstorage.v1` | Auto-cleared on tab close |
Copy file name to clipboardExpand all lines: docs/CoverageMatrix.md
+28-8Lines changed: 28 additions & 8 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5,7 +5,7 @@ title: "Test Coverage Matrix"
5
5
6
6
# Test Coverage Matrix
7
7
8
-
Correlates documented features with test coverage. The project includes 640 Python tests across 14 test files and 168 TypeScript tests across 10 test files, for a total of 808 tests.
8
+
Correlates documented features with test coverage. The project includes 775 Python tests across 14 test files and 370 TypeScript tests across 13 test files, for a total of 1,145 tests.
9
9
10
10
---
11
11
@@ -23,8 +23,10 @@ Correlates documented features with test coverage. The project includes 640 Pyth
0 commit comments