opencode-swarm 6.71.1 → 6.72.1
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/agents/architect.d.ts +11 -0
- package/dist/cli/index.js +238 -227
- package/dist/config/schema.d.ts +6 -0
- package/dist/hooks/knowledge-store.d.ts +10 -1
- package/dist/hooks/knowledge-types.d.ts +9 -1
- package/dist/index.js +671 -373
- package/dist/state.d.ts +27 -1
- package/dist/tools/convene-council.d.ts +1 -1
- package/package.json +1 -1
package/dist/config/schema.d.ts
CHANGED
|
@@ -437,6 +437,9 @@ export declare const KnowledgeConfigSchema: z.ZodObject<{
|
|
|
437
437
|
initial_encounter_score: z.ZodDefault<z.ZodNumber>;
|
|
438
438
|
encounter_increment: z.ZodDefault<z.ZodNumber>;
|
|
439
439
|
max_encounter_score: z.ZodDefault<z.ZodNumber>;
|
|
440
|
+
default_max_phases: z.ZodDefault<z.ZodNumber>;
|
|
441
|
+
todo_max_phases: z.ZodDefault<z.ZodNumber>;
|
|
442
|
+
sweep_enabled: z.ZodDefault<z.ZodBoolean>;
|
|
440
443
|
}, z.core.$strip>;
|
|
441
444
|
export type KnowledgeConfig = z.infer<typeof KnowledgeConfigSchema>;
|
|
442
445
|
export declare const CuratorConfigSchema: z.ZodObject<{
|
|
@@ -826,6 +829,9 @@ export declare const PluginConfigSchema: z.ZodObject<{
|
|
|
826
829
|
initial_encounter_score: z.ZodDefault<z.ZodNumber>;
|
|
827
830
|
encounter_increment: z.ZodDefault<z.ZodNumber>;
|
|
828
831
|
max_encounter_score: z.ZodDefault<z.ZodNumber>;
|
|
832
|
+
default_max_phases: z.ZodDefault<z.ZodNumber>;
|
|
833
|
+
todo_max_phases: z.ZodDefault<z.ZodNumber>;
|
|
834
|
+
sweep_enabled: z.ZodDefault<z.ZodBoolean>;
|
|
829
835
|
}, z.core.$strip>>;
|
|
830
836
|
curator: z.ZodOptional<z.ZodObject<{
|
|
831
837
|
enabled: z.ZodDefault<z.ZodBoolean>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/** Core storage layer for the opencode-swarm v6.17 two-tier knowledge system. */
|
|
2
|
-
import type { RejectedLesson } from './knowledge-types.js';
|
|
2
|
+
import type { KnowledgeEntryBase, RejectedLesson } from './knowledge-types.js';
|
|
3
3
|
export declare function getPlatformConfigDir(): string;
|
|
4
4
|
export declare function resolveSwarmKnowledgePath(directory: string): string;
|
|
5
5
|
export declare function resolveSwarmRejectedPath(directory: string): string;
|
|
@@ -10,6 +10,15 @@ export declare function readRejectedLessons(directory: string): Promise<Rejected
|
|
|
10
10
|
export declare function appendKnowledge<T>(filePath: string, entry: T): Promise<void>;
|
|
11
11
|
export declare function rewriteKnowledge<T>(filePath: string, entries: T[]): Promise<void>;
|
|
12
12
|
export declare function enforceKnowledgeCap<T>(filePath: string, maxEntries: number): Promise<void>;
|
|
13
|
+
export interface SweepResult {
|
|
14
|
+
scanned: number;
|
|
15
|
+
aged: number;
|
|
16
|
+
archived: number;
|
|
17
|
+
removed: number;
|
|
18
|
+
skipped_promoted: number;
|
|
19
|
+
}
|
|
20
|
+
export declare function sweepAgedEntries<T extends KnowledgeEntryBase>(filePath: string, defaultMaxPhases: number): Promise<SweepResult>;
|
|
21
|
+
export declare function sweepStaleTodos<T extends KnowledgeEntryBase>(filePath: string, todoMaxPhases: number): Promise<SweepResult>;
|
|
13
22
|
export declare function appendRejectedLesson(directory: string, lesson: RejectedLesson): Promise<void>;
|
|
14
23
|
export declare function normalize(text: string): string;
|
|
15
24
|
export declare function wordBigrams(text: string): Set<string>;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
/** Type definitions for the opencode-swarm v6.17 two-tier knowledge system. */
|
|
2
|
-
export type KnowledgeCategory = 'process' | 'architecture' | 'tooling' | 'security' | 'testing' | 'debugging' | 'performance' | 'integration' | 'other';
|
|
2
|
+
export type KnowledgeCategory = 'process' | 'architecture' | 'tooling' | 'security' | 'testing' | 'debugging' | 'performance' | 'integration' | 'todo' | 'other';
|
|
3
3
|
export interface PhaseConfirmationRecord {
|
|
4
4
|
phase_number: number;
|
|
5
5
|
confirmed_at: string;
|
|
@@ -32,6 +32,8 @@ export interface KnowledgeEntryBase {
|
|
|
32
32
|
updated_at: string;
|
|
33
33
|
hive_eligible?: boolean;
|
|
34
34
|
auto_generated?: boolean;
|
|
35
|
+
phases_alive?: number;
|
|
36
|
+
max_phases?: number;
|
|
35
37
|
}
|
|
36
38
|
export interface SwarmKnowledgeEntry extends KnowledgeEntryBase {
|
|
37
39
|
tier: 'swarm';
|
|
@@ -103,6 +105,12 @@ export interface KnowledgeConfig {
|
|
|
103
105
|
encounter_increment: number;
|
|
104
106
|
/** Weighted scoring: maximum encounter score cap. Default: 10.0 */
|
|
105
107
|
max_encounter_score: number;
|
|
108
|
+
/** Default N-phase TTL for knowledge entries. Default: 10 */
|
|
109
|
+
default_max_phases: number;
|
|
110
|
+
/** N-phase TTL for 'todo' category entries. Default: 3 */
|
|
111
|
+
todo_max_phases: number;
|
|
112
|
+
/** Enable age-based sweep of knowledge entries. Default: true */
|
|
113
|
+
sweep_enabled: boolean;
|
|
106
114
|
}
|
|
107
115
|
export interface MessageInfo {
|
|
108
116
|
role: string;
|