Skip to content
ContractSpec
Start here

module.builder-workbench

Reusable Builder workbench UI module.

domainsmodulev2.1.4experimentalservernode
@lssm-tech/module.builder-workbench
bun add @lssm-tech/module.builder-workbench
Package source ↗Manifest ↗

Manifest declarations describe the current workspace; they do not verify registry publication or runtime execution.

Package guide

Reusable React surfaces for the Builder control plane: workspace home, guided chat/voice, source inbox, omnichannel inbox, blueprint editing, and readiness review.

Company context

Pass the optional companyContext controller to BuilderWorkbench to expose CompanyContextPanel in Sources, or embed that panel independently. Hosts own authenticated retrieval; the shared projectCompanyContextView rejects stale workspace/question responses and malformed evidence before rendering text. The panel distinguishes missing configuration, denied access, conflicting sources, empty results, and loading. Knowledge does not grant release authority. English, French, and Spanish catalogs are included. Live provider activation, Storybook browser qualification, and visual baseline review remain required.

Model route inspection

The workbench exports route visibility components for Builder governance: ModelRouteBadge, ModelRouteInspector, ModelRouteOverridePanel, RiskFlagList, and RoutingEvidenceTimeline. These surfaces expose selected policy, difficulty, provider/model, risk flags, fallback routes, and rejected unsafe downgrades.

RoleMorph Workbench panels

The workbench exports RoleMorphWorkbenchPanels for rendering RoleMorph packet views with existing design-system/ui-kit primitives. The panel set covers role selection, surface preview/registry summaries, inspector diagnostics, policy diff summaries, safe missing-binding repairs, authorization/evidence summaries, and audit/replay timestamps. It renders serializable packet contracts only; provider execution, durable stores, and production authorization enforcement remain outside the module.

Candidate controls

Pass the optional candidate controller to BuilderWorkbench to expose CandidateExecutionPanel in the Plan tab, or embed that panel directly. Prepare, approve, run and status controls follow server-resolved available actions. Unconfigured, denied, stale and indeterminate states do not appear as successful execution. English, French and Spanish messages are included. Candidate review is distinct from hosted preview or release.

useBuilderCandidate({ workspaceId, planRef, request, onRefreshPlan }) from ./presentation/hooks drives that controller: one in-flight action at a time, stale responses dropped across workspace/plan switches, bounded status polling (3 s, at most 20 polls) while queued or running, and onRefreshPlan on stale/succeeded. Hosts inject the request transport (BuilderCandidateRequest) and keep authentication and routing.

Relationships

THIS PACKAGEmodule.builder-workbench6 import paths

Arrows point from a package to its direct dependency. Counts are derived from captured workspace manifests.

9 declarations

Declared capabilities

Module Builder Workbench

Reusable Builder workbench UI module.

Scripts

  • publish:pkgbun publish --tolerate-republish --ignore-scripts --verbose
  • publish:pkg:canarybun publish:pkg --tag canary
  • buildcontractspec-bun-build build
  • build:bundlecontractspec-bun-build transpile
  • build:typescontractspec-bun-build types
  • devcontractspec-bun-build dev
  • cleanrimraf dist .turbo
  • lintbun lint:fix
  • lint:fixnode ../../../../scripts/biome.cjs check --write --unsafe --only=nursery/useSortedClasses . && node ../../../../scripts/biome.cjs check --write .
  • lint:checknode ../../../../scripts/biome.cjs check .
  • testbun test
  • prebuildcontractspec-bun-build prebuild
  • typechecktsgo --noEmit