aboutsummaryrefslogtreecommitdiff
path: root/modules/core/module-predictor.js
diff options
context:
space:
mode:
Diffstat (limited to 'modules/core/module-predictor.js')
-rw-r--r--modules/core/module-predictor.js3
1 files changed, 3 insertions, 0 deletions
diff --git a/modules/core/module-predictor.js b/modules/core/module-predictor.js
index 312325b..3d868ae 100644
--- a/modules/core/module-predictor.js
+++ b/modules/core/module-predictor.js
@@ -106,6 +106,7 @@ class PredictorModule {
hasWeb: /\b(fetch|url|http|web)\b/.test(lower),
hasOrchestrate: /\b(orchestrat|delegate|agent)\b/.test(lower),
hasModule: /\b(module|edit_module|view_module)\b/.test(lower),
+ hasSync: /\b(sync|recall|remember|previous session|state sync)\b/.test(lower),
complexity: Math.min(task.length / 50, 10), // 0-10 scale
keywords: [...new Set(lower.split(/\s+/).filter(w => w.length > 3))].slice(0, 10)
};
@@ -128,6 +129,7 @@ class PredictorModule {
features.hasWeb === f.hasWeb,
features.hasOrchestrate === f.hasOrchestrate,
features.hasModule === f.hasModule,
+ features.hasSync === f.hasSync,
];
score = matches.filter(Boolean).length / matches.length;
// Keyword overlap bonus
@@ -146,6 +148,7 @@ class PredictorModule {
if (features.hasSearch || features.hasWeb) { baseDuration = 25; baseTurns = 5; }
if (features.hasWrite) { baseDuration = 20; baseTurns = 4; }
if (features.hasOrchestrate) { baseDuration = 40; baseTurns = 8; }
+ if (features.hasSync) { baseDuration = 30; baseTurns = 6; }
if (features.complexity > 5) baseDuration *= 1.5;
return {
duration: baseDuration,