@pikku/addon-ollama 0.1.1 → 0.1.3

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.
Files changed (268) hide show
  1. package/.pikku/addon/pikku-addon-types.gen.ts +105 -0
  2. package/.pikku/addon/pikku-package.gen.ts +11 -0
  3. package/.pikku/agent/pikku-agent-map.gen.d.ts +4 -0
  4. package/.pikku/agent/pikku-agent-types.gen.ts +84 -0
  5. package/.pikku/channel/pikku-channel-types.gen.ts +177 -0
  6. package/.pikku/console/pikku-addon-meta.gen.json +61 -0
  7. package/.pikku/console/pikku-node-types.gen.ts +8 -0
  8. package/.pikku/function/pikku-function-types.gen.ts +797 -0
  9. package/.pikku/function/pikku-functions-meta-verbose.gen.json +126 -0
  10. package/.pikku/function/pikku-functions-meta.gen.json +102 -0
  11. package/.pikku/function/pikku-functions-meta.gen.ts +7 -0
  12. package/.pikku/function/pikku-functions.gen.ts +14 -0
  13. package/.pikku/http/pikku-http-types.gen.ts +119 -0
  14. package/.pikku/mcp/pikku-mcp-types.gen.ts +183 -0
  15. package/.pikku/pikku-bootstrap-scenarios.gen.ts +9 -0
  16. package/.pikku/pikku-bootstrap.gen.ts +8 -0
  17. package/.pikku/pikku-meta-service.gen.ts +10 -0
  18. package/.pikku/pikku-services.gen.ts +50 -0
  19. package/.pikku/pikku-types.gen.ts +24 -0
  20. package/.pikku/queue/pikku-queue-types.gen.ts +27 -0
  21. package/.pikku/rpc/pikku-rpc-wirings-map.gen.d.ts +207 -0
  22. package/.pikku/rpc/pikku-rpc-wirings-map.internal.gen.d.ts +211 -0
  23. package/.pikku/rpc/pikku-rpc-wirings-map.remote.gen.d.ts +207 -0
  24. package/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.json +6 -0
  25. package/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.ts +6 -0
  26. package/.pikku/scenarios/features.gen.json +1 -0
  27. package/.pikku/scenarios/pikku-scenario-functions-meta.gen.json +1 -0
  28. package/.pikku/scenarios/pikku-scenario-functions-meta.gen.ts +12 -0
  29. package/.pikku/scenarios/pikku-scenario-functions.gen.ts +4 -0
  30. package/.pikku/scenarios/pikku-scenario-wirings-meta.gen.ts +15 -0
  31. package/.pikku/scenarios/pikku-scenario-wirings.gen.ts +4 -0
  32. package/.pikku/scenarios/schemas/register.gen.ts +4 -0
  33. package/.pikku/scheduler/pikku-scheduler-types.gen.ts +25 -0
  34. package/.pikku/schemas/register.gen.ts +39 -0
  35. package/.pikku/schemas/schemas/OllamaEmbedInput.schema.json +1 -0
  36. package/.pikku/schemas/schemas/OllamaEmbedManyInput.schema.json +1 -0
  37. package/.pikku/schemas/schemas/OllamaEmbedManyOutput.schema.json +1 -0
  38. package/.pikku/schemas/schemas/OllamaEmbedOutput.schema.json +1 -0
  39. package/.pikku/schemas/schemas/OllamaGenerateObjectInput.schema.json +1 -0
  40. package/.pikku/schemas/schemas/OllamaGenerateObjectOutput.schema.json +1 -0
  41. package/.pikku/schemas/schemas/OllamaGenerateTextInput.schema.json +1 -0
  42. package/.pikku/schemas/schemas/OllamaGenerateTextOutput.schema.json +1 -0
  43. package/.pikku/schemas/schemas/VariableSchema_ollama_base_url.schema.json +1 -0
  44. package/.pikku/scopes/pikku-personas-meta.gen.json +1 -0
  45. package/.pikku/scopes/pikku-personas.gen.ts +52 -0
  46. package/.pikku/scopes/pikku-roles-meta.gen.json +1 -0
  47. package/.pikku/scopes/pikku-roles.gen.ts +41 -0
  48. package/.pikku/scopes/pikku-scope-types.gen.ts +7 -0
  49. package/.pikku/scopes/pikku-scopes-meta.gen.json +1 -0
  50. package/.pikku/scopes/pikku-scopes.gen.ts +58 -0
  51. package/.pikku/secrets/pikku-secret-types.gen.ts +5 -0
  52. package/.pikku/secrets/pikku-secrets-meta.gen.json +1 -0
  53. package/.pikku/secrets/pikku-secrets.gen.ts +34 -0
  54. package/.pikku/trigger/pikku-trigger-types.gen.ts +160 -0
  55. package/.pikku/variables/pikku-variable-types.gen.ts +5 -0
  56. package/.pikku/variables/pikku-variables-meta.gen.json +10 -0
  57. package/.pikku/variables/pikku-variables.gen.ts +36 -0
  58. package/.pikku/workflow/personas.gen.json +1 -0
  59. package/.pikku/workflow/pikku-personas.gen.ts +38 -0
  60. package/.pikku/workflow/pikku-scenario-step-map.gen.d.ts +18 -0
  61. package/.pikku/workflow/pikku-workflow-map.gen.d.ts +38 -0
  62. package/.pikku/workflow/pikku-workflow-types.gen.ts +591 -0
  63. package/.pikku/workflow/pikku-workflow-wirings-meta.gen.ts +9 -0
  64. package/.pikku/workflow/pikku-workflow-wirings.gen.ts +3 -0
  65. package/dist/.pikku/addon/pikku-addon-types.gen.d.ts +4 -4
  66. package/dist/.pikku/addon/pikku-addon-types.gen.d.ts.map +1 -1
  67. package/dist/.pikku/addon/pikku-addon-types.gen.js +7 -3
  68. package/dist/.pikku/addon/pikku-addon-types.gen.js.map +1 -1
  69. package/dist/.pikku/addon/pikku-addon-types.gen.ts +11 -6
  70. package/dist/.pikku/addon/pikku-package.gen.js +2 -1
  71. package/dist/.pikku/addon/pikku-package.gen.js.map +1 -1
  72. package/dist/.pikku/addon/pikku-package.gen.ts +3 -1
  73. package/dist/.pikku/agent/pikku-agent-map.gen.d.ts +2 -14
  74. package/dist/.pikku/agent/pikku-agent-types.gen.d.ts +8 -6
  75. package/dist/.pikku/agent/pikku-agent-types.gen.d.ts.map +1 -1
  76. package/dist/.pikku/agent/pikku-agent-types.gen.js.map +1 -1
  77. package/dist/.pikku/agent/pikku-agent-types.gen.ts +15 -7
  78. package/dist/.pikku/channel/pikku-channel-types.gen.d.ts +112 -0
  79. package/dist/.pikku/channel/pikku-channel-types.gen.d.ts.map +1 -0
  80. package/dist/.pikku/channel/pikku-channel-types.gen.js +60 -0
  81. package/dist/.pikku/channel/pikku-channel-types.gen.js.map +1 -0
  82. package/dist/.pikku/channel/pikku-channel-types.gen.ts +177 -0
  83. package/dist/.pikku/console/pikku-addon-meta.gen.json +31 -28
  84. package/dist/.pikku/console/pikku-node-types.gen.d.ts +1 -1
  85. package/dist/.pikku/console/pikku-node-types.gen.ts +1 -1
  86. package/dist/.pikku/function/pikku-function-types.gen.d.ts +133 -133
  87. package/dist/.pikku/function/pikku-function-types.gen.d.ts.map +1 -1
  88. package/dist/.pikku/function/pikku-function-types.gen.js +98 -61
  89. package/dist/.pikku/function/pikku-function-types.gen.js.map +1 -1
  90. package/dist/.pikku/function/pikku-function-types.gen.ts +268 -157
  91. package/dist/.pikku/function/pikku-functions-meta-verbose.gen.json +64 -44
  92. package/dist/.pikku/function/pikku-functions-meta.gen.js +1 -1
  93. package/dist/.pikku/function/pikku-functions-meta.gen.json +67 -39
  94. package/dist/.pikku/function/pikku-functions-meta.gen.ts +1 -1
  95. package/dist/.pikku/function/pikku-functions.gen.js +2 -2
  96. package/dist/.pikku/function/pikku-functions.gen.js.map +1 -1
  97. package/dist/.pikku/function/pikku-functions.gen.ts +2 -2
  98. package/dist/.pikku/http/pikku-http-types.gen.d.ts +98 -0
  99. package/dist/.pikku/http/pikku-http-types.gen.d.ts.map +1 -0
  100. package/dist/.pikku/http/pikku-http-types.gen.js +50 -0
  101. package/dist/.pikku/http/pikku-http-types.gen.js.map +1 -0
  102. package/dist/.pikku/http/pikku-http-types.gen.ts +119 -0
  103. package/dist/.pikku/mcp/pikku-mcp-types.gen.d.ts +131 -0
  104. package/dist/.pikku/mcp/pikku-mcp-types.gen.d.ts.map +1 -0
  105. package/dist/.pikku/mcp/pikku-mcp-types.gen.js +38 -0
  106. package/dist/.pikku/mcp/pikku-mcp-types.gen.js.map +1 -0
  107. package/dist/.pikku/mcp/pikku-mcp-types.gen.ts +183 -0
  108. package/dist/.pikku/pikku-bootstrap-scenarios.gen.d.ts +10 -0
  109. package/dist/.pikku/pikku-bootstrap-scenarios.gen.d.ts.map +1 -0
  110. package/dist/.pikku/pikku-bootstrap-scenarios.gen.js +10 -0
  111. package/dist/.pikku/pikku-bootstrap-scenarios.gen.js.map +1 -0
  112. package/dist/.pikku/pikku-bootstrap-scenarios.gen.ts +9 -0
  113. package/dist/.pikku/pikku-bootstrap.gen.d.ts +4 -2
  114. package/dist/.pikku/pikku-bootstrap.gen.d.ts.map +1 -1
  115. package/dist/.pikku/pikku-bootstrap.gen.js +2 -10
  116. package/dist/.pikku/pikku-bootstrap.gen.js.map +1 -1
  117. package/dist/.pikku/pikku-bootstrap.gen.ts +2 -9
  118. package/dist/.pikku/pikku-meta-service.gen.d.ts +8 -0
  119. package/dist/.pikku/pikku-meta-service.gen.d.ts.map +1 -0
  120. package/dist/.pikku/pikku-meta-service.gen.js +10 -0
  121. package/dist/.pikku/pikku-meta-service.gen.js.map +1 -0
  122. package/dist/.pikku/pikku-meta-service.gen.ts +10 -0
  123. package/dist/.pikku/pikku-services.gen.d.ts +15 -2
  124. package/dist/.pikku/pikku-services.gen.d.ts.map +1 -1
  125. package/dist/.pikku/pikku-services.gen.js +14 -0
  126. package/dist/.pikku/pikku-services.gen.js.map +1 -1
  127. package/dist/.pikku/pikku-services.gen.ts +17 -2
  128. package/dist/.pikku/pikku-types.gen.d.ts +2 -1
  129. package/dist/.pikku/pikku-types.gen.d.ts.map +1 -1
  130. package/dist/.pikku/pikku-types.gen.js +3 -1
  131. package/dist/.pikku/pikku-types.gen.js.map +1 -1
  132. package/dist/.pikku/pikku-types.gen.ts +4 -1
  133. package/dist/.pikku/queue/pikku-queue-types.gen.d.ts +24 -0
  134. package/dist/.pikku/queue/pikku-queue-types.gen.d.ts.map +1 -0
  135. package/dist/.pikku/queue/pikku-queue-types.gen.js +17 -0
  136. package/dist/.pikku/queue/pikku-queue-types.gen.js.map +1 -0
  137. package/dist/.pikku/queue/pikku-queue-types.gen.ts +27 -0
  138. package/dist/.pikku/rpc/pikku-rpc-wirings-map.gen.d.ts +81 -62
  139. package/dist/.pikku/rpc/pikku-rpc-wirings-map.internal.gen.d.ts +84 -65
  140. package/dist/.pikku/rpc/pikku-rpc-wirings-map.remote.gen.d.ts +207 -0
  141. package/dist/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.d.ts +2 -0
  142. package/dist/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.d.ts.map +1 -0
  143. package/dist/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.js +7 -0
  144. package/dist/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.js.map +1 -0
  145. package/dist/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.json +6 -0
  146. package/dist/.pikku/rpc/pikku-rpc-wirings-meta.internal.gen.ts +6 -0
  147. package/dist/.pikku/scenarios/features.gen.json +1 -0
  148. package/dist/.pikku/scenarios/pikku-scenario-functions-meta.gen.d.ts +2 -0
  149. package/dist/.pikku/scenarios/pikku-scenario-functions-meta.gen.d.ts.map +1 -0
  150. package/dist/.pikku/scenarios/pikku-scenario-functions-meta.gen.js +11 -0
  151. package/dist/.pikku/scenarios/pikku-scenario-functions-meta.gen.js.map +1 -0
  152. package/dist/.pikku/scenarios/pikku-scenario-functions-meta.gen.json +1 -0
  153. package/dist/.pikku/scenarios/pikku-scenario-functions-meta.gen.ts +12 -0
  154. package/dist/.pikku/scenarios/pikku-scenario-functions.gen.d.ts +5 -0
  155. package/dist/.pikku/scenarios/pikku-scenario-functions.gen.d.ts.map +1 -0
  156. package/dist/.pikku/scenarios/pikku-scenario-functions.gen.js +2 -0
  157. package/dist/.pikku/scenarios/pikku-scenario-functions.gen.js.map +1 -0
  158. package/dist/.pikku/scenarios/pikku-scenario-functions.gen.ts +4 -0
  159. package/dist/.pikku/scenarios/pikku-scenario-wirings-meta.gen.d.ts +2 -0
  160. package/dist/.pikku/scenarios/pikku-scenario-wirings-meta.gen.d.ts.map +1 -0
  161. package/dist/.pikku/scenarios/pikku-scenario-wirings-meta.gen.js +11 -0
  162. package/dist/.pikku/scenarios/pikku-scenario-wirings-meta.gen.js.map +1 -0
  163. package/dist/.pikku/scenarios/pikku-scenario-wirings-meta.gen.ts +15 -0
  164. package/dist/.pikku/scenarios/pikku-scenario-wirings.gen.d.ts +5 -0
  165. package/dist/.pikku/scenarios/pikku-scenario-wirings.gen.d.ts.map +1 -0
  166. package/dist/.pikku/scenarios/pikku-scenario-wirings.gen.js +2 -0
  167. package/dist/.pikku/scenarios/pikku-scenario-wirings.gen.js.map +1 -0
  168. package/dist/.pikku/scenarios/pikku-scenario-wirings.gen.ts +4 -0
  169. package/dist/.pikku/scenarios/schemas/register.gen.d.ts +5 -0
  170. package/dist/.pikku/scenarios/schemas/register.gen.d.ts.map +1 -0
  171. package/dist/.pikku/scenarios/schemas/register.gen.js +5 -0
  172. package/dist/.pikku/scenarios/schemas/register.gen.js.map +1 -0
  173. package/dist/.pikku/scenarios/schemas/register.gen.ts +4 -0
  174. package/dist/.pikku/scheduler/pikku-scheduler-types.gen.d.ts +22 -0
  175. package/dist/.pikku/scheduler/pikku-scheduler-types.gen.d.ts.map +1 -0
  176. package/dist/.pikku/scheduler/pikku-scheduler-types.gen.js +17 -0
  177. package/dist/.pikku/scheduler/pikku-scheduler-types.gen.js.map +1 -0
  178. package/dist/.pikku/scheduler/pikku-scheduler-types.gen.ts +25 -0
  179. package/dist/.pikku/schemas/register.gen.js +11 -11
  180. package/dist/.pikku/schemas/register.gen.js.map +1 -1
  181. package/dist/.pikku/schemas/register.gen.ts +17 -17
  182. package/dist/.pikku/scopes/pikku-personas-meta.gen.json +1 -0
  183. package/dist/.pikku/scopes/pikku-personas.gen.d.ts +37 -0
  184. package/dist/.pikku/scopes/pikku-personas.gen.d.ts.map +1 -0
  185. package/dist/.pikku/scopes/pikku-personas.gen.js +18 -0
  186. package/dist/.pikku/scopes/pikku-personas.gen.js.map +1 -0
  187. package/dist/.pikku/scopes/pikku-personas.gen.ts +52 -0
  188. package/dist/.pikku/scopes/pikku-roles-meta.gen.json +1 -0
  189. package/dist/.pikku/scopes/pikku-roles.gen.d.ts +31 -0
  190. package/dist/.pikku/scopes/pikku-roles.gen.d.ts.map +1 -0
  191. package/dist/.pikku/scopes/pikku-roles.gen.js +19 -0
  192. package/dist/.pikku/scopes/pikku-roles.gen.js.map +1 -0
  193. package/dist/.pikku/scopes/pikku-roles.gen.ts +41 -0
  194. package/dist/.pikku/scopes/pikku-scope-types.gen.d.ts +8 -0
  195. package/dist/.pikku/scopes/pikku-scope-types.gen.d.ts.map +1 -0
  196. package/dist/.pikku/scopes/pikku-scope-types.gen.js +6 -0
  197. package/dist/.pikku/scopes/pikku-scope-types.gen.js.map +1 -0
  198. package/dist/.pikku/scopes/pikku-scope-types.gen.ts +7 -0
  199. package/dist/.pikku/scopes/pikku-scopes-meta.gen.json +1 -0
  200. package/dist/.pikku/scopes/pikku-scopes.gen.d.ts +36 -0
  201. package/dist/.pikku/scopes/pikku-scopes.gen.d.ts.map +1 -0
  202. package/dist/.pikku/scopes/pikku-scopes.gen.js +28 -0
  203. package/dist/.pikku/scopes/pikku-scopes.gen.js.map +1 -0
  204. package/dist/.pikku/scopes/pikku-scopes.gen.ts +58 -0
  205. package/dist/.pikku/secrets/pikku-secret-types.gen.d.ts +2 -2
  206. package/dist/.pikku/secrets/pikku-secret-types.gen.d.ts.map +1 -1
  207. package/dist/.pikku/secrets/pikku-secret-types.gen.js +2 -2
  208. package/dist/.pikku/secrets/pikku-secret-types.gen.js.map +1 -1
  209. package/dist/.pikku/secrets/pikku-secret-types.gen.ts +2 -2
  210. package/dist/.pikku/secrets/pikku-secrets.gen.d.ts +11 -1
  211. package/dist/.pikku/secrets/pikku-secrets.gen.d.ts.map +1 -1
  212. package/dist/.pikku/secrets/pikku-secrets.gen.js +11 -1
  213. package/dist/.pikku/secrets/pikku-secrets.gen.js.map +1 -1
  214. package/dist/.pikku/secrets/pikku-secrets.gen.ts +14 -1
  215. package/dist/.pikku/trigger/pikku-trigger-types.gen.d.ts +1 -1
  216. package/dist/.pikku/trigger/pikku-trigger-types.gen.js +1 -1
  217. package/dist/.pikku/trigger/pikku-trigger-types.gen.ts +1 -1
  218. package/dist/.pikku/variables/pikku-variable-types.gen.d.ts +2 -2
  219. package/dist/.pikku/variables/pikku-variable-types.gen.d.ts.map +1 -1
  220. package/dist/.pikku/variables/pikku-variable-types.gen.js +2 -2
  221. package/dist/.pikku/variables/pikku-variable-types.gen.js.map +1 -1
  222. package/dist/.pikku/variables/pikku-variable-types.gen.ts +2 -2
  223. package/dist/.pikku/variables/pikku-variables.gen.d.ts +11 -1
  224. package/dist/.pikku/variables/pikku-variables.gen.d.ts.map +1 -1
  225. package/dist/.pikku/variables/pikku-variables.gen.js +14 -4
  226. package/dist/.pikku/variables/pikku-variables.gen.js.map +1 -1
  227. package/dist/.pikku/variables/pikku-variables.gen.ts +17 -4
  228. package/dist/.pikku/workflow/personas.gen.json +1 -0
  229. package/dist/.pikku/workflow/pikku-personas.gen.d.ts +16 -0
  230. package/dist/.pikku/workflow/pikku-personas.gen.d.ts.map +1 -0
  231. package/dist/.pikku/workflow/pikku-personas.gen.js +18 -0
  232. package/dist/.pikku/workflow/pikku-personas.gen.js.map +1 -0
  233. package/dist/.pikku/workflow/pikku-personas.gen.ts +38 -0
  234. package/dist/.pikku/workflow/pikku-scenario-step-map.gen.d.ts +18 -0
  235. package/dist/.pikku/workflow/pikku-workflow-map.gen.d.ts +9 -5
  236. package/dist/.pikku/workflow/pikku-workflow-types.gen.d.ts +289 -31
  237. package/dist/.pikku/workflow/pikku-workflow-types.gen.d.ts.map +1 -1
  238. package/dist/.pikku/workflow/pikku-workflow-types.gen.js +66 -18
  239. package/dist/.pikku/workflow/pikku-workflow-types.gen.js.map +1 -1
  240. package/dist/.pikku/workflow/pikku-workflow-types.gen.ts +494 -61
  241. package/dist/.pikku/workflow/pikku-workflow-wirings-meta.gen.js +1 -1
  242. package/dist/.pikku/workflow/pikku-workflow-wirings-meta.gen.js.map +1 -1
  243. package/dist/.pikku/workflow/pikku-workflow-wirings-meta.gen.ts +3 -3
  244. package/dist/.pikku/workflow/pikku-workflow-wirings.gen.d.ts +1 -1
  245. package/dist/.pikku/workflow/pikku-workflow-wirings.gen.js +1 -1
  246. package/dist/.pikku/workflow/pikku-workflow-wirings.gen.ts +1 -1
  247. package/dist/src/functions/embeddings/embed-many.function.d.ts +2 -2
  248. package/dist/src/functions/embeddings/embed-many.function.d.ts.map +1 -1
  249. package/dist/src/functions/embeddings/embed.function.d.ts +2 -2
  250. package/dist/src/functions/embeddings/embed.function.d.ts.map +1 -1
  251. package/dist/src/functions/text/generate-object.function.d.ts +7 -7
  252. package/dist/src/functions/text/generate-object.function.d.ts.map +1 -1
  253. package/dist/src/functions/text/generate.function.d.ts +2 -2
  254. package/dist/src/functions/text/generate.function.d.ts.map +1 -1
  255. package/dist/src/ollama.variable.js +2 -2
  256. package/dist/src/ollama.variable.js.map +1 -1
  257. package/package.json +7 -6
  258. package/dist/.pikku/agent/pikku-agent-wirings-meta.gen.d.ts +0 -2
  259. package/dist/.pikku/agent/pikku-agent-wirings-meta.gen.d.ts.map +0 -1
  260. package/dist/.pikku/agent/pikku-agent-wirings-meta.gen.js +0 -7
  261. package/dist/.pikku/agent/pikku-agent-wirings-meta.gen.js.map +0 -1
  262. package/dist/.pikku/agent/pikku-agent-wirings-meta.gen.json +0 -3
  263. package/dist/.pikku/agent/pikku-agent-wirings-meta.gen.ts +0 -7
  264. package/dist/.pikku/agent/pikku-agent-wirings.gen.d.ts +0 -5
  265. package/dist/.pikku/agent/pikku-agent-wirings.gen.d.ts.map +0 -1
  266. package/dist/.pikku/agent/pikku-agent-wirings.gen.js +0 -5
  267. package/dist/.pikku/agent/pikku-agent-wirings.gen.js.map +0 -1
  268. package/dist/.pikku/agent/pikku-agent-wirings.gen.ts +0 -3
