@dxos/assistant 0.8.4-main.84f28bd → 0.8.4-main.9735255
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/lib/browser/chunk-7CDDG6LL.mjs +578 -0
- package/dist/lib/browser/chunk-7CDDG6LL.mjs.map +7 -0
- package/dist/lib/browser/chunk-J5LGTIGS.mjs +10 -0
- package/dist/lib/browser/chunk-J5LGTIGS.mjs.map +7 -0
- package/dist/lib/browser/extraction/index.mjs +225 -0
- package/dist/lib/browser/extraction/index.mjs.map +7 -0
- package/dist/lib/browser/index.mjs +723 -1892
- package/dist/lib/browser/index.mjs.map +4 -4
- package/dist/lib/browser/meta.json +1 -1
- package/dist/lib/browser/testing/index.mjs +32 -0
- package/dist/lib/browser/testing/index.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-CC7ER6Q3.mjs +579 -0
- package/dist/lib/node-esm/chunk-CC7ER6Q3.mjs.map +7 -0
- package/dist/lib/node-esm/chunk-HSLMI22Q.mjs +11 -0
- package/dist/lib/node-esm/chunk-HSLMI22Q.mjs.map +7 -0
- package/dist/lib/node-esm/extraction/index.mjs +226 -0
- package/dist/lib/node-esm/extraction/index.mjs.map +7 -0
- package/dist/lib/node-esm/index.mjs +723 -1893
- package/dist/lib/node-esm/index.mjs.map +4 -4
- package/dist/lib/node-esm/meta.json +1 -1
- package/dist/lib/node-esm/testing/index.mjs +33 -0
- package/dist/lib/node-esm/testing/index.mjs.map +7 -0
- package/dist/types/src/conversation/context.d.ts +129 -0
- package/dist/types/src/conversation/context.d.ts.map +1 -0
- package/dist/types/src/conversation/context.test.d.ts +2 -0
- package/dist/types/src/conversation/context.test.d.ts.map +1 -0
- package/dist/types/src/conversation/conversation.d.ts +29 -32
- package/dist/types/src/conversation/conversation.d.ts.map +1 -1
- package/dist/types/src/conversation/conversation.test.d.ts +2 -0
- package/dist/types/src/conversation/conversation.test.d.ts.map +1 -0
- package/dist/types/src/conversation/index.d.ts +1 -0
- package/dist/types/src/conversation/index.d.ts.map +1 -1
- package/dist/types/src/diff.d.ts +15 -0
- package/dist/types/src/diff.d.ts.map +1 -0
- package/dist/types/src/diff.test.d.ts +2 -0
- package/dist/types/src/diff.test.d.ts.map +1 -0
- package/dist/types/src/errors.d.ts +67 -0
- package/dist/types/src/errors.d.ts.map +1 -0
- package/dist/types/src/execution-graph.d.ts +85 -0
- package/dist/types/src/execution-graph.d.ts.map +1 -0
- package/dist/types/src/execution-graph.test.d.ts +2 -0
- package/dist/types/src/execution-graph.test.d.ts.map +1 -0
- package/dist/types/src/extraction/extraction-llm-function/extraction-llm-function.d.ts +1 -1
- package/dist/types/src/extraction/extraction-llm-function/extraction-llm-function.d.ts.map +1 -1
- package/dist/types/src/extraction/extraction-ner-function/extraction-ner-function.d.ts +279 -140
- package/dist/types/src/extraction/extraction-ner-function/extraction-ner-function.d.ts.map +1 -1
- package/dist/types/src/extraction/extraction-ner-function/named-entity-recognition.d.ts +1 -1
- package/dist/types/src/extraction/extraction-ner-function/named-entity-recognition.d.ts.map +1 -1
- package/dist/types/src/extraction/extraction.d.ts +345 -212
- package/dist/types/src/extraction/extraction.d.ts.map +1 -1
- package/dist/types/src/extraction/quotes.d.ts +3 -3
- package/dist/types/src/extraction/quotes.d.ts.map +1 -1
- package/dist/types/src/functions/index.d.ts +2 -0
- package/dist/types/src/functions/index.d.ts.map +1 -0
- package/dist/types/src/functions/services.d.ts +20 -0
- package/dist/types/src/functions/services.d.ts.map +1 -0
- package/dist/types/src/functions.test.d.ts +2 -0
- package/dist/types/src/functions.test.d.ts.map +1 -0
- package/dist/types/src/index.d.ts +5 -5
- package/dist/types/src/index.d.ts.map +1 -1
- package/dist/types/src/session/GenericToolkit.d.ts +85 -0
- package/dist/types/src/session/GenericToolkit.d.ts.map +1 -0
- package/dist/types/src/session/artifact-diff.d.ts +27 -0
- package/dist/types/src/session/artifact-diff.d.ts.map +1 -0
- package/dist/types/src/session/error-handling.d.ts +4 -0
- package/dist/types/src/session/error-handling.d.ts.map +1 -0
- package/dist/types/src/session/format.d.ts +12 -0
- package/dist/types/src/session/format.d.ts.map +1 -0
- package/dist/types/src/session/format.test.d.ts +2 -0
- package/dist/types/src/session/format.test.d.ts.map +1 -0
- package/dist/types/src/session/index.d.ts +4 -0
- package/dist/types/src/session/index.d.ts.map +1 -1
- package/dist/types/src/session/observer.d.ts +23 -0
- package/dist/types/src/session/observer.d.ts.map +1 -0
- package/dist/types/src/session/session.d.ts +41 -268
- package/dist/types/src/session/session.d.ts.map +1 -1
- package/dist/types/src/session/toolkit.d.ts +14 -0
- package/dist/types/src/session/toolkit.d.ts.map +1 -0
- package/dist/types/src/session/version-pin.d.ts +5 -5
- package/dist/types/src/session/version-pin.d.ts.map +1 -1
- package/dist/types/src/templates/index.d.ts +2 -0
- package/dist/types/src/templates/index.d.ts.map +1 -0
- package/dist/types/src/templates/system.d.ts +18 -0
- package/dist/types/src/templates/system.d.ts.map +1 -0
- package/dist/types/src/testing/index.d.ts +1 -2
- package/dist/types/src/testing/index.d.ts.map +1 -1
- package/dist/types/src/testing/layer.d.ts +21 -0
- package/dist/types/src/testing/layer.d.ts.map +1 -0
- package/dist/types/src/types/artifact.d.ts +28 -0
- package/dist/types/src/types/artifact.d.ts.map +1 -0
- package/dist/types/src/types/index.d.ts +2 -0
- package/dist/types/src/types/index.d.ts.map +1 -0
- package/dist/types/tsconfig.tsbuildinfo +1 -1
- package/package.json +58 -27
- package/src/conversation/context.test.ts +46 -0
- package/src/conversation/context.ts +303 -0
- package/src/conversation/conversation.test.ts +65 -0
- package/src/conversation/conversation.ts +98 -76
- package/src/conversation/index.ts +1 -0
- package/src/diff.test.ts +43 -0
- package/src/diff.ts +84 -0
- package/src/errors.ts +15 -0
- package/src/execution-graph.test.ts +740 -0
- package/src/execution-graph.ts +509 -0
- package/src/extraction/extraction-llm-function/extraction-llm-function.test.ts +14 -25
- package/src/extraction/extraction-llm-function/extraction-llm-function.ts +48 -52
- package/src/extraction/extraction-ner-function/extraction-ner-function.test.ts +22 -21
- package/src/extraction/extraction-ner-function/extraction-ner-function.ts +43 -41
- package/src/extraction/extraction-ner-function/named-entity-recognition.test.ts +12 -6
- package/src/extraction/extraction-ner-function/named-entity-recognition.ts +3 -1
- package/src/extraction/extraction.ts +10 -9
- package/src/extraction/quotes.test.ts +3 -3
- package/src/extraction/quotes.ts +6 -7
- package/src/functions/index.ts +5 -0
- package/src/functions/services.ts +180 -0
- package/src/functions.conversations.json +1 -0
- package/src/functions.test.ts +74 -0
- package/src/index.ts +5 -5
- package/src/session/GenericToolkit.ts +131 -0
- package/src/session/artifact-diff.ts +41 -0
- package/src/session/error-handling.ts +41 -0
- package/src/session/format.test.ts +124 -0
- package/src/session/format.ts +143 -0
- package/src/session/index.ts +5 -0
- package/src/session/observer.ts +61 -0
- package/src/session/session.conversations.json +1 -0
- package/src/session/session.test.ts +83 -215
- package/src/session/session.ts +181 -529
- package/src/session/toolkit.ts +39 -0
- package/src/session/version-pin.ts +12 -12
- package/src/templates/index.ts +5 -0
- package/src/templates/instructions/format.tpl +61 -0
- package/src/templates/instructions/system.tpl +48 -0
- package/src/templates/system.ts +41 -0
- package/src/testing/index.ts +2 -8
- package/src/testing/layer.ts +78 -0
- package/src/types/artifact.ts +82 -0
- package/src/types/index.ts +5 -0
- package/src/typings.d.ts +5 -0
- package/dist/types/bin/chat.d.ts +0 -2
- package/dist/types/bin/chat.d.ts.map +0 -1
- package/dist/types/src/blueprint/blueprint.d.ts +0 -41
- package/dist/types/src/blueprint/blueprint.d.ts.map +0 -1
- package/dist/types/src/blueprint/index.d.ts +0 -3
- package/dist/types/src/blueprint/index.d.ts.map +0 -1
- package/dist/types/src/blueprint/registry.d.ts +0 -7
- package/dist/types/src/blueprint/registry.d.ts.map +0 -1
- package/dist/types/src/context/binder.d.ts +0 -34
- package/dist/types/src/context/binder.d.ts.map +0 -1
- package/dist/types/src/context/binding.d.ts +0 -38
- package/dist/types/src/context/binding.d.ts.map +0 -1
- package/dist/types/src/context/index.d.ts +0 -3
- package/dist/types/src/context/index.d.ts.map +0 -1
- package/dist/types/src/research/exa.d.ts +0 -7
- package/dist/types/src/research/exa.d.ts.map +0 -1
- package/dist/types/src/research/graph.d.ts +0 -41
- package/dist/types/src/research/graph.d.ts.map +0 -1
- package/dist/types/src/research/graph.test.d.ts +0 -2
- package/dist/types/src/research/graph.test.d.ts.map +0 -1
- package/dist/types/src/research/index.d.ts +0 -4
- package/dist/types/src/research/index.d.ts.map +0 -1
- package/dist/types/src/research/research.d.ts +0 -10
- package/dist/types/src/research/research.d.ts.map +0 -1
- package/dist/types/src/research/research.test.d.ts +0 -2
- package/dist/types/src/research/research.test.d.ts.map +0 -1
- package/dist/types/src/session/version-pin.test.d.ts +0 -2
- package/dist/types/src/session/version-pin.test.d.ts.map +0 -1
- package/dist/types/src/summarization/summarization.test.d.ts +0 -2
- package/dist/types/src/summarization/summarization.test.d.ts.map +0 -1
- package/dist/types/src/testing/exa-search-1748337321991.d.ts +0 -38
- package/dist/types/src/testing/exa-search-1748337321991.d.ts.map +0 -1
- package/dist/types/src/testing/exa-search-1748337331526.d.ts +0 -37
- package/dist/types/src/testing/exa-search-1748337331526.d.ts.map +0 -1
- package/dist/types/src/testing/exa-search-1748337344119.d.ts +0 -58
- package/dist/types/src/testing/exa-search-1748337344119.d.ts.map +0 -1
- package/dist/types/src/types.d.ts +0 -3
- package/dist/types/src/types.d.ts.map +0 -1
- package/src/blueprint/blueprint.ts +0 -75
- package/src/blueprint/index.ts +0 -6
- package/src/blueprint/registry.ts +0 -15
- package/src/context/binder.ts +0 -101
- package/src/context/binding.ts +0 -31
- package/src/context/index.ts +0 -6
- package/src/research/exa.ts +0 -100
- package/src/research/graph.test.ts +0 -15
- package/src/research/graph.ts +0 -337
- package/src/research/index.ts +0 -7
- package/src/research/instructions-research.tpl +0 -97
- package/src/research/research.test.ts +0 -190
- package/src/research/research.ts +0 -90
- package/src/session/version-pin.test.ts +0 -26
- package/src/summarization/summarization.test.ts +0 -221
- package/src/testing/exa-search-1748337321991.ts +0 -131
- package/src/testing/exa-search-1748337331526.ts +0 -144
- package/src/testing/exa-search-1748337344119.ts +0 -133
- package/src/typedefs.d.ts +0 -8
- package/src/types.ts +0 -8
- /package/src/extraction/extraction-llm-function/{instructions.tpl → transcription-instructions.tpl} +0 -0
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2025 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import type * as Tool from '@effect/ai/Tool';
|
|
6
|
+
import * as Toolkit from '@effect/ai/Toolkit';
|
|
7
|
+
import * as Effect from 'effect/Effect';
|
|
8
|
+
|
|
9
|
+
import { type AiToolNotFoundError, ToolExecutionService, ToolResolverService } from '@dxos/ai';
|
|
10
|
+
import { type Blueprint } from '@dxos/blueprints';
|
|
11
|
+
import { isTruthy } from '@dxos/util';
|
|
12
|
+
|
|
13
|
+
export type CreateToolkitProps = {
|
|
14
|
+
toolkit?: Toolkit.Any;
|
|
15
|
+
blueprints?: readonly Blueprint.Blueprint[];
|
|
16
|
+
};
|
|
17
|
+
|
|
18
|
+
/**
|
|
19
|
+
* Build a combined toolkit from the blueprint tools and the provided toolkit.
|
|
20
|
+
*/
|
|
21
|
+
export const createToolkit = ({
|
|
22
|
+
toolkit: toolkitProp,
|
|
23
|
+
blueprints = [],
|
|
24
|
+
}: CreateToolkitProps): Effect.Effect<
|
|
25
|
+
Toolkit.WithHandler<any>,
|
|
26
|
+
AiToolNotFoundError,
|
|
27
|
+
ToolResolverService | ToolExecutionService | Tool.HandlersFor<any>
|
|
28
|
+
> =>
|
|
29
|
+
Effect.gen(function* () {
|
|
30
|
+
const blueprintToolkit = yield* ToolResolverService.resolveToolkit(blueprints.flatMap(({ tools }) => tools));
|
|
31
|
+
const blueprintToolHandler = yield* blueprintToolkit.toContext(ToolExecutionService.handlersFor(blueprintToolkit));
|
|
32
|
+
|
|
33
|
+
const toolkit = Toolkit.merge(...[toolkitProp, blueprintToolkit].filter(isTruthy));
|
|
34
|
+
return yield* toolkit.pipe(Effect.provide(blueprintToolHandler)) as any as Effect.Effect<
|
|
35
|
+
Toolkit.WithHandler<any>,
|
|
36
|
+
never,
|
|
37
|
+
Tool.HandlersFor<any>
|
|
38
|
+
>;
|
|
39
|
+
});
|
|
@@ -2,12 +2,12 @@
|
|
|
2
2
|
// Copyright 2025 DXOS.org
|
|
3
3
|
//
|
|
4
4
|
|
|
5
|
-
import
|
|
5
|
+
import * as Schema from 'effect/Schema';
|
|
6
6
|
|
|
7
|
-
import { type
|
|
8
|
-
import { type ObjectVersion } from '@dxos/echo-db';
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
7
|
+
import { type Obj } from '@dxos/echo';
|
|
8
|
+
import { type ObjectVersion, getVersion } from '@dxos/echo-db';
|
|
9
|
+
import { ObjectId } from '@dxos/keys';
|
|
10
|
+
import { type ContentBlock } from '@dxos/types';
|
|
11
11
|
|
|
12
12
|
// TODO(dmaretskyi): Extract.
|
|
13
13
|
const ObjectVersionSchema = Schema.Unknown as Schema.Schema<ObjectVersion>;
|
|
@@ -15,7 +15,7 @@ const ObjectVersionSchema = Schema.Unknown as Schema.Schema<ObjectVersion>;
|
|
|
15
15
|
const VersionPinSchema = Schema.Struct({
|
|
16
16
|
// TODO(dmaretskyi): Use Ref when those support encoding.
|
|
17
17
|
objectId: ObjectId,
|
|
18
|
-
// TODO(dmaretskyi): Could be opaque
|
|
18
|
+
// TODO(dmaretskyi): Could be opaque.
|
|
19
19
|
version: ObjectVersionSchema,
|
|
20
20
|
});
|
|
21
21
|
|
|
@@ -27,22 +27,22 @@ export interface VersionPin extends Schema.Schema.Type<typeof VersionPinSchema>
|
|
|
27
27
|
|
|
28
28
|
export const VersionPin: typeof VersionPinSchema & {
|
|
29
29
|
DISPOSITION: 'version-pin';
|
|
30
|
-
fromObject: (object:
|
|
31
|
-
createBlock: (pin: VersionPin) =>
|
|
30
|
+
fromObject: (object: Obj.Unknown) => VersionPin;
|
|
31
|
+
createBlock: (pin: VersionPin) => ContentBlock.Any;
|
|
32
32
|
} = class extends VersionPinSchema {
|
|
33
33
|
static readonly DISPOSITION = 'version-pin';
|
|
34
|
-
static fromObject(object:
|
|
34
|
+
static fromObject(object: Obj.Unknown): VersionPin {
|
|
35
35
|
return VersionPin.make({
|
|
36
36
|
objectId: object.id,
|
|
37
37
|
version: getVersion(object),
|
|
38
38
|
});
|
|
39
39
|
}
|
|
40
40
|
|
|
41
|
-
static createBlock(pin: VersionPin):
|
|
41
|
+
static createBlock(pin: VersionPin): ContentBlock.Any {
|
|
42
42
|
return {
|
|
43
|
-
|
|
43
|
+
_tag: 'json',
|
|
44
44
|
disposition: VersionPin.DISPOSITION,
|
|
45
|
-
|
|
45
|
+
data: JSON.stringify(pin),
|
|
46
46
|
};
|
|
47
47
|
}
|
|
48
48
|
};
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
{{! System Core }}
|
|
2
|
+
|
|
3
|
+
## Input Formats
|
|
4
|
+
|
|
5
|
+
### Blueprints
|
|
6
|
+
|
|
7
|
+
You may be provided with Blueprint definitions that include specific instructions and tools for a given set of tasks.
|
|
8
|
+
Blue print instructions will be enclosed in a <blueprint> tag.
|
|
9
|
+
|
|
10
|
+
### Context objects
|
|
11
|
+
|
|
12
|
+
You may be provided with references to objects that are relevant to the current prompt.
|
|
13
|
+
Objects will be in the form of a <object> tag with a <dxn> element that is the unique key of the object required by many tools.
|
|
14
|
+
The <typename> element is the type of the object.
|
|
15
|
+
|
|
16
|
+
<object>
|
|
17
|
+
<dxn>object-id</dxn>
|
|
18
|
+
<typename>example.com/type/TypeName</typename>
|
|
19
|
+
</object>
|
|
20
|
+
|
|
21
|
+
## Response Formats
|
|
22
|
+
|
|
23
|
+
It is very important to respond in the correct format.
|
|
24
|
+
You response must be valid Markdown.
|
|
25
|
+
In some cases you should respond with well-formed XML tags along with the content.
|
|
26
|
+
Code snippets should use 2-space indents.
|
|
27
|
+
|
|
28
|
+
{{#if cot}}
|
|
29
|
+
Before responding, explain your reasoning and include your detailed chain-of-thought enclosed in a <cot> tag.
|
|
30
|
+
The <cot> tag should be the first thing in your response.
|
|
31
|
+
{{/if}}
|
|
32
|
+
|
|
33
|
+
## Block references
|
|
34
|
+
|
|
35
|
+
You can reply with a block reference for objects if you have the DXN. For example:
|
|
36
|
+
|
|
37
|
+
<object>
|
|
38
|
+
<dxn>dxn:queue:data:B6INSIBY3CBEF4M5VZRYBCMAHQMPYK5AJ:01K24XMVHSZHS97SG1VTVQDM5Z:01K24XPK464FSCKVQJAB2H662M</dxn>
|
|
39
|
+
</object>
|
|
40
|
+
<object>
|
|
41
|
+
<dxn>dxn:echo:@:01K24XPK464FSCKVQJAB2H662M</dxn>
|
|
42
|
+
</object>
|
|
43
|
+
|
|
44
|
+
### Suggestions
|
|
45
|
+
|
|
46
|
+
Each suggestion must in the form of a proposed action enclosed in a <suggestion> tag.
|
|
47
|
+
Example: <suggestion>Show on a map</suggestion>
|
|
48
|
+
Do not use bullets when listing suggestions.
|
|
49
|
+
|
|
50
|
+
### Multiple choice questions
|
|
51
|
+
|
|
52
|
+
You may ask multiple choice questions by wrapping consise options inside <option> tags inside a well formed <select> tag.
|
|
53
|
+
Example: <select><option>Yes</option><option>No</option></select>
|
|
54
|
+
|
|
55
|
+
## Toolkit
|
|
56
|
+
|
|
57
|
+
If the user asks for a list of tools, then just emit a single self-closing <toolkit/> tag instead of listing the tools.
|
|
58
|
+
|
|
59
|
+
## Context
|
|
60
|
+
|
|
61
|
+
The current date and time is {{DATETIME}}.
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
{{! System Prompt }}
|
|
2
|
+
|
|
3
|
+
- You are a helpful assistant called Kai.
|
|
4
|
+
- Your name is Kai and you are powered by different language models.
|
|
5
|
+
- You were created by DXOS and operate inside of Composer and on the DXOS EDGE network.
|
|
6
|
+
- In your initial greeting state your name and make some suggestions based on the current context objects.
|
|
7
|
+
- You are an advanced AI assistant capable of creating and managing artifacts from provided data and tools.
|
|
8
|
+
- Your task is to process user commands and questions and decide how best to respond.
|
|
9
|
+
- In general be concise and direct.
|
|
10
|
+
- Follow all instructions carefully.
|
|
11
|
+
|
|
12
|
+
## Planning
|
|
13
|
+
|
|
14
|
+
- Analyze the structure and type of the content in the user's message.
|
|
15
|
+
- Determine if you complete the task using the available blueprint definitions?
|
|
16
|
+
- If you can't complete the task using the available blueprint definitions, query the list of available blueprint definitions using the appropriate tool.
|
|
17
|
+
- Identify which blueprint definitions are relevant to the user's request.
|
|
18
|
+
- Evaluate the potential benefits of creating an artifact vs. normal processing for each identified element.
|
|
19
|
+
- Make a final decision on whether to create an artifact and explain your reasoning.
|
|
20
|
+
- Are the required blueprint definitions already available?
|
|
21
|
+
- If not, select which blueprint definition(s) will be the most relevant and require them using the require_artifact_definitions tool.
|
|
22
|
+
- The require'd artifact tools will be available for use after require.
|
|
23
|
+
- If creating an artifact, outline how you will structure it within the response.
|
|
24
|
+
- Decide if the artifact needs to be shown to the user.
|
|
25
|
+
- Call the show tool to show the artifact to the user.
|
|
26
|
+
- Your reasoning must include: whether to use artifacts or not, to create one or query, whether to show the artifact to the user, and how to structure the response.
|
|
27
|
+
|
|
28
|
+
## Blueprints and Artifacts
|
|
29
|
+
|
|
30
|
+
- Determine if the interaction involves an artifact. Prefer artifacts for tables, lists, spreadsheets, kanbans, games, images, and other structured data.
|
|
31
|
+
- Determine if the user is explicitly talking about creating a new artifact, or wants to use an existing artifact.
|
|
32
|
+
- If it is ambiguous, query for existing artifacts first and then decide.
|
|
33
|
+
- If you decide to create an artifact, call the associated tool to create the artifact.
|
|
34
|
+
- Artifacts are stored in the database. Tools are used to create and query artifacts.
|
|
35
|
+
- If you are unsure about creating an artifact ask the user for clarification.
|
|
36
|
+
- Artifacts are mutable objects that can change over the course of the conversation.
|
|
37
|
+
- Always re-query the artifact using the tool (like query or inspect) to get the latest state of the artifact before answering the user.
|
|
38
|
+
- You must never generate the id of the artifact; only recall the ids that are already in the history.
|
|
39
|
+
- Artifacts are created by requiring the specific artifact using the require_artifact tool and creating it by calling the associated tool.
|
|
40
|
+
- You can add suggested actions at the end of your response.
|
|
41
|
+
- Suggested actions should be very concise and start with a verb and be phrased as a command to an agent -- not a question to the user.
|
|
42
|
+
- Suggested actions must be in the form of a user instruction that you can follow.
|
|
43
|
+
- Suggested actions could include actions that create artifacts.
|
|
44
|
+
- After creating an artifact use a tool to add it to the chat context.
|
|
45
|
+
|
|
46
|
+
## Context
|
|
47
|
+
|
|
48
|
+
Today is {{DATETIME}}.
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2025 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import defaultsDeep from 'lodash.defaultsdeep';
|
|
6
|
+
|
|
7
|
+
import { type ModelCapabilities } from '@dxos/ai';
|
|
8
|
+
import { Template } from '@dxos/blueprints';
|
|
9
|
+
|
|
10
|
+
import FORMAT from './instructions/format.tpl?raw';
|
|
11
|
+
import SYSTEM from './instructions/system.tpl?raw';
|
|
12
|
+
|
|
13
|
+
/**
|
|
14
|
+
* System template variables.
|
|
15
|
+
*/
|
|
16
|
+
export type SystemPromptOptions = ModelCapabilities & {
|
|
17
|
+
DATETIME: string;
|
|
18
|
+
};
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* Base system prompt.
|
|
22
|
+
* NOTE: This contains protocol instructions that can not be dynamically edited.
|
|
23
|
+
*/
|
|
24
|
+
export const createSystemPrompt = (options: Partial<SystemPromptOptions> = {}) =>
|
|
25
|
+
Template.process<SystemPromptOptions>(
|
|
26
|
+
FORMAT,
|
|
27
|
+
defaultsDeep(options, {
|
|
28
|
+
DATETIME: new Date().toISOString(),
|
|
29
|
+
}),
|
|
30
|
+
);
|
|
31
|
+
|
|
32
|
+
export const templates = {
|
|
33
|
+
/** Editable system prompt.*/
|
|
34
|
+
system: Template.make({
|
|
35
|
+
/**
|
|
36
|
+
* NOTE: We are forbidden from accessing randomness at model level in cloudflare, so we have to have pre-generated ids.
|
|
37
|
+
*/
|
|
38
|
+
id: '01K2J2FZWH39F55CS7B26GP1Q3',
|
|
39
|
+
source: SYSTEM,
|
|
40
|
+
}),
|
|
41
|
+
};
|
package/src/testing/index.ts
CHANGED
|
@@ -1,11 +1,5 @@
|
|
|
1
1
|
//
|
|
2
|
-
// Copyright
|
|
2
|
+
// Copyright 2026 DXOS.org
|
|
3
3
|
//
|
|
4
4
|
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
import Search1 from './exa-search-1748337321991';
|
|
8
|
-
import Search2 from './exa-search-1748337331526';
|
|
9
|
-
import Search3 from './exa-search-1748337344119';
|
|
10
|
-
|
|
11
|
-
export const SEARCH_RESULTS: SearchResponse<any>[] = [Search1, Search2, Search3];
|
|
5
|
+
export * from './layer';
|
|
@@ -0,0 +1,78 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2026 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import * as Layer from 'effect/Layer';
|
|
6
|
+
import * as Match from 'effect/Match';
|
|
7
|
+
|
|
8
|
+
import { AiService, type ModelName } from '@dxos/ai';
|
|
9
|
+
import { TestAiService } from '@dxos/ai/testing';
|
|
10
|
+
import type { Type } from '@dxos/echo';
|
|
11
|
+
import { CredentialsService, type FunctionDefinition, type ServiceCredential, TracingService } from '@dxos/functions';
|
|
12
|
+
import { TracingServiceExt, TriggerDispatcher, TriggerStateStore } from '@dxos/functions-runtime';
|
|
13
|
+
import { FunctionInvocationServiceLayerTest, TestDatabaseLayer } from '@dxos/functions-runtime/testing';
|
|
14
|
+
|
|
15
|
+
import { makeToolExecutionServiceFromFunctions, makeToolResolverFromFunctions } from '../functions';
|
|
16
|
+
import { GenericToolkit } from '../session';
|
|
17
|
+
|
|
18
|
+
interface TestLayerOptions {
|
|
19
|
+
aiServicePreset?: 'direct' | 'edge-local' | 'edge-remote';
|
|
20
|
+
model?: ModelName;
|
|
21
|
+
functions?: FunctionDefinition.Any[];
|
|
22
|
+
toolkits?: GenericToolkit.GenericToolkit[];
|
|
23
|
+
types?: Type.Entity.Any[];
|
|
24
|
+
credentials?: ServiceCredential[];
|
|
25
|
+
/*
|
|
26
|
+
* Tracing configuration.
|
|
27
|
+
* @default 'noop'
|
|
28
|
+
*/
|
|
29
|
+
tracing?: 'noop' | 'console' | 'pretty';
|
|
30
|
+
}
|
|
31
|
+
|
|
32
|
+
export const AssistantTestLayer = ({
|
|
33
|
+
aiServicePreset = 'direct',
|
|
34
|
+
model = '@anthropic/claude-opus-4-0',
|
|
35
|
+
functions = [],
|
|
36
|
+
toolkits = [],
|
|
37
|
+
types = [],
|
|
38
|
+
credentials = [],
|
|
39
|
+
tracing = 'noop',
|
|
40
|
+
}: TestLayerOptions) =>
|
|
41
|
+
Layer.mergeAll(
|
|
42
|
+
AiService.model(model),
|
|
43
|
+
makeToolResolverFromFunctions(functions, GenericToolkit.merge(...toolkits).toolkit as any),
|
|
44
|
+
makeToolExecutionServiceFromFunctions(
|
|
45
|
+
GenericToolkit.merge(...toolkits).toolkit as any,
|
|
46
|
+
GenericToolkit.merge(...toolkits).layer as any,
|
|
47
|
+
),
|
|
48
|
+
).pipe(
|
|
49
|
+
Layer.provideMerge(
|
|
50
|
+
FunctionInvocationServiceLayerTest({
|
|
51
|
+
functions,
|
|
52
|
+
}),
|
|
53
|
+
),
|
|
54
|
+
Layer.provideMerge(
|
|
55
|
+
Layer.mergeAll(
|
|
56
|
+
TestAiService({ preset: aiServicePreset }),
|
|
57
|
+
TestDatabaseLayer({
|
|
58
|
+
spaceKey: 'fixed',
|
|
59
|
+
types,
|
|
60
|
+
}),
|
|
61
|
+
CredentialsService.configuredLayer(credentials),
|
|
62
|
+
Match.value(tracing).pipe(
|
|
63
|
+
Match.when('noop', () => TracingService.layerNoop),
|
|
64
|
+
Match.when('console', () => TracingServiceExt.layerLogInfo()),
|
|
65
|
+
Match.when('pretty', () => TracingServiceExt.layerConsolePrettyPrint()),
|
|
66
|
+
Match.exhaustive,
|
|
67
|
+
),
|
|
68
|
+
),
|
|
69
|
+
),
|
|
70
|
+
);
|
|
71
|
+
|
|
72
|
+
interface TestLayerWithTriggersOptions extends TestLayerOptions {}
|
|
73
|
+
|
|
74
|
+
export const AssistantTestLayerWithTriggers = (options: TestLayerWithTriggersOptions) =>
|
|
75
|
+
Layer.mergeAll(
|
|
76
|
+
AssistantTestLayer(options),
|
|
77
|
+
TriggerDispatcher.layer({ timeControl: 'manual', startingTime: new Date('2025-09-05T15:01:00.000Z') }),
|
|
78
|
+
).pipe(Layer.provideMerge(TriggerStateStore.layerMemory));
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
//
|
|
2
|
+
// Copyright 2025 DXOS.org
|
|
3
|
+
//
|
|
4
|
+
|
|
5
|
+
import type * as Effect from 'effect/Effect';
|
|
6
|
+
import * as Schema from 'effect/Schema';
|
|
7
|
+
|
|
8
|
+
import { type Err, Type } from '@dxos/echo';
|
|
9
|
+
import { Database } from '@dxos/echo';
|
|
10
|
+
import { EncodedReference } from '@dxos/echo-protocol';
|
|
11
|
+
import { DXN, LOCAL_SPACE_TAG, type ObjectId, type SpaceId } from '@dxos/keys';
|
|
12
|
+
import { trim } from '@dxos/util';
|
|
13
|
+
|
|
14
|
+
/**
|
|
15
|
+
* @deprecated
|
|
16
|
+
*/
|
|
17
|
+
export const createArtifactElement = (id: ObjectId) => `<artifact id=${id} />`;
|
|
18
|
+
|
|
19
|
+
/**
|
|
20
|
+
* A model-friendly way to reference an object.
|
|
21
|
+
* Supports vairous formats that will be normalized to a DXN.
|
|
22
|
+
*
|
|
23
|
+
* @deprecated Use `RefFromLLM` instead.
|
|
24
|
+
*/
|
|
25
|
+
// TODO(burdon): Rename RefFromLLM? -- yes -dm
|
|
26
|
+
export const ArtifactId: Schema.Schema<string> & {
|
|
27
|
+
toDXN: (reference: ArtifactId, owningSpaceId?: SpaceId) => DXN;
|
|
28
|
+
resolve: <S extends Type.Entity.Any>(
|
|
29
|
+
schema: S,
|
|
30
|
+
ref: ArtifactId,
|
|
31
|
+
) => Effect.Effect<Schema.Schema.Type<S>, Err.ObjectNotFoundError, Database.Service>;
|
|
32
|
+
} = class extends Schema.String.annotations({
|
|
33
|
+
// TODO(dmaretskyi): This section gets overriden.
|
|
34
|
+
description: trim`
|
|
35
|
+
The ID of the referenced object. Formats accepted:
|
|
36
|
+
- DXN (dxn:echo:@:XXXXX). DXNs can be prepended with an @ symbol for compatibility with in-text references.
|
|
37
|
+
- space ID, object ID tuple (spaceID:objectID)
|
|
38
|
+
- Only object ID that is assumed to be in the current space (XXXXX)
|
|
39
|
+
`,
|
|
40
|
+
examples: ['dxn:echo:@:XXXXX', '@dxn:echo:@:XXXXX', 'spaceID:objectID', 'XXXXX'],
|
|
41
|
+
}) {
|
|
42
|
+
static toDXN(reference: ArtifactId, owningSpaceId?: SpaceId): DXN {
|
|
43
|
+
// Allow @dxn: prefix for compatibility with in-text references.
|
|
44
|
+
if (reference.startsWith('@dxn:')) {
|
|
45
|
+
return DXN.parse(reference.slice(1));
|
|
46
|
+
} else if (reference.startsWith('dxn:')) {
|
|
47
|
+
return DXN.parse(reference);
|
|
48
|
+
} else if (/^[A-Z0-9]+:[A-Z0-9]+$/.test(reference)) {
|
|
49
|
+
const [spaceId, objectId] = reference.split(':');
|
|
50
|
+
// This is a workaround because the current Filter API doesn't work with fully qualified Echo DXNs.
|
|
51
|
+
// We check if the space ID is the same as the owning space and then use LOCAL_SPACE_TAG for local references.
|
|
52
|
+
// TODO(dmaretskyi): Fix this in the Echo and Filter API to properly handle fully qualified DXNs.
|
|
53
|
+
return new DXN(DXN.kind.ECHO, [spaceId === owningSpaceId ? LOCAL_SPACE_TAG : spaceId, objectId]);
|
|
54
|
+
} else if (/^[A-Z0-9]+$/.test(reference)) {
|
|
55
|
+
return DXN.fromLocalObjectId(reference);
|
|
56
|
+
} else {
|
|
57
|
+
throw new Error(`Unable to parse object reference: ${reference}`);
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
|
|
61
|
+
/**
|
|
62
|
+
* Resolves an artifact ID to an object.
|
|
63
|
+
*/
|
|
64
|
+
static resolve<S extends Type.Entity.Any>(
|
|
65
|
+
schema: S,
|
|
66
|
+
ref: ArtifactId,
|
|
67
|
+
): Effect.Effect<Schema.Schema.Type<S>, Err.ObjectNotFoundError, Database.Service> {
|
|
68
|
+
const dxn = ArtifactId.toDXN(ref);
|
|
69
|
+
return Database.Service.resolve(dxn, schema);
|
|
70
|
+
}
|
|
71
|
+
};
|
|
72
|
+
|
|
73
|
+
export type ArtifactId = Schema.Schema.Type<typeof ArtifactId>;
|
|
74
|
+
|
|
75
|
+
/**
|
|
76
|
+
* Schema that decodes ECHO reference object from an LLM-friendly input.
|
|
77
|
+
*/
|
|
78
|
+
export const RefFromLLM = Schema.transform(ArtifactId, Type.Ref(Type.Obj), {
|
|
79
|
+
decode: (fromA, fromI) => EncodedReference.fromDXN(ArtifactId.toDXN(fromA)),
|
|
80
|
+
encode: (toI, toA) => EncodedReference.toDXN(toI).toString(),
|
|
81
|
+
strict: false,
|
|
82
|
+
});
|
package/src/typings.d.ts
CHANGED
package/dist/types/bin/chat.d.ts
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"chat.d.ts","sourceRoot":"","sources":["../../../bin/chat.ts"],"names":[],"mappings":""}
|
|
@@ -1,41 +0,0 @@
|
|
|
1
|
-
import { Schema } from 'effect';
|
|
2
|
-
import { Type } from '@dxos/echo';
|
|
3
|
-
/**
|
|
4
|
-
* Blueprint schema defines the structure for AI assistant blueprints.
|
|
5
|
-
* Blueprints contain instructions, tools, and artifacts that guide the AI's behavior.
|
|
6
|
-
*/
|
|
7
|
-
export declare const Blueprint: Type.obj<Schema.Struct<{
|
|
8
|
-
/**
|
|
9
|
-
* Global registry ID.
|
|
10
|
-
* NOTE: Once a blueprint has been cloned from the registry, its stored definition may converge,
|
|
11
|
-
* but the `key` property refers to the original registry entry.
|
|
12
|
-
*/
|
|
13
|
-
key: Schema.SchemaClass<string, string, never>;
|
|
14
|
-
/**
|
|
15
|
-
* Human-readable name of the blueprint.
|
|
16
|
-
*/
|
|
17
|
-
name: Schema.SchemaClass<string, string, never>;
|
|
18
|
-
/**
|
|
19
|
-
* Description of the blueprint's purpose and functionality.
|
|
20
|
-
*/
|
|
21
|
-
description: Schema.optional<typeof Schema.String>;
|
|
22
|
-
/**
|
|
23
|
-
* Instructions that guide the AI assistant's behavior and responses.
|
|
24
|
-
* These are system prompts or guidelines that the AI should follow.
|
|
25
|
-
*/
|
|
26
|
-
instructions: Schema.SchemaClass<string, string, never>;
|
|
27
|
-
/**
|
|
28
|
-
* Array of tools that the AI assistant can use when this blueprint is active.
|
|
29
|
-
*/
|
|
30
|
-
tools: Schema.Array$<Schema.SchemaClass<string, string, never>>;
|
|
31
|
-
/**
|
|
32
|
-
* Array of artifacts that the AI assistant can create or modify.
|
|
33
|
-
*/
|
|
34
|
-
artifacts: Schema.Array$<typeof Schema.String>;
|
|
35
|
-
}>>;
|
|
36
|
-
/**
|
|
37
|
-
* TypeScript type for Blueprint.
|
|
38
|
-
*/
|
|
39
|
-
export interface Blueprint extends Schema.Schema.Type<typeof Blueprint> {
|
|
40
|
-
}
|
|
41
|
-
//# sourceMappingURL=blueprint.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"blueprint.d.ts","sourceRoot":"","sources":["../../../../src/blueprint/blueprint.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAGhC,OAAO,EAAE,IAAI,EAAE,MAAM,YAAY,CAAC;AAGlC;;;GAGG;AACH,eAAO,MAAM,SAAS;IACpB;;;;OAIG;;IAMH;;OAEG;;IAKH;;OAEG;;IAKH;;;OAGG;;IAKH;;OAEG;;IAKH;;OAEG;;GAaJ,CAAC;AAEF;;GAEG;AACH,MAAM,WAAW,SAAU,SAAQ,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,SAAS,CAAC;CAAG"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/blueprint/index.ts"],"names":[],"mappings":"AAIA,cAAc,aAAa,CAAC;AAC5B,cAAc,YAAY,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"registry.d.ts","sourceRoot":"","sources":["../../../../src/blueprint/registry.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,aAAa,CAAC;AAE7C,qBAAa,iBAAiB;IAChB,OAAO,CAAC,QAAQ,CAAC,WAAW;gBAAX,WAAW,EAAE,SAAS,EAAE;IAIrD,KAAK,IAAI,SAAS,EAAE;CAGrB"}
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
import { type ReadonlySignal } from '@preact/signals-core';
|
|
2
|
-
import { type Type, type Ref } from '@dxos/echo';
|
|
3
|
-
import { type Queue } from '@dxos/echo-db';
|
|
4
|
-
import { ComplexSet } from '@dxos/util';
|
|
5
|
-
import { type Blueprint } from '../blueprint';
|
|
6
|
-
/**
|
|
7
|
-
* Manages bindings of blueprints and objects to a conversation.
|
|
8
|
-
*/
|
|
9
|
-
export declare class ContextBinder {
|
|
10
|
-
private readonly _queue;
|
|
11
|
-
constructor(_queue: Queue);
|
|
12
|
-
/**
|
|
13
|
-
* Reactive query of all bindings.
|
|
14
|
-
*/
|
|
15
|
-
readonly bindings: ReadonlySignal<Bindings>;
|
|
16
|
-
readonly blueprints: ReadonlySignal<Ref.Ref<Blueprint>[]>;
|
|
17
|
-
readonly objects: ReadonlySignal<Ref.Ref<Type.Expando>[]>;
|
|
18
|
-
/**
|
|
19
|
-
* Asynchronous query of all bindings.
|
|
20
|
-
*/
|
|
21
|
-
query(): Promise<Bindings>;
|
|
22
|
-
bind(props: BindingProps): Promise<void>;
|
|
23
|
-
unbind(props: BindingProps): Promise<void>;
|
|
24
|
-
private _reduce;
|
|
25
|
-
}
|
|
26
|
-
export type BindingProps = Partial<{
|
|
27
|
-
blueprints: Ref.Ref<Blueprint>[];
|
|
28
|
-
objects: Ref.Ref<Type.Expando>[];
|
|
29
|
-
}>;
|
|
30
|
-
export declare class Bindings {
|
|
31
|
-
blueprints: ComplexSet<Ref.Ref<Blueprint>>;
|
|
32
|
-
objects: ComplexSet<Ref.Ref<Type.Expando>>;
|
|
33
|
-
}
|
|
34
|
-
//# sourceMappingURL=binder.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"binder.d.ts","sourceRoot":"","sources":["../../../../src/context/binder.ts"],"names":[],"mappings":"AAIA,OAAO,EAAY,KAAK,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAGrE,OAAO,EAAO,KAAK,IAAI,EAAE,KAAK,GAAG,EAAiB,MAAM,YAAY,CAAC;AACrE,OAAO,EAAE,KAAK,KAAK,EAAE,MAAM,eAAe,CAAC;AAC3C,OAAO,EAAE,UAAU,EAAE,MAAM,YAAY,CAAC;AAGxC,OAAO,EAAE,KAAK,SAAS,EAAE,MAAM,cAAc,CAAC;AAE9C;;GAEG;AACH,qBAAa,aAAa;IACZ,OAAO,CAAC,QAAQ,CAAC,MAAM;gBAAN,MAAM,EAAE,KAAK;IAE1C;;OAEG;IAEH,QAAQ,CAAC,QAAQ,EAAE,cAAc,CAAC,QAAQ,CAAC,CAAqD;IAGhG,QAAQ,CAAC,UAAU,EAAE,cAAc,CAAC,GAAG,CAAC,GAAG,CAAC,SAAS,CAAC,EAAE,CAAC,CAAuD;IAChH,QAAQ,CAAC,OAAO,EAAE,cAAc,CAAC,GAAG,CAAC,GAAG,CAAC,IAAI,CAAC,OAAO,CAAC,EAAE,CAAC,CAAoD;IAE7G;;OAEG;IACG,KAAK,IAAI,OAAO,CAAC,QAAQ,CAAC;IAM1B,IAAI,CAAC,KAAK,EAAE,YAAY,GAAG,OAAO,CAAC,IAAI,CAAC;IAmBxC,MAAM,CAAC,KAAK,EAAE,YAAY,GAAG,OAAO,CAAC,IAAI,CAAC;IAmBhD,OAAO,CAAC,OAAO;CAahB;AAED,MAAM,MAAM,YAAY,GAAG,OAAO,CAAC;IACjC,UAAU,EAAE,GAAG,CAAC,GAAG,CAAC,SAAS,CAAC,EAAE,CAAC;IACjC,OAAO,EAAE,GAAG,CAAC,GAAG,CAAC,IAAI,CAAC,OAAO,CAAC,EAAE,CAAC;CAClC,CAAC,CAAC;AAEH,qBAAa,QAAQ;IACnB,UAAU,iCAAmE;IAC7E,OAAO,oCAAsE;CAC9E"}
|
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
import { Schema } from 'effect';
|
|
2
|
-
import { Type } from '@dxos/echo';
|
|
3
|
-
/**
|
|
4
|
-
* Thread message that binds or unbinds contextual objects to a conversation.
|
|
5
|
-
*/
|
|
6
|
-
export declare const ContextBinding: Type.obj<Schema.Struct<{
|
|
7
|
-
blueprints: Schema.Struct<{
|
|
8
|
-
added: Schema.Array$<Type.ref<Type.obj<Schema.Struct<{
|
|
9
|
-
key: Schema.SchemaClass<string, string, never>;
|
|
10
|
-
name: Schema.SchemaClass<string, string, never>;
|
|
11
|
-
description: Schema.optional<typeof Schema.String>;
|
|
12
|
-
instructions: Schema.SchemaClass<string, string, never>;
|
|
13
|
-
tools: Schema.Array$<Schema.SchemaClass<string, string, never>>;
|
|
14
|
-
artifacts: Schema.Array$<typeof Schema.String>;
|
|
15
|
-
}>>>>;
|
|
16
|
-
removed: Schema.Array$<Type.ref<Type.obj<Schema.Struct<{
|
|
17
|
-
key: Schema.SchemaClass<string, string, never>;
|
|
18
|
-
name: Schema.SchemaClass<string, string, never>;
|
|
19
|
-
description: Schema.optional<typeof Schema.String>;
|
|
20
|
-
instructions: Schema.SchemaClass<string, string, never>;
|
|
21
|
-
tools: Schema.Array$<Schema.SchemaClass<string, string, never>>;
|
|
22
|
-
artifacts: Schema.Array$<typeof Schema.String>;
|
|
23
|
-
}>>>>;
|
|
24
|
-
}>;
|
|
25
|
-
objects: Schema.Struct<{
|
|
26
|
-
added: Schema.Array$<Type.ref<Schema.Schema<Type.Expando, {
|
|
27
|
-
[x: string]: any;
|
|
28
|
-
id: string;
|
|
29
|
-
}, never>>>;
|
|
30
|
-
removed: Schema.Array$<Type.ref<Schema.Schema<Type.Expando, {
|
|
31
|
-
[x: string]: any;
|
|
32
|
-
id: string;
|
|
33
|
-
}, never>>>;
|
|
34
|
-
}>;
|
|
35
|
-
}>>;
|
|
36
|
-
export interface ContextBinding extends Schema.Schema.Type<typeof ContextBinding> {
|
|
37
|
-
}
|
|
38
|
-
//# sourceMappingURL=binding.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"binding.d.ts","sourceRoot":"","sources":["../../../../src/context/binding.ts"],"names":[],"mappings":"AAIA,OAAO,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAC;AAEhC,OAAO,EAAE,IAAI,EAAE,MAAM,YAAY,CAAC;AAGlC;;GAEG;AACH,eAAO,MAAM,cAAc;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAgB1B,CAAC;AAEF,MAAM,WAAW,cAAe,SAAQ,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,cAAc,CAAC;CAAG"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../../src/context/index.ts"],"names":[],"mappings":"AAIA,cAAc,UAAU,CAAC;AACzB,cAAc,WAAW,CAAC"}
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
type CreateExaToolOptions = {
|
|
2
|
-
apiKey: string;
|
|
3
|
-
};
|
|
4
|
-
export declare const createExaTool: ({ apiKey }: CreateExaToolOptions) => import("@dxos/ai").ExecutableTool;
|
|
5
|
-
export declare const createMockExaTool: () => import("@dxos/ai").ExecutableTool;
|
|
6
|
-
export {};
|
|
7
|
-
//# sourceMappingURL=exa.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"exa.d.ts","sourceRoot":"","sources":["../../../../src/research/exa.ts"],"names":[],"mappings":"AAYA,KAAK,oBAAoB,GAAG;IAC1B,MAAM,EAAE,MAAM,CAAC;CAChB,CAAC;AAEF,eAAO,MAAM,aAAa,GAAI,YAAY,oBAAoB,sCAuB7D,CAAC;AAEF,eAAO,MAAM,iBAAiB,yCAkC7B,CAAC"}
|