@serkanalgur/opencode-nexus 2.0.2 → 2.0.3

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.
Files changed (2) hide show
  1. package/dist/index.js +17 -1
  2. package/package.json +1 -1
package/dist/index.js CHANGED
@@ -12587,7 +12587,23 @@ By role: ${JSON.stringify(stats.byRole)}` };
12587
12587
  const { tasks } = input;
12588
12588
  const taskList = JSON.parse(tasks);
12589
12589
  const remaining = orchestrator.budget.maxTotalCost - orchestrator.totalSpent;
12590
- const result = orchestrator.forecaster.forecastAll(taskList, remaining);
12590
+ const normalizedTasks = taskList.map((t) => ({
12591
+ task: t.task || {
12592
+ id: `forecast-${Date.now()}`,
12593
+ name: t.name || `${t.role} task`,
12594
+ description: t.description || "",
12595
+ files: { include: [] },
12596
+ dependencies: [],
12597
+ requiredRole: t.role,
12598
+ complexity: typeof t.complexity === "number" ? { overall: t.complexity, factors: { fileCount: 0, codeLines: 0, dependencyDepth: 0, domainKnowledge: 0, riskLevel: "low" } } : { overall: 50, factors: { fileCount: 0, codeLines: 0, dependencyDepth: 0, domainKnowledge: 0, riskLevel: "low" } },
12599
+ priority: "normal",
12600
+ status: "pending"
12601
+ },
12602
+ role: t.role,
12603
+ model: t.model,
12604
+ complexity: typeof t.complexity === "number" ? { overall: t.complexity, factors: { fileCount: 0, codeLines: 0, dependencyDepth: 0, domainKnowledge: 0, riskLevel: "low" } } : t.complexity || { overall: 50, factors: { fileCount: 0, codeLines: 0, dependencyDepth: 0, domainKnowledge: 0, riskLevel: "low" } }
12605
+ }));
12606
+ const result = orchestrator.forecaster.forecastAll(normalizedTasks, remaining);
12591
12607
  const lines = result.estimates.map((e) => `${e.taskName}: ~$${e.estimatedCost.toFixed(4)} (${e.model})`);
12592
12608
  lines.push(`
12593
12609
  Total: ~$${result.totalEstimatedCost.toFixed(4)}`);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@serkanalgur/opencode-nexus",
3
- "version": "2.0.2",
3
+ "version": "2.0.3",
4
4
  "description": "Adaptive Multi-Agent Orchestration with Cost Intelligence for OpenCode V2",
5
5
  "keywords": [
6
6
  "opencode",