opencode-swarm 6.31.4 → 6.32.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/dist/cli/index.js +12 -3
- package/dist/config/schema.d.ts +12 -0
- package/dist/hooks/guardrails.d.ts +4 -3
- package/dist/index.js +270 -186
- package/dist/utils/tool-output.d.ts +3 -1
- package/package.json +1 -1
package/dist/cli/index.js
CHANGED
|
@@ -17856,7 +17856,10 @@ var PhaseCompleteConfigSchema = exports_external.object({
|
|
|
17856
17856
|
enabled: exports_external.boolean().default(true),
|
|
17857
17857
|
required_agents: exports_external.array(exports_external.enum(["coder", "reviewer", "test_engineer"])).default(["coder", "reviewer", "test_engineer"]),
|
|
17858
17858
|
require_docs: exports_external.boolean().default(true),
|
|
17859
|
-
policy: exports_external.enum(["enforce", "warn"]).default("enforce")
|
|
17859
|
+
policy: exports_external.enum(["enforce", "warn"]).default("enforce"),
|
|
17860
|
+
regression_sweep: exports_external.object({
|
|
17861
|
+
enforce: exports_external.boolean().default(false)
|
|
17862
|
+
}).optional()
|
|
17860
17863
|
});
|
|
17861
17864
|
var SummaryConfigSchema = exports_external.object({
|
|
17862
17865
|
enabled: exports_external.boolean().default(true),
|
|
@@ -18202,9 +18205,15 @@ var PluginConfigSchema = exports_external.object({
|
|
|
18202
18205
|
tool_output: exports_external.object({
|
|
18203
18206
|
truncation_enabled: exports_external.boolean().default(true),
|
|
18204
18207
|
max_lines: exports_external.number().min(10).max(500).default(150),
|
|
18205
|
-
per_tool: exports_external.record(exports_external.string(), exports_external.number()).optional()
|
|
18208
|
+
per_tool: exports_external.record(exports_external.string(), exports_external.number()).optional(),
|
|
18209
|
+
truncation_tools: exports_external.array(exports_external.string()).optional().describe("Tools to apply output truncation to. Defaults to diff, symbols, bash, shell, test_runner, lint, pre_check_batch, complexity_hotspots, pkg_audit, sbom_generate, schema_drift.")
|
|
18206
18210
|
}).optional(),
|
|
18207
18211
|
slop_detector: SlopDetectorConfigSchema.optional(),
|
|
18212
|
+
todo_gate: exports_external.object({
|
|
18213
|
+
enabled: exports_external.boolean().default(true),
|
|
18214
|
+
max_high_priority: exports_external.number().int().min(-1).default(0).describe("Max new high-priority TODOs (FIXME/HACK/XXX) before warning. 0 = warn on any. Set to -1 to disable."),
|
|
18215
|
+
block_on_threshold: exports_external.boolean().default(false).describe("If true, block phase completion when threshold exceeded. Default: advisory only.")
|
|
18216
|
+
}).optional(),
|
|
18208
18217
|
incremental_verify: IncrementalVerifyConfigSchema.optional(),
|
|
18209
18218
|
compaction_service: CompactionConfigSchema.optional()
|
|
18210
18219
|
});
|
|
@@ -36016,7 +36025,7 @@ function detectAdditionalLinter(cwd) {
|
|
|
36016
36025
|
}
|
|
36017
36026
|
async function detectAvailableLinter(directory) {
|
|
36018
36027
|
const _DETECT_TIMEOUT = 2000;
|
|
36019
|
-
const projectDir = directory
|
|
36028
|
+
const projectDir = directory;
|
|
36020
36029
|
const isWindows = process.platform === "win32";
|
|
36021
36030
|
const biomeBin = isWindows ? path17.join(projectDir, "node_modules", ".bin", "biome.EXE") : path17.join(projectDir, "node_modules", ".bin", "biome");
|
|
36022
36031
|
const eslintBin = isWindows ? path17.join(projectDir, "node_modules", ".bin", "eslint.cmd") : path17.join(projectDir, "node_modules", ".bin", "eslint");
|
package/dist/config/schema.d.ts
CHANGED
|
@@ -209,6 +209,9 @@ export declare const PhaseCompleteConfigSchema: z.ZodObject<{
|
|
|
209
209
|
enforce: "enforce";
|
|
210
210
|
warn: "warn";
|
|
211
211
|
}>>;
|
|
212
|
+
regression_sweep: z.ZodOptional<z.ZodObject<{
|
|
213
|
+
enforce: z.ZodDefault<z.ZodBoolean>;
|
|
214
|
+
}, z.core.$strip>>;
|
|
212
215
|
}, z.core.$strip>;
|
|
213
216
|
export type PhaseCompleteConfig = z.infer<typeof PhaseCompleteConfigSchema>;
|
|
214
217
|
export declare const SummaryConfigSchema: z.ZodObject<{
|
|
@@ -489,6 +492,9 @@ export declare const PluginConfigSchema: z.ZodObject<{
|
|
|
489
492
|
enforce: "enforce";
|
|
490
493
|
warn: "warn";
|
|
491
494
|
}>>;
|
|
495
|
+
regression_sweep: z.ZodOptional<z.ZodObject<{
|
|
496
|
+
enforce: z.ZodDefault<z.ZodBoolean>;
|
|
497
|
+
}, z.core.$strip>>;
|
|
492
498
|
}, z.core.$strip>>;
|
|
493
499
|
qa_retry_limit: z.ZodDefault<z.ZodNumber>;
|
|
494
500
|
inject_phase_reminders: z.ZodDefault<z.ZodBoolean>;
|
|
@@ -737,6 +743,7 @@ export declare const PluginConfigSchema: z.ZodObject<{
|
|
|
737
743
|
truncation_enabled: z.ZodDefault<z.ZodBoolean>;
|
|
738
744
|
max_lines: z.ZodDefault<z.ZodNumber>;
|
|
739
745
|
per_tool: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodNumber>>;
|
|
746
|
+
truncation_tools: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
740
747
|
}, z.core.$strip>>;
|
|
741
748
|
slop_detector: z.ZodOptional<z.ZodObject<{
|
|
742
749
|
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
@@ -745,6 +752,11 @@ export declare const PluginConfigSchema: z.ZodObject<{
|
|
|
745
752
|
diffLineThreshold: z.ZodDefault<z.ZodNumber>;
|
|
746
753
|
importHygieneThreshold: z.ZodDefault<z.ZodNumber>;
|
|
747
754
|
}, z.core.$strip>>;
|
|
755
|
+
todo_gate: z.ZodOptional<z.ZodObject<{
|
|
756
|
+
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
757
|
+
max_high_priority: z.ZodDefault<z.ZodNumber>;
|
|
758
|
+
block_on_threshold: z.ZodDefault<z.ZodBoolean>;
|
|
759
|
+
}, z.core.$strip>>;
|
|
748
760
|
incremental_verify: z.ZodOptional<z.ZodObject<{
|
|
749
761
|
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
750
762
|
command: z.ZodDefault<z.ZodNullable<z.ZodUnion<readonly [z.ZodString, z.ZodArray<z.ZodString>]>>>;
|
|
@@ -28,11 +28,12 @@ export declare function setStoredInputArgs(callID: string, args: unknown): void;
|
|
|
28
28
|
export declare function deleteStoredInputArgs(callID: string): void;
|
|
29
29
|
/**
|
|
30
30
|
* Creates guardrails hooks for circuit breaker protection
|
|
31
|
-
* @param
|
|
32
|
-
* @param
|
|
31
|
+
* @param directory Working directory from plugin init context (required)
|
|
32
|
+
* @param directoryOrConfig Guardrails configuration object (when passed as second arg, replaces legacy config param)
|
|
33
|
+
* @param config Guardrails configuration (optional)
|
|
33
34
|
* @returns Tool before/after hooks and messages transform hook
|
|
34
35
|
*/
|
|
35
|
-
export declare function createGuardrailsHooks(directoryOrConfig?: string | GuardrailsConfig, config?: GuardrailsConfig): {
|
|
36
|
+
export declare function createGuardrailsHooks(directory: string, directoryOrConfig?: string | GuardrailsConfig, config?: GuardrailsConfig): {
|
|
36
37
|
toolBefore: (input: {
|
|
37
38
|
tool: string;
|
|
38
39
|
sessionID: string;
|