-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathindex.d.ts
More file actions
42 lines (36 loc) · 1.12 KB
/
index.d.ts
File metadata and controls
42 lines (36 loc) · 1.12 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
/**
* Compound Engineering - AI-powered compound engineering
* Automatic learning and improvement for AI agents
*/
export interface CompoundConfig {
memoryPath: string;
learningRate: number;
maxMemory: number;
}
export interface MemoryItem {
id: string;
content: string;
type: 'observation' | 'reflection' | 'decision';
timestamp: number;
relevance: number;
}
export interface LearningModel {
patterns: Array<{
trigger: string;
action: string;
success: number;
failures: number;
}>;
}
export declare function createCompoundEngine(config: CompoundConfig): Promise<CompoundEngine>;
export declare function loadMemory(path: string): Promise<MemoryItem[]>;
export declare function saveMemory(path: string, memory: MemoryItem[]): Promise<void>;
export declare function analyzePattern(memory: MemoryItem[]): Promise<LearningModel>;
export interface CompoundEngine {
addObservation(observation: string): Promise<void>;
reflect(): Promise<string>;
decide(input: string): Promise<string>;
getMemory(): Promise<MemoryItem[]>;
getPatterns(): Promise<LearningModel>;
}
export { CompoundEngine as default };