Skip to content

[persona-kit 5/8] Shrink @agentworkforce/workload-router (drop persona types, major bump) #68

@willwashburn

Description

@willwashburn

Part of the persona-kit consolidation. Depends on #67. This is issue 5 of 8.

Goal

Now that workforce CLI consumes everything persona-shaped from @agentworkforce/persona-kit (#67), @agentworkforce/workload-router no longer needs to re-export those symbols. Delete the moved-out exports outright. Major-version bump for the breaking change.

After this PR, workload-router is only:

  • Routing profiles (RoutingProfile, RoutingProfileRule)
  • Persona catalog (personaCatalog, the auto-generated registry from packages/workload-router/src/generated/personas.ts)
  • PersonaSelection (the routing-resolution result type)
  • Evidence + owner-decision logic
  • Anything else that's about picking a persona for a workload, not about instantiating one.

What gets deleted from packages/workload-router/src/index.ts

Everything that was re-exported via persona-kit shim in #65. Concretely:

  • Constants: HARNESS_VALUES, PERSONA_TIERS, PERSONA_TAGS, SIDECAR_MD_MODES, PERMISSION_MODES, CODEX_SANDBOX_MODES, CODEX_APPROVAL_POLICIES, SKILL_SOURCE_KINDS, HARNESS_SKILL_TARGETS.
  • Types: Harness, PersonaTier, PersonaTag, HarnessSettings, PersonaRuntime, PersonaSkill, PersonaInputSpec, PersonaPermissions, PersonaMount, McpServerSpec, PersonaSpec, HarnessSkillTarget, SkillMaterializationOptions, SkillInstall, SkillMaterializationPlan, PersonaInstallContext, PersonaContext, SidecarMdMode, CodexSandboxMode, CodexApprovalPolicy, PermissionMode.
  • Functions: materializeSkills, materializeSkillsFor, parseSkills, parsePersonaSpec, buildInstallArtifacts, resolveSkillSource.
  • Constants/types that the persona schema references: PERSONA_INTENTS, BUILT_IN_PERSONA_INTENTS — these are persona-domain.

What stays

Tasks

Constraints

  • This is a breaking change for any external consumer of @agentworkforce/workload-router that imports persona-domain symbols. Per user direction, no back-compat shim. Major version bump signals it.
  • relay's SDK still pins @agentworkforce/workload-router@^0.11.0 at this point — that's fine because relay's migration is a separate issue (relay-side). Don't break that pin from this side; relay will catch up by depending on persona-kit directly.
  • Don't touch packages/workload-router/src/generated/personas.ts or its build script; the catalog stays.

Verification

  • pnpm -r build succeeds.
  • pnpm -r test passes.
  • agentworkforce <persona> smoke test (claude/codex/opencode harnesses) — same behavior as before.
  • grep -r '@agentworkforce/workload-router' packages/cli packages/persona-kit packages/harness-kit packages/agentworkforce — only routing/catalog imports remain; no materializeSkills, PersonaSpec, PersonaSkill, Harness from workload-router anywhere in the monorepo.
  • npm pack --dry-run on workload-router shows the smaller surface area; no leftover persona files.

Reference

Plan section 1.5.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions