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 (codex): scene-balance guidance honors minComponents (add both modes under 3)
[._.]/ Adam Eivy0d55d258f5f4
diff --git a/server/lib/editorial/checkRegistry.js b/server/lib/editorial/checkRegistry.jsindex 3a5fe86fc8..04001e7169 100644--- a/server/lib/editorial/checkRegistry.js+++ b/server/lib/editorial/checkRegistry.js@@ -1119,15 +1119,20 @@ export const EDITORIAL_CHECKS = [if (present.length === 0 || present.length >= minComponents) continue;const label = sceneLabel(s);const issueNumber = Number.isInteger(s.issueNumber) ? s.issueNumber : null;+ // How many more modes reach the configured target, and whether ALL the+ // missing ones are required to get there — so the guidance honors+ // minComponents=3 (a single-mode scene must add BOTH missing modes, not one).+ const needed = minComponents - present.length;+ const addJoiner = needed >= missing.length ? ' and ' : ' or ';const problem = present.length === 1- ? `Scene "${label}" is all ${present[0]} — no ${missing.join(' or ')}. A single-mode scene reads flat; balance at least two of narrative, action, and dialogue.`+ ? `Scene "${label}" is all ${present[0]} — no ${missing.join(' or ')}. A single-mode scene reads flat; aim for at least ${minComponents} of narrative, action, and dialogue.`: `Scene "${label}" has ${present.join(' and ')} but no ${missing.join(' or ')} — only ${present.length} of the ${minComponents} components you expect.`;findings.push({severity: ctx.severityDefault,category: 'pacing',location: issueNumber != null ? `Issue ${issueNumber}: ${label}` : `Scene: ${label}`,problem,- suggestion: `Add ${missing.join(' or ')} so the scene isn't a ${present.join('/')}-only beat (e.g. ground talking heads in the room, give a narration wall a beat of action, or let an action scene breathe with a line of dialogue or interiority).`,+ suggestion: `Add ${missing.join(addJoiner)} so the scene isn't a ${present.join('/')}-only beat (e.g. ground talking heads in the room, give a narration wall a beat of action, or let an action scene breathe with a line of dialogue or interiority).`,anchorQuote: typeof s.anchorQuote === 'string' ? s.anchorQuote : '',issueNumber,});diff --git a/server/lib/editorial/checkRegistry.test.js b/server/lib/editorial/checkRegistry.test.jsindex 3a7797cd06..8102717af0 100644--- a/server/lib/editorial/checkRegistry.test.js+++ b/server/lib/editorial/checkRegistry.test.js@@ -605,6 +605,23 @@ describe('scene.component-balance — deterministic check', () => {expect(findings[0].problem).toMatch(/narrative and action but no dialogue/);});+ it('tells a single-mode scene to add BOTH missing modes under minComponents=3', () => {+ // A single-mode scene under an all-three target must add both gaps, not "either".+ const findings = runScene(+ [scene({ heading: 'Monologue', components: { narrative: false, action: false, dialogue: true } })],+ { minComponents: 3 },+ );+ expect(findings).toHaveLength(1);+ expect(findings[0].problem).toMatch(/at least 3 of/);+ expect(findings[0].suggestion).toMatch(/Add narrative and action/); // "and", not "or"+ });++ it('tells a single-mode scene it may add EITHER missing mode under the default (2)', () => {+ const findings = runScene([scene({ components: { narrative: false, action: false, dialogue: true } })]);+ expect(findings[0].problem).toMatch(/at least 2 of/);+ expect(findings[0].suggestion).toMatch(/Add narrative or action/); // "or" — one suffices+ });+it('minComponents=1 disables the check', () => {const findings = runScene([scene({ components: { narrative: false, action: false, dialogue: true } })],