Self-hosted, Self-Improving, Federated Everything App — dev management, agent orchestration, persistent mind, digital twin, second brain, and creative pipeline from a single dashboard over Tailscale to port the user into the OS
JavaScript ai-agentsdashboarddeveloper-toolsdigital-twinquantified-selfsecond-brainself-hostedtailscale
address review (claude): fix inverted estimation boundary label in adaptive badge
[._.]/ Adam Eivy2fa082a312f1
diff --git a/client/src/components/meatspace/post/PostDrillConfig.jsx b/client/src/components/meatspace/post/PostDrillConfig.jsxindex b8f0be1b02..b4ddc3f91a 100644--- a/client/src/components/meatspace/post/PostDrillConfig.jsx+++ b/client/src/components/meatspace/post/PostDrillConfig.jsx@@ -23,8 +23,11 @@ function describeAdaptive(info) {if (info.reason === 'insufficient-samples') {return { text: `Adaptive: warming up — needs more scored sessions`, tone: 'hold' };}- if (info.reason === 'at-hardest') return { text: `Adaptive: at max ${field} ${info.from}${pct}`, tone: 'up' };- if (info.reason === 'at-easiest') return { text: `Adaptive: at min ${field} ${info.from}${pct}`, tone: 'down' };+ // Use difficulty-relative wording ("hardest"/"easiest"), not "max"/"min": for+ // estimation the hardest value is the MINIMUM tolerance, so "at max" would read+ // backwards. `from` is the effective (clamped) value at the boundary.+ if (info.reason === 'at-hardest') return { text: `Adaptive: hardest ${field} ${info.from}${pct}`, tone: 'up' };+ if (info.reason === 'at-easiest') return { text: `Adaptive: easiest ${field} ${info.from}${pct}`, tone: 'down' };return { text: `Adaptive: holding ${field} ${info.from}${pct}`, tone: 'hold' };}diff --git a/client/src/components/meatspace/post/PostDrillConfig.test.jsx b/client/src/components/meatspace/post/PostDrillConfig.test.jsxindex 0b0c625963..5c4a1982d4 100644--- a/client/src/components/meatspace/post/PostDrillConfig.test.jsx+++ b/client/src/components/meatspace/post/PostDrillConfig.test.jsx@@ -149,6 +149,26 @@ describe('PostDrillConfig', () => {await waitFor(() => expect(screen.getByText(/max digits 2 → 3 \(harder\)/)).toBeTruthy());});+ it('labels the estimation hardest boundary by difficulty, not numeric max', async () => {+ // For estimation, lower tolerance is harder — so the hardest boundary carries+ // the MINIMUM tolerance value. The badge must read "hardest", never "at max".+ getPostAdaptivePreview.mockResolvedValue({+ enabled: true,+ drills: {+ estimation: { type: 'estimation', field: 'tolerancePct', from: 3, to: 3, applied: false, score: 96, samples: 6, reason: 'at-hardest' },+ },+ });+ const withAdaptive = {+ ...config,+ mentalMath: { drillTypes: { ...config.mentalMath.drillTypes, estimation: { enabled: true, tolerancePct: 3 } } },+ adaptive: { enabled: true },+ };+ render(<PostDrillConfig config={withAdaptive} onSaved={vi.fn()} onBack={vi.fn()} />);+ await waitFor(() => expect(getPostAdaptivePreview).toHaveBeenCalled());+ await waitFor(() => expect(screen.getByText(/hardest tolerance % 3/)).toBeTruthy());+ expect(screen.queryByText(/at max tolerance/)).toBeNull();+ });+it('toggling Adaptive on persists enabled=true', async () => {render(<PostDrillConfig config={config} onSaved={vi.fn()} onBack={vi.fn()} />);fireEvent.click(screen.getByRole('switch', { name: 'Adaptive difficulty' }));