@ai-matrx/agents 0.59.241 → 0.59.242
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/CHANGELOG.md +11 -1
- package/dist/models/index.cjs +4 -2
- package/dist/models/index.d.cts +13 -8
- package/dist/models/index.d.ts +13 -8
- package/dist/models/index.js +4 -2
- package/dist/models/react/index.d.cts +1 -1
- package/dist/models/react/index.d.ts +1 -1
- package/dist/versions/index.cjs +3 -3
- package/dist/versions/index.js +3 -3
- package/package.json +6 -6
package/CHANGELOG.md
CHANGED
|
@@ -1,10 +1,20 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
-
## 0.59.
|
|
3
|
+
## 0.59.242
|
|
4
4
|
|
|
5
5
|
UNVERIFIED: this release has no Unreleased entry and the source comparison could not be made (the caller supplied no source comparison). Whether source changed is unknown; consumer action is unknown.
|
|
6
6
|
Check the package's gitHead on npm against this version's gitHead: `git diff <previous gitHead> <this gitHead> -- apps/shared/matrx-agents/src`.
|
|
7
7
|
|
|
8
|
+
## 0.59.241
|
|
9
|
+
|
|
10
|
+
Automatic changed-only republish (docs/metadata drift since the last published version; verified: `git diff c3acf23378 a53838052a -- apps/shared/matrx-agents/src`
|
|
11
|
+
has no shipped-source changes outside tests, fixtures and docs). No consumer action required.
|
|
12
|
+
|
|
13
|
+
## 0.59.240
|
|
14
|
+
|
|
15
|
+
Automatic changed-only republish (docs/metadata drift since the last published version; verified: `git diff 6acfc6b938 c3acf23378 -- apps/shared/matrx-agents/src`
|
|
16
|
+
has no shipped-source changes outside tests, fixtures and docs). No consumer action required.
|
|
17
|
+
|
|
8
18
|
## 0.59.239
|
|
9
19
|
|
|
10
20
|
Automatic changed-only republish (docs/metadata drift since the last published version; verified: `git diff 9df1465977 6acfc6b938 -- apps/shared/matrx-agents/src`
|
package/dist/models/index.cjs
CHANGED
|
@@ -861,7 +861,9 @@ function createModelFavorites(config) {
|
|
|
861
861
|
};
|
|
862
862
|
const listCanonical = async () => {
|
|
863
863
|
try {
|
|
864
|
-
const
|
|
864
|
+
const c = client();
|
|
865
|
+
const scoped = c.schema?.("users");
|
|
866
|
+
const { data, error } = await (scoped?.rpc ? scoped.rpc("ues_list", { p_kind: "favorite" }) : c.rpc("ues_list", { p_kind: "favorite" }));
|
|
865
867
|
if (error) {
|
|
866
868
|
sink({ code: "model-favorite-ues_list-failed", message: error.message });
|
|
867
869
|
return null;
|
|
@@ -1599,7 +1601,7 @@ function aiRpc(client, fn) {
|
|
|
1599
1601
|
async function readCatalog(client, variant) {
|
|
1600
1602
|
if (variant === "admin") {
|
|
1601
1603
|
const [rpcRes, offeringsRes] = await Promise.all([
|
|
1602
|
-
client
|
|
1604
|
+
aiRpc(client, "admin_model_catalog"),
|
|
1603
1605
|
aiRpc(client, "admin_model_offerings")
|
|
1604
1606
|
]);
|
|
1605
1607
|
if (rpcRes.error) throw rpcRes.error;
|
package/dist/models/index.d.cts
CHANGED
|
@@ -339,14 +339,19 @@ declare function reconcileModelFavoriteIds(cached: readonly string[], canonical:
|
|
|
339
339
|
missingFromCanonical: string[];
|
|
340
340
|
};
|
|
341
341
|
declare function favoriteIdsEqual(a: readonly string[], b: readonly string[]): boolean;
|
|
342
|
+
type ModelFavoritesRpcResult = PromiseLike<{
|
|
343
|
+
data: unknown;
|
|
344
|
+
error: {
|
|
345
|
+
message: string;
|
|
346
|
+
code?: string;
|
|
347
|
+
} | null;
|
|
348
|
+
}>;
|
|
342
349
|
interface ModelFavoritesClient {
|
|
343
|
-
rpc(fn: string, args?: Record<string, unknown>):
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
} | null;
|
|
349
|
-
}>;
|
|
350
|
+
rpc(fn: string, args?: Record<string, unknown>): ModelFavoritesRpcResult;
|
|
351
|
+
/** `users.ues_list` lives in its owner schema (the public forwarder closes). */
|
|
352
|
+
schema?(name: string): {
|
|
353
|
+
rpc?(fn: string, args?: Record<string, unknown>): ModelFavoritesRpcResult;
|
|
354
|
+
};
|
|
350
355
|
}
|
|
351
356
|
interface ModelFavoritesCache {
|
|
352
357
|
get(): readonly string[];
|
|
@@ -756,7 +761,7 @@ declare const selectModelIdentityLookupStatus: (s: ModelRecordsState, modelId: s
|
|
|
756
761
|
* - "user" → `ai.model_public` (anon + authenticated; masked, points pricing), filtered to
|
|
757
762
|
* ROUTABLE models via `ai.model_offering`, which also supplies each model's serving
|
|
758
763
|
* TIERS (`served_via` — the endpoint's public Matrx brand, never the real vendor).
|
|
759
|
-
* - "admin" → `
|
|
764
|
+
* - "admin" → `ai.admin_model_catalog()` + `ai.admin_model_offerings()` (SECURITY
|
|
760
765
|
* DEFINER, gated by `is_super_admin()`): raw $ pricing, real vendors, every
|
|
761
766
|
* offering. NEVER read `ai.model_admin` / `ai.offering` directly from a client.
|
|
762
767
|
*
|
package/dist/models/index.d.ts
CHANGED
|
@@ -339,14 +339,19 @@ declare function reconcileModelFavoriteIds(cached: readonly string[], canonical:
|
|
|
339
339
|
missingFromCanonical: string[];
|
|
340
340
|
};
|
|
341
341
|
declare function favoriteIdsEqual(a: readonly string[], b: readonly string[]): boolean;
|
|
342
|
+
type ModelFavoritesRpcResult = PromiseLike<{
|
|
343
|
+
data: unknown;
|
|
344
|
+
error: {
|
|
345
|
+
message: string;
|
|
346
|
+
code?: string;
|
|
347
|
+
} | null;
|
|
348
|
+
}>;
|
|
342
349
|
interface ModelFavoritesClient {
|
|
343
|
-
rpc(fn: string, args?: Record<string, unknown>):
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
|
|
347
|
-
|
|
348
|
-
} | null;
|
|
349
|
-
}>;
|
|
350
|
+
rpc(fn: string, args?: Record<string, unknown>): ModelFavoritesRpcResult;
|
|
351
|
+
/** `users.ues_list` lives in its owner schema (the public forwarder closes). */
|
|
352
|
+
schema?(name: string): {
|
|
353
|
+
rpc?(fn: string, args?: Record<string, unknown>): ModelFavoritesRpcResult;
|
|
354
|
+
};
|
|
350
355
|
}
|
|
351
356
|
interface ModelFavoritesCache {
|
|
352
357
|
get(): readonly string[];
|
|
@@ -756,7 +761,7 @@ declare const selectModelIdentityLookupStatus: (s: ModelRecordsState, modelId: s
|
|
|
756
761
|
* - "user" → `ai.model_public` (anon + authenticated; masked, points pricing), filtered to
|
|
757
762
|
* ROUTABLE models via `ai.model_offering`, which also supplies each model's serving
|
|
758
763
|
* TIERS (`served_via` — the endpoint's public Matrx brand, never the real vendor).
|
|
759
|
-
* - "admin" → `
|
|
764
|
+
* - "admin" → `ai.admin_model_catalog()` + `ai.admin_model_offerings()` (SECURITY
|
|
760
765
|
* DEFINER, gated by `is_super_admin()`): raw $ pricing, real vendors, every
|
|
761
766
|
* offering. NEVER read `ai.model_admin` / `ai.offering` directly from a client.
|
|
762
767
|
*
|
package/dist/models/index.js
CHANGED
|
@@ -702,7 +702,9 @@ function createModelFavorites(config) {
|
|
|
702
702
|
};
|
|
703
703
|
const listCanonical = async () => {
|
|
704
704
|
try {
|
|
705
|
-
const
|
|
705
|
+
const c = client();
|
|
706
|
+
const scoped = c.schema?.("users");
|
|
707
|
+
const { data, error } = await (scoped?.rpc ? scoped.rpc("ues_list", { p_kind: "favorite" }) : c.rpc("ues_list", { p_kind: "favorite" }));
|
|
706
708
|
if (error) {
|
|
707
709
|
sink({ code: "model-favorite-ues_list-failed", message: error.message });
|
|
708
710
|
return null;
|
|
@@ -1440,7 +1442,7 @@ function aiRpc(client, fn) {
|
|
|
1440
1442
|
async function readCatalog(client, variant) {
|
|
1441
1443
|
if (variant === "admin") {
|
|
1442
1444
|
const [rpcRes, offeringsRes] = await Promise.all([
|
|
1443
|
-
client
|
|
1445
|
+
aiRpc(client, "admin_model_catalog"),
|
|
1444
1446
|
aiRpc(client, "admin_model_offerings")
|
|
1445
1447
|
]);
|
|
1446
1448
|
if (rpcRes.error) throw rpcRes.error;
|
|
@@ -372,7 +372,7 @@ interface ModelRecords {
|
|
|
372
372
|
* - "user" → `ai.model_public` (anon + authenticated; masked, points pricing), filtered to
|
|
373
373
|
* ROUTABLE models via `ai.model_offering`, which also supplies each model's serving
|
|
374
374
|
* TIERS (`served_via` — the endpoint's public Matrx brand, never the real vendor).
|
|
375
|
-
* - "admin" → `
|
|
375
|
+
* - "admin" → `ai.admin_model_catalog()` + `ai.admin_model_offerings()` (SECURITY
|
|
376
376
|
* DEFINER, gated by `is_super_admin()`): raw $ pricing, real vendors, every
|
|
377
377
|
* offering. NEVER read `ai.model_admin` / `ai.offering` directly from a client.
|
|
378
378
|
*
|
|
@@ -372,7 +372,7 @@ interface ModelRecords {
|
|
|
372
372
|
* - "user" → `ai.model_public` (anon + authenticated; masked, points pricing), filtered to
|
|
373
373
|
* ROUTABLE models via `ai.model_offering`, which also supplies each model's serving
|
|
374
374
|
* TIERS (`served_via` — the endpoint's public Matrx brand, never the real vendor).
|
|
375
|
-
* - "admin" → `
|
|
375
|
+
* - "admin" → `ai.admin_model_catalog()` + `ai.admin_model_offerings()` (SECURITY
|
|
376
376
|
* DEFINER, gated by `is_super_admin()`): raw $ pricing, real vendors, every
|
|
377
377
|
* offering. NEVER read `ai.model_admin` / `ai.offering` directly from a client.
|
|
378
378
|
*
|
package/dist/versions/index.cjs
CHANGED
|
@@ -202,7 +202,7 @@ var AgentVersionsError = class extends Error {
|
|
|
202
202
|
}
|
|
203
203
|
};
|
|
204
204
|
async function listAgentVersions(client, query) {
|
|
205
|
-
const { data, error } = await client.rpc("agx_get_version_history", {
|
|
205
|
+
const { data, error } = await client.schema("agent").rpc("agx_get_version_history", {
|
|
206
206
|
p_agent_id: query.agentId,
|
|
207
207
|
p_limit: query.limit ?? 50,
|
|
208
208
|
p_offset: query.offset ?? 0
|
|
@@ -211,7 +211,7 @@ async function listAgentVersions(client, query) {
|
|
|
211
211
|
return Array.isArray(data) ? data : [];
|
|
212
212
|
}
|
|
213
213
|
async function readAgentVersionSnapshot(client, query) {
|
|
214
|
-
const { data, error } = await client.rpc("agx_get_version_snapshot", {
|
|
214
|
+
const { data, error } = await client.schema("agent").rpc("agx_get_version_snapshot", {
|
|
215
215
|
p_agent_id: query.agentId,
|
|
216
216
|
p_version_number: query.version
|
|
217
217
|
});
|
|
@@ -227,7 +227,7 @@ async function resolveAgentVersionId(client, versionId) {
|
|
|
227
227
|
return { versionId: row.id, agentId: row.agent_id, versionNumber: row.version_number, agentName: row.name };
|
|
228
228
|
}
|
|
229
229
|
async function promoteAgentVersion(client, query) {
|
|
230
|
-
const { data, error } = await client.rpc("agx_promote_version", {
|
|
230
|
+
const { data, error } = await client.schema("agent").rpc("agx_promote_version", {
|
|
231
231
|
p_agent_id: query.agentId,
|
|
232
232
|
p_version_number: query.version
|
|
233
233
|
});
|
package/dist/versions/index.js
CHANGED
|
@@ -159,7 +159,7 @@ var AgentVersionsError = class extends Error {
|
|
|
159
159
|
}
|
|
160
160
|
};
|
|
161
161
|
async function listAgentVersions(client, query) {
|
|
162
|
-
const { data, error } = await client.rpc("agx_get_version_history", {
|
|
162
|
+
const { data, error } = await client.schema("agent").rpc("agx_get_version_history", {
|
|
163
163
|
p_agent_id: query.agentId,
|
|
164
164
|
p_limit: query.limit ?? 50,
|
|
165
165
|
p_offset: query.offset ?? 0
|
|
@@ -168,7 +168,7 @@ async function listAgentVersions(client, query) {
|
|
|
168
168
|
return Array.isArray(data) ? data : [];
|
|
169
169
|
}
|
|
170
170
|
async function readAgentVersionSnapshot(client, query) {
|
|
171
|
-
const { data, error } = await client.rpc("agx_get_version_snapshot", {
|
|
171
|
+
const { data, error } = await client.schema("agent").rpc("agx_get_version_snapshot", {
|
|
172
172
|
p_agent_id: query.agentId,
|
|
173
173
|
p_version_number: query.version
|
|
174
174
|
});
|
|
@@ -184,7 +184,7 @@ async function resolveAgentVersionId(client, versionId) {
|
|
|
184
184
|
return { versionId: row.id, agentId: row.agent_id, versionNumber: row.version_number, agentName: row.name };
|
|
185
185
|
}
|
|
186
186
|
async function promoteAgentVersion(client, query) {
|
|
187
|
-
const { data, error } = await client.rpc("agx_promote_version", {
|
|
187
|
+
const { data, error } = await client.schema("agent").rpc("agx_promote_version", {
|
|
188
188
|
p_agent_id: query.agentId,
|
|
189
189
|
p_version_number: query.version
|
|
190
190
|
});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@ai-matrx/agents",
|
|
3
|
-
"version": "0.59.
|
|
3
|
+
"version": "0.59.242",
|
|
4
4
|
"description": "Portable AI Matrx agent stream protocol, event projection, and safe result-presentation primitives.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "./dist/index.cjs",
|
|
@@ -509,13 +509,13 @@
|
|
|
509
509
|
"sideEffects": false,
|
|
510
510
|
"dependencies": {
|
|
511
511
|
"@ai-matrx/alchemy": "latest",
|
|
512
|
-
"@ai-matrx/api": "latest",
|
|
513
512
|
"@ai-matrx/associations": "latest",
|
|
514
|
-
"@ai-matrx/design-system": "latest",
|
|
515
|
-
"@ai-matrx/data": "latest",
|
|
516
513
|
"@ai-matrx/content-ir": "latest",
|
|
517
|
-
"@ai-matrx/
|
|
514
|
+
"@ai-matrx/data": "latest",
|
|
515
|
+
"@ai-matrx/design-system": "latest",
|
|
516
|
+
"@ai-matrx/api": "latest",
|
|
518
517
|
"@ai-matrx/diff": "latest",
|
|
518
|
+
"@ai-matrx/icons": "latest",
|
|
519
519
|
"@ai-matrx/kit": "latest"
|
|
520
520
|
},
|
|
521
521
|
"peerDependencies": {
|
|
@@ -561,5 +561,5 @@
|
|
|
561
561
|
"verify:tarball": "node ./scripts/verify-tarball.mjs",
|
|
562
562
|
"typegen:self-test": "node scripts/typegen/drop-guard.self-test.mjs && node scripts/typegen/check-api-types-fresh.mjs --self-test"
|
|
563
563
|
},
|
|
564
|
-
"gitHead": "
|
|
564
|
+
"gitHead": "60cd3951abb4c6805525952cccbd1d020ecb3010"
|
|
565
565
|
}
|