Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion apps/hub/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,6 @@
"@corbits/artifacts": "github:corbitsdev/corbits-artifacts#dc435ba749b4378f19e5de772159c2a57e932938",
"@corbits/artifacts-hub": "workspace:*",
"@corbits/bench": "workspace:*",
"@corbits/catalog-tools": "workspace:*",
"@corbits/chat": "workspace:*",
"@corbits/commands": "workspace:*",
"@corbits/error-sink": "workspace:*",
Expand Down
22 changes: 0 additions & 22 deletions apps/hub/src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -158,7 +158,6 @@ import {
createResolvedOfferingsRoutes,
createWorkflowCatalogRoutes,
} from "@corbits/inference-catalog";
import { createWorkflowCatalogAdminRoutes } from "@corbits/catalog-tools/routes";
import { createWorkflowAccessRoutes } from "@corbits/access-tools/routes";
import { generateId } from "@intx/hub-common";

Expand Down Expand Up @@ -3047,27 +3046,6 @@ export async function createHub(config: HubConfig) {
getPolicy: (tenantId) => benchModelPolicy.store.getPolicy(tenantId),
}),
);
// Myra's own catalog-administration surface
// (`@corbits/catalog-tools`' `create_offering`/`set_offering_priority`/
// `disable_offering`): the workflow-run-authenticated counterpart to
// `@intx/hub-api`'s tenant-session `/api/tenants/:tenantId/catalog/
// {models,providers,offerings}` mount, which only accepts a browser
// session and so 401s a workflow child. Reuses the SAME grant store and
// condition registry every other extension's own requireGrant check
// runs against, and the SAME sidecarRouter/credentialCipher the
// tenant-session mount pushes source updates through on every offering
// write, so a write through either surface propagates identically.
app.route(
"/api/workflow-catalog-admin",
createWorkflowCatalogAdminRoutes({
db,
authenticator: createWorkflowRunAuthenticator({ db }),
grantStore: chatGrantStore,
conditionRegistry: chatConditionRegistry,
sidecarRouter,
credentialCipher,
}),
);
// Myra's own principal/grant surface (`@corbits/access-tools`'
// `list_principals`/`list_grants`/`grant_access`/`revoke_access`): the
// workflow-run-authenticated counterpart to the tenant-session
Expand Down
28 changes: 11 additions & 17 deletions bun.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

30 changes: 5 additions & 25 deletions packages/catalog-tools/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -23,29 +23,9 @@ tools read only, so none is gated behind approval.

## Managing offerings

Three more tools let an agent write to the tenant's own inference catalog,
through this package's own workflow-run-authenticated mirror of the
tenant-admin catalog routes (`./src/routes.ts`'s
`createWorkflowCatalogAdminRoutes`, mounted in `apps/hub` at
`/api/workflow-catalog-admin`) rather than the read-only concept surface
above. The tenant-admin routes themselves
Catalog administration is UI-only (CL-7588): models, providers, and
offerings are managed through the tenant-admin catalog routes
(`vendor/intx/hub-api/src/routes/{models,model-providers,
model-offerings}.ts`) only accept a browser session, which a workflow run
never has — only its sidecar bearer token and run address, the same
credential the read-only surface above already uses.

- **`create_offering`** — pairs a model (by canonical name) with a model
provider (by name), both already present in this workbench's own catalog,
at a given priority with a set of advertised capabilities. Gated behind
`approval: "ask"`: it changes what this bench can resolve to at runtime.
- **`set_offering_priority`** — reorders an offering this workbench already
owns directly, changing where it falls in source-resolution fallback
order. Ungated: it only reorders an offering already live.
- **`disable_offering`** — restricts an offering this workbench already owns
directly, taking it out of source resolution without deleting its pricing
history. Gated behind `approval: "ask"`: running instances resolved
through it fail over to the next eligible source.

`create_offering` never invents a model or provider id — it resolves the
given canonical name and provider name against this tenant's own catalog
listing first, and refuses rather than guessing when neither is found.
model-offerings}.ts`) behind a browser session. This package exposes no
write tools and no hub routes — the three read-only tools above are the
whole surface.
12 changes: 2 additions & 10 deletions packages/catalog-tools/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,24 +6,16 @@
"license": "LGPL-2.1-or-later",
"type": "module",
"exports": {
".": "./src/index.ts",
"./routes": "./src/routes.ts"
".": "./src/index.ts"
},
"scripts": {
"typecheck": "tsc --noEmit",
"test": "bun test"
},
"dependencies": {
"@corbits/error-sink": "workspace:*",
"@intx/agent": "workspace:*",
"@intx/db": "workspace:*",
"@intx/hub-api": "workspace:*",
"@intx/hub-common": "0.3.0",
"@intx/hub-sessions": "workspace:*",
"@intx/types": "workspace:*",
"arktype": "catalog:",
"drizzle-orm": "catalog:",
"hono": "catalog:"
"arktype": "catalog:"
},
"devDependencies": {
"@types/bun": "catalog:",
Expand Down
Loading
Loading