@@ -1,106 +1,126 @@
1
1
  {
2
- "ollamaGenerateText": {
3
- "pikkuFuncId": "ollamaGenerateText",
2
+ "ollamaEmbedMany": {
3
+ "pikkuFuncId": "ollamaEmbedMany",
4
4
  "functionType": "user",
5
5
  "funcWrapper": "pikkuSessionlessFunc",
6
6
  "sessionless": true,
7
- "name": "ollamaGenerateText",
7
+ "name": "ollamaEmbedMany",
8
8
  "services": {
9
9
  "optimized": true,
10
10
  "services": [
11
11
  "ollama"
12
12
  ]
13
13
  },
14
- "inputSchemaName": "OllamaGenerateTextInput",
15
- "outputSchemaName": "OllamaGenerateTextOutput",
14
+ "inputSchemaName": "OllamaEmbedManyInput",
15
+ "outputSchemaName": "OllamaEmbedManyOutput",
16
16
  "inputs": [
17
- "OllamaGenerateTextInput"
17
+ "OllamaEmbedManyInput"
18
18
  ],
19
19
  "outputs": [
20
- "OllamaGenerateTextOutput"
20
+ "OllamaEmbedManyOutput"
21
21
  ],
22
- "description": "Generate text using an Ollama model",
22
+ "implementationHash": "2abe1562dff3ca44",
23
+ "description": "Create embedding vectors from multiple texts using an Ollama model",
23
24
  "isDirectFunction": false,
24
- "contractHash": "0d03988593f9adef",
25
- "inputHash": "bdf047a6",
26
- "outputHash": "4e2c22b3"
25
+ "sourceFile": "/home/runner/work/addons/addons/packages/ai/ollama/src/functions/embeddings/embed-many.function.ts",
26
+ "exportedName": "ollamaEmbedMany",
27
+ "bodyStart": 27,
28
+ "bodyEnd": 34,
29
+ "contractHash": "3db02092482ca9c6",
30
+ "inputHash": "4f6f4b67",
31
+ "outputHash": "54a0cfe3"
27
32
  },
28
- "ollamaGenerateObject": {
29
- "pikkuFuncId": "ollamaGenerateObject",
33
+ "ollamaEmbed": {
34
+ "pikkuFuncId": "ollamaEmbed",
30
35
  "functionType": "user",
31
36
  "funcWrapper": "pikkuSessionlessFunc",
32
37
  "sessionless": true,
33
- "name": "ollamaGenerateObject",
38
+ "name": "ollamaEmbed",
34
39
  "services": {
35
40
  "optimized": true,
36
41
  "services": [
37
42
  "ollama"
38
43
  ]
39
44
  },
40
- "inputSchemaName": "OllamaGenerateObjectInput",
41
- "outputSchemaName": "OllamaGenerateObjectOutput",
45
+ "inputSchemaName": "OllamaEmbedInput",
46
+ "outputSchemaName": "OllamaEmbedOutput",
42
47
  "inputs": [
43
- "OllamaGenerateObjectInput"
48
+ "OllamaEmbedInput"
44
49
  ],
45
50
  "outputs": [
46
- "OllamaGenerateObjectOutput"
51
+ "OllamaEmbedOutput"
47
52
  ],
48
- "description": "Generate a structured JSON object using an Ollama model",
53
+ "implementationHash": "ac6fc8ad50940ac6",
54
+ "description": "Create an embedding vector from text using an Ollama model",
49
55
  "isDirectFunction": false,
50
- "contractHash": "e7026856e15a96b5",
51
- "inputHash": "4ceb54b7",
52
- "outputHash": "e26f98ba"
56
+ "sourceFile": "/home/runner/work/addons/addons/packages/ai/ollama/src/functions/embeddings/embed.function.ts",
57
+ "exportedName": "ollamaEmbed",
58
+ "bodyStart": 27,
59
+ "bodyEnd": 34,
60
+ "contractHash": "0354ea934b747af7",
61
+ "inputHash": "8340c2c0",
62
+ "outputHash": "bb88b854"
53
63
  },
54
- "ollamaEmbed": {
55
- "pikkuFuncId": "ollamaEmbed",
64
+ "ollamaGenerateObject": {
65
+ "pikkuFuncId": "ollamaGenerateObject",
56
66
  "functionType": "user",
57
67
  "funcWrapper": "pikkuSessionlessFunc",
58
68
  "sessionless": true,
59
- "name": "ollamaEmbed",
69
+ "name": "ollamaGenerateObject",
60
70
  "services": {
61
71
  "optimized": true,
62
72
  "services": [
63
73
  "ollama"
64
74
  ]
65
75
  },
66
- "inputSchemaName": "OllamaEmbedInput",
67
- "outputSchemaName": "OllamaEmbedOutput",
76
+ "inputSchemaName": "OllamaGenerateObjectInput",
77
+ "outputSchemaName": "OllamaGenerateObjectOutput",
68
78
  "inputs": [
69
- "OllamaEmbedInput"
79
+ "OllamaGenerateObjectInput"
70
80
  ],
71
81
  "outputs": [
72
- "OllamaEmbedOutput"
82
+ "OllamaGenerateObjectOutput"
73
83
  ],
74
- "description": "Create an embedding vector from text using an Ollama model",
84
+ "implementationHash": "267ece83350ede19",
85
+ "description": "Generate a structured JSON object using an Ollama model",
75
86
  "isDirectFunction": false,
76
- "contractHash": "0354ea934b747af7",
77
- "inputHash": "8340c2c0",
78
- "outputHash": "bb88b854"
87
+ "sourceFile": "/home/runner/work/addons/addons/packages/ai/ollama/src/functions/text/generate-object.function.ts",
88
+ "exportedName": "ollamaGenerateObject",
89
+ "bodyStart": 44,
90
+ "bodyEnd": 60,
91
+ "contractHash": "e7026856e15a96b5",
92
+ "inputHash": "4ceb54b7",
93
+ "outputHash": "e26f98ba"
79
94
  },
80
- "ollamaEmbedMany": {
81
- "pikkuFuncId": "ollamaEmbedMany",
95
+ "ollamaGenerateText": {
96
+ "pikkuFuncId": "ollamaGenerateText",
82
97
  "functionType": "user",
83
98
  "funcWrapper": "pikkuSessionlessFunc",
84
99
  "sessionless": true,
85
- "name": "ollamaEmbedMany",
100
+ "name": "ollamaGenerateText",
86
101
  "services": {
87
102
  "optimized": true,
88
103
  "services": [
89
104
  "ollama"
90
105
  ]
91
106
  },
92
- "inputSchemaName": "OllamaEmbedManyInput",
93
- "outputSchemaName": "OllamaEmbedManyOutput",
107
+ "inputSchemaName": "OllamaGenerateTextInput",
108
+ "outputSchemaName": "OllamaGenerateTextOutput",
94
109
  "inputs": [
95
- "OllamaEmbedManyInput"
110
+ "OllamaGenerateTextInput"
96
111
  ],
97
112
  "outputs": [
98
- "OllamaEmbedManyOutput"
113
+ "OllamaGenerateTextOutput"
99
114
  ],
100
- "description": "Create embedding vectors from multiple texts using an Ollama model",
115
+ "implementationHash": "24061cbafdbafa6a",
116
+ "description": "Generate text using an Ollama model",
101
117
  "isDirectFunction": false,
102
- "contractHash": "3db02092482ca9c6",
103
- "inputHash": "4f6f4b67",
104
- "outputHash": "54a0cfe3"
118
+ "sourceFile": "/home/runner/work/addons/addons/packages/ai/ollama/src/functions/text/generate.function.ts",
119
+ "exportedName": "ollamaGenerateText",
120
+ "bodyStart": 42,
121
+ "bodyEnd": 56,
122
+ "contractHash": "0d03988593f9adef",
123
+ "inputHash": "bdf047a6",
124
+ "outputHash": "4e2c22b3"
105
125
  }
106
126
  }
@@ -1,5 +1,5 @@
1
1
  /**
2
- * This file was generated by @pikku/cli@0.12.6
2
+ * This file was generated by @pikku/cli@0.12.96
3
3
  */
4
4
  import { pikkuState } from '@pikku/core/internal';
5
5
  import metaData from './pikku-functions-meta.gen.json' with { type: 'json' };
@@ -1,39 +1,28 @@
1
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",
2
+ "ollamaEmbedMany": {
3
+ "pikkuFuncId": "ollamaEmbedMany",
22
4
  "functionType": "user",
23
5
  "funcWrapper": "pikkuSessionlessFunc",
24
6
  "sessionless": true,
25
- "name": "ollamaGenerateObject",
26
- "inputSchemaName": "OllamaGenerateObjectInput",
27
- "outputSchemaName": "OllamaGenerateObjectOutput",
7
+ "name": "ollamaEmbedMany",
8
+ "inputSchemaName": "OllamaEmbedManyInput",
9
+ "outputSchemaName": "OllamaEmbedManyOutput",
28
10
  "inputs": [
29
- "OllamaGenerateObjectInput"
11
+ "OllamaEmbedManyInput"
30
12
  ],
31
13
  "outputs": [
32
- "OllamaGenerateObjectOutput"
14
+ "OllamaEmbedManyOutput"
33
15
  ],
34
- "contractHash": "e7026856e15a96b5",
35
- "inputHash": "4ceb54b7",
36
- "outputHash": "e26f98ba"
16
+ "implementationHash": "2abe1562dff3ca44",
17
+ "contractHash": "3db02092482ca9c6",
18
+ "inputHash": "4f6f4b67",
19
+ "outputHash": "54a0cfe3",
20
+ "services": {
21
+ "optimized": true,
22
+ "services": [
23
+ "ollama"
24
+ ]
25
+ }
37
26
  },
38
27
  "ollamaEmbed": {
39
28
  "pikkuFuncId": "ollamaEmbed",
@@ -49,26 +38,65 @@
49
38
  "outputs": [
50
39
  "OllamaEmbedOutput"
51
40
  ],
41
+ "implementationHash": "ac6fc8ad50940ac6",
52
42
  "contractHash": "0354ea934b747af7",
53
43
  "inputHash": "8340c2c0",
54
- "outputHash": "bb88b854"
44
+ "outputHash": "bb88b854",
45
+ "services": {
46
+ "optimized": true,
47
+ "services": [
48
+ "ollama"
49
+ ]
50
+ }
55
51
  },
56
- "ollamaEmbedMany": {
57
- "pikkuFuncId": "ollamaEmbedMany",
52
+ "ollamaGenerateObject": {
53
+ "pikkuFuncId": "ollamaGenerateObject",
58
54
  "functionType": "user",
59
55
  "funcWrapper": "pikkuSessionlessFunc",
60
56
  "sessionless": true,
61
- "name": "ollamaEmbedMany",
62
- "inputSchemaName": "OllamaEmbedManyInput",
63
- "outputSchemaName": "OllamaEmbedManyOutput",
57
+ "name": "ollamaGenerateObject",
58
+ "inputSchemaName": "OllamaGenerateObjectInput",
59
+ "outputSchemaName": "OllamaGenerateObjectOutput",
64
60
  "inputs": [
65
- "OllamaEmbedManyInput"
61
+ "OllamaGenerateObjectInput"
66
62
  ],
67
63
  "outputs": [
68
- "OllamaEmbedManyOutput"
64
+ "OllamaGenerateObjectOutput"
69
65
  ],
70
- "contractHash": "3db02092482ca9c6",
71
- "inputHash": "4f6f4b67",
72
- "outputHash": "54a0cfe3"
66
+ "implementationHash": "267ece83350ede19",
67
+ "contractHash": "e7026856e15a96b5",
68
+ "inputHash": "4ceb54b7",
69
+ "outputHash": "e26f98ba",
70
+ "services": {
71
+ "optimized": true,
72
+ "services": [
73
+ "ollama"
74
+ ]
75
+ }
76
+ },
77
+ "ollamaGenerateText": {
78
+ "pikkuFuncId": "ollamaGenerateText",
79
+ "functionType": "user",
80
+ "funcWrapper": "pikkuSessionlessFunc",
81
+ "sessionless": true,
82
+ "name": "ollamaGenerateText",
83
+ "inputSchemaName": "OllamaGenerateTextInput",
84
+ "outputSchemaName": "OllamaGenerateTextOutput",
85
+ "inputs": [
86
+ "OllamaGenerateTextInput"
87
+ ],
88
+ "outputs": [
89
+ "OllamaGenerateTextOutput"
90
+ ],
91
+ "implementationHash": "24061cbafdbafa6a",
92
+ "contractHash": "0d03988593f9adef",
93
+ "inputHash": "bdf047a6",
94
+ "outputHash": "4e2c22b3",
95
+ "services": {
96
+ "optimized": true,
97
+ "services": [
98
+ "ollama"
99
+ ]
100
+ }
73
101
  }
74
102
  }
@@ -1,5 +1,5 @@
1
1
  /**
2
- * This file was generated by @pikku/cli@0.12.6
2
+ * This file was generated by @pikku/cli@0.12.96
3
3
  */
4
4
  import { pikkuState } from '@pikku/core/internal'
5
5
  import type { FunctionsMeta } from '@pikku/core'
@@ -1,8 +1,8 @@
1
1
  /**
2
- * This file was generated by @pikku/cli@0.12.6
2
+ * This file was generated by @pikku/cli@0.12.96
3
3
  */
4
4
  /* Import and register functions used by RPCs */
5
- import { addFunction } from '@pikku/core';
5
+ import { addFunction } from '@pikku/core/function';
6
6
  import { ollamaEmbed } from '../../src/functions/embeddings/embed.function.js';
7
7
  import { ollamaEmbedMany } from '../../src/functions/embeddings/embed-many.function.js';
8
8
  import { ollamaGenerateObject } from '../../src/functions/text/generate-object.function.js';
@@ -1 +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"}
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,sBAAsB,CAAA;AAClD,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"}
@@ -1,8 +1,8 @@
1
1
  /**
2
- * This file was generated by @pikku/cli@0.12.6
2
+ * This file was generated by @pikku/cli@0.12.96
3
3
  */
4
4
  /* Import and register functions used by RPCs */
5
- import { addFunction } from '@pikku/core'
5
+ import { addFunction } from '@pikku/core/function'
6
6
  import { ollamaEmbed } from '../../src/functions/embeddings/embed.function.js'
7
7
  import { ollamaEmbedMany } from '../../src/functions/embeddings/embed-many.function.js'
8
8
  import { ollamaGenerateObject } from '../../src/functions/text/generate-object.function.js'
@@ -0,0 +1,98 @@
1
+ /**
2
+ * This file was generated by @pikku/cli@0.12.96
3
+ */
4
+ /**
5
+ * HTTP-specific type definitions for tree-shaking optimization
6
+ */
7
+ import { AssertHTTPWiringParams } from '@pikku/core/http';
8
+ import type { PikkuFunction, PikkuFunctionSessionless, PikkuPermission, PikkuMiddleware, PikkuFunctionConfig } from '../function/pikku-function-types.gen.js';
9
+ import type { CoreHTTPFunctionWiring, HTTPMethod, HTTPRouteBaseConfig } from '@pikku/core/http';
10
+ /**
11
+ * Type definition for HTTP API wirings with type-safe path parameters.
12
+ * Supports both authenticated and unauthenticated functions.
13
+ *
14
+ * @template In - Input type for the HTTP wiring
15
+ * @template Out - Output type for the HTTP wiring
16
+ * @template Route - String literal type for the HTTP path (e.g., "/users/:id")
17
+ */
18
+ type HTTPWiring<In, Out, Route extends string> = CoreHTTPFunctionWiring<In, Out, Route, PikkuFunction<In, Out, 'rpc' | 'session'>, PikkuFunctionSessionless<In, Out, 'rpc' | 'session'>, PikkuPermission<In>, PikkuMiddleware>;
19
+ /**
20
+ * Registers an HTTP wiring with the Pikku framework.
21
+ *
22
+ * @template In - Input type for the HTTP wiring
23
+ * @template Out - Output type for the HTTP wiring
24
+ * @template Route - String literal type for the HTTP path (e.g., "/users/:id")
25
+ * @param httpWiring - HTTP wiring definition with handler, method, and optional middleware
26
+ */
27
+ export declare const wireHTTP: <In, Out, Route extends string>(httpWiring: HTTPWiring<In, Out, Route> & AssertHTTPWiringParams<In, Route>) => void;
28
+ /**
29
+ * Registers HTTP middleware either globally or for a specific route pattern.
30
+ *
31
+ * When a string route pattern is provided along with middleware, the middleware
32
+ * is applied only to that route. Otherwise, if an array is provided, it is treated
33
+ * as global middleware (applied to all routes).
34
+ *
35
+ * @param routeOrMiddleware - Either a global middleware array or a route pattern string
36
+ * @param middleware - The middleware array to apply when a route pattern is specified
37
+ *
38
+ * @example
39
+ * ```typescript
40
+ * // Add global HTTP middleware
41
+ * addHTTPMiddleware([authMiddleware, loggingMiddleware])
42
+ *
43
+ * // Add route-specific middleware
44
+ * addHTTPMiddleware('/api/admin/*', [adminAuthMiddleware])
45
+ * ```
46
+ */
47
+ export declare const addHTTPMiddleware: (routeOrMiddleware: PikkuMiddleware[] | string, middleware?: PikkuMiddleware[]) => void;
48
+ /**
49
+ * Route configuration for wireHTTPRoutes with proper typing
50
+ */
51
+ type HTTPRouteConfig = HTTPRouteBaseConfig & {
52
+ method: HTTPMethod;
53
+ route: string;
54
+ func: PikkuFunctionConfig<any, any, any, any, any, any>;
55
+ auth?: boolean;
56
+ middleware?: PikkuMiddleware[];
57
+ sse?: boolean;
58
+ };
59
+ /**
60
+ * Typed route map for wireHTTPRoutes
61
+ */
62
+ type TypedHTTPRouteMap = {
63
+ [key: string]: HTTPRouteConfig | TypedHTTPRouteMap | TypedHTTPRouteContract;
64
+ };
65
+ /**
66
+ * Typed route contract for defineHTTPRoutes
67
+ */
68
+ type TypedHTTPRouteContract<T extends TypedHTTPRouteMap = TypedHTTPRouteMap> = TypedHTTPRoutesGroupConfig & {
69
+ routes: T;
70
+ };
71
+ /**
72
+ * Group config with typed middleware
73
+ */
74
+ type TypedHTTPRoutesGroupConfig = {
75
+ basePath?: string;
76
+ tags?: string[];
77
+ auth?: boolean;
78
+ middleware?: PikkuMiddleware[];
79
+ };
80
+ /**
81
+ * Full config for wireHTTPRoutes
82
+ */
83
+ type TypedWireHTTPRoutesConfig = TypedHTTPRoutesGroupConfig & {
84
+ routes: TypedHTTPRouteMap | HTTPRouteConfig[];
85
+ };
86
+ /**
87
+ * Type-safe helper for defining route contracts that can be composed.
88
+ */
89
+ export declare function defineHTTPRoutes<T extends TypedHTTPRouteMap>(routes: T): TypedHTTPRouteContract<T>;
90
+ export declare function defineHTTPRoutes<T extends TypedHTTPRouteMap>(config: TypedHTTPRoutesGroupConfig & {
91
+ routes: T;
92
+ }): TypedHTTPRouteContract<T>;
93
+ /**
94
+ * Wires multiple HTTP routes from a nested map or array configuration.
95
+ */
96
+ export declare const wireHTTPRoutes: (config: TypedWireHTTPRoutesConfig) => void;
97
+ export {};
98
+ //# sourceMappingURL=pikku-http-types.gen.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"pikku-http-types.gen.d.ts","sourceRoot":"","sources":["../../../.pikku/http/pikku-http-types.gen.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;GAEG;AAEH,OAAO,EAAE,sBAAsB,EAAwJ,MAAM,kBAAkB,CAAA;AAC/M,OAAO,KAAK,EAAE,aAAa,EAAE,wBAAwB,EAAE,eAAe,EAAE,eAAe,EAAE,mBAAmB,EAAE,MAAM,yCAAyC,CAAA;AAC7J,OAAO,KAAK,EAAE,sBAAsB,EAAE,UAAU,EAAE,mBAAmB,EAAE,MAAM,kBAAkB,CAAA;AAE/F;;;;;;;GAOG;AACH,KAAK,UAAU,CAAC,EAAE,EAAE,GAAG,EAAE,KAAK,SAAS,MAAM,IAAI,sBAAsB,CAAC,EAAE,EAAE,GAAG,EAAE,KAAK,EAAE,aAAa,CAAC,EAAE,EAAE,GAAG,EAAE,KAAK,GAAG,SAAS,CAAC,EAAE,wBAAwB,CAAC,EAAE,EAAE,GAAG,EAAE,KAAK,GAAG,SAAS,CAAC,EAAE,eAAe,CAAC,EAAE,CAAC,EAAE,eAAe,CAAC,CAAA;AAE9N;;;;;;;GAOG;AACH,eAAO,MAAM,QAAQ,GAAI,EAAE,EAAE,GAAG,EAAE,KAAK,SAAS,MAAM,EACpD,YAAY,UAAU,CAAC,EAAE,EAAE,GAAG,EAAE,KAAK,CAAC,GAAG,sBAAsB,CAAC,EAAE,EAAE,KAAK,CAAC,SAG3E,CAAA;AAED;;;;;;;;;;;;;;;;;;GAkBG;AACH,eAAO,MAAM,iBAAiB,GAC5B,mBAAmB,eAAe,EAAE,GAAG,MAAM,EAC7C,aAAa,eAAe,EAAE,SAG/B,CAAA;AAED;;GAEG;AACH,KAAK,eAAe,GAAG,mBAAmB,GAAG;IAC3C,MAAM,EAAE,UAAU,CAAA;IAClB,KAAK,EAAE,MAAM,CAAA;IACb,IAAI,EAAE,mBAAmB,CAAC,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,EAAE,GAAG,CAAC,CAAA;IACvD,IAAI,CAAC,EAAE,OAAO,CAAA;IACd,UAAU,CAAC,EAAE,eAAe,EAAE,CAAA;IAC9B,GAAG,CAAC,EAAE,OAAO,CAAA;CACd,CAAA;AAED;;GAEG;AACH,KAAK,iBAAiB,GAAG;IACvB,CAAC,GAAG,EAAE,MAAM,GAAG,eAAe,GAAG,iBAAiB,GAAG,sBAAsB,CAAA;CAC5E,CAAA;AAED;;GAEG;AACH,KAAK,sBAAsB,CAAC,CAAC,SAAS,iBAAiB,GAAG,iBAAiB,IAAI,0BAA0B,GAAG;IAC1G,MAAM,EAAE,CAAC,CAAA;CACV,CAAA;AAED;;GAEG;AACH,KAAK,0BAA0B,GAAG;IAChC,QAAQ,CAAC,EAAE,MAAM,CAAA;IACjB,IAAI,CAAC,EAAE,MAAM,EAAE,CAAA;IACf,IAAI,CAAC,EAAE,OAAO,CAAA;IACd,UAAU,CAAC,EAAE,eAAe,EAAE,CAAA;CAC/B,CAAA;AAED;;GAEG;AACH,KAAK,yBAAyB,GAAG,0BAA0B,GAAG;IAC5D,MAAM,EAAE,iBAAiB,GAAG,eAAe,EAAE,CAAA;CAC9C,CAAA;AAED;;GAEG;AACH,wBAAgB,gBAAgB,CAAC,CAAC,SAAS,iBAAiB,EAAE,MAAM,EAAE,CAAC,GAAG,sBAAsB,CAAC,CAAC,CAAC,CAAA;AACnG,wBAAgB,gBAAgB,CAAC,CAAC,SAAS,iBAAiB,EAAE,MAAM,EAAE,0BAA0B,GAAG;IAAE,MAAM,EAAE,CAAC,CAAA;CAAE,GAAG,sBAAsB,CAAC,CAAC,CAAC,CAAA;AAK5I;;GAEG;AACH,eAAO,MAAM,cAAc,GAAI,QAAQ,yBAAyB,KAAG,IAElE,CAAA"}
@@ -0,0 +1,50 @@
1
+ /**
2
+ * This file was generated by @pikku/cli@0.12.96
3
+ */
4
+ /**
5
+ * HTTP-specific type definitions for tree-shaking optimization
6
+ */
7
+ import { wireHTTP as wireHTTPCore, addHTTPMiddleware as addHTTPMiddlewareCore, wireHTTPRoutes as wireHTTPRoutesCore, defineHTTPRoutes as defineHTTPRoutesCore } from '@pikku/core/http';
8
+ /**
9
+ * Registers an HTTP wiring with the Pikku framework.
10
+ *
11
+ * @template In - Input type for the HTTP wiring
12
+ * @template Out - Output type for the HTTP wiring
13
+ * @template Route - String literal type for the HTTP path (e.g., "/users/:id")
14
+ * @param httpWiring - HTTP wiring definition with handler, method, and optional middleware
15
+ */
16
+ export const wireHTTP = (httpWiring) => {
17
+ wireHTTPCore(httpWiring);
18
+ };
19
+ /**
20
+ * Registers HTTP middleware either globally or for a specific route pattern.
21
+ *
22
+ * When a string route pattern is provided along with middleware, the middleware
23
+ * is applied only to that route. Otherwise, if an array is provided, it is treated
24
+ * as global middleware (applied to all routes).
25
+ *
26
+ * @param routeOrMiddleware - Either a global middleware array or a route pattern string
27
+ * @param middleware - The middleware array to apply when a route pattern is specified
28
+ *
29
+ * @example
30
+ * ```typescript
31
+ * // Add global HTTP middleware
32
+ * addHTTPMiddleware([authMiddleware, loggingMiddleware])
33
+ *
34
+ * // Add route-specific middleware
35
+ * addHTTPMiddleware('/api/admin/*', [adminAuthMiddleware])
36
+ * ```
37
+ */
38
+ export const addHTTPMiddleware = (routeOrMiddleware, middleware) => {
39
+ addHTTPMiddlewareCore(routeOrMiddleware, middleware);
40
+ };
41
+ export function defineHTTPRoutes(configOrRoutes) {
42
+ return defineHTTPRoutesCore(configOrRoutes);
43
+ }
44
+ /**
45
+ * Wires multiple HTTP routes from a nested map or array configuration.
46
+ */
47
+ export const wireHTTPRoutes = (config) => {
48
+ wireHTTPRoutesCore(config);
49
+ };
50
+ //# sourceMappingURL=pikku-http-types.gen.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"pikku-http-types.gen.js","sourceRoot":"","sources":["../../../.pikku/http/pikku-http-types.gen.ts"],"names":[],"mappings":"AAAA;;GAEG;AACH;;GAEG;AAEH,OAAO,EAA0B,QAAQ,IAAI,YAAY,EAAE,iBAAiB,IAAI,qBAAqB,EAAE,cAAc,IAAI,kBAAkB,EAAE,gBAAgB,IAAI,oBAAoB,EAAE,MAAM,kBAAkB,CAAA;AAc/M;;;;;;;GAOG;AACH,MAAM,CAAC,MAAM,QAAQ,GAAG,CACtB,UAA0E,EAC1E,EAAE;IACF,YAAY,CAAC,UAAiB,CAAC,CAAA;AACjC,CAAC,CAAA;AAED;;;;;;;;;;;;;;;;;;GAkBG;AACH,MAAM,CAAC,MAAM,iBAAiB,GAAG,CAC/B,iBAA6C,EAC7C,UAA8B,EAC9B,EAAE;IACF,qBAAqB,CAAC,iBAAwB,EAAE,UAAiB,CAAC,CAAA;AACpE,CAAC,CAAA;AAkDD,MAAM,UAAU,gBAAgB,CAA8B,cAAgE;IAC5H,OAAO,oBAAoB,CAAC,cAAqB,CAAyC,CAAA;AAC5F,CAAC;AAED;;GAEG;AACH,MAAM,CAAC,MAAM,cAAc,GAAG,CAAC,MAAiC,EAAQ,EAAE;IACxE,kBAAkB,CAAC,MAAa,CAAC,CAAA;AACnC,CAAC,CAAA"}
@@ -0,0 +1,119 @@
1
+ /**
2
+ * This file was generated by @pikku/cli@0.12.96
3
+ */
4
+ /**
5
+ * HTTP-specific type definitions for tree-shaking optimization
6
+ */
7
+
8
+ import { AssertHTTPWiringParams, wireHTTP as wireHTTPCore, addHTTPMiddleware as addHTTPMiddlewareCore, wireHTTPRoutes as wireHTTPRoutesCore, defineHTTPRoutes as defineHTTPRoutesCore } from '@pikku/core/http'
9
+ import type { PikkuFunction, PikkuFunctionSessionless, PikkuPermission, PikkuMiddleware, PikkuFunctionConfig } from '../function/pikku-function-types.gen.js'
10
+ import type { CoreHTTPFunctionWiring, HTTPMethod, HTTPRouteBaseConfig } from '@pikku/core/http'
11
+
12
+ /**
13
+ * Type definition for HTTP API wirings with type-safe path parameters.
14
+ * Supports both authenticated and unauthenticated functions.
15
+ *
16
+ * @template In - Input type for the HTTP wiring
17
+ * @template Out - Output type for the HTTP wiring
18
+ * @template Route - String literal type for the HTTP path (e.g., "/users/:id")
19
+ */
20
+ type HTTPWiring<In, Out, Route extends string> = CoreHTTPFunctionWiring<In, Out, Route, PikkuFunction<In, Out, 'rpc' | 'session'>, PikkuFunctionSessionless<In, Out, 'rpc' | 'session'>, PikkuPermission<In>, PikkuMiddleware>
21
+
22
+ /**
23
+ * Registers an HTTP wiring with the Pikku framework.
24
+ *
25
+ * @template In - Input type for the HTTP wiring
26
+ * @template Out - Output type for the HTTP wiring
27
+ * @template Route - String literal type for the HTTP path (e.g., "/users/:id")
28
+ * @param httpWiring - HTTP wiring definition with handler, method, and optional middleware
29
+ */
30
+ export const wireHTTP = <In, Out, Route extends string>(
31
+ httpWiring: HTTPWiring<In, Out, Route> & AssertHTTPWiringParams<In, Route>
32
+ ) => {
33
+ wireHTTPCore(httpWiring as any)
34
+ }
35
+
36
+ /**
37
+ * Registers HTTP middleware either globally or for a specific route pattern.
38
+ *
39
+ * When a string route pattern is provided along with middleware, the middleware
40
+ * is applied only to that route. Otherwise, if an array is provided, it is treated
41
+ * as global middleware (applied to all routes).
42
+ *
43
+ * @param routeOrMiddleware - Either a global middleware array or a route pattern string
44
+ * @param middleware - The middleware array to apply when a route pattern is specified
45
+ *
46
+ * @example
47
+ * ```typescript
48
+ * // Add global HTTP middleware
49
+ * addHTTPMiddleware([authMiddleware, loggingMiddleware])
50
+ *
51
+ * // Add route-specific middleware
52
+ * addHTTPMiddleware('/api/admin/*', [adminAuthMiddleware])
53
+ * ```
54
+ */
55
+ export const addHTTPMiddleware = (
56
+ routeOrMiddleware: PikkuMiddleware[] | string,
57
+ middleware?: PikkuMiddleware[]
58
+ ) => {
59
+ addHTTPMiddlewareCore(routeOrMiddleware as any, middleware as any)
60
+ }
61
+
62
+ /**
63
+ * Route configuration for wireHTTPRoutes with proper typing
64
+ */
65
+ type HTTPRouteConfig = HTTPRouteBaseConfig & {
66
+ method: HTTPMethod
67
+ route: string
68
+ func: PikkuFunctionConfig<any, any, any, any, any, any>
69
+ auth?: boolean
70
+ middleware?: PikkuMiddleware[]
71
+ sse?: boolean
72
+ }
73
+
74
+ /**
75
+ * Typed route map for wireHTTPRoutes
76
+ */
77
+ type TypedHTTPRouteMap = {
78
+ [key: string]: HTTPRouteConfig | TypedHTTPRouteMap | TypedHTTPRouteContract
79
+ }
80
+
81
+ /**
82
+ * Typed route contract for defineHTTPRoutes
83
+ */
84
+ type TypedHTTPRouteContract<T extends TypedHTTPRouteMap = TypedHTTPRouteMap> = TypedHTTPRoutesGroupConfig & {
85
+ routes: T
86
+ }
87
+
88
+ /**
89
+ * Group config with typed middleware
90
+ */
91
+ type TypedHTTPRoutesGroupConfig = {
92
+ basePath?: string
93
+ tags?: string[]
94
+ auth?: boolean
95
+ middleware?: PikkuMiddleware[]
96
+ }
97
+
98
+ /**
99
+ * Full config for wireHTTPRoutes
100
+ */
101
+ type TypedWireHTTPRoutesConfig = TypedHTTPRoutesGroupConfig & {
102
+ routes: TypedHTTPRouteMap | HTTPRouteConfig[]
103
+ }
104
+
105
+ /**
106
+ * Type-safe helper for defining route contracts that can be composed.
107
+ */
108
+ export function defineHTTPRoutes<T extends TypedHTTPRouteMap>(routes: T): TypedHTTPRouteContract<T>
109
+ export function defineHTTPRoutes<T extends TypedHTTPRouteMap>(config: TypedHTTPRoutesGroupConfig & { routes: T }): TypedHTTPRouteContract<T>
110
+ export function defineHTTPRoutes<T extends TypedHTTPRouteMap>(configOrRoutes: T | (TypedHTTPRoutesGroupConfig & { routes: T })): TypedHTTPRouteContract<T> {
111
+ return defineHTTPRoutesCore(configOrRoutes as any) as unknown as TypedHTTPRouteContract<T>
112
+ }
113
+
114
+ /**
115
+ * Wires multiple HTTP routes from a nested map or array configuration.
116
+ */
117
+ export const wireHTTPRoutes = (config: TypedWireHTTPRoutesConfig): void => {
118
+ wireHTTPRoutesCore(config as any)
119
+ }