@pikku/addon-ollama 0.1.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/.pikku/addon/pikku-addon-types.gen.ts +78 -0
- package/.pikku/addon/pikku-package.gen.ts +9 -0
- package/.pikku/agent/pikku-agent-map.gen.d.ts +16 -0
- package/.pikku/agent/pikku-agent-types.gen.ts +76 -0
- package/.pikku/agent/pikku-agent-wirings-meta.gen.json +3 -0
- package/.pikku/agent/pikku-agent-wirings-meta.gen.ts +7 -0
- package/.pikku/agent/pikku-agent-wirings.gen.ts +3 -0
- package/.pikku/console/pikku-node-types.gen.ts +8 -0
- package/.pikku/console/pikku-nodes-meta.gen.json +57 -0
- package/.pikku/function/pikku-function-types.gen.ts +648 -0
- package/.pikku/function/pikku-functions-meta-verbose.gen.json +106 -0
- package/.pikku/function/pikku-functions-meta.gen.json +74 -0
- package/.pikku/function/pikku-functions-meta.gen.ts +7 -0
- package/.pikku/function/pikku-functions.gen.ts +14 -0
- package/.pikku/pikku-bootstrap.gen.ts +15 -0
- package/.pikku/pikku-services.gen.ts +33 -0
- package/.pikku/pikku-types.gen.ts +21 -0
- package/.pikku/rpc/pikku-rpc-wirings-map.gen.d.ts +188 -0
- package/.pikku/rpc/pikku-rpc-wirings-map.internal.gen.d.ts +192 -0
- package/.pikku/schemas/register.gen.ts +39 -0
- package/.pikku/schemas/schemas/OllamaEmbedInput.schema.json +1 -0
- package/.pikku/schemas/schemas/OllamaEmbedManyInput.schema.json +1 -0
- package/.pikku/schemas/schemas/OllamaEmbedManyOutput.schema.json +1 -0
- package/.pikku/schemas/schemas/OllamaEmbedOutput.schema.json +1 -0
- package/.pikku/schemas/schemas/OllamaGenerateObjectInput.schema.json +1 -0
- package/.pikku/schemas/schemas/OllamaGenerateObjectOutput.schema.json +1 -0
- package/.pikku/schemas/schemas/OllamaGenerateTextInput.schema.json +1 -0
- package/.pikku/schemas/schemas/OllamaGenerateTextOutput.schema.json +1 -0
- package/.pikku/schemas/schemas/VariableSchema_ollama_base_url.schema.json +1 -0
- package/.pikku/secrets/pikku-secret-types.gen.ts +5 -0
- package/.pikku/secrets/pikku-secrets-meta.gen.json +1 -0
- package/.pikku/secrets/pikku-secrets.gen.ts +21 -0
- package/.pikku/trigger/pikku-trigger-types.gen.ts +160 -0
- package/.pikku/variables/pikku-variable-types.gen.ts +5 -0
- package/.pikku/variables/pikku-variables-meta.gen.json +10 -0
- package/.pikku/variables/pikku-variables.gen.ts +23 -0
- package/.pikku/workflow/pikku-workflow-map.gen.d.ts +34 -0
- package/.pikku/workflow/pikku-workflow-types.gen.ts +158 -0
- package/.pikku/workflow/pikku-workflow-wirings-meta.gen.ts +9 -0
- package/.pikku/workflow/pikku-workflow-wirings.gen.ts +3 -0
- package/README.md +19 -0
- package/dist/.pikku/addon/pikku-addon-types.gen.d.ts +49 -0
- package/dist/.pikku/addon/pikku-addon-types.gen.d.ts.map +1 -0
- package/dist/.pikku/addon/pikku-addon-types.gen.js +55 -0
- package/dist/.pikku/addon/pikku-addon-types.gen.js.map +1 -0
- package/dist/.pikku/addon/pikku-addon-types.gen.ts +78 -0
- package/dist/.pikku/addon/pikku-package.gen.d.ts +2 -0
- package/dist/.pikku/addon/pikku-package.gen.d.ts.map +1 -0
- package/dist/.pikku/addon/pikku-package.gen.js +9 -0
- package/dist/.pikku/addon/pikku-package.gen.js.map +1 -0
- package/dist/.pikku/addon/pikku-package.gen.ts +9 -0
- package/dist/.pikku/agent/pikku-agent-map.gen.d.ts +16 -0
- package/dist/.pikku/agent/pikku-agent-types.gen.d.ts +47 -0
- package/dist/.pikku/agent/pikku-agent-types.gen.d.ts.map +1 -0
- package/dist/.pikku/agent/pikku-agent-types.gen.js +18 -0
- package/dist/.pikku/agent/pikku-agent-types.gen.js.map +1 -0
- package/dist/.pikku/agent/pikku-agent-types.gen.ts +76 -0
- package/dist/.pikku/agent/pikku-agent-wirings-meta.gen.d.ts +2 -0
- package/dist/.pikku/agent/pikku-agent-wirings-meta.gen.d.ts.map +1 -0
- package/dist/.pikku/agent/pikku-agent-wirings-meta.gen.js +7 -0
- package/dist/.pikku/agent/pikku-agent-wirings-meta.gen.js.map +1 -0
- package/dist/.pikku/agent/pikku-agent-wirings-meta.gen.json +3 -0
- package/dist/.pikku/agent/pikku-agent-wirings-meta.gen.ts +7 -0
- package/dist/.pikku/agent/pikku-agent-wirings.gen.d.ts +5 -0
- package/dist/.pikku/agent/pikku-agent-wirings.gen.d.ts.map +1 -0
- package/dist/.pikku/agent/pikku-agent-wirings.gen.js +5 -0
- package/dist/.pikku/agent/pikku-agent-wirings.gen.js.map +1 -0
- package/dist/.pikku/agent/pikku-agent-wirings.gen.ts +3 -0
- package/dist/.pikku/console/pikku-node-types.gen.d.ts +7 -0
- package/dist/.pikku/console/pikku-node-types.gen.d.ts.map +1 -0
- package/dist/.pikku/console/pikku-node-types.gen.js +2 -0
- package/dist/.pikku/console/pikku-node-types.gen.js.map +1 -0
- package/dist/.pikku/console/pikku-node-types.gen.ts +8 -0
- package/dist/.pikku/console/pikku-nodes-meta.gen.json +57 -0
- package/dist/.pikku/function/pikku-function-types.gen.d.ts +477 -0
- package/dist/.pikku/function/pikku-function-types.gen.d.ts.map +1 -0
- package/dist/.pikku/function/pikku-function-types.gen.js +298 -0
- package/dist/.pikku/function/pikku-function-types.gen.js.map +1 -0
- package/dist/.pikku/function/pikku-function-types.gen.ts +648 -0
- package/dist/.pikku/function/pikku-functions-meta-verbose.gen.json +106 -0
- package/dist/.pikku/function/pikku-functions-meta.gen.d.ts +2 -0
- package/dist/.pikku/function/pikku-functions-meta.gen.d.ts.map +1 -0
- package/dist/.pikku/function/pikku-functions-meta.gen.js +7 -0
- package/dist/.pikku/function/pikku-functions-meta.gen.js.map +1 -0
- package/dist/.pikku/function/pikku-functions-meta.gen.json +74 -0
- package/dist/.pikku/function/pikku-functions-meta.gen.ts +7 -0
- package/dist/.pikku/function/pikku-functions.gen.d.ts +2 -0
- package/dist/.pikku/function/pikku-functions.gen.d.ts.map +1 -0
- package/dist/.pikku/function/pikku-functions.gen.js +14 -0
- package/dist/.pikku/function/pikku-functions.gen.js.map +1 -0
- package/dist/.pikku/function/pikku-functions.gen.ts +14 -0
- package/dist/.pikku/pikku-bootstrap.gen.d.ts +7 -0
- package/dist/.pikku/pikku-bootstrap.gen.d.ts.map +1 -0
- package/dist/.pikku/pikku-bootstrap.gen.js +17 -0
- package/dist/.pikku/pikku-bootstrap.gen.js.map +1 -0
- package/dist/.pikku/pikku-bootstrap.gen.ts +15 -0
- package/dist/.pikku/pikku-services.gen.d.ts +26 -0
- package/dist/.pikku/pikku-services.gen.d.ts.map +1 -0
- package/dist/.pikku/pikku-services.gen.js +21 -0
- package/dist/.pikku/pikku-services.gen.js.map +1 -0
- package/dist/.pikku/pikku-services.gen.ts +33 -0
- package/dist/.pikku/pikku-types.gen.d.ts +12 -0
- package/dist/.pikku/pikku-types.gen.d.ts.map +1 -0
- package/dist/.pikku/pikku-types.gen.js +17 -0
- package/dist/.pikku/pikku-types.gen.js.map +1 -0
- package/dist/.pikku/pikku-types.gen.ts +21 -0
- package/dist/.pikku/rpc/pikku-rpc-wirings-map.gen.d.ts +188 -0
- package/dist/.pikku/rpc/pikku-rpc-wirings-map.internal.gen.d.ts +192 -0
- package/dist/.pikku/schemas/register.gen.d.ts +2 -0
- package/dist/.pikku/schemas/register.gen.d.ts.map +1 -0
- package/dist/.pikku/schemas/register.gen.js +23 -0
- package/dist/.pikku/schemas/register.gen.js.map +1 -0
- package/dist/.pikku/schemas/register.gen.ts +39 -0
- package/dist/.pikku/schemas/schemas/OllamaEmbedInput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/OllamaEmbedManyInput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/OllamaEmbedManyOutput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/OllamaEmbedOutput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/OllamaGenerateObjectInput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/OllamaGenerateObjectOutput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/OllamaGenerateTextInput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/OllamaGenerateTextOutput.schema.json +1 -0
- package/dist/.pikku/schemas/schemas/VariableSchema_ollama_base_url.schema.json +1 -0
- package/dist/.pikku/secrets/pikku-secret-types.gen.d.ts +6 -0
- package/dist/.pikku/secrets/pikku-secret-types.gen.d.ts.map +1 -0
- package/dist/.pikku/secrets/pikku-secret-types.gen.js +5 -0
- package/dist/.pikku/secrets/pikku-secret-types.gen.js.map +1 -0
- package/dist/.pikku/secrets/pikku-secret-types.gen.ts +5 -0
- package/dist/.pikku/secrets/pikku-secrets-meta.gen.json +1 -0
- package/dist/.pikku/secrets/pikku-secrets.gen.d.ts +12 -0
- package/dist/.pikku/secrets/pikku-secrets.gen.d.ts.map +1 -0
- package/dist/.pikku/secrets/pikku-secrets.gen.js +11 -0
- package/dist/.pikku/secrets/pikku-secrets.gen.js.map +1 -0
- package/dist/.pikku/secrets/pikku-secrets.gen.ts +21 -0
- package/dist/.pikku/trigger/pikku-trigger-types.gen.d.ts +114 -0
- package/dist/.pikku/trigger/pikku-trigger-types.gen.d.ts.map +1 -0
- package/dist/.pikku/trigger/pikku-trigger-types.gen.js +34 -0
- package/dist/.pikku/trigger/pikku-trigger-types.gen.js.map +1 -0
- package/dist/.pikku/trigger/pikku-trigger-types.gen.ts +160 -0
- package/dist/.pikku/variables/pikku-variable-types.gen.d.ts +6 -0
- package/dist/.pikku/variables/pikku-variable-types.gen.d.ts.map +1 -0
- package/dist/.pikku/variables/pikku-variable-types.gen.js +5 -0
- package/dist/.pikku/variables/pikku-variable-types.gen.js.map +1 -0
- package/dist/.pikku/variables/pikku-variable-types.gen.ts +5 -0
- package/dist/.pikku/variables/pikku-variables-meta.gen.json +10 -0
- package/dist/.pikku/variables/pikku-variables.gen.d.ts +15 -0
- package/dist/.pikku/variables/pikku-variables.gen.d.ts.map +1 -0
- package/dist/.pikku/variables/pikku-variables.gen.js +13 -0
- package/dist/.pikku/variables/pikku-variables.gen.js.map +1 -0
- package/dist/.pikku/variables/pikku-variables.gen.ts +23 -0
- package/dist/.pikku/workflow/pikku-workflow-map.gen.d.ts +34 -0
- package/dist/.pikku/workflow/pikku-workflow-types.gen.d.ts +81 -0
- package/dist/.pikku/workflow/pikku-workflow-types.gen.d.ts.map +1 -0
- package/dist/.pikku/workflow/pikku-workflow-types.gen.js +31 -0
- package/dist/.pikku/workflow/pikku-workflow-types.gen.js.map +1 -0
- package/dist/.pikku/workflow/pikku-workflow-types.gen.ts +158 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings-meta.gen.d.ts +2 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings-meta.gen.d.ts.map +1 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings-meta.gen.js +7 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings-meta.gen.js.map +1 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings-meta.gen.ts +9 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings.gen.d.ts +5 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings.gen.d.ts.map +1 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings.gen.js +5 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings.gen.js.map +1 -0
- package/dist/.pikku/workflow/pikku-workflow-wirings.gen.ts +3 -0
- package/dist/src/functions/embeddings/embed-many.function.d.ts +37 -0
- package/dist/src/functions/embeddings/embed-many.function.d.ts.map +1 -0
- package/dist/src/functions/embeddings/embed-many.function.js +31 -0
- package/dist/src/functions/embeddings/embed-many.function.js.map +1 -0
- package/dist/src/functions/embeddings/embed.function.d.ts +37 -0
- package/dist/src/functions/embeddings/embed.function.d.ts.map +1 -0
- package/dist/src/functions/embeddings/embed.function.js +31 -0
- package/dist/src/functions/embeddings/embed.function.js.map +1 -0
- package/dist/src/functions/text/generate-object.function.d.ts +101 -0
- package/dist/src/functions/text/generate-object.function.d.ts.map +1 -0
- package/dist/src/functions/text/generate-object.function.js +56 -0
- package/dist/src/functions/text/generate-object.function.js.map +1 -0
- package/dist/src/functions/text/generate.function.d.ts +89 -0
- package/dist/src/functions/text/generate.function.d.ts.map +1 -0
- package/dist/src/functions/text/generate.function.js +51 -0
- package/dist/src/functions/text/generate.function.js.map +1 -0
- package/dist/src/index.d.ts +5 -0
- package/dist/src/index.d.ts.map +1 -0
- package/dist/src/index.js +7 -0
- package/dist/src/index.js.map +1 -0
- package/dist/src/ollama.variable.d.ts +3 -0
- package/dist/src/ollama.variable.d.ts.map +1 -0
- package/dist/src/ollama.variable.js +11 -0
- package/dist/src/ollama.variable.js.map +1 -0
- package/dist/src/services.d.ts +2 -0
- package/dist/src/services.d.ts.map +1 -0
- package/dist/src/services.js +11 -0
- package/dist/src/services.js.map +1 -0
- package/package.json +44 -0
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
{
|
|
2
|
+
"ollamaGenerateText": {
|
|
3
|
+
"pikkuFuncId": "ollamaGenerateText",
|
|
4
|
+
"functionType": "user",
|
|
5
|
+
"funcWrapper": "pikkuSessionlessFunc",
|
|
6
|
+
"sessionless": true,
|
|
7
|
+
"name": "ollamaGenerateText",
|
|
8
|
+
"services": {
|
|
9
|
+
"optimized": true,
|
|
10
|
+
"services": [
|
|
11
|
+
"ollama"
|
|
12
|
+
]
|
|
13
|
+
},
|
|
14
|
+
"inputSchemaName": "OllamaGenerateTextInput",
|
|
15
|
+
"outputSchemaName": "OllamaGenerateTextOutput",
|
|
16
|
+
"inputs": [
|
|
17
|
+
"OllamaGenerateTextInput"
|
|
18
|
+
],
|
|
19
|
+
"outputs": [
|
|
20
|
+
"OllamaGenerateTextOutput"
|
|
21
|
+
],
|
|
22
|
+
"description": "Generate text using an Ollama model",
|
|
23
|
+
"isDirectFunction": false,
|
|
24
|
+
"contractHash": "0d03988593f9adef",
|
|
25
|
+
"inputHash": "bdf047a6",
|
|
26
|
+
"outputHash": "4e2c22b3"
|
|
27
|
+
},
|
|
28
|
+
"ollamaGenerateObject": {
|
|
29
|
+
"pikkuFuncId": "ollamaGenerateObject",
|
|
30
|
+
"functionType": "user",
|
|
31
|
+
"funcWrapper": "pikkuSessionlessFunc",
|
|
32
|
+
"sessionless": true,
|
|
33
|
+
"name": "ollamaGenerateObject",
|
|
34
|
+
"services": {
|
|
35
|
+
"optimized": true,
|
|
36
|
+
"services": [
|
|
37
|
+
"ollama"
|
|
38
|
+
]
|
|
39
|
+
},
|
|
40
|
+
"inputSchemaName": "OllamaGenerateObjectInput",
|
|
41
|
+
"outputSchemaName": "OllamaGenerateObjectOutput",
|
|
42
|
+
"inputs": [
|
|
43
|
+
"OllamaGenerateObjectInput"
|
|
44
|
+
],
|
|
45
|
+
"outputs": [
|
|
46
|
+
"OllamaGenerateObjectOutput"
|
|
47
|
+
],
|
|
48
|
+
"description": "Generate a structured JSON object using an Ollama model",
|
|
49
|
+
"isDirectFunction": false,
|
|
50
|
+
"contractHash": "e7026856e15a96b5",
|
|
51
|
+
"inputHash": "4ceb54b7",
|
|
52
|
+
"outputHash": "e26f98ba"
|
|
53
|
+
},
|
|
54
|
+
"ollamaEmbed": {
|
|
55
|
+
"pikkuFuncId": "ollamaEmbed",
|
|
56
|
+
"functionType": "user",
|
|
57
|
+
"funcWrapper": "pikkuSessionlessFunc",
|
|
58
|
+
"sessionless": true,
|
|
59
|
+
"name": "ollamaEmbed",
|
|
60
|
+
"services": {
|
|
61
|
+
"optimized": true,
|
|
62
|
+
"services": [
|
|
63
|
+
"ollama"
|
|
64
|
+
]
|
|
65
|
+
},
|
|
66
|
+
"inputSchemaName": "OllamaEmbedInput",
|
|
67
|
+
"outputSchemaName": "OllamaEmbedOutput",
|
|
68
|
+
"inputs": [
|
|
69
|
+
"OllamaEmbedInput"
|
|
70
|
+
],
|
|
71
|
+
"outputs": [
|
|
72
|
+
"OllamaEmbedOutput"
|
|
73
|
+
],
|
|
74
|
+
"description": "Create an embedding vector from text using an Ollama model",
|
|
75
|
+
"isDirectFunction": false,
|
|
76
|
+
"contractHash": "0354ea934b747af7",
|
|
77
|
+
"inputHash": "8340c2c0",
|
|
78
|
+
"outputHash": "bb88b854"
|
|
79
|
+
},
|
|
80
|
+
"ollamaEmbedMany": {
|
|
81
|
+
"pikkuFuncId": "ollamaEmbedMany",
|
|
82
|
+
"functionType": "user",
|
|
83
|
+
"funcWrapper": "pikkuSessionlessFunc",
|
|
84
|
+
"sessionless": true,
|
|
85
|
+
"name": "ollamaEmbedMany",
|
|
86
|
+
"services": {
|
|
87
|
+
"optimized": true,
|
|
88
|
+
"services": [
|
|
89
|
+
"ollama"
|
|
90
|
+
]
|
|
91
|
+
},
|
|
92
|
+
"inputSchemaName": "OllamaEmbedManyInput",
|
|
93
|
+
"outputSchemaName": "OllamaEmbedManyOutput",
|
|
94
|
+
"inputs": [
|
|
95
|
+
"OllamaEmbedManyInput"
|
|
96
|
+
],
|
|
97
|
+
"outputs": [
|
|
98
|
+
"OllamaEmbedManyOutput"
|
|
99
|
+
],
|
|
100
|
+
"description": "Create embedding vectors from multiple texts using an Ollama model",
|
|
101
|
+
"isDirectFunction": false,
|
|
102
|
+
"contractHash": "3db02092482ca9c6",
|
|
103
|
+
"inputHash": "4f6f4b67",
|
|
104
|
+
"outputHash": "54a0cfe3"
|
|
105
|
+
}
|
|
106
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pikku-functions-meta.gen.d.ts","sourceRoot":"","sources":["../../../.pikku/function/pikku-functions-meta.gen.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.1
|
|
3
|
+
*/
|
|
4
|
+
import { pikkuState } from '@pikku/core/internal';
|
|
5
|
+
import metaData from './pikku-functions-meta.gen.json' with { type: 'json' };
|
|
6
|
+
pikkuState('@pikku/addon-ollama', 'function', 'meta', metaData);
|
|
7
|
+
//# sourceMappingURL=pikku-functions-meta.gen.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pikku-functions-meta.gen.js","sourceRoot":"","sources":["../../../.pikku/function/pikku-functions-meta.gen.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EAAE,UAAU,EAAE,MAAM,sBAAsB,CAAA;AAEjD,OAAO,QAAQ,MAAM,iCAAiC,CAAC,OAAO,IAAI,EAAE,MAAM,EAAE,CAAA;AAC5E,UAAU,CAAC,qBAAqB,EAAE,UAAU,EAAE,MAAM,EAAE,QAAyB,CAAC,CAAA"}
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
{
|
|
2
|
+
"ollamaGenerateText": {
|
|
3
|
+
"pikkuFuncId": "ollamaGenerateText",
|
|
4
|
+
"functionType": "user",
|
|
5
|
+
"funcWrapper": "pikkuSessionlessFunc",
|
|
6
|
+
"sessionless": true,
|
|
7
|
+
"name": "ollamaGenerateText",
|
|
8
|
+
"inputSchemaName": "OllamaGenerateTextInput",
|
|
9
|
+
"outputSchemaName": "OllamaGenerateTextOutput",
|
|
10
|
+
"inputs": [
|
|
11
|
+
"OllamaGenerateTextInput"
|
|
12
|
+
],
|
|
13
|
+
"outputs": [
|
|
14
|
+
"OllamaGenerateTextOutput"
|
|
15
|
+
],
|
|
16
|
+
"contractHash": "0d03988593f9adef",
|
|
17
|
+
"inputHash": "bdf047a6",
|
|
18
|
+
"outputHash": "4e2c22b3"
|
|
19
|
+
},
|
|
20
|
+
"ollamaGenerateObject": {
|
|
21
|
+
"pikkuFuncId": "ollamaGenerateObject",
|
|
22
|
+
"functionType": "user",
|
|
23
|
+
"funcWrapper": "pikkuSessionlessFunc",
|
|
24
|
+
"sessionless": true,
|
|
25
|
+
"name": "ollamaGenerateObject",
|
|
26
|
+
"inputSchemaName": "OllamaGenerateObjectInput",
|
|
27
|
+
"outputSchemaName": "OllamaGenerateObjectOutput",
|
|
28
|
+
"inputs": [
|
|
29
|
+
"OllamaGenerateObjectInput"
|
|
30
|
+
],
|
|
31
|
+
"outputs": [
|
|
32
|
+
"OllamaGenerateObjectOutput"
|
|
33
|
+
],
|
|
34
|
+
"contractHash": "e7026856e15a96b5",
|
|
35
|
+
"inputHash": "4ceb54b7",
|
|
36
|
+
"outputHash": "e26f98ba"
|
|
37
|
+
},
|
|
38
|
+
"ollamaEmbed": {
|
|
39
|
+
"pikkuFuncId": "ollamaEmbed",
|
|
40
|
+
"functionType": "user",
|
|
41
|
+
"funcWrapper": "pikkuSessionlessFunc",
|
|
42
|
+
"sessionless": true,
|
|
43
|
+
"name": "ollamaEmbed",
|
|
44
|
+
"inputSchemaName": "OllamaEmbedInput",
|
|
45
|
+
"outputSchemaName": "OllamaEmbedOutput",
|
|
46
|
+
"inputs": [
|
|
47
|
+
"OllamaEmbedInput"
|
|
48
|
+
],
|
|
49
|
+
"outputs": [
|
|
50
|
+
"OllamaEmbedOutput"
|
|
51
|
+
],
|
|
52
|
+
"contractHash": "0354ea934b747af7",
|
|
53
|
+
"inputHash": "8340c2c0",
|
|
54
|
+
"outputHash": "bb88b854"
|
|
55
|
+
},
|
|
56
|
+
"ollamaEmbedMany": {
|
|
57
|
+
"pikkuFuncId": "ollamaEmbedMany",
|
|
58
|
+
"functionType": "user",
|
|
59
|
+
"funcWrapper": "pikkuSessionlessFunc",
|
|
60
|
+
"sessionless": true,
|
|
61
|
+
"name": "ollamaEmbedMany",
|
|
62
|
+
"inputSchemaName": "OllamaEmbedManyInput",
|
|
63
|
+
"outputSchemaName": "OllamaEmbedManyOutput",
|
|
64
|
+
"inputs": [
|
|
65
|
+
"OllamaEmbedManyInput"
|
|
66
|
+
],
|
|
67
|
+
"outputs": [
|
|
68
|
+
"OllamaEmbedManyOutput"
|
|
69
|
+
],
|
|
70
|
+
"contractHash": "3db02092482ca9c6",
|
|
71
|
+
"inputHash": "4f6f4b67",
|
|
72
|
+
"outputHash": "54a0cfe3"
|
|
73
|
+
}
|
|
74
|
+
}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.1
|
|
3
|
+
*/
|
|
4
|
+
import { pikkuState } from '@pikku/core/internal'
|
|
5
|
+
import type { FunctionsMeta } from '@pikku/core'
|
|
6
|
+
import metaData from './pikku-functions-meta.gen.json' with { type: 'json' }
|
|
7
|
+
pikkuState('@pikku/addon-ollama', 'function', 'meta', metaData as FunctionsMeta)
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pikku-functions.gen.d.ts","sourceRoot":"","sources":["../../../.pikku/function/pikku-functions.gen.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.1
|
|
3
|
+
*/
|
|
4
|
+
/* Import and register functions used by RPCs */
|
|
5
|
+
import { addFunction } from '@pikku/core';
|
|
6
|
+
import { ollamaEmbed } from '../../src/functions/embeddings/embed.function.js';
|
|
7
|
+
import { ollamaEmbedMany } from '../../src/functions/embeddings/embed-many.function.js';
|
|
8
|
+
import { ollamaGenerateObject } from '../../src/functions/text/generate-object.function.js';
|
|
9
|
+
import { ollamaGenerateText } from '../../src/functions/text/generate.function.js';
|
|
10
|
+
addFunction('ollamaEmbed', ollamaEmbed, '@pikku/addon-ollama');
|
|
11
|
+
addFunction('ollamaEmbedMany', ollamaEmbedMany, '@pikku/addon-ollama');
|
|
12
|
+
addFunction('ollamaGenerateObject', ollamaGenerateObject, '@pikku/addon-ollama');
|
|
13
|
+
addFunction('ollamaGenerateText', ollamaGenerateText, '@pikku/addon-ollama');
|
|
14
|
+
//# sourceMappingURL=pikku-functions.gen.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pikku-functions.gen.js","sourceRoot":"","sources":["../../../.pikku/function/pikku-functions.gen.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,gDAAgD;AAChD,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAA;AACzC,OAAO,EAAE,WAAW,EAAE,MAAM,kDAAkD,CAAA;AAC9E,OAAO,EAAE,eAAe,EAAE,MAAM,uDAAuD,CAAA;AACvF,OAAO,EAAE,oBAAoB,EAAE,MAAM,sDAAsD,CAAA;AAC3F,OAAO,EAAE,kBAAkB,EAAE,MAAM,+CAA+C,CAAA;AAElF,WAAW,CAAC,aAAa,EAAE,WAAW,EAAE,qBAAqB,CAAC,CAAA;AAC9D,WAAW,CAAC,iBAAiB,EAAE,eAAe,EAAE,qBAAqB,CAAC,CAAA;AACtE,WAAW,CAAC,sBAAsB,EAAE,oBAAoB,EAAE,qBAAqB,CAAC,CAAA;AAChF,WAAW,CAAC,oBAAoB,EAAE,kBAAkB,EAAE,qBAAqB,CAAC,CAAA"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.1
|
|
3
|
+
*/
|
|
4
|
+
/* Import and register functions used by RPCs */
|
|
5
|
+
import { addFunction } from '@pikku/core'
|
|
6
|
+
import { ollamaEmbed } from '../../src/functions/embeddings/embed.function.js'
|
|
7
|
+
import { ollamaEmbedMany } from '../../src/functions/embeddings/embed-many.function.js'
|
|
8
|
+
import { ollamaGenerateObject } from '../../src/functions/text/generate-object.function.js'
|
|
9
|
+
import { ollamaGenerateText } from '../../src/functions/text/generate.function.js'
|
|
10
|
+
|
|
11
|
+
addFunction('ollamaEmbed', ollamaEmbed, '@pikku/addon-ollama')
|
|
12
|
+
addFunction('ollamaEmbedMany', ollamaEmbedMany, '@pikku/addon-ollama')
|
|
13
|
+
addFunction('ollamaGenerateObject', ollamaGenerateObject, '@pikku/addon-ollama')
|
|
14
|
+
addFunction('ollamaGenerateText', ollamaGenerateText, '@pikku/addon-ollama')
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import './agent/pikku-agent-wirings-meta.gen.js';
|
|
2
|
+
import './function/pikku-functions-meta.gen.js';
|
|
3
|
+
import './addon/pikku-package.gen.js';
|
|
4
|
+
import './agent/pikku-agent-wirings.gen.js';
|
|
5
|
+
import './schemas/register.gen.js';
|
|
6
|
+
import './function/pikku-functions.gen.js';
|
|
7
|
+
//# sourceMappingURL=pikku-bootstrap.gen.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pikku-bootstrap.gen.d.ts","sourceRoot":"","sources":["../../.pikku/pikku-bootstrap.gen.ts"],"names":[],"mappings":"AASA,OAAO,yCAAyC,CAAA;AAChD,OAAO,wCAAwC,CAAA;AAC/C,OAAO,8BAA8B,CAAA;AACrC,OAAO,oCAAoC,CAAA;AAC3C,OAAO,2BAA2B,CAAA;AAClC,OAAO,mCAAmC,CAAA"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.1
|
|
3
|
+
*/
|
|
4
|
+
import { pikkuState as __pikkuState } from '@pikku/core/internal';
|
|
5
|
+
try {
|
|
6
|
+
const { fileURLToPath: __fileURLToPath } = await import('url');
|
|
7
|
+
const { dirname: __dirname } = await import('path');
|
|
8
|
+
__pikkuState('@pikku/addon-ollama', 'package', 'metaDir', __dirname(__fileURLToPath(import.meta.url)));
|
|
9
|
+
}
|
|
10
|
+
catch { }
|
|
11
|
+
import './agent/pikku-agent-wirings-meta.gen.js';
|
|
12
|
+
import './function/pikku-functions-meta.gen.js';
|
|
13
|
+
import './addon/pikku-package.gen.js';
|
|
14
|
+
import './agent/pikku-agent-wirings.gen.js';
|
|
15
|
+
import './schemas/register.gen.js';
|
|
16
|
+
import './function/pikku-functions.gen.js';
|
|
17
|
+
//# sourceMappingURL=pikku-bootstrap.gen.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pikku-bootstrap.gen.js","sourceRoot":"","sources":["../../.pikku/pikku-bootstrap.gen.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,EAAE,UAAU,IAAI,YAAY,EAAE,MAAM,sBAAsB,CAAA;AACjE,IAAI,CAAC;IACH,MAAM,EAAE,aAAa,EAAE,eAAe,EAAE,GAAG,MAAM,MAAM,CAAC,KAAK,CAAC,CAAA;IAC9D,MAAM,EAAE,OAAO,EAAE,SAAS,EAAE,GAAG,MAAM,MAAM,CAAC,MAAM,CAAC,CAAA;IACnD,YAAY,CAAC,qBAAqB,EAAE,SAAS,EAAE,SAAS,EAAE,SAAS,CAAC,eAAe,CAAC,MAAM,CAAC,IAAI,CAAC,GAAG,CAAC,CAAC,CAAC,CAAA;AACxG,CAAC;AAAC,MAAM,CAAC,CAAA,CAAC;AACV,OAAO,yCAAyC,CAAA;AAChD,OAAO,wCAAwC,CAAA;AAC/C,OAAO,8BAA8B,CAAA;AACrC,OAAO,oCAAoC,CAAA;AAC3C,OAAO,2BAA2B,CAAA;AAClC,OAAO,mCAAmC,CAAA"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.1
|
|
3
|
+
*/
|
|
4
|
+
import { pikkuState as __pikkuState } from '@pikku/core/internal'
|
|
5
|
+
try {
|
|
6
|
+
const { fileURLToPath: __fileURLToPath } = await import('url')
|
|
7
|
+
const { dirname: __dirname } = await import('path')
|
|
8
|
+
__pikkuState('@pikku/addon-ollama', 'package', 'metaDir', __dirname(__fileURLToPath(import.meta.url)))
|
|
9
|
+
} catch {}
|
|
10
|
+
import './agent/pikku-agent-wirings-meta.gen.js'
|
|
11
|
+
import './function/pikku-functions-meta.gen.js'
|
|
12
|
+
import './addon/pikku-package.gen.js'
|
|
13
|
+
import './agent/pikku-agent-wirings.gen.js'
|
|
14
|
+
import './schemas/register.gen.js'
|
|
15
|
+
import './function/pikku-functions.gen.js'
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.1
|
|
3
|
+
*/
|
|
4
|
+
import type { SingletonServices } from '../types/application-types.d.js';
|
|
5
|
+
import type { Services } from '../types/application-types.d.js';
|
|
6
|
+
export declare const requiredSingletonServices: {
|
|
7
|
+
readonly aiAgentRunner: false;
|
|
8
|
+
readonly aiRunState: false;
|
|
9
|
+
readonly aiStorage: false;
|
|
10
|
+
readonly config: true;
|
|
11
|
+
readonly content: false;
|
|
12
|
+
readonly deploymentService: false;
|
|
13
|
+
readonly jwt: false;
|
|
14
|
+
readonly logger: true;
|
|
15
|
+
readonly ollama: false;
|
|
16
|
+
readonly queueService: false;
|
|
17
|
+
readonly schedulerService: false;
|
|
18
|
+
readonly schema: true;
|
|
19
|
+
readonly secrets: true;
|
|
20
|
+
readonly variables: true;
|
|
21
|
+
readonly workflowService: false;
|
|
22
|
+
};
|
|
23
|
+
export declare const requiredWireServices: {};
|
|
24
|
+
export type RequiredSingletonServices = Pick<SingletonServices, 'config' | 'logger' | 'schema' | 'secrets' | 'variables'> & Partial<Omit<SingletonServices, 'config' | 'logger' | 'schema' | 'secrets' | 'variables'>>;
|
|
25
|
+
export type RequiredWireServices = Partial<Services>;
|
|
26
|
+
//# sourceMappingURL=pikku-services.gen.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pikku-services.gen.d.ts","sourceRoot":"","sources":["../../.pikku/pikku-services.gen.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH,OAAO,KAAK,EAAE,iBAAiB,EAAE,MAAM,iCAAiC,CAAA;AACxE,OAAO,KAAK,EAAE,QAAQ,EAAE,MAAM,iCAAiC,CAAA;AAG/D,eAAO,MAAM,yBAAyB;;;;;;;;;;;;;;;;CAgB5B,CAAA;AAGV,eAAO,MAAM,oBAAoB,IACvB,CAAA;AAGV,MAAM,MAAM,yBAAyB,GAAG,IAAI,CAAC,iBAAiB,EAAE,QAAQ,GAAG,QAAQ,GAAG,QAAQ,GAAG,SAAS,GAAG,WAAW,CAAC,GAAG,OAAO,CAAC,IAAI,CAAC,iBAAiB,EAAE,QAAQ,GAAG,QAAQ,GAAG,QAAQ,GAAG,SAAS,GAAG,WAAW,CAAC,CAAC,CAAA;AAEtN,MAAM,MAAM,oBAAoB,GAAG,OAAO,CAAC,QAAQ,CAAC,CAAA"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
// Singleton services map: true if required, false if available but unused
|
|
2
|
+
export const requiredSingletonServices = {
|
|
3
|
+
'aiAgentRunner': false,
|
|
4
|
+
'aiRunState': false,
|
|
5
|
+
'aiStorage': false,
|
|
6
|
+
'config': true,
|
|
7
|
+
'content': false,
|
|
8
|
+
'deploymentService': false,
|
|
9
|
+
'jwt': false,
|
|
10
|
+
'logger': true,
|
|
11
|
+
'ollama': false,
|
|
12
|
+
'queueService': false,
|
|
13
|
+
'schedulerService': false,
|
|
14
|
+
'schema': true,
|
|
15
|
+
'secrets': true,
|
|
16
|
+
'variables': true,
|
|
17
|
+
'workflowService': false,
|
|
18
|
+
};
|
|
19
|
+
// Wire services map: true if required, false if available but unused
|
|
20
|
+
export const requiredWireServices = {};
|
|
21
|
+
//# sourceMappingURL=pikku-services.gen.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pikku-services.gen.js","sourceRoot":"","sources":["../../.pikku/pikku-services.gen.ts"],"names":[],"mappings":"AAMA,0EAA0E;AAC1E,MAAM,CAAC,MAAM,yBAAyB,GAAG;IACvC,eAAe,EAAE,KAAK;IACtB,YAAY,EAAE,KAAK;IACnB,WAAW,EAAE,KAAK;IAClB,QAAQ,EAAE,IAAI;IACd,SAAS,EAAE,KAAK;IAChB,mBAAmB,EAAE,KAAK;IAC1B,KAAK,EAAE,KAAK;IACZ,QAAQ,EAAE,IAAI;IACd,QAAQ,EAAE,KAAK;IACf,cAAc,EAAE,KAAK;IACrB,kBAAkB,EAAE,KAAK;IACzB,QAAQ,EAAE,IAAI;IACd,SAAS,EAAE,IAAI;IACf,WAAW,EAAE,IAAI;IACjB,iBAAiB,EAAE,KAAK;CAChB,CAAA;AAEV,qEAAqE;AACrE,MAAM,CAAC,MAAM,oBAAoB,GAAG,EAC1B,CAAA"}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.1
|
|
3
|
+
*/
|
|
4
|
+
import type { SingletonServices } from '../types/application-types.d.js'
|
|
5
|
+
import type { Services } from '../types/application-types.d.js'
|
|
6
|
+
|
|
7
|
+
// Singleton services map: true if required, false if available but unused
|
|
8
|
+
export const requiredSingletonServices = {
|
|
9
|
+
'aiAgentRunner': false,
|
|
10
|
+
'aiRunState': false,
|
|
11
|
+
'aiStorage': false,
|
|
12
|
+
'config': true,
|
|
13
|
+
'content': false,
|
|
14
|
+
'deploymentService': false,
|
|
15
|
+
'jwt': false,
|
|
16
|
+
'logger': true,
|
|
17
|
+
'ollama': false,
|
|
18
|
+
'queueService': false,
|
|
19
|
+
'schedulerService': false,
|
|
20
|
+
'schema': true,
|
|
21
|
+
'secrets': true,
|
|
22
|
+
'variables': true,
|
|
23
|
+
'workflowService': false,
|
|
24
|
+
} as const
|
|
25
|
+
|
|
26
|
+
// Wire services map: true if required, false if available but unused
|
|
27
|
+
export const requiredWireServices = {
|
|
28
|
+
} as const
|
|
29
|
+
|
|
30
|
+
// Type exports
|
|
31
|
+
export type RequiredSingletonServices = Pick<SingletonServices, 'config' | 'logger' | 'schema' | 'secrets' | 'variables'> & Partial<Omit<SingletonServices, 'config' | 'logger' | 'schema' | 'secrets' | 'variables'>>
|
|
32
|
+
|
|
33
|
+
export type RequiredWireServices = Partial<Services>
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.1
|
|
3
|
+
*/
|
|
4
|
+
/**
|
|
5
|
+
* Main type export hub - re-exports all wiring-specific types
|
|
6
|
+
*/
|
|
7
|
+
export * from './function/pikku-function-types.gen.js';
|
|
8
|
+
export * from './trigger/pikku-trigger-types.gen.js';
|
|
9
|
+
export * from './console/pikku-node-types.gen.js';
|
|
10
|
+
export * from './secrets/pikku-secret-types.gen.js';
|
|
11
|
+
export * from './addon/pikku-addon-types.gen.js';
|
|
12
|
+
//# sourceMappingURL=pikku-types.gen.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pikku-types.gen.d.ts","sourceRoot":"","sources":["../../.pikku/pikku-types.gen.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;GAEG;AAGH,cAAc,wCAAwC,CAAA;AAGtD,cAAc,sCAAsC,CAAA;AAGpD,cAAc,mCAAmC,CAAA;AAGjD,cAAc,qCAAqC,CAAA;AAGnD,cAAc,kCAAkC,CAAA"}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.1
|
|
3
|
+
*/
|
|
4
|
+
/**
|
|
5
|
+
* Main type export hub - re-exports all wiring-specific types
|
|
6
|
+
*/
|
|
7
|
+
// Core function, middleware, and permission types
|
|
8
|
+
export * from './function/pikku-function-types.gen.js';
|
|
9
|
+
// Trigger wiring types
|
|
10
|
+
export * from './trigger/pikku-trigger-types.gen.js';
|
|
11
|
+
// Node wiring types
|
|
12
|
+
export * from './console/pikku-node-types.gen.js';
|
|
13
|
+
// Secret definition types
|
|
14
|
+
export * from './secrets/pikku-secret-types.gen.js';
|
|
15
|
+
// Addon types
|
|
16
|
+
export * from './addon/pikku-addon-types.gen.js';
|
|
17
|
+
//# sourceMappingURL=pikku-types.gen.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"pikku-types.gen.js","sourceRoot":"","sources":["../../.pikku/pikku-types.gen.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;GAEG;AAEH,kDAAkD;AAClD,cAAc,wCAAwC,CAAA;AAEtD,uBAAuB;AACvB,cAAc,sCAAsC,CAAA;AAEpD,oBAAoB;AACpB,cAAc,mCAAmC,CAAA;AAEjD,0BAA0B;AAC1B,cAAc,qCAAqC,CAAA;AAEnD,cAAc;AACd,cAAc,kCAAkC,CAAA"}
|
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.1
|
|
3
|
+
*/
|
|
4
|
+
/**
|
|
5
|
+
* Main type export hub - re-exports all wiring-specific types
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
// Core function, middleware, and permission types
|
|
9
|
+
export * from './function/pikku-function-types.gen.js'
|
|
10
|
+
|
|
11
|
+
// Trigger wiring types
|
|
12
|
+
export * from './trigger/pikku-trigger-types.gen.js'
|
|
13
|
+
|
|
14
|
+
// Node wiring types
|
|
15
|
+
export * from './console/pikku-node-types.gen.js'
|
|
16
|
+
|
|
17
|
+
// Secret definition types
|
|
18
|
+
export * from './secrets/pikku-secret-types.gen.js'
|
|
19
|
+
|
|
20
|
+
// Addon types
|
|
21
|
+
export * from './addon/pikku-addon-types.gen.js'
|
|
@@ -0,0 +1,188 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* This file was generated by @pikku/cli@0.12.1
|
|
3
|
+
*/
|
|
4
|
+
/**
|
|
5
|
+
* This provides the structure needed for typescript to be aware of RPCs and their return types
|
|
6
|
+
*/
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
export type OllamaGenerateTextInput = {
|
|
13
|
+
/** The Ollama model to use (e.g. "llama3.2", "phi3:mini") */
|
|
14
|
+
model: string;
|
|
15
|
+
/** The prompt to generate text from */
|
|
16
|
+
prompt?: string | undefined;
|
|
17
|
+
/** A list of messages comprising the conversation so far */
|
|
18
|
+
messages?: {
|
|
19
|
+
/** The role of the message author */
|
|
20
|
+
role: "system" | "user" | "assistant";
|
|
21
|
+
/** The contents of the message */
|
|
22
|
+
content: string;
|
|
23
|
+
}[] | undefined;
|
|
24
|
+
/** System message to set the behavior of the model */
|
|
25
|
+
system?: string | undefined;
|
|
26
|
+
/** Maximum number of tokens to generate */
|
|
27
|
+
maxTokens?: number | undefined;
|
|
28
|
+
/** Sampling temperature between 0 and 2 */
|
|
29
|
+
temperature?: number | undefined;
|
|
30
|
+
/** Nucleus sampling parameter */
|
|
31
|
+
topP?: number | undefined;
|
|
32
|
+
/** Random seed for reproducible results */
|
|
33
|
+
seed?: number | undefined;
|
|
34
|
+
}
|
|
35
|
+
export type OllamaGenerateTextOutput = {
|
|
36
|
+
/** The generated text */
|
|
37
|
+
text: string;
|
|
38
|
+
/** The reason the model stopped generating */
|
|
39
|
+
finishReason: string;
|
|
40
|
+
/** Token usage statistics */
|
|
41
|
+
usage: {
|
|
42
|
+
/** Number of tokens in the prompt */
|
|
43
|
+
promptTokens: number;
|
|
44
|
+
/** Number of tokens in the completion */
|
|
45
|
+
completionTokens: number;
|
|
46
|
+
/** Total number of tokens used */
|
|
47
|
+
totalTokens: number;
|
|
48
|
+
};
|
|
49
|
+
}
|
|
50
|
+
export type OllamaGenerateObjectInput = {
|
|
51
|
+
/** The Ollama model to use (e.g. "llama3.2", "phi3:mini") */
|
|
52
|
+
model: string;
|
|
53
|
+
/** The prompt to generate a structured object from */
|
|
54
|
+
prompt?: string | undefined;
|
|
55
|
+
/** A list of messages comprising the conversation so far */
|
|
56
|
+
messages?: {
|
|
57
|
+
/** The role of the message author */
|
|
58
|
+
role: "system" | "user" | "assistant";
|
|
59
|
+
/** The contents of the message */
|
|
60
|
+
content: string;
|
|
61
|
+
}[] | undefined;
|
|
62
|
+
/** System message to set the behavior of the model */
|
|
63
|
+
system?: string | undefined;
|
|
64
|
+
/** JSON Schema describing the expected output object */
|
|
65
|
+
schema: {
|
|
66
|
+
[key: string]: any;
|
|
67
|
+
};
|
|
68
|
+
/** Optional name for the schema */
|
|
69
|
+
schemaName?: string | undefined;
|
|
70
|
+
/** Optional description of what the schema represents */
|
|
71
|
+
schemaDescription?: string | undefined;
|
|
72
|
+
/** Mode for object generation. Use "json" for models that do not support tools. */
|
|
73
|
+
mode?: ("auto" | "tool" | "json") | undefined;
|
|
74
|
+
/** Maximum number of tokens to generate */
|
|
75
|
+
maxTokens?: number | undefined;
|
|
76
|
+
/** Sampling temperature between 0 and 2 */
|
|
77
|
+
temperature?: number | undefined;
|
|
78
|
+
}
|
|
79
|
+
export type OllamaGenerateObjectOutput = {
|
|
80
|
+
/** The generated structured object */
|
|
81
|
+
object: any;
|
|
82
|
+
/** The reason the model stopped generating */
|
|
83
|
+
finishReason: string;
|
|
84
|
+
/** Token usage statistics */
|
|
85
|
+
usage: {
|
|
86
|
+
/** Number of tokens in the prompt */
|
|
87
|
+
promptTokens: number;
|
|
88
|
+
/** Number of tokens in the completion */
|
|
89
|
+
completionTokens: number;
|
|
90
|
+
/** Total number of tokens used */
|
|
91
|
+
totalTokens: number;
|
|
92
|
+
};
|
|
93
|
+
}
|
|
94
|
+
export type OllamaEmbedInput = {
|
|
95
|
+
/** The Ollama embedding model to use (e.g. "nomic-embed-text", "mxbai-embed-large") */
|
|
96
|
+
model: string;
|
|
97
|
+
/** The text to embed */
|
|
98
|
+
value: string;
|
|
99
|
+
}
|
|
100
|
+
export type OllamaEmbedOutput = {
|
|
101
|
+
/** The embedding vector */
|
|
102
|
+
embedding: number[];
|
|
103
|
+
/** Token usage statistics */
|
|
104
|
+
usage: {
|
|
105
|
+
/** Number of tokens used */
|
|
106
|
+
tokens: number;
|
|
107
|
+
};
|
|
108
|
+
}
|
|
109
|
+
export type OllamaEmbedManyInput = {
|
|
110
|
+
/** The Ollama embedding model to use (e.g. "nomic-embed-text", "mxbai-embed-large") */
|
|
111
|
+
model: string;
|
|
112
|
+
/** The texts to embed */
|
|
113
|
+
values: string[];
|
|
114
|
+
}
|
|
115
|
+
export type OllamaEmbedManyOutput = {
|
|
116
|
+
/** The embedding vectors */
|
|
117
|
+
embeddings: number[][];
|
|
118
|
+
/** Token usage statistics */
|
|
119
|
+
usage: {
|
|
120
|
+
/** Number of tokens used */
|
|
121
|
+
tokens: number;
|
|
122
|
+
};
|
|
123
|
+
}
|
|
124
|
+
export type VariableSchema_ollama_base_url = string
|
|
125
|
+
|
|
126
|
+
interface RPCHandler<I, O> {
|
|
127
|
+
input: I;
|
|
128
|
+
output: O;
|
|
129
|
+
}
|
|
130
|
+
|
|
131
|
+
export type RPCMap = {
|
|
132
|
+
};
|
|
133
|
+
|
|
134
|
+
|
|
135
|
+
|
|
136
|
+
// No addon packages, use RPCMap directly
|
|
137
|
+
export type FlattenedRPCMap = RPCMap
|
|
138
|
+
|
|
139
|
+
|
|
140
|
+
export type RPCInvoke = <Name extends keyof FlattenedRPCMap>(
|
|
141
|
+
name: Name,
|
|
142
|
+
data: FlattenedRPCMap[Name]['input']
|
|
143
|
+
) => Promise<FlattenedRPCMap[Name]['output']>
|
|
144
|
+
|
|
145
|
+
export type RPCRemote = <Name extends keyof FlattenedRPCMap>(
|
|
146
|
+
name: Name,
|
|
147
|
+
data: FlattenedRPCMap[Name]['input']
|
|
148
|
+
) => Promise<FlattenedRPCMap[Name]['output']>
|
|
149
|
+
|
|
150
|
+
import type { WorkflowMap } from '../workflow/pikku-workflow-map.gen.d.js'
|
|
151
|
+
|
|
152
|
+
import type { AgentMap } from '../agent/pikku-agent-map.gen.d.js'
|
|
153
|
+
|
|
154
|
+
|
|
155
|
+
type FlattenedAgentMap = AgentMap
|
|
156
|
+
|
|
157
|
+
|
|
158
|
+
import type { PikkuRPC } from '@pikku/core/rpc'
|
|
159
|
+
|
|
160
|
+
interface AIAgentInput {
|
|
161
|
+
message: string
|
|
162
|
+
threadId: string
|
|
163
|
+
resourceId: string
|
|
164
|
+
}
|
|
165
|
+
|
|
166
|
+
export type TypedStartWorkflow = <Name extends keyof WorkflowMap>(
|
|
167
|
+
name: Name,
|
|
168
|
+
input: WorkflowMap[Name]['input'],
|
|
169
|
+
options?: { startNode?: string }
|
|
170
|
+
) => Promise<{ runId: string }>
|
|
171
|
+
|
|
172
|
+
type TypedAgentRun = [keyof FlattenedAgentMap] extends [never]
|
|
173
|
+
? (name: string, input: AIAgentInput) => Promise<any>
|
|
174
|
+
: <Name extends keyof FlattenedAgentMap>(
|
|
175
|
+
name: Name,
|
|
176
|
+
input: AIAgentInput
|
|
177
|
+
) => Promise<{ runId: string; result: FlattenedAgentMap[Name]['output']; usage: { inputTokens: number; outputTokens: number } }>
|
|
178
|
+
|
|
179
|
+
type TypedAgentStream = [keyof FlattenedAgentMap] extends [never]
|
|
180
|
+
? (name: string, input: AIAgentInput, options?: { requiresToolApproval?: 'all' | 'explicit' | false }) => Promise<void>
|
|
181
|
+
: <Name extends keyof FlattenedAgentMap>(
|
|
182
|
+
name: Name,
|
|
183
|
+
input: AIAgentInput,
|
|
184
|
+
options?: { requiresToolApproval?: 'all' | 'explicit' | false }
|
|
185
|
+
) => Promise<void>
|
|
186
|
+
|
|
187
|
+
export type TypedPikkuRPC = PikkuRPC<RPCInvoke, RPCRemote, TypedStartWorkflow, TypedAgentRun, TypedAgentStream>
|
|
188
|
+
|