Skip to content

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

feat: preload open issues for quality audits

[._.]/ Adam Eivyf1758a61a420
diff --git a/server/services/taskSchedule.test.js b/server/services/taskSchedule.test.js
index c75d0a7660..53a7b3149b 100644
--- a/server/services/taskSchedule.test.js
+++ b/server/services/taskSchedule.test.js
@@ -1853,15 +1853,14 @@ describe('taskSchedule', () => {
// Every file-issues-by-default lane, in ONE table: the posture is a single
// product decision ("an unattended scheduled run must not land code"), so
// asserting it in two places 20 lines apart just means a future flag gets
- // added to one of them. `dataInputs` is the only column that varies — the
- // lanes that preload open issues/PRs dedup against work already filed or in
- // flight without spending the agent's own forge calls.
- const NO_PRELOAD = undefined
+ // added to one of them. Every audit includes open issues; some also preload
+ // PRs to dedup against work in flight without spending forge calls.
+ const OPEN_ISSUES_ONLY = ['open-issues']
const DEDUP_PRELOAD = ['open-issues', 'open-pull-requests']
const FILE_ISSUES_LANES = [
- ['data-safety', NO_PRELOAD],
- ['simplify', NO_PRELOAD],
- ['ui-lifecycle', NO_PRELOAD],
+ ['data-safety', OPEN_ISSUES_ONLY],
+ ['simplify', OPEN_ISSUES_ONLY],
+ ['ui-lifecycle', OPEN_ISSUES_ONLY],
['module-hygiene', DEDUP_PRELOAD],
// Derived, so a seventh better-* lane cannot be added without landing here.
...[...AUDIT_TASK_TYPES]
@@ -1881,6 +1880,12 @@ describe('taskSchedule', () => {
])
})
+ it('ships open issues for every scheduled quality audit', () => {
+ for (const taskType of AUDIT_TASK_TYPES) {
+ expect(DEFAULT_TASK_INTERVALS[taskType]?.dataInputs, taskType).toContain('open-issues')
+ }
+ })
+
it.each(FILE_ISSUES_LANES)('registers %s as an enabled on-demand file-issues audit', (taskType, dataInputs) => {
expect(SELF_IMPROVEMENT_TASK_TYPES).toContain(taskType)
expect(TASK_TYPE_DESCRIPTIONS[taskType]).toBeTruthy()
diff --git a/server/services/taskScheduleRegistry.js b/server/services/taskScheduleRegistry.js
index 41eb94a54d..3f9d5703e6 100644
--- a/server/services/taskScheduleRegistry.js
+++ b/server/services/taskScheduleRegistry.js
@@ -177,7 +177,7 @@ const fileIssuesAuditInterval = () => ({
taskMetadata: { fileIssues: true, useWorktree: false, openPR: false },
});
-export const DEFAULT_TASK_INTERVALS = {
+const TASK_INTERVAL_DEFAULTS = {
[PRIVATE_SECURITY_TASK_TYPE]: { type: INTERVAL_TYPES.ON_DEMAND, enabled: true, providerId: null, model: null, prompt: null, taskMetadata: { ...PRIVATE_SECURITY_DELIVERY } },
'model-comparison-refresh': { type: INTERVAL_TYPES.ON_DEMAND, enabled: false, providerId: null, model: null, prompt: null, taskMetadata: { ...NON_COMMITTING_COORDINATOR_METADATA } },
'security': { type: INTERVAL_TYPES.ON_DEMAND, enabled: true, providerId: null, model: null, prompt: null, taskMetadata: { fileIssues: false } },
@@ -423,6 +423,18 @@ export const DEFAULT_TASK_INTERVALS = {
'universe-bible-images': { type: INTERVAL_TYPES.ON_DEMAND, enabled: true, providerId: null, model: null, prompt: null, taskMetadata: { universeId: 'all', scope: 'all', maxEntries: 10, requireDescribed: false } }
};
+// Every catalog audit is displayed as a `better-*` quality task. Give all of
+// them the current issue inventory by default so they can avoid filing work
+// that is already tracked. Preserve other configured inputs such as PRs.
+export const DEFAULT_TASK_INTERVALS = Object.fromEntries(
+ Object.entries(TASK_INTERVAL_DEFAULTS).map(([taskType, interval]) => [
+ taskType,
+ isAuditTaskType(taskType)
+ ? { ...interval, dataInputs: [...new Set([...(interval.dataInputs || []), 'open-issues'])] }
+ : interval
+ ])
+);
+
// Agent-options that a task manages internally — UI locks the toggle, and
// loadSchedule/updateTaskInterval enforce the default value regardless of
// what's persisted or POSTed. The reasoning lives next to each task above