@masslessai/push-todo 3.5.3 → 3.5.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/daemon.js +6 -37
- package/package.json +1 -1
package/lib/daemon.js
CHANGED
|
@@ -459,7 +459,7 @@ function getProjectPath(gitRemote) {
|
|
|
459
459
|
|
|
460
460
|
try {
|
|
461
461
|
const data = JSON.parse(readFileSync(REGISTRY_FILE, 'utf8'));
|
|
462
|
-
return data.projects?.[gitRemote]?.
|
|
462
|
+
return data.projects?.[gitRemote]?.localPath || data.projects?.[gitRemote]?.local_path || null;
|
|
463
463
|
} catch {
|
|
464
464
|
return null;
|
|
465
465
|
}
|
|
@@ -474,7 +474,7 @@ function getListedProjects() {
|
|
|
474
474
|
const data = JSON.parse(readFileSync(REGISTRY_FILE, 'utf8'));
|
|
475
475
|
const result = {};
|
|
476
476
|
for (const [remote, info] of Object.entries(data.projects || {})) {
|
|
477
|
-
result[remote] = info.
|
|
477
|
+
result[remote] = info.localPath || info.local_path;
|
|
478
478
|
}
|
|
479
479
|
return result;
|
|
480
480
|
} catch {
|
|
@@ -823,45 +823,14 @@ function executeTask(task) {
|
|
|
823
823
|
|
|
824
824
|
// Analyze certainty
|
|
825
825
|
const analysis = analyzeTaskCertainty(task);
|
|
826
|
-
|
|
826
|
+
let executionMode = determineExecutionMode(analysis);
|
|
827
827
|
|
|
828
828
|
log(`Task #${displayNumber} execution mode: ${executionMode}`);
|
|
829
829
|
|
|
830
|
-
//
|
|
830
|
+
// Low-certainty tasks: run in planning mode instead of blocking
|
|
831
831
|
if (executionMode === 'clarify') {
|
|
832
|
-
log(`Task #${displayNumber}
|
|
833
|
-
|
|
834
|
-
const questions = analysis?.clarificationQuestions?.map(q => ({
|
|
835
|
-
question: q.question,
|
|
836
|
-
options: q.options,
|
|
837
|
-
priority: q.priority
|
|
838
|
-
})) || [];
|
|
839
|
-
|
|
840
|
-
let clarificationSummary = 'Task requires clarification before execution.';
|
|
841
|
-
if (analysis) {
|
|
842
|
-
clarificationSummary += ` Certainty score: ${analysis.score}`;
|
|
843
|
-
if (analysis.reasons?.length > 0) {
|
|
844
|
-
clarificationSummary += ` (${analysis.reasons[0].explanation})`;
|
|
845
|
-
}
|
|
846
|
-
}
|
|
847
|
-
|
|
848
|
-
updateTaskStatus(displayNumber, 'needs_clarification', {
|
|
849
|
-
summary: clarificationSummary,
|
|
850
|
-
certaintyScore: analysis?.score,
|
|
851
|
-
clarificationQuestions: questions
|
|
852
|
-
});
|
|
853
|
-
|
|
854
|
-
if (NOTIFY_ON_NEEDS_INPUT) {
|
|
855
|
-
sendMacNotification(
|
|
856
|
-
`Task #${displayNumber} needs clarification`,
|
|
857
|
-
`${summary.slice(0, 50)}... Low certainty - please clarify.`,
|
|
858
|
-
'Ping'
|
|
859
|
-
);
|
|
860
|
-
}
|
|
861
|
-
|
|
862
|
-
taskDetails.delete(displayNumber);
|
|
863
|
-
updateStatusFile();
|
|
864
|
-
return null;
|
|
832
|
+
log(`Task #${displayNumber} low certainty - running in planning mode instead of blocking`);
|
|
833
|
+
executionMode = 'planning';
|
|
865
834
|
}
|
|
866
835
|
|
|
867
836
|
// Create worktree
|