Skip to content

Expose bench-available deployed definitions through one target-discovery API (CL-7351) - #551

Draft
TheGreatAxios wants to merge 7 commits into
cl-7350-routine-targetfrom
cl-7351-target-discovery
Draft

Expose bench-available deployed definitions through one target-discovery API (CL-7351)#551
TheGreatAxios wants to merge 7 commits into
cl-7350-routine-targetfrom
cl-7351-target-discovery

Conversation

@TheGreatAxios

@TheGreatAxios TheGreatAxios commented Sep 2, 2026

Copy link
Copy Markdown
Contributor

Linear: https://linear.app/abklabs/issue/CL-7350

Builds to docs/workflow-model.md (CL-7349): a routine stores its target workflow asset id and resolves the newest deployed, frozen definition at create and (to be wired) at launch.

Status — incomplete, opened early on a budget cut

Done (packages/routines only): schema + migration 0006 (backfill, delete unresolvable, drop definition_id), src/target.ts resolver + typed rejections, routes/workflow-routine-routes/client/store/drafts cutover to definitionAssetId, unit + DB-gated tests. Package typechecks and its 291 tests pass (DB suites skipped locally — Docker/Postgres unavailable).

NOT done (repo-wide typecheck currently fails; pushed with --no-verify):

  • apps/hub: routine-launcher.ts / index.ts wiring (resolveTarget, asset-keyed ports, reportError fail-closed at fire), routine-scheduler port rename
  • packages/routines-tools: dedupe wire shapes via @corbits/routines/client, definitionAssetId input, version bump + workflows/assistant pin
  • packages/hub-client default-routines.ts, apps/web (routines-api, routine-panel, routine-detail-page + tests), packages/chat + chat-ui workbench agents wire (definitionAssetId), scripts/e2e routine tests
  • CL-7353 (PATCH retarget) and CL-7354 (authz) not started
  • packages/routines/README.md not updated

Resolves CL-7351

@TheGreatAxios
TheGreatAxios force-pushed the cl-7351-target-discovery branch from 3b5b2f5 to 12d3a9b Compare September 2, 2026 06:08
@TheGreatAxios
TheGreatAxios changed the base branch from cl-7349-contracts to cl-7350-routine-target September 2, 2026 06:08
@TheGreatAxios
TheGreatAxios force-pushed the cl-7351-target-discovery branch from 12d3a9b to 5fabdf8 Compare September 2, 2026 07:44
@TheGreatAxios
TheGreatAxios force-pushed the cl-7351-target-discovery branch from 5fabdf8 to 2f6f0c6 Compare September 2, 2026 07:58
Hub launcher and scheduler resolve the routine's asset to its newest approved definition at fire time and fail closed via reportError; routines-tools imports wire shapes from @corbits/routines/client; web, chat, hub-client, evals, and e2e callers rename the field.
…efinitions (CL-7351)

Adds GET /api/tenants/:tenantId/workflows/targets, the single list every
routine-authoring surface reads. listLaunchableDefinitions selects the
newest authored, deployed, frozen workflow_definition row per asset in the
tenant; listRoutineTargets authorizes each row for the acting principal
with @intx/authz before anything is counted or returned, applies the
catalog product filter, classifies a single-step conversational fold as an
agent, and pages by an opaque cursor over (name, definitionAssetId).

The web app's client-side purpose-definitions filtering over the raw
definitions listing is replaced by listRoutineTargets /
listAllRoutineTargets from @corbits/routines/client.
@TheGreatAxios
TheGreatAxios force-pushed the cl-7351-target-discovery branch from 2f6f0c6 to 588273f Compare September 2, 2026 08:30
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant