@recombine-ai/bosun-lib 0.1.0 → 0.2.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/package.json +34 -28
- package/build/index.test.d.ts +0 -2
- package/build/index.test.d.ts.map +0 -1
- package/build/interfaces/context.d.ts +0 -23
- package/build/interfaces/context.d.ts.map +0 -1
- package/build/interfaces/mock.d.ts +0 -6
- package/build/interfaces/mock.d.ts.map +0 -1
- package/build/interfaces/other.d.ts +0 -19
- package/build/interfaces/other.d.ts.map +0 -1
- package/build/interfaces/step-registry.d.ts +0 -16
- package/build/interfaces/step-registry.d.ts.map +0 -1
- package/build/stubs.d.ts +0 -4
- package/build/stubs.d.ts.map +0 -1
package/package.json
CHANGED
|
@@ -1,30 +1,36 @@
|
|
|
1
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
|
-
"@types/node": "^25.2.3"
|
|
2
|
+
"name": "@recombine-ai/bosun-lib",
|
|
3
|
+
"version": "0.2.0",
|
|
4
|
+
"description": "Bosun conversational agents IDE bindings to agents build on Recombine platform",
|
|
5
|
+
"license": "EULA",
|
|
6
|
+
"author": "recombine.ai",
|
|
7
|
+
"repository": {
|
|
8
|
+
"type": "git",
|
|
9
|
+
"url": "https://github.com/recombine-ai/platform.git",
|
|
10
|
+
"directory": "packages/bosun-lib"
|
|
11
|
+
},
|
|
12
|
+
"files": [
|
|
13
|
+
"build"
|
|
14
|
+
],
|
|
15
|
+
"type": "module",
|
|
16
|
+
"types": "./build/index.d.ts",
|
|
17
|
+
"dependencies": {
|
|
18
|
+
"@recombine-ai/engine": "1.0.0",
|
|
19
|
+
"@recombine-ai/platform": "0.2.0",
|
|
20
|
+
"@recombine-ai/telescope": "0.2.0",
|
|
21
|
+
"zod": "^4.4.3"
|
|
22
|
+
},
|
|
23
|
+
"exports": {
|
|
24
|
+
".": {
|
|
25
|
+
"types": "./build/index.d.ts",
|
|
26
|
+
"import": "./build/index.js",
|
|
27
|
+
"default": "./build/index.js"
|
|
29
28
|
}
|
|
30
|
-
}
|
|
29
|
+
},
|
|
30
|
+
"publishConfig": {
|
|
31
|
+
"registry": "https://registry.npmjs.org"
|
|
32
|
+
},
|
|
33
|
+
"devDependencies": {
|
|
34
|
+
"@types/node": "^25.2.3"
|
|
35
|
+
}
|
|
36
|
+
}
|
package/build/index.test.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.test.d.ts","sourceRoot":"","sources":["../src/index.test.ts"],"names":[],"mappings":""}
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
type Ctx = Record<string, any>;
|
|
2
|
-
type Paths<T> = T extends object ? {
|
|
3
|
-
[K in keyof T]: [K] | [K, ...Paths<T[K]>];
|
|
4
|
-
}[keyof T] : never;
|
|
5
|
-
type PathValue<T, P extends any[]> = P extends [infer First, ...infer Rest] ? First extends keyof T ? Rest['length'] extends 0 ? T[First] : PathValue<T[First], Rest> : never : never;
|
|
6
|
-
declare class Context<T extends Ctx> {
|
|
7
|
-
#private;
|
|
8
|
-
constructor(context: T);
|
|
9
|
-
set<P extends Paths<T>>(path: P extends any[] ? P : never, value: PathValue<T, P>): void;
|
|
10
|
-
set(newContext: T): void;
|
|
11
|
-
get(): T;
|
|
12
|
-
swap(newContext: T): void;
|
|
13
|
-
subscribe: (listener: (context: T) => void) => () => boolean;
|
|
14
|
-
setPromptContextMapper(promptMapper: (ctx: T) => object): void;
|
|
15
|
-
getPromptContextMapper(): (ctx: T) => object;
|
|
16
|
-
}
|
|
17
|
-
export declare function createContext<T extends Ctx>(context: T): Context<T>;
|
|
18
|
-
type Public<T> = {
|
|
19
|
-
[P in keyof T]: T[P];
|
|
20
|
-
};
|
|
21
|
-
type PublicContext<T extends Ctx> = Public<Context<T>>;
|
|
22
|
-
export type { PublicContext as Context };
|
|
23
|
-
//# sourceMappingURL=context.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"context.d.ts","sourceRoot":"","sources":["../../src/interfaces/context.ts"],"names":[],"mappings":"AAAA,KAAK,GAAG,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,CAAA;AAC9B,KAAK,KAAK,CAAC,CAAC,IAAI,CAAC,SAAS,MAAM,GAC1B;KACK,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,EAAE,GAAG,KAAK,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;CAC5C,CAAC,MAAM,CAAC,CAAC,GACV,KAAK,CAAA;AAEX,KAAK,SAAS,CAAC,CAAC,EAAE,CAAC,SAAS,GAAG,EAAE,IAAI,CAAC,SAAS,CAAC,MAAM,KAAK,EAAE,GAAG,MAAM,IAAI,CAAC,GACrE,KAAK,SAAS,MAAM,CAAC,GACjB,IAAI,CAAC,QAAQ,CAAC,SAAS,CAAC,GACpB,CAAC,CAAC,KAAK,CAAC,GACR,SAAS,CAAC,CAAC,CAAC,KAAK,CAAC,EAAE,IAAI,CAAC,GAC7B,KAAK,GACT,KAAK,CAAA;AAEX,cAAM,OAAO,CAAC,CAAC,SAAS,GAAG;;gBAIX,OAAO,EAAE,CAAC;IAItB,GAAG,CAAC,CAAC,SAAS,KAAK,CAAC,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,SAAS,GAAG,EAAE,GAAG,CAAC,GAAG,KAAK,EAAE,KAAK,EAAE,SAAS,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG,IAAI;IACxF,GAAG,CAAC,UAAU,EAAE,CAAC,GAAG,IAAI;IAgBxB,GAAG;IAKH,IAAI,CAAC,UAAU,EAAE,CAAC;IAIlB,SAAS,GAAI,UAAU,CAAC,OAAO,EAAE,CAAC,KAAK,IAAI,mBAG1C;IAED,sBAAsB,CAAC,YAAY,EAAE,CAAC,GAAG,EAAE,CAAC,KAAK,MAAM;IAIvD,sBAAsB,UAxCD,CAAC,KAAK,MAAM;CA2CpC;AAED,wBAAgB,aAAa,CAAC,CAAC,SAAS,GAAG,EAAE,OAAO,EAAE,CAAC,cAEtD;AAED,KAAK,MAAM,CAAC,CAAC,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAAE,CAAA;AAEzC,KAAK,aAAa,CAAC,CAAC,SAAS,GAAG,IAAI,MAAM,CAAC,OAAO,CAAC,CAAC,CAAC,CAAC,CAAA;AAEtD,YAAY,EAAE,aAAa,IAAI,OAAO,EAAE,CAAA"}
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import { Logger } from './dockyard';
|
|
2
|
-
type ConstructorType<T> = new (...args: any[]) => T;
|
|
3
|
-
type InstanceType<T extends ConstructorType<any>> = T extends new (...args: any[]) => infer R ? R : never;
|
|
4
|
-
export declare function createMock<T extends ConstructorType<any>>(logger: Logger, constructor: T, overrides?: Partial<InstanceType<T>>): InstanceType<T>;
|
|
5
|
-
export {};
|
|
6
|
-
//# sourceMappingURL=mock.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"mock.d.ts","sourceRoot":"","sources":["../../src/interfaces/mock.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,MAAM,EAAE,MAAM,YAAY,CAAA;AAEnC,KAAK,eAAe,CAAC,CAAC,IAAI,KAAK,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,CAAC,CAAA;AACnD,KAAK,YAAY,CAAC,CAAC,SAAS,eAAe,CAAC,GAAG,CAAC,IAAI,CAAC,SAAS,KAAK,GAAG,IAAI,EAAE,GAAG,EAAE,KAAK,MAAM,CAAC,GACvF,CAAC,GACD,KAAK,CAAA;AAEX,wBAAgB,UAAU,CAAC,CAAC,SAAS,eAAe,CAAC,GAAG,CAAC,EACrD,MAAM,EAAE,MAAM,EACd,WAAW,EAAE,CAAC,EACd,SAAS,CAAC,EAAE,OAAO,CAAC,YAAY,CAAC,CAAC,CAAC,CAAC,GACrC,YAAY,CAAC,CAAC,CAAC,CAuBjB"}
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
export type ScheduleAction = (delay: Date, phone: string) => Promise<void>;
|
|
2
|
-
export interface Scheduler {
|
|
3
|
-
registerAction: (actionName: string, action: (phone: string) => Promise<unknown>) => ScheduleAction;
|
|
4
|
-
clearAllPendingActions: (phone: string) => Promise<unknown>;
|
|
5
|
-
}
|
|
6
|
-
export interface PromptFile {
|
|
7
|
-
type: 'file';
|
|
8
|
-
content: () => Promise<string>;
|
|
9
|
-
path: string;
|
|
10
|
-
}
|
|
11
|
-
export interface PromptFS {
|
|
12
|
-
loadFile(path: string): PromptFile;
|
|
13
|
-
}
|
|
14
|
-
export interface Message {
|
|
15
|
-
sender: 'user' | 'agent' | 'system';
|
|
16
|
-
text: string;
|
|
17
|
-
imageUrl?: string;
|
|
18
|
-
}
|
|
19
|
-
//# sourceMappingURL=other.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"other.d.ts","sourceRoot":"","sources":["../../src/interfaces/other.ts"],"names":[],"mappings":"AAQA,MAAM,MAAM,cAAc,GAAG,CAAC,KAAK,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,KAAK,OAAO,CAAC,IAAI,CAAC,CAAA;AAE1E,MAAM,WAAW,SAAS;IAOtB,cAAc,EAAE,CACZ,UAAU,EAAE,MAAM,EAClB,MAAM,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,OAAO,CAAC,OAAO,CAAC,KAC1C,cAAc,CAAA;IAKnB,sBAAsB,EAAE,CAAC,KAAK,EAAE,MAAM,KAAK,OAAO,CAAC,OAAO,CAAC,CAAA;CAC9D;AAED,MAAM,WAAW,UAAU;IACvB,IAAI,EAAE,MAAM,CAAA;IACZ,OAAO,EAAE,MAAM,OAAO,CAAC,MAAM,CAAC,CAAA;IAC9B,IAAI,EAAE,MAAM,CAAA;CACf;AAED,MAAM,WAAW,QAAQ;IACrB,QAAQ,CAAC,IAAI,EAAE,MAAM,GAAG,UAAU,CAAA;CACrC;AASD,MAAM,WAAW,OAAO;IAEpB,MAAM,EAAE,MAAM,GAAG,OAAO,GAAG,QAAQ,CAAA;IAEnC,IAAI,EAAE,MAAM,CAAA;IAEZ,QAAQ,CAAC,EAAE,MAAM,CAAA;CACpB"}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import { type ZodType } from 'zod';
|
|
2
|
-
import { PromptFile } from './other';
|
|
3
|
-
export interface PromptString {
|
|
4
|
-
type: 'string';
|
|
5
|
-
content: () => Promise<string>;
|
|
6
|
-
}
|
|
7
|
-
export interface StepDef {
|
|
8
|
-
name: string;
|
|
9
|
-
type: 'streaming-response' | 'streaming-detect' | 'text';
|
|
10
|
-
prompt: PromptFile | PromptString;
|
|
11
|
-
schema?: ZodType;
|
|
12
|
-
}
|
|
13
|
-
export interface StepRegistry {
|
|
14
|
-
addStep(def: StepDef): void;
|
|
15
|
-
}
|
|
16
|
-
//# sourceMappingURL=step-registry.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"step-registry.d.ts","sourceRoot":"","sources":["../../src/interfaces/step-registry.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,KAAK,OAAO,EAAE,MAAM,KAAK,CAAA;AAGlC,OAAO,EAAE,UAAU,EAAE,MAAM,SAAS,CAAA;AAEpC,MAAM,WAAW,YAAY;IACzB,IAAI,EAAE,QAAQ,CAAA;IACd,OAAO,EAAE,MAAM,OAAO,CAAC,MAAM,CAAC,CAAA;CACjC;AAED,MAAM,WAAW,OAAO;IACpB,IAAI,EAAE,MAAM,CAAA;IACZ,IAAI,EAAE,oBAAoB,GAAG,kBAAkB,GAAG,MAAM,CAAA;IACxD,MAAM,EAAE,UAAU,GAAG,YAAY,CAAA;IACjC,MAAM,CAAC,EAAE,OAAO,CAAA;CACnB;AAED,MAAM,WAAW,YAAY;IACzB,OAAO,CAAC,GAAG,EAAE,OAAO,GAAG,IAAI,CAAA;CAC9B"}
|
package/build/stubs.d.ts
DELETED
package/build/stubs.d.ts.map
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"stubs.d.ts","sourceRoot":"","sources":["../src/stubs.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,EAAE,MAAM,uBAAuB,CAAA;AAC9C,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAA;AAKzD,wBAAgB,kBAAkB,CAAC,MAAM,EAAE,MAAM,GAAG,YAAY,CAM/D"}
|