molecule-core/canvas/src/components
Molecule AI Frontend Engineer 848b745b6e feat(canvas): expose effort + task_budget in ConfigTab (#608)
Adds two new Claude API primitives (Opus 4.7+) as configurable workspace
fields in the Config tab form:

  effort: 'low' | 'medium' | 'high' | 'xhigh'
    Maps to output_config.effort in the Anthropic Messages API.
    Controls thinking depth — xhigh enables extended thinking mode.

  task_budget: integer (token count, 0 = unset)
    Maps to output_config.task_budget.total; requires beta header
    task-budgets-2026-03-13. Lets operators cap token spend per task.

Both fields are stored as top-level keys in config.yaml and read by
claude_sdk_executor.py (workspace-template side, tracked in #608).

Canvas changes:
- form-inputs.tsx: effort?: string, task_budget?: number added to
  ConfigData; DEFAULT_CONFIG initialises them to "" / 0
- yaml-utils.ts: toYaml() emits effort + task_budget (omits when
  empty/zero); parseYaml() already handles plain string/integer keys
- ConfigTab.tsx: new collapsible "Claude Settings" section (defaultOpen=false)
  shown when runtime === "claude-code" OR model name contains "claude"
  or "anthropic". Dropdown for effort (4 options + unset), number input
  for task_budget (step 1000, 0 = unset).

Tests (25 cases in ClaudeSettings.test.tsx):
  - toYaml serialises all four effort values + omits empty/undefined
  - toYaml serialises task_budget + omits 0/undefined
  - effort appears before task_budget in YAML output
  - parseYaml round-trips both fields correctly
  - DEFAULT_CONFIG shape assertions
  - Source assertions for section guards + option values
  - React rendering: section visible for claude-code/claude model,
    hidden for non-Claude runtime (crewai + gpt-4o)

640/640 tests pass. Build clean.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-04-17 06:24:36 +00:00
..
__tests__ feat(canvas): expose effort + task_budget in ConfigTab (#608) 2026-04-17 06:24:36 +00:00
canvas initial commit — Molecule AI platform 2026-04-13 11:55:37 -07:00
settings fix: code review findings — token UI, auth hardening, WS dedup 2026-04-16 10:42:26 -07:00
tabs feat(canvas): expose effort + task_budget in ConfigTab (#608) 2026-04-17 06:24:36 +00:00
ui feat(canvas): wire live metrics API in WorkspaceUsage (#592) 2026-04-17 06:00:14 +00:00
ApprovalBanner.tsx fix(a11y): WCAG ARIA fixes for time-sensitive components (Fixes #Fix1/#Fix2/#Fix3) 2026-04-16 05:40:40 -07:00
AuthGate.tsx fix(canvas): UIUX Cycle 15 dark-theme & a11y sweep (C1-C5, A1-A4, F1, M1) 2026-04-16 10:35:32 +00:00
BundleDropZone.tsx fix(a11y): WCAG ARIA fixes for time-sensitive components (Fixes #Fix1/#Fix2/#Fix3) 2026-04-16 05:40:40 -07:00
Canvas.tsx fix(canvas): fitView on new workspace provision — respects user zoom level (#426) 2026-04-16 05:40:40 -07:00
CommunicationOverlay.tsx fix(canvas): address all code review findings on PR #482 2026-04-16 07:48:47 -07:00
ConfirmDialog.tsx fix(canvas): WCAG critical — ARIA live toasts, dialog focus trap, keyboard nav 2026-04-15 08:31:06 +00:00
ContextMenu.tsx fix(canvas): hydration error UI (#554), radio arrow-key nav (#556), zoom-to-team context menu (#557) (#565) 2026-04-17 00:35:54 +00:00
ConversationTraceModal.tsx fix(canvas): dark theme a11y — settings buttons, input fields, ReactFlow colorMode, zinc-400 contrast, aria-labels 2026-04-15 07:56:53 +00:00
CookieConsent.tsx feat(canvas): cookie consent banner with privacy-preserving default 2026-04-15 13:01:48 -07:00
CreateWorkspaceDialog.tsx fix(canvas): WCAG SC 1.3.1 — programmatic label/input association in InputField 2026-04-17 06:07:08 +00:00
EmptyState.tsx fix(canvas): address all code review findings on PR #482 2026-04-16 07:48:47 -07:00
ErrorBoundary.tsx test: 100% coverage of extracted helpers + ConfirmDialog singleButton 2026-04-13 17:08:33 -07:00
Legend.tsx fix(canvas): address all code review findings on PR #482 2026-04-16 07:48:47 -07:00
MissingKeysModal.tsx fix(wcag): sweep text-zinc-600→zinc-500 across 9 components with small text 2026-04-16 07:53:00 +00:00
OnboardingWizard.tsx fix(canvas): UIUX Cycle 15 dark-theme & a11y sweep (C1-C5, A1-A4, F1, M1) 2026-04-16 10:35:32 +00:00
PricingTable.tsx feat(canvas): /pricing route with plan selector + Stripe checkout 2026-04-15 13:41:44 -07:00
ProvisioningTimeout.tsx initial commit — Molecule AI platform 2026-04-13 11:55:37 -07:00
SearchDialog.tsx fix(canvas): address all code review findings on PR #482 2026-04-16 07:48:47 -07:00
SidePanel.tsx fix(canvas): 5 UX polish fixes — error handling, a11y, loading state 2026-04-16 21:39:44 -07:00
Spinner.tsx fix(canvas): address all code review findings on PR #482 2026-04-16 07:48:47 -07:00
StatusDot.tsx fix(canvas): address all code review findings on PR #482 2026-04-16 07:48:47 -07:00
TemplatePalette.tsx fix(canvas): address all code review findings on PR #482 2026-04-16 07:48:47 -07:00
Toaster.tsx fix(canvas): WCAG critical — ARIA live toasts, dialog focus trap, keyboard nav 2026-04-15 08:31:06 +00:00
Toolbar.tsx fix(canvas): address all code review findings on PR #482 2026-04-16 07:48:47 -07:00
Tooltip.tsx initial commit — Molecule AI platform 2026-04-13 11:55:37 -07:00
WorkspaceNode.tsx fix(canvas): UX improvements — shared tokens, focus rings, loading spinners, a11y 2026-04-16 07:35:44 -07:00
WorkspaceUsage.tsx feat(canvas): wire live metrics API in WorkspaceUsage (#592) 2026-04-17 06:00:14 +00:00