anbaric-tsapi 1.40.0 → 1.41.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.
|
@@ -4,17 +4,16 @@ type Prompt = {
|
|
|
4
4
|
promptId: string;
|
|
5
5
|
version: number;
|
|
6
6
|
instructions: string;
|
|
7
|
-
inputSchema?: JsonSchema;
|
|
8
7
|
outputSchema?: JsonSchema;
|
|
9
8
|
createdAt: string;
|
|
10
9
|
};
|
|
11
10
|
interface PromptManager {
|
|
12
|
-
save(promptId: string, instructions: string,
|
|
11
|
+
save(promptId: string, instructions: string, outputSchema?: JsonSchema): Promise<Prompt>;
|
|
13
12
|
retrieve(promptId: string, version?: number): Promise<Prompt>;
|
|
14
13
|
list(): Promise<Array<Prompt>>;
|
|
15
14
|
history(promptId: string): Promise<Array<Prompt>>;
|
|
16
15
|
}
|
|
17
|
-
declare const samePromptContent: (existing: Pick<Prompt, "instructions" | "
|
|
16
|
+
declare const samePromptContent: (existing: Pick<Prompt, "instructions" | "outputSchema">, instructions: string, outputSchema?: JsonSchema) => boolean;
|
|
18
17
|
export { samePromptContent };
|
|
19
18
|
export type { Prompt, PromptManager };
|
|
20
19
|
//# sourceMappingURL=PromptManager.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PromptManager.d.ts","sourceRoot":"","sources":["../../../src/api/prompts/PromptManager.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,UAAU,EAAC,MAAM,4BAA4B,CAAC;AAItD,KAAK,MAAM,GAAG;IAEV,KAAK,EAAG,MAAM,CAAC;IACf,QAAQ,EAAG,MAAM,CAAC;IAClB,OAAO,EAAG,MAAM,CAAC;IACjB,YAAY,EAAG,MAAM,CAAC;IACtB,
|
|
1
|
+
{"version":3,"file":"PromptManager.d.ts","sourceRoot":"","sources":["../../../src/api/prompts/PromptManager.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,UAAU,EAAC,MAAM,4BAA4B,CAAC;AAItD,KAAK,MAAM,GAAG;IAEV,KAAK,EAAG,MAAM,CAAC;IACf,QAAQ,EAAG,MAAM,CAAC;IAClB,OAAO,EAAG,MAAM,CAAC;IACjB,YAAY,EAAG,MAAM,CAAC;IACtB,YAAY,CAAC,EAAG,UAAU,CAAC;IAC3B,SAAS,EAAG,MAAM,CAAC;CAEtB,CAAC;AAMF,UAAU,aAAa;IAEnB,IAAI,CAAC,QAAQ,EAAG,MAAM,EAAE,YAAY,EAAG,MAAM,EAAE,YAAY,CAAC,EAAG,UAAU,GAAI,OAAO,CAAC,MAAM,CAAC,CAAC;IAE7F,QAAQ,CAAC,QAAQ,EAAG,MAAM,EAAE,OAAO,CAAC,EAAG,MAAM,GAAI,OAAO,CAAC,MAAM,CAAC,CAAC;IAEjE,IAAI,IAAK,OAAO,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC;IAEhC,OAAO,CAAC,QAAQ,EAAG,MAAM,GAAI,OAAO,CAAC,KAAK,CAAC,MAAM,CAAC,CAAC,CAAC;CAEvD;AAYD,QAAA,MAAM,iBAAiB,aAAe,IAAI,CAAC,MAAM,EAAE,cAAc,GAAG,cAAc,CAAC,gBACzC,MAAM,iBAAkB,UAAU,KAAI,OAEN,CAAC;AAE3E,OAAO,EAAE,iBAAiB,EAAE,CAAC;AAC7B,YAAY,EAAE,MAAM,EAAE,aAAa,EAAE,CAAC"}
|
|
@@ -8,8 +8,7 @@ const stable = (value) => {
|
|
|
8
8
|
};
|
|
9
9
|
/* Whether a prompt's content would be unchanged by a save - the check that
|
|
10
10
|
keeps a start-up registration from minting a new version every run. */
|
|
11
|
-
const samePromptContent = (existing, instructions,
|
|
12
|
-
stable(existing.inputSchema ?? null) === stable(inputSchema ?? null) &&
|
|
11
|
+
const samePromptContent = (existing, instructions, outputSchema) => existing.instructions === instructions &&
|
|
13
12
|
stable(existing.outputSchema ?? null) === stable(outputSchema ?? null);
|
|
14
13
|
export { samePromptContent };
|
|
15
14
|
//# sourceMappingURL=PromptManager.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"PromptManager.js","sourceRoot":"","sources":["../../../src/api/prompts/PromptManager.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"PromptManager.js","sourceRoot":"","sources":["../../../src/api/prompts/PromptManager.ts"],"names":[],"mappings":"AA+BA,MAAM,MAAM,GAAG,CAAC,KAAW,EAAW,EAAE;IACpC,IAAI,KAAK,CAAC,OAAO,CAAC,KAAK,CAAC;QAAE,OAAO,IAAI,KAAK,CAAC,GAAG,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,GAAG,CAAC;IACpE,IAAI,KAAK,IAAI,OAAO,KAAK,KAAK,QAAQ,EAAE,CAAC;QACrC,OAAO,IAAI,MAAM,CAAC,IAAI,CAAC,KAAK,CAAC,CAAC,IAAI,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,IAAI,CAAC,SAAS,CAAC,GAAG,CAAC,IAAI,MAAM,CAAC,KAAK,CAAC,GAAG,CAAC,CAAC,EAAE,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,GAAG,CAAC;IACjH,CAAC;IACD,OAAO,IAAI,CAAC,SAAS,CAAC,KAAK,CAAC,CAAC;AACjC,CAAC,CAAC;AAEF;yEACyE;AACzE,MAAM,iBAAiB,GAAG,CAAC,QAAwD,EACxD,YAAqB,EAAE,YAA0B,EAAY,EAAE,CACtF,QAAQ,CAAC,YAAY,KAAK,YAAY;IACtC,MAAM,CAAC,QAAQ,CAAC,YAAY,IAAI,IAAI,CAAC,KAAK,MAAM,CAAC,YAAY,IAAI,IAAI,CAAC,CAAC;AAE3E,OAAO,EAAE,iBAAiB,EAAE,CAAC"}
|
package/package.json
CHANGED