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
gate the no-commit-criterion exemption on a tracker-filing type, not the flag alone (#3273)
[._.]/ Adam Eivy72fd1ad13177
diff --git a/.changelog/NEXT.md b/.changelog/NEXT.mdindex a8fa762d51..baae169502 100644--- a/.changelog/NEXT.md+++ b/.changelog/NEXT.md@@ -42,7 +42,7 @@- **[issue-3246] Completed direct-CLI agents now survive a PortOS restart without repeating their work.** When an agent has already written its completion sentinel, shutdown finalizes that result and dispatches its output instead of requeuing the task and potentially opening a duplicate pull request.- **[issue-3273] A new "UX/design audit" scheduled task reviews whether your screens are actually usable — and proposes, rather than rewrites.** The existing UI tasks are all narrow and all fix-and-commit: broken elements, viewport breakage, ARIA and contrast. None of them ask whether a primary action is buried below the fold, whether an empty state tells you what to do next, or whether two sibling screens confirm a delete two different ways. The `ux` task walks the running app against a seven-point checklist at desktop and mobile widths and files one issue per finding into whichever tracker the app uses — PLAN.md, GitHub, GitLab or JIRA — with the route, what the user was trying to do, why the design got in the way, the component file to change, and a size estimate. It touches no source code and opens no pull requests, because design judgment should be triaged by a human, not auto-merged. Off by default, like every other scheduled task.-- **Tracker-filing tasks no longer score every successful run as a failure.** A task whose whole job is to file issues makes no commit, so the commit check that grades autonomous runs marked each correct run a miss and drove the task type's measured success rate toward zero — which in turn slowed its schedule. Runs that are expected to leave the working tree clean are now graded on whether they finished, not on whether they committed. This also fixes the same latent problem for reference-repo watching on GitHub, GitLab and JIRA projects.+- **Tracker-filing tasks no longer score every successful run as a failure.** A task whose whole job is to file issues makes no commit, so the commit check that grades autonomous runs marked each correct run a miss and drove the task type's measured success rate toward zero — which in turn slowed its schedule. Those tasks are now graded on whether they finished rather than on whether they committed, but only on projects where they really do file out of band: the same task still has to commit on a PLAN.md project, where recording a finding means editing a file. This also fixes the same latent problem for reference-repo watching on GitHub, GitLab and JIRA projects.## POSTdiff --git a/server/services/agentFinalization.successCriteria.test.js b/server/services/agentFinalization.successCriteria.test.jsindex c810c7920f..9cdcae7bfd 100644--- a/server/services/agentFinalization.successCriteria.test.js+++ b/server/services/agentFinalization.successCriteria.test.js@@ -100,6 +100,24 @@ describe('evaluateSuccessCriteria — tracker-filing tasks (#3273)', () => {expect(await evaluateSuccessCriteria({ task, workspacePath: '/w' })).toBeNull();expect(checkForTaskCommit).not.toHaveBeenCalled();});++ it('resolves the archived-agent projection the same way as the live task', async () => {+ const task = { id: 't3', taskType: 'internal', metadata: { taskAnalysisType: 'ux', worktreeChangesExpected: false } };+ expect(await evaluateSuccessCriteria({ task, workspacePath: '/w' })).toBeNull();+ expect(checkForTaskCommit).not.toHaveBeenCalled();+ });++ it('does NOT let the flag exempt a non-tracker-filing type from its commit criterion', async () => {+ // `worktreeChangesExpected` is a user-settable per-app taskMetadata override+ // accepted for EVERY task type — it exists to opt a run out of the TUI+ // idle-complete clean-tree gate, not to disable success validation. Ungated,+ // a `security` run that exited 0 having committed nothing would be recorded+ // as a pass instead of the honest miss it is.+ checkForTaskCommit.mockResolvedValue(false);+ const task = { id: 't4', taskType: 'internal', metadata: { analysisType: 'security', worktreeChangesExpected: false } };+ expect(await evaluateSuccessCriteria({ task, workspacePath: '/w' })).toBe(false);+ expect(checkForTaskCommit).toHaveBeenCalledWith('t4', '/w');+ });});/**diff --git a/server/services/taskTypeHooks.js b/server/services/taskTypeHooks.jsindex 52dc43331a..27ea00b367 100644--- a/server/services/taskTypeHooks.js+++ b/server/services/taskTypeHooks.js@@ -43,6 +43,7 @@*/import { isFalsyMeta } from './agentState.js';+import { TRACKER_FILING_TASK_TYPES } from '../lib/workTracker.js';// taskType → () => import('./path/to/hookModule.js'). A module may export either// or both hooks; a missing export means "no hook of that kind for this type".@@ -162,27 +163,42 @@ export function isNonCommittingCoordinatorTask(task) {}/**- * Whether a task declares NO `[task-<id>]` commit criterion — the union of the- * static coordinator set above and the PER-TASK `worktreeChangesExpected: false`- * signal that the tracker-filing types (reference-watch / ux) stamp at dispatch- * (cosTaskGenerator.js#resolveTrackerFilingBlock, referenceRepos.js#triggerReferenceAnalysis).+ * Whether a task declares NO `[task-<id>]` commit criterion: the static+ * coordinator set above, OR a TRACKER-FILING task whose dispatch derived+ * `worktreeChangesExpected: false` (cosTaskGenerator.js#resolveTrackerFilingBlock,+ * referenceRepos.js#triggerReferenceAnalysis).*- * The type-keyed set cannot express the tracker-filing shape: the SAME task type- * legitimately commits on a `plan`-tracker app (it appends + commits PLAN.md- * checklist items) and legitimately commits NOTHING on a github/gitlab/jira app- * (it files issues/tickets out of band). Keying on the already-derived per-task- * flag gets both right, and retro-fixes the same latent #2696-class artifact- * `reference-watch` has on non-`plan` trackers today — every successful run- * scoring as a failure and pinning the type's learning bucket at ~0% (#3273).+ * A type-keyed set alone cannot express the tracker-filing shape: the SAME task+ * type legitimately commits on a `plan`-tracker app (it appends + commits+ * PLAN.md checklist items) and legitimately commits NOTHING on a+ * github/gitlab/jira app (it files issues/tickets out of band). Reading the+ * already-derived per-task flag gets both right, and retro-fixes the same latent+ * #2696-class artifact `reference-watch` has on non-`plan` trackers today —+ * every successful run scoring as a failure and pinning the type's learning+ * bucket at ~0% (#3273).+ *+ * The flag alone is NOT sufficient, hence the type gate in front of it:+ * `worktreeChangesExpected` is a user-settable per-app taskMetadata override+ * accepted for EVERY task type (`cosValidation.js` ALLOWED keys → `POST+ * /api/apps/:id/task-types` → merged into `metadata` in+ * cosTaskGenerator.js#generateManagedAppImprovementTaskForType). It exists to+ * opt a run out of the TUI idle-complete clean-tree gate; someone setting it+ * there is not asking to disable success validation. Ungated, a `security` task+ * carrying it would exit 0 having committed nothing and be recorded as a pass+ * instead of the honest miss it is.** Accepts the `'false'` string form for parity with the spawn-side gate- * (agentTuiSpawning.js's `isFalsyMeta`), since task metadata round-trips- * through TASKS.md as text. `true`/absent falls through to the commit check- * unchanged.+ * (agentTuiSpawning.js's `isFalsyMeta`), since task metadata round-trips through+ * TASKS.md as text. `true`/absent falls through to the commit check unchanged.*/export function declaresNoCommitCriterion(task) {- if (isFalsyMeta(task?.metadata?.worktreeChangesExpected)) return true;- return isNonCommittingCoordinatorTask(task);+ if (isNonCommittingCoordinatorTask(task)) return true;+ // Resolved the same way isNonCommittingCoordinatorTask (and the learning+ // bucket) resolves it, so a LIVE queue task (`analysisType`) and the archived+ // agent projection (`taskAnalysisType`) agree.+ const type = task?.metadata?.analysisType || task?.metadata?.taskAnalysisType || task?.taskType || null;+ if (!TRACKER_FILING_TASK_TYPES.has(type)) return false;+ return isFalsyMeta(task?.metadata?.worktreeChangesExpected);}/**