@covibes/zeroshot 5.2.1 → 5.4.0
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/CHANGELOG.md +174 -189
- package/README.md +226 -195
- package/cli/commands/providers.js +149 -0
- package/cli/index.js +3145 -2366
- package/cli/lib/first-run.js +40 -3
- package/cli/message-formatters-normal.js +28 -6
- package/cluster-templates/base-templates/debug-workflow.json +24 -78
- package/cluster-templates/base-templates/full-workflow.json +99 -316
- package/cluster-templates/base-templates/single-worker.json +23 -15
- package/cluster-templates/base-templates/worker-validator.json +105 -36
- package/cluster-templates/conductor-bootstrap.json +9 -7
- package/lib/docker-config.js +14 -1
- package/lib/git-remote-utils.js +165 -0
- package/lib/id-detector.js +10 -7
- package/lib/provider-defaults.js +62 -0
- package/lib/provider-detection.js +59 -0
- package/lib/provider-names.js +57 -0
- package/lib/settings/claude-auth.js +78 -0
- package/lib/settings.js +298 -15
- package/lib/stream-json-parser.js +4 -238
- package/package.json +27 -6
- package/scripts/setup-merge-queue.sh +170 -0
- package/scripts/validate-templates.js +100 -0
- package/src/agent/agent-config.js +140 -63
- package/src/agent/agent-context-builder.js +336 -165
- package/src/agent/agent-hook-executor.js +337 -67
- package/src/agent/agent-lifecycle.js +386 -287
- package/src/agent/agent-stuck-detector.js +7 -7
- package/src/agent/agent-task-executor.js +944 -683
- package/src/agent/output-extraction.js +217 -0
- package/src/agent/output-reformatter.js +175 -0
- package/src/agent/schema-utils.js +146 -0
- package/src/agent-wrapper.js +112 -31
- package/src/agents/git-pusher-template.js +285 -0
- package/src/claude-task-runner.js +145 -44
- package/src/config-router.js +13 -13
- package/src/config-validator.js +1049 -563
- package/src/input-helpers.js +65 -0
- package/src/isolation-manager.js +499 -320
- package/src/issue-providers/README.md +305 -0
- package/src/issue-providers/azure-devops-provider.js +273 -0
- package/src/issue-providers/base-provider.js +232 -0
- package/src/issue-providers/github-provider.js +179 -0
- package/src/issue-providers/gitlab-provider.js +241 -0
- package/src/issue-providers/index.js +196 -0
- package/src/issue-providers/jira-provider.js +239 -0
- package/src/ledger.js +50 -11
- package/src/lib/safe-exec.js +88 -0
- package/src/orchestrator.js +1348 -757
- package/src/preflight.js +306 -149
- package/src/process-metrics.js +98 -56
- package/src/providers/anthropic/cli-builder.js +73 -0
- package/src/providers/anthropic/index.js +204 -0
- package/src/providers/anthropic/models.js +23 -0
- package/src/providers/anthropic/output-parser.js +177 -0
- package/src/providers/base-provider.js +251 -0
- package/src/providers/capabilities.js +60 -0
- package/src/providers/google/cli-builder.js +55 -0
- package/src/providers/google/index.js +116 -0
- package/src/providers/google/models.js +24 -0
- package/src/providers/google/output-parser.js +101 -0
- package/src/providers/index.js +91 -0
- package/src/providers/openai/cli-builder.js +133 -0
- package/src/providers/openai/index.js +136 -0
- package/src/providers/openai/models.js +21 -0
- package/src/providers/openai/output-parser.js +143 -0
- package/src/providers/opencode/cli-builder.js +42 -0
- package/src/providers/opencode/index.js +103 -0
- package/src/providers/opencode/models.js +55 -0
- package/src/providers/opencode/output-parser.js +122 -0
- package/src/schemas/sub-cluster.js +68 -39
- package/src/status-footer.js +94 -48
- package/src/sub-cluster-wrapper.js +92 -36
- package/src/task-runner.js +8 -6
- package/src/template-resolver.js +12 -9
- package/src/tui/data-poller.js +123 -99
- package/src/tui/formatters.js +4 -3
- package/src/tui/keybindings.js +259 -318
- package/src/tui/layout.js +20 -3
- package/src/tui/renderer.js +11 -21
- package/task-lib/attachable-watcher.js +150 -111
- package/task-lib/claude-recovery.js +156 -0
- package/task-lib/commands/episodes.js +105 -0
- package/task-lib/commands/list.js +3 -3
- package/task-lib/commands/logs.js +231 -189
- package/task-lib/commands/resume.js +3 -2
- package/task-lib/commands/run.js +12 -3
- package/task-lib/commands/schedules.js +111 -61
- package/task-lib/config.js +0 -2
- package/task-lib/runner.js +128 -50
- package/task-lib/scheduler.js +3 -3
- package/task-lib/store.js +464 -152
- package/task-lib/tui/formatters.js +94 -45
- package/task-lib/tui/renderer.js +13 -3
- package/task-lib/tui.js +73 -32
- package/task-lib/watcher.js +157 -100
- package/src/agents/git-pusher-agent.json +0 -20
- package/src/github.js +0 -103
package/src/github.js
DELETED
|
@@ -1,103 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* GitHub - Fetch and parse GitHub issues
|
|
3
|
-
*
|
|
4
|
-
* Provides:
|
|
5
|
-
* - Issue fetching via gh CLI
|
|
6
|
-
* - Parsing of issue data into context
|
|
7
|
-
* - Fallback to plain text input
|
|
8
|
-
*/
|
|
9
|
-
|
|
10
|
-
const { execSync } = require('child_process');
|
|
11
|
-
|
|
12
|
-
class GitHub {
|
|
13
|
-
/**
|
|
14
|
-
* Fetch GitHub issue by URL or number
|
|
15
|
-
* @param {String} issueRef - Issue URL or number
|
|
16
|
-
* @returns {Object} Parsed issue data
|
|
17
|
-
*/
|
|
18
|
-
static fetchIssue(issueRef) {
|
|
19
|
-
try {
|
|
20
|
-
// Extract issue number from URL if needed
|
|
21
|
-
const issueNumber = this._extractIssueNumber(issueRef);
|
|
22
|
-
|
|
23
|
-
// Fetch issue using gh CLI
|
|
24
|
-
const cmd = `gh issue view ${issueNumber} --json number,title,body,labels,assignees,comments,url`;
|
|
25
|
-
const output = execSync(cmd, { encoding: 'utf8' });
|
|
26
|
-
const issue = JSON.parse(output);
|
|
27
|
-
|
|
28
|
-
return this._parseIssue(issue);
|
|
29
|
-
} catch (error) {
|
|
30
|
-
throw new Error(`Failed to fetch GitHub issue: ${error.message}`);
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
/**
|
|
35
|
-
* Extract issue number from URL or return as-is
|
|
36
|
-
* @private
|
|
37
|
-
*/
|
|
38
|
-
static _extractIssueNumber(issueRef) {
|
|
39
|
-
// If it's a URL, extract the number
|
|
40
|
-
const urlMatch = issueRef.match(/\/issues\/(\d+)/);
|
|
41
|
-
if (urlMatch) {
|
|
42
|
-
return urlMatch[1];
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
// Otherwise assume it's already a number
|
|
46
|
-
return issueRef;
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
/**
|
|
50
|
-
* Parse issue into structured context
|
|
51
|
-
* @private
|
|
52
|
-
*/
|
|
53
|
-
static _parseIssue(issue) {
|
|
54
|
-
let context = `# GitHub Issue #${issue.number}\n\n`;
|
|
55
|
-
context += `## Title\n${issue.title}\n\n`;
|
|
56
|
-
|
|
57
|
-
if (issue.body) {
|
|
58
|
-
context += `## Description\n${issue.body}\n\n`;
|
|
59
|
-
}
|
|
60
|
-
|
|
61
|
-
if (issue.labels && issue.labels.length > 0) {
|
|
62
|
-
context += `## Labels\n`;
|
|
63
|
-
context += issue.labels.map((l) => `- ${l.name}`).join('\n');
|
|
64
|
-
context += '\n\n';
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
if (issue.comments && issue.comments.length > 0) {
|
|
68
|
-
context += `## Comments\n\n`;
|
|
69
|
-
for (const comment of issue.comments) {
|
|
70
|
-
context += `### ${comment.author.login} (${new Date(comment.createdAt).toISOString()})\n`;
|
|
71
|
-
context += `${comment.body}\n\n`;
|
|
72
|
-
}
|
|
73
|
-
}
|
|
74
|
-
|
|
75
|
-
return {
|
|
76
|
-
number: issue.number,
|
|
77
|
-
title: issue.title,
|
|
78
|
-
body: issue.body,
|
|
79
|
-
labels: issue.labels || [],
|
|
80
|
-
comments: issue.comments || [],
|
|
81
|
-
url: issue.url || null,
|
|
82
|
-
context,
|
|
83
|
-
};
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
/**
|
|
87
|
-
* Create a plain text input wrapper
|
|
88
|
-
* @param {String} text - Plain text input
|
|
89
|
-
* @returns {Object} Structured context
|
|
90
|
-
*/
|
|
91
|
-
static createTextInput(text) {
|
|
92
|
-
return {
|
|
93
|
-
number: null,
|
|
94
|
-
title: 'Manual Input',
|
|
95
|
-
body: text,
|
|
96
|
-
labels: [],
|
|
97
|
-
comments: [],
|
|
98
|
-
context: `# Manual Input\n\n${text}\n`,
|
|
99
|
-
};
|
|
100
|
-
}
|
|
101
|
-
}
|
|
102
|
-
|
|
103
|
-
module.exports = GitHub;
|