@orq-ai/node 4.3.2 → 4.4.0-rc.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.
Files changed (482) hide show
  1. package/examples/package-lock.json +4 -7
  2. package/jsr.json +1 -1
  3. package/lib/config.d.ts +2 -2
  4. package/lib/config.js +2 -2
  5. package/lib/config.js.map +1 -1
  6. package/models/components/conversationresponse.js +1 -1
  7. package/models/components/conversationwithmessagesresponse.js +1 -1
  8. package/models/components/partdoneevent.js +1 -1
  9. package/models/components/reasoningpart.js +1 -1
  10. package/models/operations/createcontact.js +1 -1
  11. package/models/operations/createconversation.js +1 -1
  12. package/models/operations/createconversationresponse.js +2 -2
  13. package/models/operations/createdataset.js +1 -1
  14. package/models/operations/createdatasetitem.js +4 -4
  15. package/models/operations/createdatasource.js +1 -1
  16. package/models/operations/createeval.js +14 -14
  17. package/models/operations/createidentity.js +1 -1
  18. package/models/operations/createtool.js +6 -6
  19. package/models/operations/fileget.js +1 -1
  20. package/models/operations/filelist.js +1 -1
  21. package/models/operations/fileupload.js +1 -1
  22. package/models/operations/generateconversationname.js +1 -1
  23. package/models/operations/getalltools.js +6 -6
  24. package/models/operations/getevals.js +14 -14
  25. package/models/operations/listdatasetdatapoints.js +4 -4
  26. package/models/operations/listdatasets.js +1 -1
  27. package/models/operations/listdatasources.js +1 -1
  28. package/models/operations/listidentities.js +1 -1
  29. package/models/operations/retrievedatapoint.js +4 -4
  30. package/models/operations/retrievedataset.js +1 -1
  31. package/models/operations/retrievedatasource.js +1 -1
  32. package/models/operations/retrieveidentity.js +1 -1
  33. package/models/operations/retrievetool.js +6 -6
  34. package/models/operations/runagent.js +1 -1
  35. package/models/operations/streamrunagent.js +1 -1
  36. package/models/operations/updateconversation.js +1 -1
  37. package/models/operations/updatedatapoint.js +4 -4
  38. package/models/operations/updatedataset.js +1 -1
  39. package/models/operations/updatedatasource.js +1 -1
  40. package/models/operations/updateeval.js +14 -14
  41. package/models/operations/updateidentity.js +1 -1
  42. package/models/operations/updatetool.js +7 -7
  43. package/package.json +4 -3
  44. package/src/lib/config.ts +2 -2
  45. package/src/models/components/conversationresponse.ts +1 -1
  46. package/src/models/components/conversationwithmessagesresponse.ts +1 -1
  47. package/src/models/components/partdoneevent.ts +1 -1
  48. package/src/models/components/reasoningpart.ts +1 -1
  49. package/src/models/operations/createcontact.ts +1 -1
  50. package/src/models/operations/createconversation.ts +1 -1
  51. package/src/models/operations/createconversationresponse.ts +2 -2
  52. package/src/models/operations/createdataset.ts +1 -1
  53. package/src/models/operations/createdatasetitem.ts +4 -4
  54. package/src/models/operations/createdatasource.ts +1 -1
  55. package/src/models/operations/createeval.ts +14 -14
  56. package/src/models/operations/createidentity.ts +1 -1
  57. package/src/models/operations/createtool.ts +6 -6
  58. package/src/models/operations/fileget.ts +1 -1
  59. package/src/models/operations/filelist.ts +1 -1
  60. package/src/models/operations/fileupload.ts +1 -1
  61. package/src/models/operations/generateconversationname.ts +1 -1
  62. package/src/models/operations/getalltools.ts +6 -6
  63. package/src/models/operations/getevals.ts +14 -14
  64. package/src/models/operations/listdatasetdatapoints.ts +4 -4
  65. package/src/models/operations/listdatasets.ts +1 -1
  66. package/src/models/operations/listdatasources.ts +1 -1
  67. package/src/models/operations/listidentities.ts +1 -1
  68. package/src/models/operations/retrievedatapoint.ts +4 -4
  69. package/src/models/operations/retrievedataset.ts +1 -1
  70. package/src/models/operations/retrievedatasource.ts +1 -1
  71. package/src/models/operations/retrieveidentity.ts +1 -1
  72. package/src/models/operations/retrievetool.ts +6 -6
  73. package/src/models/operations/runagent.ts +1 -1
  74. package/src/models/operations/streamrunagent.ts +1 -1
  75. package/src/models/operations/updateconversation.ts +1 -1
  76. package/src/models/operations/updatedatapoint.ts +4 -4
  77. package/src/models/operations/updatedataset.ts +1 -1
  78. package/src/models/operations/updatedatasource.ts +1 -1
  79. package/src/models/operations/updateeval.ts +14 -14
  80. package/src/models/operations/updateidentity.ts +1 -1
  81. package/src/models/operations/updatetool.ts +7 -7
  82. package/_speakeasy/.github/action-inputs-config.json +0 -53
  83. package/_speakeasy/.github/action-security-config.json +0 -88
  84. package/packages/orq-rc/examples/contactsCreate.example.ts +0 -42
  85. package/packages/orq-rc/examples/package-lock.json +0 -610
  86. package/packages/orq-rc/examples/package.json +0 -18
  87. package/packages/orq-rc/jsr.json +0 -28
  88. package/packages/orq-rc/package-lock.json +0 -1740
  89. package/packages/orq-rc/package.json +0 -30
  90. package/packages/orq-rc/src/core.ts +0 -13
  91. package/packages/orq-rc/src/funcs/agentsCreate.ts +0 -161
  92. package/packages/orq-rc/src/funcs/agentsDelete.ts +0 -180
  93. package/packages/orq-rc/src/funcs/agentsInvoke.ts +0 -177
  94. package/packages/orq-rc/src/funcs/agentsList.ts +0 -179
  95. package/packages/orq-rc/src/funcs/agentsResponsesCreate.ts +0 -183
  96. package/packages/orq-rc/src/funcs/agentsRetrieve.ts +0 -180
  97. package/packages/orq-rc/src/funcs/agentsRun.ts +0 -162
  98. package/packages/orq-rc/src/funcs/agentsStream.ts +0 -201
  99. package/packages/orq-rc/src/funcs/agentsStreamRun.ts +0 -186
  100. package/packages/orq-rc/src/funcs/agentsUpdate.ts +0 -184
  101. package/packages/orq-rc/src/funcs/chunkingParse.ts +0 -160
  102. package/packages/orq-rc/src/funcs/contactsCreate.ts +0 -160
  103. package/packages/orq-rc/src/funcs/conversationsCreate.ts +0 -161
  104. package/packages/orq-rc/src/funcs/conversationsCreateConversationResponse.ts +0 -186
  105. package/packages/orq-rc/src/funcs/conversationsDelete.ts +0 -180
  106. package/packages/orq-rc/src/funcs/conversationsGenerateName.ts +0 -194
  107. package/packages/orq-rc/src/funcs/conversationsList.ts +0 -186
  108. package/packages/orq-rc/src/funcs/conversationsRetrieve.ts +0 -181
  109. package/packages/orq-rc/src/funcs/conversationsUpdate.ts +0 -184
  110. package/packages/orq-rc/src/funcs/datasetsClear.ts +0 -167
  111. package/packages/orq-rc/src/funcs/datasetsCreate.ts +0 -165
  112. package/packages/orq-rc/src/funcs/datasetsCreateDatapoint.ts +0 -171
  113. package/packages/orq-rc/src/funcs/datasetsDelete.ts +0 -167
  114. package/packages/orq-rc/src/funcs/datasetsDeleteDatapoint.ts +0 -182
  115. package/packages/orq-rc/src/funcs/datasetsList.ts +0 -167
  116. package/packages/orq-rc/src/funcs/datasetsListDatapoints.ts +0 -174
  117. package/packages/orq-rc/src/funcs/datasetsRetrieve.ts +0 -175
  118. package/packages/orq-rc/src/funcs/datasetsRetrieveDatapoint.ts +0 -181
  119. package/packages/orq-rc/src/funcs/datasetsUpdate.ts +0 -176
  120. package/packages/orq-rc/src/funcs/datasetsUpdateDatapoint.ts +0 -179
  121. package/packages/orq-rc/src/funcs/deploymentsGetConfig.ts +0 -168
  122. package/packages/orq-rc/src/funcs/deploymentsInvoke.ts +0 -176
  123. package/packages/orq-rc/src/funcs/deploymentsList.ts +0 -176
  124. package/packages/orq-rc/src/funcs/deploymentsMetricsCreate.ts +0 -168
  125. package/packages/orq-rc/src/funcs/deploymentsStream.ts +0 -183
  126. package/packages/orq-rc/src/funcs/evalsAll.ts +0 -173
  127. package/packages/orq-rc/src/funcs/evalsCreate.ts +0 -169
  128. package/packages/orq-rc/src/funcs/evalsDelete.ts +0 -173
  129. package/packages/orq-rc/src/funcs/evalsInvoke.ts +0 -181
  130. package/packages/orq-rc/src/funcs/evalsUpdate.ts +0 -173
  131. package/packages/orq-rc/src/funcs/evaluatorsGetV2EvaluatorsIdVersions.ts +0 -183
  132. package/packages/orq-rc/src/funcs/feedbackCreate.ts +0 -160
  133. package/packages/orq-rc/src/funcs/filesCreate.ts +0 -187
  134. package/packages/orq-rc/src/funcs/filesDelete.ts +0 -164
  135. package/packages/orq-rc/src/funcs/filesGet.ts +0 -166
  136. package/packages/orq-rc/src/funcs/filesList.ts +0 -167
  137. package/packages/orq-rc/src/funcs/identitiesCreate.ts +0 -165
  138. package/packages/orq-rc/src/funcs/identitiesDelete.ts +0 -176
  139. package/packages/orq-rc/src/funcs/identitiesList.ts +0 -170
  140. package/packages/orq-rc/src/funcs/identitiesRetrieve.ts +0 -175
  141. package/packages/orq-rc/src/funcs/identitiesUpdate.ts +0 -176
  142. package/packages/orq-rc/src/funcs/knowledgeCreate.ts +0 -158
  143. package/packages/orq-rc/src/funcs/knowledgeCreateChunks.ts +0 -171
  144. package/packages/orq-rc/src/funcs/knowledgeCreateDatasource.ts +0 -166
  145. package/packages/orq-rc/src/funcs/knowledgeDelete.ts +0 -167
  146. package/packages/orq-rc/src/funcs/knowledgeDeleteChunk.ts +0 -174
  147. package/packages/orq-rc/src/funcs/knowledgeDeleteChunks.ts +0 -170
  148. package/packages/orq-rc/src/funcs/knowledgeDeleteDatasource.ts +0 -173
  149. package/packages/orq-rc/src/funcs/knowledgeGetChunksCount.ts +0 -170
  150. package/packages/orq-rc/src/funcs/knowledgeList.ts +0 -169
  151. package/packages/orq-rc/src/funcs/knowledgeListChunks.ts +0 -178
  152. package/packages/orq-rc/src/funcs/knowledgeListChunksPaginated.ts +0 -171
  153. package/packages/orq-rc/src/funcs/knowledgeListDatasources.ts +0 -174
  154. package/packages/orq-rc/src/funcs/knowledgeRetrieve.ts +0 -166
  155. package/packages/orq-rc/src/funcs/knowledgeRetrieveChunk.ts +0 -173
  156. package/packages/orq-rc/src/funcs/knowledgeRetrieveDatasource.ts +0 -169
  157. package/packages/orq-rc/src/funcs/knowledgeSearch.ts +0 -167
  158. package/packages/orq-rc/src/funcs/knowledgeUpdate.ts +0 -164
  159. package/packages/orq-rc/src/funcs/knowledgeUpdateChunk.ts +0 -174
  160. package/packages/orq-rc/src/funcs/knowledgeUpdateDatasource.ts +0 -170
  161. package/packages/orq-rc/src/funcs/memoryStoresCreate.ts +0 -162
  162. package/packages/orq-rc/src/funcs/memoryStoresCreateDocument.ts +0 -176
  163. package/packages/orq-rc/src/funcs/memoryStoresCreateMemory.ts +0 -170
  164. package/packages/orq-rc/src/funcs/memoryStoresDelete.ts +0 -168
  165. package/packages/orq-rc/src/funcs/memoryStoresDeleteDocument.ts +0 -185
  166. package/packages/orq-rc/src/funcs/memoryStoresDeleteMemory.ts +0 -180
  167. package/packages/orq-rc/src/funcs/memoryStoresList.ts +0 -178
  168. package/packages/orq-rc/src/funcs/memoryStoresListDocuments.ts +0 -184
  169. package/packages/orq-rc/src/funcs/memoryStoresListMemories.ts +0 -177
  170. package/packages/orq-rc/src/funcs/memoryStoresRetrieve.ts +0 -177
  171. package/packages/orq-rc/src/funcs/memoryStoresRetrieveDocument.ts +0 -179
  172. package/packages/orq-rc/src/funcs/memoryStoresRetrieveMemory.ts +0 -174
  173. package/packages/orq-rc/src/funcs/memoryStoresUpdate.ts +0 -168
  174. package/packages/orq-rc/src/funcs/memoryStoresUpdateDocument.ts +0 -180
  175. package/packages/orq-rc/src/funcs/memoryStoresUpdateMemory.ts +0 -175
  176. package/packages/orq-rc/src/funcs/modelsList.ts +0 -142
  177. package/packages/orq-rc/src/funcs/promptsCreate.ts +0 -160
  178. package/packages/orq-rc/src/funcs/promptsDelete.ts +0 -173
  179. package/packages/orq-rc/src/funcs/promptsGetVersion.ts +0 -181
  180. package/packages/orq-rc/src/funcs/promptsList.ts +0 -167
  181. package/packages/orq-rc/src/funcs/promptsListVersions.ts +0 -173
  182. package/packages/orq-rc/src/funcs/promptsRetrieve.ts +0 -166
  183. package/packages/orq-rc/src/funcs/promptsUpdate.ts +0 -173
  184. package/packages/orq-rc/src/funcs/remoteconfigsRetrieve.ts +0 -161
  185. package/packages/orq-rc/src/funcs/routerAudioSpeechCreate.ts +0 -161
  186. package/packages/orq-rc/src/funcs/routerAudioTranscriptionsCreate.ts +0 -262
  187. package/packages/orq-rc/src/funcs/routerAudioTranslationsCreate.ts +0 -252
  188. package/packages/orq-rc/src/funcs/routerChatCompletionsCreate.ts +0 -168
  189. package/packages/orq-rc/src/funcs/routerCompletionsCreate.ts +0 -168
  190. package/packages/orq-rc/src/funcs/routerEmbeddingsCreate.ts +0 -161
  191. package/packages/orq-rc/src/funcs/routerImagesEditsCreate.ts +0 -222
  192. package/packages/orq-rc/src/funcs/routerImagesGenerationsCreate.ts +0 -160
  193. package/packages/orq-rc/src/funcs/routerImagesVariationsCreate.ts +0 -218
  194. package/packages/orq-rc/src/funcs/routerModerationsCreate.ts +0 -167
  195. package/packages/orq-rc/src/funcs/routerOcr.ts +0 -158
  196. package/packages/orq-rc/src/funcs/routerRerankCreate.ts +0 -160
  197. package/packages/orq-rc/src/funcs/routerResponsesCreate.ts +0 -167
  198. package/packages/orq-rc/src/funcs/toolsCreate.ts +0 -163
  199. package/packages/orq-rc/src/funcs/toolsDelete.ts +0 -167
  200. package/packages/orq-rc/src/funcs/toolsGetV2ToolsToolIdVersions.ts +0 -183
  201. package/packages/orq-rc/src/funcs/toolsGetV2ToolsToolIdVersionsVersionId.ts +0 -190
  202. package/packages/orq-rc/src/funcs/toolsList.ts +0 -176
  203. package/packages/orq-rc/src/funcs/toolsRetrieve.ts +0 -166
  204. package/packages/orq-rc/src/funcs/toolsUpdate.ts +0 -176
  205. package/packages/orq-rc/src/hooks/global.ts +0 -44
  206. package/packages/orq-rc/src/hooks/hooks.ts +0 -132
  207. package/packages/orq-rc/src/hooks/index.ts +0 -6
  208. package/packages/orq-rc/src/hooks/registration.ts +0 -15
  209. package/packages/orq-rc/src/hooks/types.ts +0 -112
  210. package/packages/orq-rc/src/index.ts +0 -9
  211. package/packages/orq-rc/src/lib/base64.ts +0 -37
  212. package/packages/orq-rc/src/lib/config.ts +0 -74
  213. package/packages/orq-rc/src/lib/dlv.ts +0 -53
  214. package/packages/orq-rc/src/lib/encodings.ts +0 -497
  215. package/packages/orq-rc/src/lib/env.ts +0 -89
  216. package/packages/orq-rc/src/lib/event-streams.ts +0 -152
  217. package/packages/orq-rc/src/lib/files.ts +0 -82
  218. package/packages/orq-rc/src/lib/http.ts +0 -323
  219. package/packages/orq-rc/src/lib/is-plain-object.ts +0 -43
  220. package/packages/orq-rc/src/lib/logger.ts +0 -9
  221. package/packages/orq-rc/src/lib/matchers.ts +0 -345
  222. package/packages/orq-rc/src/lib/primitives.ts +0 -150
  223. package/packages/orq-rc/src/lib/retries.ts +0 -218
  224. package/packages/orq-rc/src/lib/schemas.ts +0 -91
  225. package/packages/orq-rc/src/lib/sdks.ts +0 -407
  226. package/packages/orq-rc/src/lib/security.ts +0 -264
  227. package/packages/orq-rc/src/lib/url.ts +0 -33
  228. package/packages/orq-rc/src/models/components/actionreviewedstreamingevent.ts +0 -99
  229. package/packages/orq-rc/src/models/components/actionreviewrequestedstreamingevent.ts +0 -185
  230. package/packages/orq-rc/src/models/components/agenterroredstreamingevent.ts +0 -73
  231. package/packages/orq-rc/src/models/components/agentexecutionstartedstreamingevent.ts +0 -91
  232. package/packages/orq-rc/src/models/components/agenthandedoffstreamingevent.ts +0 -71
  233. package/packages/orq-rc/src/models/components/agentinactivestreamingevent.ts +0 -507
  234. package/packages/orq-rc/src/models/components/agentmessagecreatedstreamingevent.ts +0 -165
  235. package/packages/orq-rc/src/models/components/agentresponsemessage.ts +0 -103
  236. package/packages/orq-rc/src/models/components/agentstartedstreamingevent.ts +0 -503
  237. package/packages/orq-rc/src/models/components/agentthoughtstreamingevent.ts +0 -807
  238. package/packages/orq-rc/src/models/components/audiocontentpartschema.ts +0 -136
  239. package/packages/orq-rc/src/models/components/conversationresponse.ts +0 -132
  240. package/packages/orq-rc/src/models/components/conversationwithmessagesresponse.ts +0 -149
  241. package/packages/orq-rc/src/models/components/createagentresponse.ts +0 -299
  242. package/packages/orq-rc/src/models/components/datapart.ts +0 -38
  243. package/packages/orq-rc/src/models/components/errorpart.ts +0 -58
  244. package/packages/orq-rc/src/models/components/errorstreamingevent.ts +0 -66
  245. package/packages/orq-rc/src/models/components/executionnamedstreamingevent.ts +0 -71
  246. package/packages/orq-rc/src/models/components/executionreviewedstreamingevent.ts +0 -61
  247. package/packages/orq-rc/src/models/components/executionreviewrequiredstreamingevent.ts +0 -67
  248. package/packages/orq-rc/src/models/components/filecontentpartschema.ts +0 -87
  249. package/packages/orq-rc/src/models/components/filepart.ts +0 -218
  250. package/packages/orq-rc/src/models/components/imagecontentpartschema.ts +0 -268
  251. package/packages/orq-rc/src/models/components/index.ts +0 -60
  252. package/packages/orq-rc/src/models/components/invokedeploymentrequest.ts +0 -3457
  253. package/packages/orq-rc/src/models/components/messageresponse.ts +0 -127
  254. package/packages/orq-rc/src/models/components/partdelta.ts +0 -39
  255. package/packages/orq-rc/src/models/components/partdeltaevent.ts +0 -73
  256. package/packages/orq-rc/src/models/components/partdoneevent.ts +0 -139
  257. package/packages/orq-rc/src/models/components/publiccontact.ts +0 -71
  258. package/packages/orq-rc/src/models/components/publicidentity.ts +0 -69
  259. package/packages/orq-rc/src/models/components/reasoningpart.ts +0 -62
  260. package/packages/orq-rc/src/models/components/reasoningpartschema.ts +0 -71
  261. package/packages/orq-rc/src/models/components/redactedreasoningpartschema.ts +0 -66
  262. package/packages/orq-rc/src/models/components/refusalpartschema.ts +0 -64
  263. package/packages/orq-rc/src/models/components/responsedoneevent.ts +0 -318
  264. package/packages/orq-rc/src/models/components/responsefailedevent.ts +0 -72
  265. package/packages/orq-rc/src/models/components/responsestartedevent.ts +0 -91
  266. package/packages/orq-rc/src/models/components/responsestreamingevent.ts +0 -85
  267. package/packages/orq-rc/src/models/components/reviewoutcome.ts +0 -23
  268. package/packages/orq-rc/src/models/components/security.ts +0 -32
  269. package/packages/orq-rc/src/models/components/textcontentpartschema.ts +0 -207
  270. package/packages/orq-rc/src/models/components/textpart.ts +0 -54
  271. package/packages/orq-rc/src/models/components/thinkingconfigdisabledschema.ts +0 -59
  272. package/packages/orq-rc/src/models/components/thinkingconfigenabledschema.ts +0 -106
  273. package/packages/orq-rc/src/models/components/timeoutstreamingevent.ts +0 -64
  274. package/packages/orq-rc/src/models/components/toolcallpart.ts +0 -51
  275. package/packages/orq-rc/src/models/components/tooldoneevent.ts +0 -77
  276. package/packages/orq-rc/src/models/components/toolexecutionfailedstreamingevent.ts +0 -230
  277. package/packages/orq-rc/src/models/components/toolexecutionfinishedstreamingevent.ts +0 -214
  278. package/packages/orq-rc/src/models/components/toolexecutionstartedstreamingevent.ts +0 -200
  279. package/packages/orq-rc/src/models/components/toolfailedevent.ts +0 -77
  280. package/packages/orq-rc/src/models/components/toolresultpart.ts +0 -71
  281. package/packages/orq-rc/src/models/components/toolreviewdoneevent.ts +0 -78
  282. package/packages/orq-rc/src/models/components/toolreviewrequestedevent.ts +0 -87
  283. package/packages/orq-rc/src/models/components/toolstartedevent.ts +0 -82
  284. package/packages/orq-rc/src/models/components/usermessagerequest.ts +0 -136
  285. package/packages/orq-rc/src/models/errors/apierror.ts +0 -40
  286. package/packages/orq-rc/src/models/errors/createeval.ts +0 -51
  287. package/packages/orq-rc/src/models/errors/createmoderation.ts +0 -84
  288. package/packages/orq-rc/src/models/errors/createtranscription.ts +0 -87
  289. package/packages/orq-rc/src/models/errors/createtranslation.ts +0 -87
  290. package/packages/orq-rc/src/models/errors/deleteagent.ts +0 -51
  291. package/packages/orq-rc/src/models/errors/deleteconversation.ts +0 -51
  292. package/packages/orq-rc/src/models/errors/deleteeval.ts +0 -51
  293. package/packages/orq-rc/src/models/errors/deleteidentity.ts +0 -62
  294. package/packages/orq-rc/src/models/errors/deleteprompt.ts +0 -51
  295. package/packages/orq-rc/src/models/errors/generateconversationname.ts +0 -99
  296. package/packages/orq-rc/src/models/errors/getevals.ts +0 -51
  297. package/packages/orq-rc/src/models/errors/getpromptversion.ts +0 -51
  298. package/packages/orq-rc/src/models/errors/getv2evaluatorsidversions.ts +0 -51
  299. package/packages/orq-rc/src/models/errors/getv2toolstoolidversions.ts +0 -51
  300. package/packages/orq-rc/src/models/errors/getv2toolstoolidversionsversionid.ts +0 -52
  301. package/packages/orq-rc/src/models/errors/honoapierror.ts +0 -59
  302. package/packages/orq-rc/src/models/errors/httpclienterrors.ts +0 -62
  303. package/packages/orq-rc/src/models/errors/index.ts +0 -37
  304. package/packages/orq-rc/src/models/errors/invokeeval.ts +0 -141
  305. package/packages/orq-rc/src/models/errors/orqerror.ts +0 -35
  306. package/packages/orq-rc/src/models/errors/responsevalidationerror.ts +0 -50
  307. package/packages/orq-rc/src/models/errors/retrieveagentrequest.ts +0 -51
  308. package/packages/orq-rc/src/models/errors/retrieveconversation.ts +0 -51
  309. package/packages/orq-rc/src/models/errors/retrieveidentity.ts +0 -62
  310. package/packages/orq-rc/src/models/errors/sdkvalidationerror.ts +0 -109
  311. package/packages/orq-rc/src/models/errors/streamagent.ts +0 -51
  312. package/packages/orq-rc/src/models/errors/streamrunagent.ts +0 -51
  313. package/packages/orq-rc/src/models/errors/updateagent.ts +0 -51
  314. package/packages/orq-rc/src/models/errors/updateconversation.ts +0 -51
  315. package/packages/orq-rc/src/models/errors/updateeval.ts +0 -51
  316. package/packages/orq-rc/src/models/errors/updateidentity.ts +0 -54
  317. package/packages/orq-rc/src/models/errors/updateprompt.ts +0 -51
  318. package/packages/orq-rc/src/models/errors/updatetool.ts +0 -62
  319. package/packages/orq-rc/src/models/operations/cleardataset.ts +0 -39
  320. package/packages/orq-rc/src/models/operations/createagentrequest.ts +0 -7093
  321. package/packages/orq-rc/src/models/operations/createagentresponserequest.ts +0 -609
  322. package/packages/orq-rc/src/models/operations/createchatcompletion.ts +0 -6381
  323. package/packages/orq-rc/src/models/operations/createchunk.ts +0 -222
  324. package/packages/orq-rc/src/models/operations/createcompletion.ts +0 -3413
  325. package/packages/orq-rc/src/models/operations/createcontact.ts +0 -156
  326. package/packages/orq-rc/src/models/operations/createconversation.ts +0 -227
  327. package/packages/orq-rc/src/models/operations/createconversationresponse.ts +0 -498
  328. package/packages/orq-rc/src/models/operations/createdataset.ts +0 -162
  329. package/packages/orq-rc/src/models/operations/createdatasetitem.ts +0 -2551
  330. package/packages/orq-rc/src/models/operations/createdatasource.ts +0 -437
  331. package/packages/orq-rc/src/models/operations/createembedding.ts +0 -947
  332. package/packages/orq-rc/src/models/operations/createeval.ts +0 -3128
  333. package/packages/orq-rc/src/models/operations/createfeedback.ts +0 -144
  334. package/packages/orq-rc/src/models/operations/createidentity.ts +0 -162
  335. package/packages/orq-rc/src/models/operations/createimage.ts +0 -1028
  336. package/packages/orq-rc/src/models/operations/createimageedit.ts +0 -1045
  337. package/packages/orq-rc/src/models/operations/createimagevariation.ts +0 -1067
  338. package/packages/orq-rc/src/models/operations/createknowledge.ts +0 -944
  339. package/packages/orq-rc/src/models/operations/creatememory.ts +0 -142
  340. package/packages/orq-rc/src/models/operations/creatememorydocument.ts +0 -152
  341. package/packages/orq-rc/src/models/operations/creatememorystore.ts +0 -199
  342. package/packages/orq-rc/src/models/operations/createmoderation.ts +0 -664
  343. package/packages/orq-rc/src/models/operations/createprompt.ts +0 -5400
  344. package/packages/orq-rc/src/models/operations/creatererank.ts +0 -890
  345. package/packages/orq-rc/src/models/operations/createresponse.ts +0 -3294
  346. package/packages/orq-rc/src/models/operations/createspeech.ts +0 -700
  347. package/packages/orq-rc/src/models/operations/createtool.ts +0 -2499
  348. package/packages/orq-rc/src/models/operations/createtranscription.ts +0 -955
  349. package/packages/orq-rc/src/models/operations/createtranslation.ts +0 -930
  350. package/packages/orq-rc/src/models/operations/deleteagent.ts +0 -39
  351. package/packages/orq-rc/src/models/operations/deletechunk.ts +0 -53
  352. package/packages/orq-rc/src/models/operations/deletechunks.ts +0 -125
  353. package/packages/orq-rc/src/models/operations/deleteconversation.ts +0 -39
  354. package/packages/orq-rc/src/models/operations/deletedatapoint.ts +0 -46
  355. package/packages/orq-rc/src/models/operations/deletedataset.ts +0 -39
  356. package/packages/orq-rc/src/models/operations/deletedatasource.ts +0 -46
  357. package/packages/orq-rc/src/models/operations/deleteeval.ts +0 -31
  358. package/packages/orq-rc/src/models/operations/deleteidentity.ts +0 -34
  359. package/packages/orq-rc/src/models/operations/deleteknowledge.ts +0 -39
  360. package/packages/orq-rc/src/models/operations/deletememory.ts +0 -46
  361. package/packages/orq-rc/src/models/operations/deletememorydocument.ts +0 -55
  362. package/packages/orq-rc/src/models/operations/deletememorystore.ts +0 -39
  363. package/packages/orq-rc/src/models/operations/deleteprompt.ts +0 -34
  364. package/packages/orq-rc/src/models/operations/deletetool.ts +0 -36
  365. package/packages/orq-rc/src/models/operations/deploymentcreatemetric.ts +0 -2370
  366. package/packages/orq-rc/src/models/operations/deploymentgetconfig.ts +0 -4525
  367. package/packages/orq-rc/src/models/operations/deploymentinvoke.ts +0 -689
  368. package/packages/orq-rc/src/models/operations/deployments.ts +0 -1267
  369. package/packages/orq-rc/src/models/operations/deploymentstream.ts +0 -4613
  370. package/packages/orq-rc/src/models/operations/filedelete.ts +0 -39
  371. package/packages/orq-rc/src/models/operations/fileget.ts +0 -116
  372. package/packages/orq-rc/src/models/operations/filelist.ts +0 -172
  373. package/packages/orq-rc/src/models/operations/fileupload.ts +0 -170
  374. package/packages/orq-rc/src/models/operations/generateconversationname.ts +0 -207
  375. package/packages/orq-rc/src/models/operations/getallmemories.ts +0 -173
  376. package/packages/orq-rc/src/models/operations/getallmemorydocuments.ts +0 -188
  377. package/packages/orq-rc/src/models/operations/getallmemorystores.ts +0 -200
  378. package/packages/orq-rc/src/models/operations/getallprompts.ts +0 -3163
  379. package/packages/orq-rc/src/models/operations/getalltools.ts +0 -1398
  380. package/packages/orq-rc/src/models/operations/getchunkscount.ts +0 -121
  381. package/packages/orq-rc/src/models/operations/getevals.ts +0 -2330
  382. package/packages/orq-rc/src/models/operations/getonechunk.ts +0 -171
  383. package/packages/orq-rc/src/models/operations/getoneknowledge.ts +0 -652
  384. package/packages/orq-rc/src/models/operations/getoneprompt.ts +0 -3088
  385. package/packages/orq-rc/src/models/operations/getpromptversion.ts +0 -3133
  386. package/packages/orq-rc/src/models/operations/getv2evaluatorsidversions.ts +0 -162
  387. package/packages/orq-rc/src/models/operations/getv2toolstoolidversions.ts +0 -163
  388. package/packages/orq-rc/src/models/operations/getv2toolstoolidversionsversionid.ts +0 -110
  389. package/packages/orq-rc/src/models/operations/index.ts +0 -118
  390. package/packages/orq-rc/src/models/operations/invokeagent.ts +0 -733
  391. package/packages/orq-rc/src/models/operations/invokeeval.ts +0 -1129
  392. package/packages/orq-rc/src/models/operations/listagents.ts +0 -3018
  393. package/packages/orq-rc/src/models/operations/listchunks.ts +0 -260
  394. package/packages/orq-rc/src/models/operations/listchunkspaginated.ts +0 -263
  395. package/packages/orq-rc/src/models/operations/listconversations.ts +0 -104
  396. package/packages/orq-rc/src/models/operations/listdatasetdatapoints.ts +0 -1498
  397. package/packages/orq-rc/src/models/operations/listdatasets.ts +0 -205
  398. package/packages/orq-rc/src/models/operations/listdatasources.ts +0 -235
  399. package/packages/orq-rc/src/models/operations/listidentities.ts +0 -275
  400. package/packages/orq-rc/src/models/operations/listknowledgebases.ts +0 -642
  401. package/packages/orq-rc/src/models/operations/listmodels.ts +0 -143
  402. package/packages/orq-rc/src/models/operations/listpromptversions.ts +0 -3208
  403. package/packages/orq-rc/src/models/operations/parse.ts +0 -777
  404. package/packages/orq-rc/src/models/operations/postv2routerocr.ts +0 -478
  405. package/packages/orq-rc/src/models/operations/remoteconfigsgetconfig.ts +0 -108
  406. package/packages/orq-rc/src/models/operations/retrieveagentrequest.ts +0 -3104
  407. package/packages/orq-rc/src/models/operations/retrieveconversation.ts +0 -41
  408. package/packages/orq-rc/src/models/operations/retrievedatapoint.ts +0 -1402
  409. package/packages/orq-rc/src/models/operations/retrievedataset.ts +0 -150
  410. package/packages/orq-rc/src/models/operations/retrievedatasource.ts +0 -152
  411. package/packages/orq-rc/src/models/operations/retrieveidentity.ts +0 -117
  412. package/packages/orq-rc/src/models/operations/retrievememory.ts +0 -112
  413. package/packages/orq-rc/src/models/operations/retrievememorydocument.ts +0 -118
  414. package/packages/orq-rc/src/models/operations/retrievememorystore.ts +0 -144
  415. package/packages/orq-rc/src/models/operations/retrievetool.ts +0 -1379
  416. package/packages/orq-rc/src/models/operations/runagent.ts +0 -5351
  417. package/packages/orq-rc/src/models/operations/searchknowledge.ts +0 -1762
  418. package/packages/orq-rc/src/models/operations/streamagent.ts +0 -629
  419. package/packages/orq-rc/src/models/operations/streamrunagent.ts +0 -5546
  420. package/packages/orq-rc/src/models/operations/updateagent.ts +0 -7447
  421. package/packages/orq-rc/src/models/operations/updatechunk.ts +0 -236
  422. package/packages/orq-rc/src/models/operations/updateconversation.ts +0 -252
  423. package/packages/orq-rc/src/models/operations/updatedatapoint.ts +0 -2555
  424. package/packages/orq-rc/src/models/operations/updatedataset.ts +0 -206
  425. package/packages/orq-rc/src/models/operations/updatedatasource.ts +0 -186
  426. package/packages/orq-rc/src/models/operations/updateeval.ts +0 -3303
  427. package/packages/orq-rc/src/models/operations/updateidentity.ts +0 -189
  428. package/packages/orq-rc/src/models/operations/updateknowledge.ts +0 -1231
  429. package/packages/orq-rc/src/models/operations/updatememory.ts +0 -142
  430. package/packages/orq-rc/src/models/operations/updatememorydocument.ts +0 -159
  431. package/packages/orq-rc/src/models/operations/updatememorystore.ts +0 -245
  432. package/packages/orq-rc/src/models/operations/updateprompt.ts +0 -5471
  433. package/packages/orq-rc/src/models/operations/updatetool.ts +0 -2696
  434. package/packages/orq-rc/src/sdk/agents.ts +0 -196
  435. package/packages/orq-rc/src/sdk/audio.ts +0 -25
  436. package/packages/orq-rc/src/sdk/chat.ts +0 -13
  437. package/packages/orq-rc/src/sdk/chunking.ts +0 -27
  438. package/packages/orq-rc/src/sdk/completions.ts +0 -32
  439. package/packages/orq-rc/src/sdk/contacts.ts +0 -27
  440. package/packages/orq-rc/src/sdk/conversations.ts +0 -147
  441. package/packages/orq-rc/src/sdk/datasets.ts +0 -204
  442. package/packages/orq-rc/src/sdk/deployments.ts +0 -89
  443. package/packages/orq-rc/src/sdk/edits.ts +0 -27
  444. package/packages/orq-rc/src/sdk/embeddings.ts +0 -27
  445. package/packages/orq-rc/src/sdk/evals.ts +0 -84
  446. package/packages/orq-rc/src/sdk/evaluators.ts +0 -27
  447. package/packages/orq-rc/src/sdk/feedback.ts +0 -27
  448. package/packages/orq-rc/src/sdk/files.ts +0 -78
  449. package/packages/orq-rc/src/sdk/generations.ts +0 -27
  450. package/packages/orq-rc/src/sdk/identities.ts +0 -99
  451. package/packages/orq-rc/src/sdk/images.ts +0 -25
  452. package/packages/orq-rc/src/sdk/index.ts +0 -5
  453. package/packages/orq-rc/src/sdk/internal.ts +0 -28
  454. package/packages/orq-rc/src/sdk/knowledge.ts +0 -309
  455. package/packages/orq-rc/src/sdk/memorystores.ts +0 -286
  456. package/packages/orq-rc/src/sdk/metrics.ts +0 -27
  457. package/packages/orq-rc/src/sdk/models.ts +0 -25
  458. package/packages/orq-rc/src/sdk/moderations.ts +0 -24
  459. package/packages/orq-rc/src/sdk/orqcompletions.ts +0 -32
  460. package/packages/orq-rc/src/sdk/orqresponses.ts +0 -32
  461. package/packages/orq-rc/src/sdk/prompts.ts +0 -126
  462. package/packages/orq-rc/src/sdk/remoteconfigs.ts +0 -24
  463. package/packages/orq-rc/src/sdk/rerank.ts +0 -27
  464. package/packages/orq-rc/src/sdk/responses.ts +0 -34
  465. package/packages/orq-rc/src/sdk/router.ts +0 -72
  466. package/packages/orq-rc/src/sdk/sdk.ts +0 -121
  467. package/packages/orq-rc/src/sdk/speech.ts +0 -27
  468. package/packages/orq-rc/src/sdk/tools.ts +0 -135
  469. package/packages/orq-rc/src/sdk/transcriptions.ts +0 -24
  470. package/packages/orq-rc/src/sdk/translations.ts +0 -24
  471. package/packages/orq-rc/src/sdk/variations.ts +0 -27
  472. package/packages/orq-rc/src/types/async.ts +0 -68
  473. package/packages/orq-rc/src/types/blobs.ts +0 -32
  474. package/packages/orq-rc/src/types/constdatetime.ts +0 -15
  475. package/packages/orq-rc/src/types/enums.ts +0 -45
  476. package/packages/orq-rc/src/types/fp.ts +0 -50
  477. package/packages/orq-rc/src/types/index.ts +0 -11
  478. package/packages/orq-rc/src/types/operations.ts +0 -105
  479. package/packages/orq-rc/src/types/rfcdate.ts +0 -54
  480. package/packages/orq-rc/src/types/streams.ts +0 -21
  481. package/packages/orq-rc/src/types/unrecognized.ts +0 -35
  482. package/packages/orq-rc/tsconfig.json +0 -40
@@ -1,807 +0,0 @@
1
- /*
2
- * Code generated by Speakeasy (https://speakeasy.com). DO NOT EDIT.
3
- */
4
-
5
- import * as z from "zod/v3";
6
- import { remap as remap$ } from "../../lib/primitives.js";
7
- import { safeParse } from "../../lib/schemas.js";
8
- import { ClosedEnum } from "../../types/enums.js";
9
- import { Result as SafeParseResult } from "../../types/fp.js";
10
- import { SDKValidationError } from "../errors/sdkvalidationerror.js";
11
- import { DataPart, DataPart$inboundSchema } from "./datapart.js";
12
- import { ErrorPart, ErrorPart$inboundSchema } from "./errorpart.js";
13
- import { FilePart, FilePart$inboundSchema } from "./filepart.js";
14
- import { TextPart, TextPart$inboundSchema } from "./textpart.js";
15
- import { ToolCallPart, ToolCallPart$inboundSchema } from "./toolcallpart.js";
16
- import {
17
- ToolResultPart,
18
- ToolResultPart$inboundSchema,
19
- } from "./toolresultpart.js";
20
-
21
- export const AgentThoughtStreamingEventRole = {
22
- User: "user",
23
- Agent: "agent",
24
- Tool: "tool",
25
- System: "system",
26
- } as const;
27
- export type AgentThoughtStreamingEventRole = ClosedEnum<
28
- typeof AgentThoughtStreamingEventRole
29
- >;
30
-
31
- export type AgentThoughtStreamingEventParts =
32
- | TextPart
33
- | ErrorPart
34
- | DataPart
35
- | FilePart
36
- | ToolCallPart
37
- | ToolResultPart;
38
-
39
- export type MessageDifference = {
40
- messageId: string;
41
- role: AgentThoughtStreamingEventRole;
42
- parts: Array<
43
- TextPart | ErrorPart | DataPart | FilePart | ToolCallPart | ToolResultPart
44
- >;
45
- metadata?: { [k: string]: any } | undefined;
46
- agentId: string;
47
- agentExecutionId: string;
48
- workspaceId: string;
49
- };
50
-
51
- /**
52
- * The reason the model stopped generating tokens.
53
- */
54
- export const AgentThoughtStreamingEventFinishReason = {
55
- Stop: "stop",
56
- Length: "length",
57
- ToolCalls: "tool_calls",
58
- ContentFilter: "content_filter",
59
- FunctionCall: "function_call",
60
- } as const;
61
- /**
62
- * The reason the model stopped generating tokens.
63
- */
64
- export type AgentThoughtStreamingEventFinishReason = ClosedEnum<
65
- typeof AgentThoughtStreamingEventFinishReason
66
- >;
67
-
68
- export const AgentThoughtStreamingEventDataType = {
69
- Function: "function",
70
- } as const;
71
- export type AgentThoughtStreamingEventDataType = ClosedEnum<
72
- typeof AgentThoughtStreamingEventDataType
73
- >;
74
-
75
- export type AgentThoughtStreamingEventFunction = {
76
- /**
77
- * The name of the function to be called. Must be a-z, A-Z, 0-9, or contain underscores and dashes, with a maximum length of 64.
78
- */
79
- name?: string | undefined;
80
- /**
81
- * The arguments to call the function with, as generated by the model in JSON format. Note that the model does not always generate valid JSON, and may hallucinate parameters not defined by your function schema. Validate the arguments in your code before calling your function.
82
- */
83
- arguments?: string | undefined;
84
- };
85
-
86
- export type AgentThoughtStreamingEventToolCalls = {
87
- index?: number | undefined;
88
- id?: string | undefined;
89
- type?: AgentThoughtStreamingEventDataType | undefined;
90
- function?: AgentThoughtStreamingEventFunction | undefined;
91
- /**
92
- * Encrypted representation of the model internal reasoning state during function calling. Required by Gemini 3 models when continuing a conversation after a tool call.
93
- */
94
- thoughtSignature?: string | undefined;
95
- };
96
-
97
- export const AgentThoughtStreamingEventDataRole = {
98
- Assistant: "assistant",
99
- } as const;
100
- export type AgentThoughtStreamingEventDataRole = ClosedEnum<
101
- typeof AgentThoughtStreamingEventDataRole
102
- >;
103
-
104
- /**
105
- * If the audio output modality is requested, this object contains data about the audio response from the model.
106
- */
107
- export type AgentThoughtStreamingEventAudio = {
108
- id: string;
109
- expiresAt: number;
110
- data: string;
111
- transcript: string;
112
- };
113
-
114
- /**
115
- * A chat completion message generated by the model.
116
- */
117
- export type AgentThoughtStreamingEventMessage = {
118
- content?: string | null | undefined;
119
- refusal?: string | null | undefined;
120
- toolCalls?: Array<AgentThoughtStreamingEventToolCalls> | undefined;
121
- role?: AgentThoughtStreamingEventDataRole | undefined;
122
- /**
123
- * Internal thought process of the model
124
- */
125
- reasoning?: string | null | undefined;
126
- /**
127
- * The signature holds a cryptographic token which verifies that the thinking block was generated by the model, and is verified when thinking is part of a multiturn conversation. This value should not be modified and should always be sent to the API when the reasoning is redacted. Currently only supported by `Anthropic`.
128
- */
129
- reasoningSignature?: string | null | undefined;
130
- /**
131
- * Occasionally the model's internal reasoning will be flagged by the safety systems of the provider. When this occurs, the provider will encrypt the reasoning. These redacted reasoning is decrypted when passed back to the API, allowing the model to continue its response without losing context.
132
- */
133
- redactedReasoning?: string | undefined;
134
- /**
135
- * If the audio output modality is requested, this object contains data about the audio response from the model.
136
- */
137
- audio?: AgentThoughtStreamingEventAudio | null | undefined;
138
- };
139
-
140
- export type TopLogprobs = {
141
- /**
142
- * The token.
143
- */
144
- token: string;
145
- /**
146
- * The log probability of this token, if it is within the top 20 most likely tokens. Otherwise, the value -9999.0 is used to signify that the token is very unlikely.
147
- */
148
- logprob: number;
149
- /**
150
- * A list of integers representing the UTF-8 bytes representation of the token.
151
- */
152
- bytes: Array<number> | null;
153
- };
154
-
155
- export type AgentThoughtStreamingEventContent = {
156
- /**
157
- * The token.
158
- */
159
- token: string;
160
- /**
161
- * The log probability of this token, if it is within the top 20 most likely tokens. Otherwise, the value -9999.0 is used to signify that the token is very unlikely.
162
- */
163
- logprob: number;
164
- /**
165
- * A list of integers representing the UTF-8 bytes representation of the token.
166
- */
167
- bytes: Array<number> | null;
168
- /**
169
- * List of the most likely tokens and their log probability, at this token position.
170
- */
171
- topLogprobs: Array<TopLogprobs>;
172
- };
173
-
174
- export type AgentThoughtStreamingEventTopLogprobs = {
175
- /**
176
- * The token.
177
- */
178
- token: string;
179
- /**
180
- * The log probability of this token, if it is within the top 20 most likely tokens. Otherwise, the value -9999.0 is used to signify that the token is very unlikely.
181
- */
182
- logprob: number;
183
- /**
184
- * A list of integers representing the UTF-8 bytes representation of the token.
185
- */
186
- bytes: Array<number> | null;
187
- };
188
-
189
- export type Refusal = {
190
- /**
191
- * The token.
192
- */
193
- token: string;
194
- /**
195
- * The log probability of this token, if it is within the top 20 most likely tokens. Otherwise, the value -9999.0 is used to signify that the token is very unlikely.
196
- */
197
- logprob: number;
198
- /**
199
- * A list of integers representing the UTF-8 bytes representation of the token.
200
- */
201
- bytes: Array<number> | null;
202
- /**
203
- * List of the most likely tokens and their log probability, at this token position.
204
- */
205
- topLogprobs: Array<AgentThoughtStreamingEventTopLogprobs>;
206
- };
207
-
208
- /**
209
- * Log probability information for the choice.
210
- */
211
- export type Logprobs = {
212
- /**
213
- * A list of message content tokens with log probability information.
214
- */
215
- content: Array<AgentThoughtStreamingEventContent> | null;
216
- /**
217
- * A list of message refusal tokens with log probability information.
218
- */
219
- refusal: Array<Refusal> | null;
220
- };
221
-
222
- export type Choice = {
223
- /**
224
- * The reason the model stopped generating tokens.
225
- */
226
- finishReason: AgentThoughtStreamingEventFinishReason | null;
227
- /**
228
- * The index of the choice in the list of choices.
229
- */
230
- index: number;
231
- /**
232
- * A chat completion message generated by the model.
233
- */
234
- message: AgentThoughtStreamingEventMessage;
235
- /**
236
- * Log probability information for the choice.
237
- */
238
- logprobs?: Logprobs | null | undefined;
239
- };
240
-
241
- export type AgentThoughtStreamingEventPromptTokensDetails = {
242
- cachedTokens?: number | null | undefined;
243
- cacheCreationTokens?: number | null | undefined;
244
- /**
245
- * The number of audio input tokens consumed by the request.
246
- */
247
- audioTokens?: number | null | undefined;
248
- };
249
-
250
- export type AgentThoughtStreamingEventCompletionTokensDetails = {
251
- reasoningTokens?: number | null | undefined;
252
- acceptedPredictionTokens?: number | null | undefined;
253
- rejectedPredictionTokens?: number | null | undefined;
254
- /**
255
- * The number of audio output tokens produced by the response.
256
- */
257
- audioTokens?: number | null | undefined;
258
- };
259
-
260
- /**
261
- * Usage statistics for the completion request.
262
- */
263
- export type AgentThoughtStreamingEventUsage = {
264
- /**
265
- * Number of tokens in the generated completion.
266
- */
267
- completionTokens?: number | undefined;
268
- /**
269
- * Number of tokens in the prompt.
270
- */
271
- promptTokens?: number | undefined;
272
- /**
273
- * Total number of tokens used in the request (prompt + completion).
274
- */
275
- totalTokens?: number | undefined;
276
- promptTokensDetails?:
277
- | AgentThoughtStreamingEventPromptTokensDetails
278
- | null
279
- | undefined;
280
- completionTokensDetails?:
281
- | AgentThoughtStreamingEventCompletionTokensDetails
282
- | null
283
- | undefined;
284
- };
285
-
286
- export type AgentThoughtStreamingEventData = {
287
- agentId: string;
288
- messageDifference: { [k: string]: MessageDifference };
289
- choice?: Choice | undefined;
290
- choiceIndex?: number | undefined;
291
- iteration: number;
292
- accumulatedExecutionTime: number;
293
- responseId?: string | undefined;
294
- /**
295
- * Usage statistics for the completion request.
296
- */
297
- usage?: AgentThoughtStreamingEventUsage | undefined;
298
- };
299
-
300
- /**
301
- * Emitted during agent reasoning. Contains the incremental message changes, model choices, iteration count, and token usage for this processing step.
302
- */
303
- export type AgentThoughtStreamingEvent = {
304
- type: "event.agents.thought";
305
- /**
306
- * ISO timestamp of the event
307
- */
308
- timestamp: string;
309
- data: AgentThoughtStreamingEventData;
310
- };
311
-
312
- /** @internal */
313
- export const AgentThoughtStreamingEventRole$inboundSchema: z.ZodNativeEnum<
314
- typeof AgentThoughtStreamingEventRole
315
- > = z.nativeEnum(AgentThoughtStreamingEventRole);
316
-
317
- /** @internal */
318
- export const AgentThoughtStreamingEventParts$inboundSchema: z.ZodType<
319
- AgentThoughtStreamingEventParts,
320
- z.ZodTypeDef,
321
- unknown
322
- > = z.union([
323
- TextPart$inboundSchema,
324
- ErrorPart$inboundSchema,
325
- DataPart$inboundSchema,
326
- FilePart$inboundSchema,
327
- ToolCallPart$inboundSchema,
328
- ToolResultPart$inboundSchema,
329
- ]);
330
-
331
- export function agentThoughtStreamingEventPartsFromJSON(
332
- jsonString: string,
333
- ): SafeParseResult<AgentThoughtStreamingEventParts, SDKValidationError> {
334
- return safeParse(
335
- jsonString,
336
- (x) => AgentThoughtStreamingEventParts$inboundSchema.parse(JSON.parse(x)),
337
- `Failed to parse 'AgentThoughtStreamingEventParts' from JSON`,
338
- );
339
- }
340
-
341
- /** @internal */
342
- export const MessageDifference$inboundSchema: z.ZodType<
343
- MessageDifference,
344
- z.ZodTypeDef,
345
- unknown
346
- > = z.object({
347
- messageId: z.string(),
348
- role: AgentThoughtStreamingEventRole$inboundSchema,
349
- parts: z.array(
350
- z.union([
351
- TextPart$inboundSchema,
352
- ErrorPart$inboundSchema,
353
- DataPart$inboundSchema,
354
- FilePart$inboundSchema,
355
- ToolCallPart$inboundSchema,
356
- ToolResultPart$inboundSchema,
357
- ]),
358
- ),
359
- metadata: z.record(z.any()).optional(),
360
- agent_id: z.string(),
361
- agent_execution_id: z.string(),
362
- workspace_id: z.string(),
363
- }).transform((v) => {
364
- return remap$(v, {
365
- "agent_id": "agentId",
366
- "agent_execution_id": "agentExecutionId",
367
- "workspace_id": "workspaceId",
368
- });
369
- });
370
-
371
- export function messageDifferenceFromJSON(
372
- jsonString: string,
373
- ): SafeParseResult<MessageDifference, SDKValidationError> {
374
- return safeParse(
375
- jsonString,
376
- (x) => MessageDifference$inboundSchema.parse(JSON.parse(x)),
377
- `Failed to parse 'MessageDifference' from JSON`,
378
- );
379
- }
380
-
381
- /** @internal */
382
- export const AgentThoughtStreamingEventFinishReason$inboundSchema:
383
- z.ZodNativeEnum<typeof AgentThoughtStreamingEventFinishReason> = z.nativeEnum(
384
- AgentThoughtStreamingEventFinishReason,
385
- );
386
-
387
- /** @internal */
388
- export const AgentThoughtStreamingEventDataType$inboundSchema: z.ZodNativeEnum<
389
- typeof AgentThoughtStreamingEventDataType
390
- > = z.nativeEnum(AgentThoughtStreamingEventDataType);
391
-
392
- /** @internal */
393
- export const AgentThoughtStreamingEventFunction$inboundSchema: z.ZodType<
394
- AgentThoughtStreamingEventFunction,
395
- z.ZodTypeDef,
396
- unknown
397
- > = z.object({
398
- name: z.string().optional(),
399
- arguments: z.string().optional(),
400
- });
401
-
402
- export function agentThoughtStreamingEventFunctionFromJSON(
403
- jsonString: string,
404
- ): SafeParseResult<AgentThoughtStreamingEventFunction, SDKValidationError> {
405
- return safeParse(
406
- jsonString,
407
- (x) =>
408
- AgentThoughtStreamingEventFunction$inboundSchema.parse(JSON.parse(x)),
409
- `Failed to parse 'AgentThoughtStreamingEventFunction' from JSON`,
410
- );
411
- }
412
-
413
- /** @internal */
414
- export const AgentThoughtStreamingEventToolCalls$inboundSchema: z.ZodType<
415
- AgentThoughtStreamingEventToolCalls,
416
- z.ZodTypeDef,
417
- unknown
418
- > = z.object({
419
- index: z.number().optional(),
420
- id: z.string().optional(),
421
- type: AgentThoughtStreamingEventDataType$inboundSchema.optional(),
422
- function: z.lazy(() => AgentThoughtStreamingEventFunction$inboundSchema)
423
- .optional(),
424
- thought_signature: z.string().optional(),
425
- }).transform((v) => {
426
- return remap$(v, {
427
- "thought_signature": "thoughtSignature",
428
- });
429
- });
430
-
431
- export function agentThoughtStreamingEventToolCallsFromJSON(
432
- jsonString: string,
433
- ): SafeParseResult<AgentThoughtStreamingEventToolCalls, SDKValidationError> {
434
- return safeParse(
435
- jsonString,
436
- (x) =>
437
- AgentThoughtStreamingEventToolCalls$inboundSchema.parse(JSON.parse(x)),
438
- `Failed to parse 'AgentThoughtStreamingEventToolCalls' from JSON`,
439
- );
440
- }
441
-
442
- /** @internal */
443
- export const AgentThoughtStreamingEventDataRole$inboundSchema: z.ZodNativeEnum<
444
- typeof AgentThoughtStreamingEventDataRole
445
- > = z.nativeEnum(AgentThoughtStreamingEventDataRole);
446
-
447
- /** @internal */
448
- export const AgentThoughtStreamingEventAudio$inboundSchema: z.ZodType<
449
- AgentThoughtStreamingEventAudio,
450
- z.ZodTypeDef,
451
- unknown
452
- > = z.object({
453
- id: z.string(),
454
- expires_at: z.number().int(),
455
- data: z.string(),
456
- transcript: z.string(),
457
- }).transform((v) => {
458
- return remap$(v, {
459
- "expires_at": "expiresAt",
460
- });
461
- });
462
-
463
- export function agentThoughtStreamingEventAudioFromJSON(
464
- jsonString: string,
465
- ): SafeParseResult<AgentThoughtStreamingEventAudio, SDKValidationError> {
466
- return safeParse(
467
- jsonString,
468
- (x) => AgentThoughtStreamingEventAudio$inboundSchema.parse(JSON.parse(x)),
469
- `Failed to parse 'AgentThoughtStreamingEventAudio' from JSON`,
470
- );
471
- }
472
-
473
- /** @internal */
474
- export const AgentThoughtStreamingEventMessage$inboundSchema: z.ZodType<
475
- AgentThoughtStreamingEventMessage,
476
- z.ZodTypeDef,
477
- unknown
478
- > = z.object({
479
- content: z.nullable(z.string()).optional(),
480
- refusal: z.nullable(z.string()).optional(),
481
- tool_calls: z.array(
482
- z.lazy(() => AgentThoughtStreamingEventToolCalls$inboundSchema),
483
- ).optional(),
484
- role: AgentThoughtStreamingEventDataRole$inboundSchema.optional(),
485
- reasoning: z.nullable(z.string()).optional(),
486
- reasoning_signature: z.nullable(z.string()).optional(),
487
- redacted_reasoning: z.string().optional(),
488
- audio: z.nullable(z.lazy(() => AgentThoughtStreamingEventAudio$inboundSchema))
489
- .optional(),
490
- }).transform((v) => {
491
- return remap$(v, {
492
- "tool_calls": "toolCalls",
493
- "reasoning_signature": "reasoningSignature",
494
- "redacted_reasoning": "redactedReasoning",
495
- });
496
- });
497
-
498
- export function agentThoughtStreamingEventMessageFromJSON(
499
- jsonString: string,
500
- ): SafeParseResult<AgentThoughtStreamingEventMessage, SDKValidationError> {
501
- return safeParse(
502
- jsonString,
503
- (x) => AgentThoughtStreamingEventMessage$inboundSchema.parse(JSON.parse(x)),
504
- `Failed to parse 'AgentThoughtStreamingEventMessage' from JSON`,
505
- );
506
- }
507
-
508
- /** @internal */
509
- export const TopLogprobs$inboundSchema: z.ZodType<
510
- TopLogprobs,
511
- z.ZodTypeDef,
512
- unknown
513
- > = z.object({
514
- token: z.string(),
515
- logprob: z.number(),
516
- bytes: z.nullable(z.array(z.number())),
517
- });
518
-
519
- export function topLogprobsFromJSON(
520
- jsonString: string,
521
- ): SafeParseResult<TopLogprobs, SDKValidationError> {
522
- return safeParse(
523
- jsonString,
524
- (x) => TopLogprobs$inboundSchema.parse(JSON.parse(x)),
525
- `Failed to parse 'TopLogprobs' from JSON`,
526
- );
527
- }
528
-
529
- /** @internal */
530
- export const AgentThoughtStreamingEventContent$inboundSchema: z.ZodType<
531
- AgentThoughtStreamingEventContent,
532
- z.ZodTypeDef,
533
- unknown
534
- > = z.object({
535
- token: z.string(),
536
- logprob: z.number(),
537
- bytes: z.nullable(z.array(z.number())),
538
- top_logprobs: z.array(z.lazy(() => TopLogprobs$inboundSchema)),
539
- }).transform((v) => {
540
- return remap$(v, {
541
- "top_logprobs": "topLogprobs",
542
- });
543
- });
544
-
545
- export function agentThoughtStreamingEventContentFromJSON(
546
- jsonString: string,
547
- ): SafeParseResult<AgentThoughtStreamingEventContent, SDKValidationError> {
548
- return safeParse(
549
- jsonString,
550
- (x) => AgentThoughtStreamingEventContent$inboundSchema.parse(JSON.parse(x)),
551
- `Failed to parse 'AgentThoughtStreamingEventContent' from JSON`,
552
- );
553
- }
554
-
555
- /** @internal */
556
- export const AgentThoughtStreamingEventTopLogprobs$inboundSchema: z.ZodType<
557
- AgentThoughtStreamingEventTopLogprobs,
558
- z.ZodTypeDef,
559
- unknown
560
- > = z.object({
561
- token: z.string(),
562
- logprob: z.number(),
563
- bytes: z.nullable(z.array(z.number())),
564
- });
565
-
566
- export function agentThoughtStreamingEventTopLogprobsFromJSON(
567
- jsonString: string,
568
- ): SafeParseResult<AgentThoughtStreamingEventTopLogprobs, SDKValidationError> {
569
- return safeParse(
570
- jsonString,
571
- (x) =>
572
- AgentThoughtStreamingEventTopLogprobs$inboundSchema.parse(JSON.parse(x)),
573
- `Failed to parse 'AgentThoughtStreamingEventTopLogprobs' from JSON`,
574
- );
575
- }
576
-
577
- /** @internal */
578
- export const Refusal$inboundSchema: z.ZodType<Refusal, z.ZodTypeDef, unknown> =
579
- z.object({
580
- token: z.string(),
581
- logprob: z.number(),
582
- bytes: z.nullable(z.array(z.number())),
583
- top_logprobs: z.array(
584
- z.lazy(() => AgentThoughtStreamingEventTopLogprobs$inboundSchema),
585
- ),
586
- }).transform((v) => {
587
- return remap$(v, {
588
- "top_logprobs": "topLogprobs",
589
- });
590
- });
591
-
592
- export function refusalFromJSON(
593
- jsonString: string,
594
- ): SafeParseResult<Refusal, SDKValidationError> {
595
- return safeParse(
596
- jsonString,
597
- (x) => Refusal$inboundSchema.parse(JSON.parse(x)),
598
- `Failed to parse 'Refusal' from JSON`,
599
- );
600
- }
601
-
602
- /** @internal */
603
- export const Logprobs$inboundSchema: z.ZodType<
604
- Logprobs,
605
- z.ZodTypeDef,
606
- unknown
607
- > = z.object({
608
- content: z.nullable(
609
- z.array(z.lazy(() => AgentThoughtStreamingEventContent$inboundSchema)),
610
- ),
611
- refusal: z.nullable(z.array(z.lazy(() => Refusal$inboundSchema))),
612
- });
613
-
614
- export function logprobsFromJSON(
615
- jsonString: string,
616
- ): SafeParseResult<Logprobs, SDKValidationError> {
617
- return safeParse(
618
- jsonString,
619
- (x) => Logprobs$inboundSchema.parse(JSON.parse(x)),
620
- `Failed to parse 'Logprobs' from JSON`,
621
- );
622
- }
623
-
624
- /** @internal */
625
- export const Choice$inboundSchema: z.ZodType<Choice, z.ZodTypeDef, unknown> = z
626
- .object({
627
- finish_reason: z.nullable(
628
- AgentThoughtStreamingEventFinishReason$inboundSchema,
629
- ),
630
- index: z.number().default(0),
631
- message: z.lazy(() => AgentThoughtStreamingEventMessage$inboundSchema),
632
- logprobs: z.nullable(z.lazy(() => Logprobs$inboundSchema)).optional(),
633
- }).transform((v) => {
634
- return remap$(v, {
635
- "finish_reason": "finishReason",
636
- });
637
- });
638
-
639
- export function choiceFromJSON(
640
- jsonString: string,
641
- ): SafeParseResult<Choice, SDKValidationError> {
642
- return safeParse(
643
- jsonString,
644
- (x) => Choice$inboundSchema.parse(JSON.parse(x)),
645
- `Failed to parse 'Choice' from JSON`,
646
- );
647
- }
648
-
649
- /** @internal */
650
- export const AgentThoughtStreamingEventPromptTokensDetails$inboundSchema:
651
- z.ZodType<
652
- AgentThoughtStreamingEventPromptTokensDetails,
653
- z.ZodTypeDef,
654
- unknown
655
- > = z.object({
656
- cached_tokens: z.nullable(z.number().int()).optional(),
657
- cache_creation_tokens: z.nullable(z.number().int()).optional(),
658
- audio_tokens: z.nullable(z.number().int()).optional(),
659
- }).transform((v) => {
660
- return remap$(v, {
661
- "cached_tokens": "cachedTokens",
662
- "cache_creation_tokens": "cacheCreationTokens",
663
- "audio_tokens": "audioTokens",
664
- });
665
- });
666
-
667
- export function agentThoughtStreamingEventPromptTokensDetailsFromJSON(
668
- jsonString: string,
669
- ): SafeParseResult<
670
- AgentThoughtStreamingEventPromptTokensDetails,
671
- SDKValidationError
672
- > {
673
- return safeParse(
674
- jsonString,
675
- (x) =>
676
- AgentThoughtStreamingEventPromptTokensDetails$inboundSchema.parse(
677
- JSON.parse(x),
678
- ),
679
- `Failed to parse 'AgentThoughtStreamingEventPromptTokensDetails' from JSON`,
680
- );
681
- }
682
-
683
- /** @internal */
684
- export const AgentThoughtStreamingEventCompletionTokensDetails$inboundSchema:
685
- z.ZodType<
686
- AgentThoughtStreamingEventCompletionTokensDetails,
687
- z.ZodTypeDef,
688
- unknown
689
- > = z.object({
690
- reasoning_tokens: z.nullable(z.number()).optional(),
691
- accepted_prediction_tokens: z.nullable(z.number()).optional(),
692
- rejected_prediction_tokens: z.nullable(z.number()).optional(),
693
- audio_tokens: z.nullable(z.number().int()).optional(),
694
- }).transform((v) => {
695
- return remap$(v, {
696
- "reasoning_tokens": "reasoningTokens",
697
- "accepted_prediction_tokens": "acceptedPredictionTokens",
698
- "rejected_prediction_tokens": "rejectedPredictionTokens",
699
- "audio_tokens": "audioTokens",
700
- });
701
- });
702
-
703
- export function agentThoughtStreamingEventCompletionTokensDetailsFromJSON(
704
- jsonString: string,
705
- ): SafeParseResult<
706
- AgentThoughtStreamingEventCompletionTokensDetails,
707
- SDKValidationError
708
- > {
709
- return safeParse(
710
- jsonString,
711
- (x) =>
712
- AgentThoughtStreamingEventCompletionTokensDetails$inboundSchema.parse(
713
- JSON.parse(x),
714
- ),
715
- `Failed to parse 'AgentThoughtStreamingEventCompletionTokensDetails' from JSON`,
716
- );
717
- }
718
-
719
- /** @internal */
720
- export const AgentThoughtStreamingEventUsage$inboundSchema: z.ZodType<
721
- AgentThoughtStreamingEventUsage,
722
- z.ZodTypeDef,
723
- unknown
724
- > = z.object({
725
- completion_tokens: z.number().optional(),
726
- prompt_tokens: z.number().optional(),
727
- total_tokens: z.number().optional(),
728
- prompt_tokens_details: z.nullable(
729
- z.lazy(() => AgentThoughtStreamingEventPromptTokensDetails$inboundSchema),
730
- ).optional(),
731
- completion_tokens_details: z.nullable(
732
- z.lazy(() =>
733
- AgentThoughtStreamingEventCompletionTokensDetails$inboundSchema
734
- ),
735
- ).optional(),
736
- }).transform((v) => {
737
- return remap$(v, {
738
- "completion_tokens": "completionTokens",
739
- "prompt_tokens": "promptTokens",
740
- "total_tokens": "totalTokens",
741
- "prompt_tokens_details": "promptTokensDetails",
742
- "completion_tokens_details": "completionTokensDetails",
743
- });
744
- });
745
-
746
- export function agentThoughtStreamingEventUsageFromJSON(
747
- jsonString: string,
748
- ): SafeParseResult<AgentThoughtStreamingEventUsage, SDKValidationError> {
749
- return safeParse(
750
- jsonString,
751
- (x) => AgentThoughtStreamingEventUsage$inboundSchema.parse(JSON.parse(x)),
752
- `Failed to parse 'AgentThoughtStreamingEventUsage' from JSON`,
753
- );
754
- }
755
-
756
- /** @internal */
757
- export const AgentThoughtStreamingEventData$inboundSchema: z.ZodType<
758
- AgentThoughtStreamingEventData,
759
- z.ZodTypeDef,
760
- unknown
761
- > = z.object({
762
- agent_id: z.string(),
763
- message_difference: z.record(z.lazy(() => MessageDifference$inboundSchema)),
764
- choice: z.lazy(() => Choice$inboundSchema).optional(),
765
- choiceIndex: z.number().optional(),
766
- iteration: z.number(),
767
- accumulated_execution_time: z.number(),
768
- responseId: z.string().optional(),
769
- usage: z.lazy(() => AgentThoughtStreamingEventUsage$inboundSchema).optional(),
770
- }).transform((v) => {
771
- return remap$(v, {
772
- "agent_id": "agentId",
773
- "message_difference": "messageDifference",
774
- "accumulated_execution_time": "accumulatedExecutionTime",
775
- });
776
- });
777
-
778
- export function agentThoughtStreamingEventDataFromJSON(
779
- jsonString: string,
780
- ): SafeParseResult<AgentThoughtStreamingEventData, SDKValidationError> {
781
- return safeParse(
782
- jsonString,
783
- (x) => AgentThoughtStreamingEventData$inboundSchema.parse(JSON.parse(x)),
784
- `Failed to parse 'AgentThoughtStreamingEventData' from JSON`,
785
- );
786
- }
787
-
788
- /** @internal */
789
- export const AgentThoughtStreamingEvent$inboundSchema: z.ZodType<
790
- AgentThoughtStreamingEvent,
791
- z.ZodTypeDef,
792
- unknown
793
- > = z.object({
794
- type: z.literal("event.agents.thought"),
795
- timestamp: z.string(),
796
- data: z.lazy(() => AgentThoughtStreamingEventData$inboundSchema),
797
- });
798
-
799
- export function agentThoughtStreamingEventFromJSON(
800
- jsonString: string,
801
- ): SafeParseResult<AgentThoughtStreamingEvent, SDKValidationError> {
802
- return safeParse(
803
- jsonString,
804
- (x) => AgentThoughtStreamingEvent$inboundSchema.parse(JSON.parse(x)),
805
- `Failed to parse 'AgentThoughtStreamingEvent' from JSON`,
806
- );
807
- }