@allbluecn/database 0.4.0 → 0.4.1

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 (190) hide show
  1. package/desktop-init.ts +128 -0
  2. package/generated/browser.ts +494 -0
  3. package/generated/client.ts +518 -0
  4. package/generated/commonInputTypes.ts +1056 -0
  5. package/generated/enums.ts +93 -0
  6. package/generated/internal/class.ts +1144 -0
  7. package/generated/internal/prismaNamespace.ts +9603 -0
  8. package/generated/internal/prismaNamespaceBrowser.ts +1695 -0
  9. package/generated/models/Account.ts +1648 -0
  10. package/generated/models/AgentConversation.ts +1651 -0
  11. package/generated/models/AgentMessage.ts +1409 -0
  12. package/generated/models/AiProvider.ts +1607 -0
  13. package/generated/models/AiProviderConfig.ts +1514 -0
  14. package/generated/models/AiUsageLog.ts +1863 -0
  15. package/generated/models/AnyHubApp.ts +1911 -0
  16. package/generated/models/AnyHubMarketApp.ts +2008 -0
  17. package/generated/models/AnyHubPermission.ts +1422 -0
  18. package/generated/models/AnyHubRecommendation.ts +1870 -0
  19. package/generated/models/AnyHubRecommender.ts +1471 -0
  20. package/generated/models/Artboard.ts +1811 -0
  21. package/generated/models/ArtboardExport.ts +1548 -0
  22. package/generated/models/ArticleFavorite.ts +1352 -0
  23. package/generated/models/AuditLog.ts +1533 -0
  24. package/generated/models/Block.ts +1650 -0
  25. package/generated/models/BlockComponent.ts +1734 -0
  26. package/generated/models/BlockInstance.ts +2043 -0
  27. package/generated/models/BookmarkCategory.ts +1670 -0
  28. package/generated/models/ChatInterrupt.ts +1699 -0
  29. package/generated/models/ChatMessage.ts +1438 -0
  30. package/generated/models/ChatRun.ts +1632 -0
  31. package/generated/models/ChatThread.ts +2133 -0
  32. package/generated/models/Comment.ts +2206 -0
  33. package/generated/models/CommentIgnore.ts +1430 -0
  34. package/generated/models/CommentReaction.ts +1472 -0
  35. package/generated/models/ComplianceExport.ts +1345 -0
  36. package/generated/models/Component.ts +2345 -0
  37. package/generated/models/ComponentInstance.ts +2102 -0
  38. package/generated/models/ComponentTag.ts +1281 -0
  39. package/generated/models/CustomRole.ts +1560 -0
  40. package/generated/models/DesignProject.ts +1643 -0
  41. package/generated/models/DictionaryTerm.ts +1642 -0
  42. package/generated/models/GenerationRun.ts +1543 -0
  43. package/generated/models/IndustryCompliance.ts +1797 -0
  44. package/generated/models/InvitationCode.ts +1417 -0
  45. package/generated/models/InvitationUse.ts +1424 -0
  46. package/generated/models/Invoice.ts +1710 -0
  47. package/generated/models/KnowledgeBase.ts +1671 -0
  48. package/generated/models/KnowledgeDocument.ts +2458 -0
  49. package/generated/models/KnowledgeShareRecord.ts +1352 -0
  50. package/generated/models/Label.ts +1482 -0
  51. package/generated/models/LegalRegulation.ts +1873 -0
  52. package/generated/models/LicenseActivation.ts +1415 -0
  53. package/generated/models/LicenseKey.ts +1884 -0
  54. package/generated/models/LoginLog.ts +1450 -0
  55. package/generated/models/MonitoringErrorReport.ts +1299 -0
  56. package/generated/models/MonitoringHealthSnapshot.ts +1249 -0
  57. package/generated/models/MonitoringMetricsSnapshot.ts +1369 -0
  58. package/generated/models/MonitoringRequestLog.ts +1283 -0
  59. package/generated/models/PRD.ts +2805 -0
  60. package/generated/models/PRDPage.ts +2402 -0
  61. package/generated/models/PRDTag.ts +1430 -0
  62. package/generated/models/PRDVersion.ts +2121 -0
  63. package/generated/models/PageVersion.ts +1523 -0
  64. package/generated/models/PasswordResetToken.ts +1380 -0
  65. package/generated/models/Plan.ts +2069 -0
  66. package/generated/models/Project.ts +2148 -0
  67. package/generated/models/ProjectActivity.ts +1582 -0
  68. package/generated/models/ProjectMember.ts +1512 -0
  69. package/generated/models/ProviderEvent.ts +1227 -0
  70. package/generated/models/Reference.ts +1177 -0
  71. package/generated/models/Review.ts +1912 -0
  72. package/generated/models/ReviewComment.ts +1904 -0
  73. package/generated/models/RoleAssignment.ts +1430 -0
  74. package/generated/models/SequenceCounter.ts +1137 -0
  75. package/generated/models/Share.ts +1681 -0
  76. package/generated/models/ShareVersion.ts +1389 -0
  77. package/generated/models/SsoMapping.ts +1512 -0
  78. package/generated/models/SsoProvider.ts +1639 -0
  79. package/generated/models/Story.ts +5234 -0
  80. package/generated/models/StoryActivity.ts +1664 -0
  81. package/generated/models/StoryAttachment.ts +1467 -0
  82. package/generated/models/StoryComment.ts +1992 -0
  83. package/generated/models/StoryDependency.ts +1517 -0
  84. package/generated/models/StoryDocLink.ts +1430 -0
  85. package/generated/models/StoryFilterView.ts +1587 -0
  86. package/generated/models/StoryLabel.ts +1349 -0
  87. package/generated/models/StoryLink.ts +1415 -0
  88. package/generated/models/StoryPrdLink.ts +1430 -0
  89. package/generated/models/StoryReaction.ts +1472 -0
  90. package/generated/models/Subscription.ts +2147 -0
  91. package/generated/models/SystemSetting.ts +1217 -0
  92. package/generated/models/Tag.ts +1655 -0
  93. package/generated/models/TeamInvitation.ts +1526 -0
  94. package/generated/models/TeamMembership.ts +1436 -0
  95. package/generated/models/Template.ts +1391 -0
  96. package/generated/models/TemplateBlock.ts +1664 -0
  97. package/generated/models/ThirdPartyDependency.ts +1473 -0
  98. package/generated/models/UsageRecord.ts +1505 -0
  99. package/generated/models/User.ts +20998 -0
  100. package/generated/models/UserAgent.ts +1900 -0
  101. package/generated/models/UserSkill.ts +1456 -0
  102. package/generated/models/WebsiteBookmark.ts +2219 -0
  103. package/generated/models/Workspace.ts +2279 -0
  104. package/generated/models.ts +106 -0
  105. package/generated-sqlite/browser.ts +399 -0
  106. package/generated-sqlite/client.ts +423 -0
  107. package/generated-sqlite/commonInputTypes.ts +608 -0
  108. package/generated-sqlite/enums.ts +15 -0
  109. package/generated-sqlite/internal/class.ts +954 -0
  110. package/generated-sqlite/internal/prismaNamespace.ts +7716 -0
  111. package/generated-sqlite/internal/prismaNamespaceBrowser.ts +1415 -0
  112. package/generated-sqlite/models/AgentConversation.ts +1647 -0
  113. package/generated-sqlite/models/AgentMessage.ts +1406 -0
  114. package/generated-sqlite/models/AiProvider.ts +1605 -0
  115. package/generated-sqlite/models/AiProviderConfig.ts +1511 -0
  116. package/generated-sqlite/models/AiUsageLog.ts +1845 -0
  117. package/generated-sqlite/models/AnyHubApp.ts +1908 -0
  118. package/generated-sqlite/models/AnyHubMarketApp.ts +1997 -0
  119. package/generated-sqlite/models/AnyHubPermission.ts +1419 -0
  120. package/generated-sqlite/models/AnyHubRecommendation.ts +1867 -0
  121. package/generated-sqlite/models/AnyHubRecommender.ts +1467 -0
  122. package/generated-sqlite/models/Artboard.ts +1808 -0
  123. package/generated-sqlite/models/ArtboardExport.ts +1545 -0
  124. package/generated-sqlite/models/ArticleFavorite.ts +1349 -0
  125. package/generated-sqlite/models/AuditLog.ts +1287 -0
  126. package/generated-sqlite/models/Block.ts +1648 -0
  127. package/generated-sqlite/models/BlockComponent.ts +1730 -0
  128. package/generated-sqlite/models/BlockInstance.ts +2039 -0
  129. package/generated-sqlite/models/BookmarkCategory.ts +1667 -0
  130. package/generated-sqlite/models/ChatInterrupt.ts +1695 -0
  131. package/generated-sqlite/models/ChatMessage.ts +1435 -0
  132. package/generated-sqlite/models/ChatRun.ts +1629 -0
  133. package/generated-sqlite/models/ChatThread.ts +2129 -0
  134. package/generated-sqlite/models/Comment.ts +2201 -0
  135. package/generated-sqlite/models/CommentIgnore.ts +1426 -0
  136. package/generated-sqlite/models/ComplianceExport.ts +1343 -0
  137. package/generated-sqlite/models/Component.ts +2326 -0
  138. package/generated-sqlite/models/ComponentInstance.ts +2097 -0
  139. package/generated-sqlite/models/ComponentTag.ts +1278 -0
  140. package/generated-sqlite/models/CustomRole.ts +1209 -0
  141. package/generated-sqlite/models/DesignProject.ts +1640 -0
  142. package/generated-sqlite/models/DictionaryTerm.ts +1639 -0
  143. package/generated-sqlite/models/GenerationRun.ts +1540 -0
  144. package/generated-sqlite/models/IndustryCompliance.ts +1794 -0
  145. package/generated-sqlite/models/InvitationCode.ts +1415 -0
  146. package/generated-sqlite/models/InvitationUse.ts +1420 -0
  147. package/generated-sqlite/models/Invoice.ts +1707 -0
  148. package/generated-sqlite/models/KnowledgeBase.ts +1668 -0
  149. package/generated-sqlite/models/KnowledgeDocument.ts +2282 -0
  150. package/generated-sqlite/models/KnowledgeShareRecord.ts +1349 -0
  151. package/generated-sqlite/models/LegalRegulation.ts +1870 -0
  152. package/generated-sqlite/models/LicenseActivation.ts +1203 -0
  153. package/generated-sqlite/models/LicenseKey.ts +1443 -0
  154. package/generated-sqlite/models/LoginLog.ts +1447 -0
  155. package/generated-sqlite/models/PRD.ts +2616 -0
  156. package/generated-sqlite/models/PRDPage.ts +2398 -0
  157. package/generated-sqlite/models/PRDTag.ts +1426 -0
  158. package/generated-sqlite/models/PRDVersion.ts +2117 -0
  159. package/generated-sqlite/models/PageVersion.ts +1528 -0
  160. package/generated-sqlite/models/PasswordResetToken.ts +1377 -0
  161. package/generated-sqlite/models/Plan.ts +2060 -0
  162. package/generated-sqlite/models/Project.ts +1994 -0
  163. package/generated-sqlite/models/ProjectActivity.ts +1578 -0
  164. package/generated-sqlite/models/ProjectMember.ts +1508 -0
  165. package/generated-sqlite/models/ProviderEvent.ts +1225 -0
  166. package/generated-sqlite/models/Reference.ts +1175 -0
  167. package/generated-sqlite/models/Review.ts +1903 -0
  168. package/generated-sqlite/models/ReviewComment.ts +1899 -0
  169. package/generated-sqlite/models/RoleAssignment.ts +1125 -0
  170. package/generated-sqlite/models/Share.ts +1674 -0
  171. package/generated-sqlite/models/ShareVersion.ts +1385 -0
  172. package/generated-sqlite/models/SsoMapping.ts +1181 -0
  173. package/generated-sqlite/models/SsoProvider.ts +1266 -0
  174. package/generated-sqlite/models/Subscription.ts +2137 -0
  175. package/generated-sqlite/models/SystemSetting.ts +1215 -0
  176. package/generated-sqlite/models/Tag.ts +1652 -0
  177. package/generated-sqlite/models/TeamInvitation.ts +1523 -0
  178. package/generated-sqlite/models/TeamMembership.ts +1433 -0
  179. package/generated-sqlite/models/Template.ts +1389 -0
  180. package/generated-sqlite/models/TemplateBlock.ts +1660 -0
  181. package/generated-sqlite/models/ThirdPartyDependency.ts +1471 -0
  182. package/generated-sqlite/models/UsageRecord.ts +1498 -0
  183. package/generated-sqlite/models/User.ts +13558 -0
  184. package/generated-sqlite/models/UserAgent.ts +1897 -0
  185. package/generated-sqlite/models/UserSkill.ts +1453 -0
  186. package/generated-sqlite/models/WebsiteBookmark.ts +2215 -0
  187. package/generated-sqlite/models/Workspace.ts +1824 -0
  188. package/generated-sqlite/models.ts +87 -0
  189. package/package.json +7 -3
  190. package/LICENSE +0 -661
@@ -0,0 +1,2133 @@
1
+
2
+ /* !!! This is code generated by Prisma. Do not edit directly. !!! */
3
+ /* eslint-disable */
4
+ // biome-ignore-all lint: generated file
5
+ // @ts-nocheck
6
+ /*
7
+ * This file exports the `ChatThread` model and its related types.
8
+ *
9
+ * 🟢 You can import this file directly.
10
+ */
11
+ import type * as runtime from "@prisma/client/runtime/client"
12
+ import type * as $Enums from "../enums"
13
+ import type * as Prisma from "../internal/prismaNamespace"
14
+
15
+ /**
16
+ * Model ChatThread
17
+ *
18
+ */
19
+ export type ChatThreadModel = runtime.Types.Result.DefaultSelection<Prisma.$ChatThreadPayload>
20
+
21
+ export type AggregateChatThread = {
22
+ _count: ChatThreadCountAggregateOutputType | null
23
+ _min: ChatThreadMinAggregateOutputType | null
24
+ _max: ChatThreadMaxAggregateOutputType | null
25
+ }
26
+
27
+ export type ChatThreadMinAggregateOutputType = {
28
+ id: string | null
29
+ userId: string | null
30
+ title: string | null
31
+ isArchived: boolean | null
32
+ createdAt: Date | null
33
+ updatedAt: Date | null
34
+ agentId: string | null
35
+ }
36
+
37
+ export type ChatThreadMaxAggregateOutputType = {
38
+ id: string | null
39
+ userId: string | null
40
+ title: string | null
41
+ isArchived: boolean | null
42
+ createdAt: Date | null
43
+ updatedAt: Date | null
44
+ agentId: string | null
45
+ }
46
+
47
+ export type ChatThreadCountAggregateOutputType = {
48
+ id: number
49
+ userId: number
50
+ title: number
51
+ isArchived: number
52
+ createdAt: number
53
+ updatedAt: number
54
+ agentId: number
55
+ _all: number
56
+ }
57
+
58
+
59
+ export type ChatThreadMinAggregateInputType = {
60
+ id?: true
61
+ userId?: true
62
+ title?: true
63
+ isArchived?: true
64
+ createdAt?: true
65
+ updatedAt?: true
66
+ agentId?: true
67
+ }
68
+
69
+ export type ChatThreadMaxAggregateInputType = {
70
+ id?: true
71
+ userId?: true
72
+ title?: true
73
+ isArchived?: true
74
+ createdAt?: true
75
+ updatedAt?: true
76
+ agentId?: true
77
+ }
78
+
79
+ export type ChatThreadCountAggregateInputType = {
80
+ id?: true
81
+ userId?: true
82
+ title?: true
83
+ isArchived?: true
84
+ createdAt?: true
85
+ updatedAt?: true
86
+ agentId?: true
87
+ _all?: true
88
+ }
89
+
90
+ export type ChatThreadAggregateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
91
+ /**
92
+ * Filter which ChatThread to aggregate.
93
+ */
94
+ where?: Prisma.ChatThreadWhereInput
95
+ /**
96
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
97
+ *
98
+ * Determine the order of ChatThreads to fetch.
99
+ */
100
+ orderBy?: Prisma.ChatThreadOrderByWithRelationInput | Prisma.ChatThreadOrderByWithRelationInput[]
101
+ /**
102
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
103
+ *
104
+ * Sets the start position
105
+ */
106
+ cursor?: Prisma.ChatThreadWhereUniqueInput
107
+ /**
108
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
109
+ *
110
+ * Take `±n` ChatThreads from the position of the cursor.
111
+ */
112
+ take?: number
113
+ /**
114
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
115
+ *
116
+ * Skip the first `n` ChatThreads.
117
+ */
118
+ skip?: number
119
+ /**
120
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
121
+ *
122
+ * Count returned ChatThreads
123
+ **/
124
+ _count?: true | ChatThreadCountAggregateInputType
125
+ /**
126
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
127
+ *
128
+ * Select which fields to find the minimum value
129
+ **/
130
+ _min?: ChatThreadMinAggregateInputType
131
+ /**
132
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
133
+ *
134
+ * Select which fields to find the maximum value
135
+ **/
136
+ _max?: ChatThreadMaxAggregateInputType
137
+ }
138
+
139
+ export type GetChatThreadAggregateType<T extends ChatThreadAggregateArgs> = {
140
+ [P in keyof T & keyof AggregateChatThread]: P extends '_count' | 'count'
141
+ ? T[P] extends true
142
+ ? number
143
+ : Prisma.GetScalarType<T[P], AggregateChatThread[P]>
144
+ : Prisma.GetScalarType<T[P], AggregateChatThread[P]>
145
+ }
146
+
147
+
148
+
149
+
150
+ export type ChatThreadGroupByArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
151
+ where?: Prisma.ChatThreadWhereInput
152
+ orderBy?: Prisma.ChatThreadOrderByWithAggregationInput | Prisma.ChatThreadOrderByWithAggregationInput[]
153
+ by: Prisma.ChatThreadScalarFieldEnum[] | Prisma.ChatThreadScalarFieldEnum
154
+ having?: Prisma.ChatThreadScalarWhereWithAggregatesInput
155
+ take?: number
156
+ skip?: number
157
+ _count?: ChatThreadCountAggregateInputType | true
158
+ _min?: ChatThreadMinAggregateInputType
159
+ _max?: ChatThreadMaxAggregateInputType
160
+ }
161
+
162
+ export type ChatThreadGroupByOutputType = {
163
+ id: string
164
+ userId: string
165
+ title: string | null
166
+ isArchived: boolean
167
+ createdAt: Date
168
+ updatedAt: Date
169
+ agentId: string | null
170
+ _count: ChatThreadCountAggregateOutputType | null
171
+ _min: ChatThreadMinAggregateOutputType | null
172
+ _max: ChatThreadMaxAggregateOutputType | null
173
+ }
174
+
175
+ export type GetChatThreadGroupByPayload<T extends ChatThreadGroupByArgs> = Prisma.PrismaPromise<
176
+ Array<
177
+ Prisma.PickEnumerable<ChatThreadGroupByOutputType, T['by']> &
178
+ {
179
+ [P in ((keyof T) & (keyof ChatThreadGroupByOutputType))]: P extends '_count'
180
+ ? T[P] extends boolean
181
+ ? number
182
+ : Prisma.GetScalarType<T[P], ChatThreadGroupByOutputType[P]>
183
+ : Prisma.GetScalarType<T[P], ChatThreadGroupByOutputType[P]>
184
+ }
185
+ >
186
+ >
187
+
188
+
189
+
190
+ export type ChatThreadWhereInput = {
191
+ AND?: Prisma.ChatThreadWhereInput | Prisma.ChatThreadWhereInput[]
192
+ OR?: Prisma.ChatThreadWhereInput[]
193
+ NOT?: Prisma.ChatThreadWhereInput | Prisma.ChatThreadWhereInput[]
194
+ id?: Prisma.StringFilter<"ChatThread"> | string
195
+ userId?: Prisma.StringFilter<"ChatThread"> | string
196
+ title?: Prisma.StringNullableFilter<"ChatThread"> | string | null
197
+ isArchived?: Prisma.BoolFilter<"ChatThread"> | boolean
198
+ createdAt?: Prisma.DateTimeFilter<"ChatThread"> | Date | string
199
+ updatedAt?: Prisma.DateTimeFilter<"ChatThread"> | Date | string
200
+ agentId?: Prisma.StringNullableFilter<"ChatThread"> | string | null
201
+ user?: Prisma.XOR<Prisma.UserScalarRelationFilter, Prisma.UserWhereInput>
202
+ messages?: Prisma.ChatMessageListRelationFilter
203
+ runs?: Prisma.ChatRunListRelationFilter
204
+ interrupts?: Prisma.ChatInterruptListRelationFilter
205
+ generations?: Prisma.GenerationRunListRelationFilter
206
+ agent?: Prisma.XOR<Prisma.UserAgentNullableScalarRelationFilter, Prisma.UserAgentWhereInput> | null
207
+ }
208
+
209
+ export type ChatThreadOrderByWithRelationInput = {
210
+ id?: Prisma.SortOrder
211
+ userId?: Prisma.SortOrder
212
+ title?: Prisma.SortOrderInput | Prisma.SortOrder
213
+ isArchived?: Prisma.SortOrder
214
+ createdAt?: Prisma.SortOrder
215
+ updatedAt?: Prisma.SortOrder
216
+ agentId?: Prisma.SortOrderInput | Prisma.SortOrder
217
+ user?: Prisma.UserOrderByWithRelationInput
218
+ messages?: Prisma.ChatMessageOrderByRelationAggregateInput
219
+ runs?: Prisma.ChatRunOrderByRelationAggregateInput
220
+ interrupts?: Prisma.ChatInterruptOrderByRelationAggregateInput
221
+ generations?: Prisma.GenerationRunOrderByRelationAggregateInput
222
+ agent?: Prisma.UserAgentOrderByWithRelationInput
223
+ }
224
+
225
+ export type ChatThreadWhereUniqueInput = Prisma.AtLeast<{
226
+ id?: string
227
+ AND?: Prisma.ChatThreadWhereInput | Prisma.ChatThreadWhereInput[]
228
+ OR?: Prisma.ChatThreadWhereInput[]
229
+ NOT?: Prisma.ChatThreadWhereInput | Prisma.ChatThreadWhereInput[]
230
+ userId?: Prisma.StringFilter<"ChatThread"> | string
231
+ title?: Prisma.StringNullableFilter<"ChatThread"> | string | null
232
+ isArchived?: Prisma.BoolFilter<"ChatThread"> | boolean
233
+ createdAt?: Prisma.DateTimeFilter<"ChatThread"> | Date | string
234
+ updatedAt?: Prisma.DateTimeFilter<"ChatThread"> | Date | string
235
+ agentId?: Prisma.StringNullableFilter<"ChatThread"> | string | null
236
+ user?: Prisma.XOR<Prisma.UserScalarRelationFilter, Prisma.UserWhereInput>
237
+ messages?: Prisma.ChatMessageListRelationFilter
238
+ runs?: Prisma.ChatRunListRelationFilter
239
+ interrupts?: Prisma.ChatInterruptListRelationFilter
240
+ generations?: Prisma.GenerationRunListRelationFilter
241
+ agent?: Prisma.XOR<Prisma.UserAgentNullableScalarRelationFilter, Prisma.UserAgentWhereInput> | null
242
+ }, "id">
243
+
244
+ export type ChatThreadOrderByWithAggregationInput = {
245
+ id?: Prisma.SortOrder
246
+ userId?: Prisma.SortOrder
247
+ title?: Prisma.SortOrderInput | Prisma.SortOrder
248
+ isArchived?: Prisma.SortOrder
249
+ createdAt?: Prisma.SortOrder
250
+ updatedAt?: Prisma.SortOrder
251
+ agentId?: Prisma.SortOrderInput | Prisma.SortOrder
252
+ _count?: Prisma.ChatThreadCountOrderByAggregateInput
253
+ _max?: Prisma.ChatThreadMaxOrderByAggregateInput
254
+ _min?: Prisma.ChatThreadMinOrderByAggregateInput
255
+ }
256
+
257
+ export type ChatThreadScalarWhereWithAggregatesInput = {
258
+ AND?: Prisma.ChatThreadScalarWhereWithAggregatesInput | Prisma.ChatThreadScalarWhereWithAggregatesInput[]
259
+ OR?: Prisma.ChatThreadScalarWhereWithAggregatesInput[]
260
+ NOT?: Prisma.ChatThreadScalarWhereWithAggregatesInput | Prisma.ChatThreadScalarWhereWithAggregatesInput[]
261
+ id?: Prisma.StringWithAggregatesFilter<"ChatThread"> | string
262
+ userId?: Prisma.StringWithAggregatesFilter<"ChatThread"> | string
263
+ title?: Prisma.StringNullableWithAggregatesFilter<"ChatThread"> | string | null
264
+ isArchived?: Prisma.BoolWithAggregatesFilter<"ChatThread"> | boolean
265
+ createdAt?: Prisma.DateTimeWithAggregatesFilter<"ChatThread"> | Date | string
266
+ updatedAt?: Prisma.DateTimeWithAggregatesFilter<"ChatThread"> | Date | string
267
+ agentId?: Prisma.StringNullableWithAggregatesFilter<"ChatThread"> | string | null
268
+ }
269
+
270
+ export type ChatThreadCreateInput = {
271
+ id?: string
272
+ title?: string | null
273
+ isArchived?: boolean
274
+ createdAt?: Date | string
275
+ updatedAt?: Date | string
276
+ user: Prisma.UserCreateNestedOneWithoutChatThreadsInput
277
+ messages?: Prisma.ChatMessageCreateNestedManyWithoutThreadInput
278
+ runs?: Prisma.ChatRunCreateNestedManyWithoutThreadInput
279
+ interrupts?: Prisma.ChatInterruptCreateNestedManyWithoutThreadInput
280
+ generations?: Prisma.GenerationRunCreateNestedManyWithoutThreadInput
281
+ agent?: Prisma.UserAgentCreateNestedOneWithoutThreadsInput
282
+ }
283
+
284
+ export type ChatThreadUncheckedCreateInput = {
285
+ id?: string
286
+ userId: string
287
+ title?: string | null
288
+ isArchived?: boolean
289
+ createdAt?: Date | string
290
+ updatedAt?: Date | string
291
+ agentId?: string | null
292
+ messages?: Prisma.ChatMessageUncheckedCreateNestedManyWithoutThreadInput
293
+ runs?: Prisma.ChatRunUncheckedCreateNestedManyWithoutThreadInput
294
+ interrupts?: Prisma.ChatInterruptUncheckedCreateNestedManyWithoutThreadInput
295
+ generations?: Prisma.GenerationRunUncheckedCreateNestedManyWithoutThreadInput
296
+ }
297
+
298
+ export type ChatThreadUpdateInput = {
299
+ id?: Prisma.StringFieldUpdateOperationsInput | string
300
+ title?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
301
+ isArchived?: Prisma.BoolFieldUpdateOperationsInput | boolean
302
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
303
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
304
+ user?: Prisma.UserUpdateOneRequiredWithoutChatThreadsNestedInput
305
+ messages?: Prisma.ChatMessageUpdateManyWithoutThreadNestedInput
306
+ runs?: Prisma.ChatRunUpdateManyWithoutThreadNestedInput
307
+ interrupts?: Prisma.ChatInterruptUpdateManyWithoutThreadNestedInput
308
+ generations?: Prisma.GenerationRunUpdateManyWithoutThreadNestedInput
309
+ agent?: Prisma.UserAgentUpdateOneWithoutThreadsNestedInput
310
+ }
311
+
312
+ export type ChatThreadUncheckedUpdateInput = {
313
+ id?: Prisma.StringFieldUpdateOperationsInput | string
314
+ userId?: Prisma.StringFieldUpdateOperationsInput | string
315
+ title?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
316
+ isArchived?: Prisma.BoolFieldUpdateOperationsInput | boolean
317
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
318
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
319
+ agentId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
320
+ messages?: Prisma.ChatMessageUncheckedUpdateManyWithoutThreadNestedInput
321
+ runs?: Prisma.ChatRunUncheckedUpdateManyWithoutThreadNestedInput
322
+ interrupts?: Prisma.ChatInterruptUncheckedUpdateManyWithoutThreadNestedInput
323
+ generations?: Prisma.GenerationRunUncheckedUpdateManyWithoutThreadNestedInput
324
+ }
325
+
326
+ export type ChatThreadCreateManyInput = {
327
+ id?: string
328
+ userId: string
329
+ title?: string | null
330
+ isArchived?: boolean
331
+ createdAt?: Date | string
332
+ updatedAt?: Date | string
333
+ agentId?: string | null
334
+ }
335
+
336
+ export type ChatThreadUpdateManyMutationInput = {
337
+ id?: Prisma.StringFieldUpdateOperationsInput | string
338
+ title?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
339
+ isArchived?: Prisma.BoolFieldUpdateOperationsInput | boolean
340
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
341
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
342
+ }
343
+
344
+ export type ChatThreadUncheckedUpdateManyInput = {
345
+ id?: Prisma.StringFieldUpdateOperationsInput | string
346
+ userId?: Prisma.StringFieldUpdateOperationsInput | string
347
+ title?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
348
+ isArchived?: Prisma.BoolFieldUpdateOperationsInput | boolean
349
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
350
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
351
+ agentId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
352
+ }
353
+
354
+ export type ChatThreadListRelationFilter = {
355
+ every?: Prisma.ChatThreadWhereInput
356
+ some?: Prisma.ChatThreadWhereInput
357
+ none?: Prisma.ChatThreadWhereInput
358
+ }
359
+
360
+ export type ChatThreadOrderByRelationAggregateInput = {
361
+ _count?: Prisma.SortOrder
362
+ }
363
+
364
+ export type ChatThreadCountOrderByAggregateInput = {
365
+ id?: Prisma.SortOrder
366
+ userId?: Prisma.SortOrder
367
+ title?: Prisma.SortOrder
368
+ isArchived?: Prisma.SortOrder
369
+ createdAt?: Prisma.SortOrder
370
+ updatedAt?: Prisma.SortOrder
371
+ agentId?: Prisma.SortOrder
372
+ }
373
+
374
+ export type ChatThreadMaxOrderByAggregateInput = {
375
+ id?: Prisma.SortOrder
376
+ userId?: Prisma.SortOrder
377
+ title?: Prisma.SortOrder
378
+ isArchived?: Prisma.SortOrder
379
+ createdAt?: Prisma.SortOrder
380
+ updatedAt?: Prisma.SortOrder
381
+ agentId?: Prisma.SortOrder
382
+ }
383
+
384
+ export type ChatThreadMinOrderByAggregateInput = {
385
+ id?: Prisma.SortOrder
386
+ userId?: Prisma.SortOrder
387
+ title?: Prisma.SortOrder
388
+ isArchived?: Prisma.SortOrder
389
+ createdAt?: Prisma.SortOrder
390
+ updatedAt?: Prisma.SortOrder
391
+ agentId?: Prisma.SortOrder
392
+ }
393
+
394
+ export type ChatThreadScalarRelationFilter = {
395
+ is?: Prisma.ChatThreadWhereInput
396
+ isNot?: Prisma.ChatThreadWhereInput
397
+ }
398
+
399
+ export type ChatThreadCreateNestedManyWithoutUserInput = {
400
+ create?: Prisma.XOR<Prisma.ChatThreadCreateWithoutUserInput, Prisma.ChatThreadUncheckedCreateWithoutUserInput> | Prisma.ChatThreadCreateWithoutUserInput[] | Prisma.ChatThreadUncheckedCreateWithoutUserInput[]
401
+ connectOrCreate?: Prisma.ChatThreadCreateOrConnectWithoutUserInput | Prisma.ChatThreadCreateOrConnectWithoutUserInput[]
402
+ createMany?: Prisma.ChatThreadCreateManyUserInputEnvelope
403
+ connect?: Prisma.ChatThreadWhereUniqueInput | Prisma.ChatThreadWhereUniqueInput[]
404
+ }
405
+
406
+ export type ChatThreadUncheckedCreateNestedManyWithoutUserInput = {
407
+ create?: Prisma.XOR<Prisma.ChatThreadCreateWithoutUserInput, Prisma.ChatThreadUncheckedCreateWithoutUserInput> | Prisma.ChatThreadCreateWithoutUserInput[] | Prisma.ChatThreadUncheckedCreateWithoutUserInput[]
408
+ connectOrCreate?: Prisma.ChatThreadCreateOrConnectWithoutUserInput | Prisma.ChatThreadCreateOrConnectWithoutUserInput[]
409
+ createMany?: Prisma.ChatThreadCreateManyUserInputEnvelope
410
+ connect?: Prisma.ChatThreadWhereUniqueInput | Prisma.ChatThreadWhereUniqueInput[]
411
+ }
412
+
413
+ export type ChatThreadUpdateManyWithoutUserNestedInput = {
414
+ create?: Prisma.XOR<Prisma.ChatThreadCreateWithoutUserInput, Prisma.ChatThreadUncheckedCreateWithoutUserInput> | Prisma.ChatThreadCreateWithoutUserInput[] | Prisma.ChatThreadUncheckedCreateWithoutUserInput[]
415
+ connectOrCreate?: Prisma.ChatThreadCreateOrConnectWithoutUserInput | Prisma.ChatThreadCreateOrConnectWithoutUserInput[]
416
+ upsert?: Prisma.ChatThreadUpsertWithWhereUniqueWithoutUserInput | Prisma.ChatThreadUpsertWithWhereUniqueWithoutUserInput[]
417
+ createMany?: Prisma.ChatThreadCreateManyUserInputEnvelope
418
+ set?: Prisma.ChatThreadWhereUniqueInput | Prisma.ChatThreadWhereUniqueInput[]
419
+ disconnect?: Prisma.ChatThreadWhereUniqueInput | Prisma.ChatThreadWhereUniqueInput[]
420
+ delete?: Prisma.ChatThreadWhereUniqueInput | Prisma.ChatThreadWhereUniqueInput[]
421
+ connect?: Prisma.ChatThreadWhereUniqueInput | Prisma.ChatThreadWhereUniqueInput[]
422
+ update?: Prisma.ChatThreadUpdateWithWhereUniqueWithoutUserInput | Prisma.ChatThreadUpdateWithWhereUniqueWithoutUserInput[]
423
+ updateMany?: Prisma.ChatThreadUpdateManyWithWhereWithoutUserInput | Prisma.ChatThreadUpdateManyWithWhereWithoutUserInput[]
424
+ deleteMany?: Prisma.ChatThreadScalarWhereInput | Prisma.ChatThreadScalarWhereInput[]
425
+ }
426
+
427
+ export type ChatThreadUncheckedUpdateManyWithoutUserNestedInput = {
428
+ create?: Prisma.XOR<Prisma.ChatThreadCreateWithoutUserInput, Prisma.ChatThreadUncheckedCreateWithoutUserInput> | Prisma.ChatThreadCreateWithoutUserInput[] | Prisma.ChatThreadUncheckedCreateWithoutUserInput[]
429
+ connectOrCreate?: Prisma.ChatThreadCreateOrConnectWithoutUserInput | Prisma.ChatThreadCreateOrConnectWithoutUserInput[]
430
+ upsert?: Prisma.ChatThreadUpsertWithWhereUniqueWithoutUserInput | Prisma.ChatThreadUpsertWithWhereUniqueWithoutUserInput[]
431
+ createMany?: Prisma.ChatThreadCreateManyUserInputEnvelope
432
+ set?: Prisma.ChatThreadWhereUniqueInput | Prisma.ChatThreadWhereUniqueInput[]
433
+ disconnect?: Prisma.ChatThreadWhereUniqueInput | Prisma.ChatThreadWhereUniqueInput[]
434
+ delete?: Prisma.ChatThreadWhereUniqueInput | Prisma.ChatThreadWhereUniqueInput[]
435
+ connect?: Prisma.ChatThreadWhereUniqueInput | Prisma.ChatThreadWhereUniqueInput[]
436
+ update?: Prisma.ChatThreadUpdateWithWhereUniqueWithoutUserInput | Prisma.ChatThreadUpdateWithWhereUniqueWithoutUserInput[]
437
+ updateMany?: Prisma.ChatThreadUpdateManyWithWhereWithoutUserInput | Prisma.ChatThreadUpdateManyWithWhereWithoutUserInput[]
438
+ deleteMany?: Prisma.ChatThreadScalarWhereInput | Prisma.ChatThreadScalarWhereInput[]
439
+ }
440
+
441
+ export type BoolFieldUpdateOperationsInput = {
442
+ set?: boolean
443
+ }
444
+
445
+ export type ChatThreadCreateNestedOneWithoutMessagesInput = {
446
+ create?: Prisma.XOR<Prisma.ChatThreadCreateWithoutMessagesInput, Prisma.ChatThreadUncheckedCreateWithoutMessagesInput>
447
+ connectOrCreate?: Prisma.ChatThreadCreateOrConnectWithoutMessagesInput
448
+ connect?: Prisma.ChatThreadWhereUniqueInput
449
+ }
450
+
451
+ export type ChatThreadUpdateOneRequiredWithoutMessagesNestedInput = {
452
+ create?: Prisma.XOR<Prisma.ChatThreadCreateWithoutMessagesInput, Prisma.ChatThreadUncheckedCreateWithoutMessagesInput>
453
+ connectOrCreate?: Prisma.ChatThreadCreateOrConnectWithoutMessagesInput
454
+ upsert?: Prisma.ChatThreadUpsertWithoutMessagesInput
455
+ connect?: Prisma.ChatThreadWhereUniqueInput
456
+ update?: Prisma.XOR<Prisma.XOR<Prisma.ChatThreadUpdateToOneWithWhereWithoutMessagesInput, Prisma.ChatThreadUpdateWithoutMessagesInput>, Prisma.ChatThreadUncheckedUpdateWithoutMessagesInput>
457
+ }
458
+
459
+ export type ChatThreadCreateNestedOneWithoutRunsInput = {
460
+ create?: Prisma.XOR<Prisma.ChatThreadCreateWithoutRunsInput, Prisma.ChatThreadUncheckedCreateWithoutRunsInput>
461
+ connectOrCreate?: Prisma.ChatThreadCreateOrConnectWithoutRunsInput
462
+ connect?: Prisma.ChatThreadWhereUniqueInput
463
+ }
464
+
465
+ export type ChatThreadUpdateOneRequiredWithoutRunsNestedInput = {
466
+ create?: Prisma.XOR<Prisma.ChatThreadCreateWithoutRunsInput, Prisma.ChatThreadUncheckedCreateWithoutRunsInput>
467
+ connectOrCreate?: Prisma.ChatThreadCreateOrConnectWithoutRunsInput
468
+ upsert?: Prisma.ChatThreadUpsertWithoutRunsInput
469
+ connect?: Prisma.ChatThreadWhereUniqueInput
470
+ update?: Prisma.XOR<Prisma.XOR<Prisma.ChatThreadUpdateToOneWithWhereWithoutRunsInput, Prisma.ChatThreadUpdateWithoutRunsInput>, Prisma.ChatThreadUncheckedUpdateWithoutRunsInput>
471
+ }
472
+
473
+ export type ChatThreadCreateNestedOneWithoutInterruptsInput = {
474
+ create?: Prisma.XOR<Prisma.ChatThreadCreateWithoutInterruptsInput, Prisma.ChatThreadUncheckedCreateWithoutInterruptsInput>
475
+ connectOrCreate?: Prisma.ChatThreadCreateOrConnectWithoutInterruptsInput
476
+ connect?: Prisma.ChatThreadWhereUniqueInput
477
+ }
478
+
479
+ export type ChatThreadUpdateOneRequiredWithoutInterruptsNestedInput = {
480
+ create?: Prisma.XOR<Prisma.ChatThreadCreateWithoutInterruptsInput, Prisma.ChatThreadUncheckedCreateWithoutInterruptsInput>
481
+ connectOrCreate?: Prisma.ChatThreadCreateOrConnectWithoutInterruptsInput
482
+ upsert?: Prisma.ChatThreadUpsertWithoutInterruptsInput
483
+ connect?: Prisma.ChatThreadWhereUniqueInput
484
+ update?: Prisma.XOR<Prisma.XOR<Prisma.ChatThreadUpdateToOneWithWhereWithoutInterruptsInput, Prisma.ChatThreadUpdateWithoutInterruptsInput>, Prisma.ChatThreadUncheckedUpdateWithoutInterruptsInput>
485
+ }
486
+
487
+ export type ChatThreadCreateNestedOneWithoutGenerationsInput = {
488
+ create?: Prisma.XOR<Prisma.ChatThreadCreateWithoutGenerationsInput, Prisma.ChatThreadUncheckedCreateWithoutGenerationsInput>
489
+ connectOrCreate?: Prisma.ChatThreadCreateOrConnectWithoutGenerationsInput
490
+ connect?: Prisma.ChatThreadWhereUniqueInput
491
+ }
492
+
493
+ export type ChatThreadUpdateOneRequiredWithoutGenerationsNestedInput = {
494
+ create?: Prisma.XOR<Prisma.ChatThreadCreateWithoutGenerationsInput, Prisma.ChatThreadUncheckedCreateWithoutGenerationsInput>
495
+ connectOrCreate?: Prisma.ChatThreadCreateOrConnectWithoutGenerationsInput
496
+ upsert?: Prisma.ChatThreadUpsertWithoutGenerationsInput
497
+ connect?: Prisma.ChatThreadWhereUniqueInput
498
+ update?: Prisma.XOR<Prisma.XOR<Prisma.ChatThreadUpdateToOneWithWhereWithoutGenerationsInput, Prisma.ChatThreadUpdateWithoutGenerationsInput>, Prisma.ChatThreadUncheckedUpdateWithoutGenerationsInput>
499
+ }
500
+
501
+ export type ChatThreadCreateNestedManyWithoutAgentInput = {
502
+ create?: Prisma.XOR<Prisma.ChatThreadCreateWithoutAgentInput, Prisma.ChatThreadUncheckedCreateWithoutAgentInput> | Prisma.ChatThreadCreateWithoutAgentInput[] | Prisma.ChatThreadUncheckedCreateWithoutAgentInput[]
503
+ connectOrCreate?: Prisma.ChatThreadCreateOrConnectWithoutAgentInput | Prisma.ChatThreadCreateOrConnectWithoutAgentInput[]
504
+ createMany?: Prisma.ChatThreadCreateManyAgentInputEnvelope
505
+ connect?: Prisma.ChatThreadWhereUniqueInput | Prisma.ChatThreadWhereUniqueInput[]
506
+ }
507
+
508
+ export type ChatThreadUncheckedCreateNestedManyWithoutAgentInput = {
509
+ create?: Prisma.XOR<Prisma.ChatThreadCreateWithoutAgentInput, Prisma.ChatThreadUncheckedCreateWithoutAgentInput> | Prisma.ChatThreadCreateWithoutAgentInput[] | Prisma.ChatThreadUncheckedCreateWithoutAgentInput[]
510
+ connectOrCreate?: Prisma.ChatThreadCreateOrConnectWithoutAgentInput | Prisma.ChatThreadCreateOrConnectWithoutAgentInput[]
511
+ createMany?: Prisma.ChatThreadCreateManyAgentInputEnvelope
512
+ connect?: Prisma.ChatThreadWhereUniqueInput | Prisma.ChatThreadWhereUniqueInput[]
513
+ }
514
+
515
+ export type ChatThreadUpdateManyWithoutAgentNestedInput = {
516
+ create?: Prisma.XOR<Prisma.ChatThreadCreateWithoutAgentInput, Prisma.ChatThreadUncheckedCreateWithoutAgentInput> | Prisma.ChatThreadCreateWithoutAgentInput[] | Prisma.ChatThreadUncheckedCreateWithoutAgentInput[]
517
+ connectOrCreate?: Prisma.ChatThreadCreateOrConnectWithoutAgentInput | Prisma.ChatThreadCreateOrConnectWithoutAgentInput[]
518
+ upsert?: Prisma.ChatThreadUpsertWithWhereUniqueWithoutAgentInput | Prisma.ChatThreadUpsertWithWhereUniqueWithoutAgentInput[]
519
+ createMany?: Prisma.ChatThreadCreateManyAgentInputEnvelope
520
+ set?: Prisma.ChatThreadWhereUniqueInput | Prisma.ChatThreadWhereUniqueInput[]
521
+ disconnect?: Prisma.ChatThreadWhereUniqueInput | Prisma.ChatThreadWhereUniqueInput[]
522
+ delete?: Prisma.ChatThreadWhereUniqueInput | Prisma.ChatThreadWhereUniqueInput[]
523
+ connect?: Prisma.ChatThreadWhereUniqueInput | Prisma.ChatThreadWhereUniqueInput[]
524
+ update?: Prisma.ChatThreadUpdateWithWhereUniqueWithoutAgentInput | Prisma.ChatThreadUpdateWithWhereUniqueWithoutAgentInput[]
525
+ updateMany?: Prisma.ChatThreadUpdateManyWithWhereWithoutAgentInput | Prisma.ChatThreadUpdateManyWithWhereWithoutAgentInput[]
526
+ deleteMany?: Prisma.ChatThreadScalarWhereInput | Prisma.ChatThreadScalarWhereInput[]
527
+ }
528
+
529
+ export type ChatThreadUncheckedUpdateManyWithoutAgentNestedInput = {
530
+ create?: Prisma.XOR<Prisma.ChatThreadCreateWithoutAgentInput, Prisma.ChatThreadUncheckedCreateWithoutAgentInput> | Prisma.ChatThreadCreateWithoutAgentInput[] | Prisma.ChatThreadUncheckedCreateWithoutAgentInput[]
531
+ connectOrCreate?: Prisma.ChatThreadCreateOrConnectWithoutAgentInput | Prisma.ChatThreadCreateOrConnectWithoutAgentInput[]
532
+ upsert?: Prisma.ChatThreadUpsertWithWhereUniqueWithoutAgentInput | Prisma.ChatThreadUpsertWithWhereUniqueWithoutAgentInput[]
533
+ createMany?: Prisma.ChatThreadCreateManyAgentInputEnvelope
534
+ set?: Prisma.ChatThreadWhereUniqueInput | Prisma.ChatThreadWhereUniqueInput[]
535
+ disconnect?: Prisma.ChatThreadWhereUniqueInput | Prisma.ChatThreadWhereUniqueInput[]
536
+ delete?: Prisma.ChatThreadWhereUniqueInput | Prisma.ChatThreadWhereUniqueInput[]
537
+ connect?: Prisma.ChatThreadWhereUniqueInput | Prisma.ChatThreadWhereUniqueInput[]
538
+ update?: Prisma.ChatThreadUpdateWithWhereUniqueWithoutAgentInput | Prisma.ChatThreadUpdateWithWhereUniqueWithoutAgentInput[]
539
+ updateMany?: Prisma.ChatThreadUpdateManyWithWhereWithoutAgentInput | Prisma.ChatThreadUpdateManyWithWhereWithoutAgentInput[]
540
+ deleteMany?: Prisma.ChatThreadScalarWhereInput | Prisma.ChatThreadScalarWhereInput[]
541
+ }
542
+
543
+ export type ChatThreadCreateWithoutUserInput = {
544
+ id?: string
545
+ title?: string | null
546
+ isArchived?: boolean
547
+ createdAt?: Date | string
548
+ updatedAt?: Date | string
549
+ messages?: Prisma.ChatMessageCreateNestedManyWithoutThreadInput
550
+ runs?: Prisma.ChatRunCreateNestedManyWithoutThreadInput
551
+ interrupts?: Prisma.ChatInterruptCreateNestedManyWithoutThreadInput
552
+ generations?: Prisma.GenerationRunCreateNestedManyWithoutThreadInput
553
+ agent?: Prisma.UserAgentCreateNestedOneWithoutThreadsInput
554
+ }
555
+
556
+ export type ChatThreadUncheckedCreateWithoutUserInput = {
557
+ id?: string
558
+ title?: string | null
559
+ isArchived?: boolean
560
+ createdAt?: Date | string
561
+ updatedAt?: Date | string
562
+ agentId?: string | null
563
+ messages?: Prisma.ChatMessageUncheckedCreateNestedManyWithoutThreadInput
564
+ runs?: Prisma.ChatRunUncheckedCreateNestedManyWithoutThreadInput
565
+ interrupts?: Prisma.ChatInterruptUncheckedCreateNestedManyWithoutThreadInput
566
+ generations?: Prisma.GenerationRunUncheckedCreateNestedManyWithoutThreadInput
567
+ }
568
+
569
+ export type ChatThreadCreateOrConnectWithoutUserInput = {
570
+ where: Prisma.ChatThreadWhereUniqueInput
571
+ create: Prisma.XOR<Prisma.ChatThreadCreateWithoutUserInput, Prisma.ChatThreadUncheckedCreateWithoutUserInput>
572
+ }
573
+
574
+ export type ChatThreadCreateManyUserInputEnvelope = {
575
+ data: Prisma.ChatThreadCreateManyUserInput | Prisma.ChatThreadCreateManyUserInput[]
576
+ skipDuplicates?: boolean
577
+ }
578
+
579
+ export type ChatThreadUpsertWithWhereUniqueWithoutUserInput = {
580
+ where: Prisma.ChatThreadWhereUniqueInput
581
+ update: Prisma.XOR<Prisma.ChatThreadUpdateWithoutUserInput, Prisma.ChatThreadUncheckedUpdateWithoutUserInput>
582
+ create: Prisma.XOR<Prisma.ChatThreadCreateWithoutUserInput, Prisma.ChatThreadUncheckedCreateWithoutUserInput>
583
+ }
584
+
585
+ export type ChatThreadUpdateWithWhereUniqueWithoutUserInput = {
586
+ where: Prisma.ChatThreadWhereUniqueInput
587
+ data: Prisma.XOR<Prisma.ChatThreadUpdateWithoutUserInput, Prisma.ChatThreadUncheckedUpdateWithoutUserInput>
588
+ }
589
+
590
+ export type ChatThreadUpdateManyWithWhereWithoutUserInput = {
591
+ where: Prisma.ChatThreadScalarWhereInput
592
+ data: Prisma.XOR<Prisma.ChatThreadUpdateManyMutationInput, Prisma.ChatThreadUncheckedUpdateManyWithoutUserInput>
593
+ }
594
+
595
+ export type ChatThreadScalarWhereInput = {
596
+ AND?: Prisma.ChatThreadScalarWhereInput | Prisma.ChatThreadScalarWhereInput[]
597
+ OR?: Prisma.ChatThreadScalarWhereInput[]
598
+ NOT?: Prisma.ChatThreadScalarWhereInput | Prisma.ChatThreadScalarWhereInput[]
599
+ id?: Prisma.StringFilter<"ChatThread"> | string
600
+ userId?: Prisma.StringFilter<"ChatThread"> | string
601
+ title?: Prisma.StringNullableFilter<"ChatThread"> | string | null
602
+ isArchived?: Prisma.BoolFilter<"ChatThread"> | boolean
603
+ createdAt?: Prisma.DateTimeFilter<"ChatThread"> | Date | string
604
+ updatedAt?: Prisma.DateTimeFilter<"ChatThread"> | Date | string
605
+ agentId?: Prisma.StringNullableFilter<"ChatThread"> | string | null
606
+ }
607
+
608
+ export type ChatThreadCreateWithoutMessagesInput = {
609
+ id?: string
610
+ title?: string | null
611
+ isArchived?: boolean
612
+ createdAt?: Date | string
613
+ updatedAt?: Date | string
614
+ user: Prisma.UserCreateNestedOneWithoutChatThreadsInput
615
+ runs?: Prisma.ChatRunCreateNestedManyWithoutThreadInput
616
+ interrupts?: Prisma.ChatInterruptCreateNestedManyWithoutThreadInput
617
+ generations?: Prisma.GenerationRunCreateNestedManyWithoutThreadInput
618
+ agent?: Prisma.UserAgentCreateNestedOneWithoutThreadsInput
619
+ }
620
+
621
+ export type ChatThreadUncheckedCreateWithoutMessagesInput = {
622
+ id?: string
623
+ userId: string
624
+ title?: string | null
625
+ isArchived?: boolean
626
+ createdAt?: Date | string
627
+ updatedAt?: Date | string
628
+ agentId?: string | null
629
+ runs?: Prisma.ChatRunUncheckedCreateNestedManyWithoutThreadInput
630
+ interrupts?: Prisma.ChatInterruptUncheckedCreateNestedManyWithoutThreadInput
631
+ generations?: Prisma.GenerationRunUncheckedCreateNestedManyWithoutThreadInput
632
+ }
633
+
634
+ export type ChatThreadCreateOrConnectWithoutMessagesInput = {
635
+ where: Prisma.ChatThreadWhereUniqueInput
636
+ create: Prisma.XOR<Prisma.ChatThreadCreateWithoutMessagesInput, Prisma.ChatThreadUncheckedCreateWithoutMessagesInput>
637
+ }
638
+
639
+ export type ChatThreadUpsertWithoutMessagesInput = {
640
+ update: Prisma.XOR<Prisma.ChatThreadUpdateWithoutMessagesInput, Prisma.ChatThreadUncheckedUpdateWithoutMessagesInput>
641
+ create: Prisma.XOR<Prisma.ChatThreadCreateWithoutMessagesInput, Prisma.ChatThreadUncheckedCreateWithoutMessagesInput>
642
+ where?: Prisma.ChatThreadWhereInput
643
+ }
644
+
645
+ export type ChatThreadUpdateToOneWithWhereWithoutMessagesInput = {
646
+ where?: Prisma.ChatThreadWhereInput
647
+ data: Prisma.XOR<Prisma.ChatThreadUpdateWithoutMessagesInput, Prisma.ChatThreadUncheckedUpdateWithoutMessagesInput>
648
+ }
649
+
650
+ export type ChatThreadUpdateWithoutMessagesInput = {
651
+ id?: Prisma.StringFieldUpdateOperationsInput | string
652
+ title?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
653
+ isArchived?: Prisma.BoolFieldUpdateOperationsInput | boolean
654
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
655
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
656
+ user?: Prisma.UserUpdateOneRequiredWithoutChatThreadsNestedInput
657
+ runs?: Prisma.ChatRunUpdateManyWithoutThreadNestedInput
658
+ interrupts?: Prisma.ChatInterruptUpdateManyWithoutThreadNestedInput
659
+ generations?: Prisma.GenerationRunUpdateManyWithoutThreadNestedInput
660
+ agent?: Prisma.UserAgentUpdateOneWithoutThreadsNestedInput
661
+ }
662
+
663
+ export type ChatThreadUncheckedUpdateWithoutMessagesInput = {
664
+ id?: Prisma.StringFieldUpdateOperationsInput | string
665
+ userId?: Prisma.StringFieldUpdateOperationsInput | string
666
+ title?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
667
+ isArchived?: Prisma.BoolFieldUpdateOperationsInput | boolean
668
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
669
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
670
+ agentId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
671
+ runs?: Prisma.ChatRunUncheckedUpdateManyWithoutThreadNestedInput
672
+ interrupts?: Prisma.ChatInterruptUncheckedUpdateManyWithoutThreadNestedInput
673
+ generations?: Prisma.GenerationRunUncheckedUpdateManyWithoutThreadNestedInput
674
+ }
675
+
676
+ export type ChatThreadCreateWithoutRunsInput = {
677
+ id?: string
678
+ title?: string | null
679
+ isArchived?: boolean
680
+ createdAt?: Date | string
681
+ updatedAt?: Date | string
682
+ user: Prisma.UserCreateNestedOneWithoutChatThreadsInput
683
+ messages?: Prisma.ChatMessageCreateNestedManyWithoutThreadInput
684
+ interrupts?: Prisma.ChatInterruptCreateNestedManyWithoutThreadInput
685
+ generations?: Prisma.GenerationRunCreateNestedManyWithoutThreadInput
686
+ agent?: Prisma.UserAgentCreateNestedOneWithoutThreadsInput
687
+ }
688
+
689
+ export type ChatThreadUncheckedCreateWithoutRunsInput = {
690
+ id?: string
691
+ userId: string
692
+ title?: string | null
693
+ isArchived?: boolean
694
+ createdAt?: Date | string
695
+ updatedAt?: Date | string
696
+ agentId?: string | null
697
+ messages?: Prisma.ChatMessageUncheckedCreateNestedManyWithoutThreadInput
698
+ interrupts?: Prisma.ChatInterruptUncheckedCreateNestedManyWithoutThreadInput
699
+ generations?: Prisma.GenerationRunUncheckedCreateNestedManyWithoutThreadInput
700
+ }
701
+
702
+ export type ChatThreadCreateOrConnectWithoutRunsInput = {
703
+ where: Prisma.ChatThreadWhereUniqueInput
704
+ create: Prisma.XOR<Prisma.ChatThreadCreateWithoutRunsInput, Prisma.ChatThreadUncheckedCreateWithoutRunsInput>
705
+ }
706
+
707
+ export type ChatThreadUpsertWithoutRunsInput = {
708
+ update: Prisma.XOR<Prisma.ChatThreadUpdateWithoutRunsInput, Prisma.ChatThreadUncheckedUpdateWithoutRunsInput>
709
+ create: Prisma.XOR<Prisma.ChatThreadCreateWithoutRunsInput, Prisma.ChatThreadUncheckedCreateWithoutRunsInput>
710
+ where?: Prisma.ChatThreadWhereInput
711
+ }
712
+
713
+ export type ChatThreadUpdateToOneWithWhereWithoutRunsInput = {
714
+ where?: Prisma.ChatThreadWhereInput
715
+ data: Prisma.XOR<Prisma.ChatThreadUpdateWithoutRunsInput, Prisma.ChatThreadUncheckedUpdateWithoutRunsInput>
716
+ }
717
+
718
+ export type ChatThreadUpdateWithoutRunsInput = {
719
+ id?: Prisma.StringFieldUpdateOperationsInput | string
720
+ title?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
721
+ isArchived?: Prisma.BoolFieldUpdateOperationsInput | boolean
722
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
723
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
724
+ user?: Prisma.UserUpdateOneRequiredWithoutChatThreadsNestedInput
725
+ messages?: Prisma.ChatMessageUpdateManyWithoutThreadNestedInput
726
+ interrupts?: Prisma.ChatInterruptUpdateManyWithoutThreadNestedInput
727
+ generations?: Prisma.GenerationRunUpdateManyWithoutThreadNestedInput
728
+ agent?: Prisma.UserAgentUpdateOneWithoutThreadsNestedInput
729
+ }
730
+
731
+ export type ChatThreadUncheckedUpdateWithoutRunsInput = {
732
+ id?: Prisma.StringFieldUpdateOperationsInput | string
733
+ userId?: Prisma.StringFieldUpdateOperationsInput | string
734
+ title?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
735
+ isArchived?: Prisma.BoolFieldUpdateOperationsInput | boolean
736
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
737
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
738
+ agentId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
739
+ messages?: Prisma.ChatMessageUncheckedUpdateManyWithoutThreadNestedInput
740
+ interrupts?: Prisma.ChatInterruptUncheckedUpdateManyWithoutThreadNestedInput
741
+ generations?: Prisma.GenerationRunUncheckedUpdateManyWithoutThreadNestedInput
742
+ }
743
+
744
+ export type ChatThreadCreateWithoutInterruptsInput = {
745
+ id?: string
746
+ title?: string | null
747
+ isArchived?: boolean
748
+ createdAt?: Date | string
749
+ updatedAt?: Date | string
750
+ user: Prisma.UserCreateNestedOneWithoutChatThreadsInput
751
+ messages?: Prisma.ChatMessageCreateNestedManyWithoutThreadInput
752
+ runs?: Prisma.ChatRunCreateNestedManyWithoutThreadInput
753
+ generations?: Prisma.GenerationRunCreateNestedManyWithoutThreadInput
754
+ agent?: Prisma.UserAgentCreateNestedOneWithoutThreadsInput
755
+ }
756
+
757
+ export type ChatThreadUncheckedCreateWithoutInterruptsInput = {
758
+ id?: string
759
+ userId: string
760
+ title?: string | null
761
+ isArchived?: boolean
762
+ createdAt?: Date | string
763
+ updatedAt?: Date | string
764
+ agentId?: string | null
765
+ messages?: Prisma.ChatMessageUncheckedCreateNestedManyWithoutThreadInput
766
+ runs?: Prisma.ChatRunUncheckedCreateNestedManyWithoutThreadInput
767
+ generations?: Prisma.GenerationRunUncheckedCreateNestedManyWithoutThreadInput
768
+ }
769
+
770
+ export type ChatThreadCreateOrConnectWithoutInterruptsInput = {
771
+ where: Prisma.ChatThreadWhereUniqueInput
772
+ create: Prisma.XOR<Prisma.ChatThreadCreateWithoutInterruptsInput, Prisma.ChatThreadUncheckedCreateWithoutInterruptsInput>
773
+ }
774
+
775
+ export type ChatThreadUpsertWithoutInterruptsInput = {
776
+ update: Prisma.XOR<Prisma.ChatThreadUpdateWithoutInterruptsInput, Prisma.ChatThreadUncheckedUpdateWithoutInterruptsInput>
777
+ create: Prisma.XOR<Prisma.ChatThreadCreateWithoutInterruptsInput, Prisma.ChatThreadUncheckedCreateWithoutInterruptsInput>
778
+ where?: Prisma.ChatThreadWhereInput
779
+ }
780
+
781
+ export type ChatThreadUpdateToOneWithWhereWithoutInterruptsInput = {
782
+ where?: Prisma.ChatThreadWhereInput
783
+ data: Prisma.XOR<Prisma.ChatThreadUpdateWithoutInterruptsInput, Prisma.ChatThreadUncheckedUpdateWithoutInterruptsInput>
784
+ }
785
+
786
+ export type ChatThreadUpdateWithoutInterruptsInput = {
787
+ id?: Prisma.StringFieldUpdateOperationsInput | string
788
+ title?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
789
+ isArchived?: Prisma.BoolFieldUpdateOperationsInput | boolean
790
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
791
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
792
+ user?: Prisma.UserUpdateOneRequiredWithoutChatThreadsNestedInput
793
+ messages?: Prisma.ChatMessageUpdateManyWithoutThreadNestedInput
794
+ runs?: Prisma.ChatRunUpdateManyWithoutThreadNestedInput
795
+ generations?: Prisma.GenerationRunUpdateManyWithoutThreadNestedInput
796
+ agent?: Prisma.UserAgentUpdateOneWithoutThreadsNestedInput
797
+ }
798
+
799
+ export type ChatThreadUncheckedUpdateWithoutInterruptsInput = {
800
+ id?: Prisma.StringFieldUpdateOperationsInput | string
801
+ userId?: Prisma.StringFieldUpdateOperationsInput | string
802
+ title?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
803
+ isArchived?: Prisma.BoolFieldUpdateOperationsInput | boolean
804
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
805
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
806
+ agentId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
807
+ messages?: Prisma.ChatMessageUncheckedUpdateManyWithoutThreadNestedInput
808
+ runs?: Prisma.ChatRunUncheckedUpdateManyWithoutThreadNestedInput
809
+ generations?: Prisma.GenerationRunUncheckedUpdateManyWithoutThreadNestedInput
810
+ }
811
+
812
+ export type ChatThreadCreateWithoutGenerationsInput = {
813
+ id?: string
814
+ title?: string | null
815
+ isArchived?: boolean
816
+ createdAt?: Date | string
817
+ updatedAt?: Date | string
818
+ user: Prisma.UserCreateNestedOneWithoutChatThreadsInput
819
+ messages?: Prisma.ChatMessageCreateNestedManyWithoutThreadInput
820
+ runs?: Prisma.ChatRunCreateNestedManyWithoutThreadInput
821
+ interrupts?: Prisma.ChatInterruptCreateNestedManyWithoutThreadInput
822
+ agent?: Prisma.UserAgentCreateNestedOneWithoutThreadsInput
823
+ }
824
+
825
+ export type ChatThreadUncheckedCreateWithoutGenerationsInput = {
826
+ id?: string
827
+ userId: string
828
+ title?: string | null
829
+ isArchived?: boolean
830
+ createdAt?: Date | string
831
+ updatedAt?: Date | string
832
+ agentId?: string | null
833
+ messages?: Prisma.ChatMessageUncheckedCreateNestedManyWithoutThreadInput
834
+ runs?: Prisma.ChatRunUncheckedCreateNestedManyWithoutThreadInput
835
+ interrupts?: Prisma.ChatInterruptUncheckedCreateNestedManyWithoutThreadInput
836
+ }
837
+
838
+ export type ChatThreadCreateOrConnectWithoutGenerationsInput = {
839
+ where: Prisma.ChatThreadWhereUniqueInput
840
+ create: Prisma.XOR<Prisma.ChatThreadCreateWithoutGenerationsInput, Prisma.ChatThreadUncheckedCreateWithoutGenerationsInput>
841
+ }
842
+
843
+ export type ChatThreadUpsertWithoutGenerationsInput = {
844
+ update: Prisma.XOR<Prisma.ChatThreadUpdateWithoutGenerationsInput, Prisma.ChatThreadUncheckedUpdateWithoutGenerationsInput>
845
+ create: Prisma.XOR<Prisma.ChatThreadCreateWithoutGenerationsInput, Prisma.ChatThreadUncheckedCreateWithoutGenerationsInput>
846
+ where?: Prisma.ChatThreadWhereInput
847
+ }
848
+
849
+ export type ChatThreadUpdateToOneWithWhereWithoutGenerationsInput = {
850
+ where?: Prisma.ChatThreadWhereInput
851
+ data: Prisma.XOR<Prisma.ChatThreadUpdateWithoutGenerationsInput, Prisma.ChatThreadUncheckedUpdateWithoutGenerationsInput>
852
+ }
853
+
854
+ export type ChatThreadUpdateWithoutGenerationsInput = {
855
+ id?: Prisma.StringFieldUpdateOperationsInput | string
856
+ title?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
857
+ isArchived?: Prisma.BoolFieldUpdateOperationsInput | boolean
858
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
859
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
860
+ user?: Prisma.UserUpdateOneRequiredWithoutChatThreadsNestedInput
861
+ messages?: Prisma.ChatMessageUpdateManyWithoutThreadNestedInput
862
+ runs?: Prisma.ChatRunUpdateManyWithoutThreadNestedInput
863
+ interrupts?: Prisma.ChatInterruptUpdateManyWithoutThreadNestedInput
864
+ agent?: Prisma.UserAgentUpdateOneWithoutThreadsNestedInput
865
+ }
866
+
867
+ export type ChatThreadUncheckedUpdateWithoutGenerationsInput = {
868
+ id?: Prisma.StringFieldUpdateOperationsInput | string
869
+ userId?: Prisma.StringFieldUpdateOperationsInput | string
870
+ title?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
871
+ isArchived?: Prisma.BoolFieldUpdateOperationsInput | boolean
872
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
873
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
874
+ agentId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
875
+ messages?: Prisma.ChatMessageUncheckedUpdateManyWithoutThreadNestedInput
876
+ runs?: Prisma.ChatRunUncheckedUpdateManyWithoutThreadNestedInput
877
+ interrupts?: Prisma.ChatInterruptUncheckedUpdateManyWithoutThreadNestedInput
878
+ }
879
+
880
+ export type ChatThreadCreateWithoutAgentInput = {
881
+ id?: string
882
+ title?: string | null
883
+ isArchived?: boolean
884
+ createdAt?: Date | string
885
+ updatedAt?: Date | string
886
+ user: Prisma.UserCreateNestedOneWithoutChatThreadsInput
887
+ messages?: Prisma.ChatMessageCreateNestedManyWithoutThreadInput
888
+ runs?: Prisma.ChatRunCreateNestedManyWithoutThreadInput
889
+ interrupts?: Prisma.ChatInterruptCreateNestedManyWithoutThreadInput
890
+ generations?: Prisma.GenerationRunCreateNestedManyWithoutThreadInput
891
+ }
892
+
893
+ export type ChatThreadUncheckedCreateWithoutAgentInput = {
894
+ id?: string
895
+ userId: string
896
+ title?: string | null
897
+ isArchived?: boolean
898
+ createdAt?: Date | string
899
+ updatedAt?: Date | string
900
+ messages?: Prisma.ChatMessageUncheckedCreateNestedManyWithoutThreadInput
901
+ runs?: Prisma.ChatRunUncheckedCreateNestedManyWithoutThreadInput
902
+ interrupts?: Prisma.ChatInterruptUncheckedCreateNestedManyWithoutThreadInput
903
+ generations?: Prisma.GenerationRunUncheckedCreateNestedManyWithoutThreadInput
904
+ }
905
+
906
+ export type ChatThreadCreateOrConnectWithoutAgentInput = {
907
+ where: Prisma.ChatThreadWhereUniqueInput
908
+ create: Prisma.XOR<Prisma.ChatThreadCreateWithoutAgentInput, Prisma.ChatThreadUncheckedCreateWithoutAgentInput>
909
+ }
910
+
911
+ export type ChatThreadCreateManyAgentInputEnvelope = {
912
+ data: Prisma.ChatThreadCreateManyAgentInput | Prisma.ChatThreadCreateManyAgentInput[]
913
+ skipDuplicates?: boolean
914
+ }
915
+
916
+ export type ChatThreadUpsertWithWhereUniqueWithoutAgentInput = {
917
+ where: Prisma.ChatThreadWhereUniqueInput
918
+ update: Prisma.XOR<Prisma.ChatThreadUpdateWithoutAgentInput, Prisma.ChatThreadUncheckedUpdateWithoutAgentInput>
919
+ create: Prisma.XOR<Prisma.ChatThreadCreateWithoutAgentInput, Prisma.ChatThreadUncheckedCreateWithoutAgentInput>
920
+ }
921
+
922
+ export type ChatThreadUpdateWithWhereUniqueWithoutAgentInput = {
923
+ where: Prisma.ChatThreadWhereUniqueInput
924
+ data: Prisma.XOR<Prisma.ChatThreadUpdateWithoutAgentInput, Prisma.ChatThreadUncheckedUpdateWithoutAgentInput>
925
+ }
926
+
927
+ export type ChatThreadUpdateManyWithWhereWithoutAgentInput = {
928
+ where: Prisma.ChatThreadScalarWhereInput
929
+ data: Prisma.XOR<Prisma.ChatThreadUpdateManyMutationInput, Prisma.ChatThreadUncheckedUpdateManyWithoutAgentInput>
930
+ }
931
+
932
+ export type ChatThreadCreateManyUserInput = {
933
+ id?: string
934
+ title?: string | null
935
+ isArchived?: boolean
936
+ createdAt?: Date | string
937
+ updatedAt?: Date | string
938
+ agentId?: string | null
939
+ }
940
+
941
+ export type ChatThreadUpdateWithoutUserInput = {
942
+ id?: Prisma.StringFieldUpdateOperationsInput | string
943
+ title?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
944
+ isArchived?: Prisma.BoolFieldUpdateOperationsInput | boolean
945
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
946
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
947
+ messages?: Prisma.ChatMessageUpdateManyWithoutThreadNestedInput
948
+ runs?: Prisma.ChatRunUpdateManyWithoutThreadNestedInput
949
+ interrupts?: Prisma.ChatInterruptUpdateManyWithoutThreadNestedInput
950
+ generations?: Prisma.GenerationRunUpdateManyWithoutThreadNestedInput
951
+ agent?: Prisma.UserAgentUpdateOneWithoutThreadsNestedInput
952
+ }
953
+
954
+ export type ChatThreadUncheckedUpdateWithoutUserInput = {
955
+ id?: Prisma.StringFieldUpdateOperationsInput | string
956
+ title?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
957
+ isArchived?: Prisma.BoolFieldUpdateOperationsInput | boolean
958
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
959
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
960
+ agentId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
961
+ messages?: Prisma.ChatMessageUncheckedUpdateManyWithoutThreadNestedInput
962
+ runs?: Prisma.ChatRunUncheckedUpdateManyWithoutThreadNestedInput
963
+ interrupts?: Prisma.ChatInterruptUncheckedUpdateManyWithoutThreadNestedInput
964
+ generations?: Prisma.GenerationRunUncheckedUpdateManyWithoutThreadNestedInput
965
+ }
966
+
967
+ export type ChatThreadUncheckedUpdateManyWithoutUserInput = {
968
+ id?: Prisma.StringFieldUpdateOperationsInput | string
969
+ title?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
970
+ isArchived?: Prisma.BoolFieldUpdateOperationsInput | boolean
971
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
972
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
973
+ agentId?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
974
+ }
975
+
976
+ export type ChatThreadCreateManyAgentInput = {
977
+ id?: string
978
+ userId: string
979
+ title?: string | null
980
+ isArchived?: boolean
981
+ createdAt?: Date | string
982
+ updatedAt?: Date | string
983
+ }
984
+
985
+ export type ChatThreadUpdateWithoutAgentInput = {
986
+ id?: Prisma.StringFieldUpdateOperationsInput | string
987
+ title?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
988
+ isArchived?: Prisma.BoolFieldUpdateOperationsInput | boolean
989
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
990
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
991
+ user?: Prisma.UserUpdateOneRequiredWithoutChatThreadsNestedInput
992
+ messages?: Prisma.ChatMessageUpdateManyWithoutThreadNestedInput
993
+ runs?: Prisma.ChatRunUpdateManyWithoutThreadNestedInput
994
+ interrupts?: Prisma.ChatInterruptUpdateManyWithoutThreadNestedInput
995
+ generations?: Prisma.GenerationRunUpdateManyWithoutThreadNestedInput
996
+ }
997
+
998
+ export type ChatThreadUncheckedUpdateWithoutAgentInput = {
999
+ id?: Prisma.StringFieldUpdateOperationsInput | string
1000
+ userId?: Prisma.StringFieldUpdateOperationsInput | string
1001
+ title?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
1002
+ isArchived?: Prisma.BoolFieldUpdateOperationsInput | boolean
1003
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
1004
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
1005
+ messages?: Prisma.ChatMessageUncheckedUpdateManyWithoutThreadNestedInput
1006
+ runs?: Prisma.ChatRunUncheckedUpdateManyWithoutThreadNestedInput
1007
+ interrupts?: Prisma.ChatInterruptUncheckedUpdateManyWithoutThreadNestedInput
1008
+ generations?: Prisma.GenerationRunUncheckedUpdateManyWithoutThreadNestedInput
1009
+ }
1010
+
1011
+ export type ChatThreadUncheckedUpdateManyWithoutAgentInput = {
1012
+ id?: Prisma.StringFieldUpdateOperationsInput | string
1013
+ userId?: Prisma.StringFieldUpdateOperationsInput | string
1014
+ title?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
1015
+ isArchived?: Prisma.BoolFieldUpdateOperationsInput | boolean
1016
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
1017
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
1018
+ }
1019
+
1020
+
1021
+ /**
1022
+ * Count Type ChatThreadCountOutputType
1023
+ */
1024
+
1025
+ export type ChatThreadCountOutputType = {
1026
+ messages: number
1027
+ runs: number
1028
+ interrupts: number
1029
+ generations: number
1030
+ }
1031
+
1032
+ export type ChatThreadCountOutputTypeSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1033
+ messages?: boolean | ChatThreadCountOutputTypeCountMessagesArgs
1034
+ runs?: boolean | ChatThreadCountOutputTypeCountRunsArgs
1035
+ interrupts?: boolean | ChatThreadCountOutputTypeCountInterruptsArgs
1036
+ generations?: boolean | ChatThreadCountOutputTypeCountGenerationsArgs
1037
+ }
1038
+
1039
+ /**
1040
+ * ChatThreadCountOutputType without action
1041
+ */
1042
+ export type ChatThreadCountOutputTypeDefaultArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1043
+ /**
1044
+ * Select specific fields to fetch from the ChatThreadCountOutputType
1045
+ */
1046
+ select?: Prisma.ChatThreadCountOutputTypeSelect<ExtArgs> | null
1047
+ }
1048
+
1049
+ /**
1050
+ * ChatThreadCountOutputType without action
1051
+ */
1052
+ export type ChatThreadCountOutputTypeCountMessagesArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1053
+ where?: Prisma.ChatMessageWhereInput
1054
+ }
1055
+
1056
+ /**
1057
+ * ChatThreadCountOutputType without action
1058
+ */
1059
+ export type ChatThreadCountOutputTypeCountRunsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1060
+ where?: Prisma.ChatRunWhereInput
1061
+ }
1062
+
1063
+ /**
1064
+ * ChatThreadCountOutputType without action
1065
+ */
1066
+ export type ChatThreadCountOutputTypeCountInterruptsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1067
+ where?: Prisma.ChatInterruptWhereInput
1068
+ }
1069
+
1070
+ /**
1071
+ * ChatThreadCountOutputType without action
1072
+ */
1073
+ export type ChatThreadCountOutputTypeCountGenerationsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1074
+ where?: Prisma.GenerationRunWhereInput
1075
+ }
1076
+
1077
+
1078
+ export type ChatThreadSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
1079
+ id?: boolean
1080
+ userId?: boolean
1081
+ title?: boolean
1082
+ isArchived?: boolean
1083
+ createdAt?: boolean
1084
+ updatedAt?: boolean
1085
+ agentId?: boolean
1086
+ user?: boolean | Prisma.UserDefaultArgs<ExtArgs>
1087
+ messages?: boolean | Prisma.ChatThread$messagesArgs<ExtArgs>
1088
+ runs?: boolean | Prisma.ChatThread$runsArgs<ExtArgs>
1089
+ interrupts?: boolean | Prisma.ChatThread$interruptsArgs<ExtArgs>
1090
+ generations?: boolean | Prisma.ChatThread$generationsArgs<ExtArgs>
1091
+ agent?: boolean | Prisma.ChatThread$agentArgs<ExtArgs>
1092
+ _count?: boolean | Prisma.ChatThreadCountOutputTypeDefaultArgs<ExtArgs>
1093
+ }, ExtArgs["result"]["chatThread"]>
1094
+
1095
+ export type ChatThreadSelectCreateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
1096
+ id?: boolean
1097
+ userId?: boolean
1098
+ title?: boolean
1099
+ isArchived?: boolean
1100
+ createdAt?: boolean
1101
+ updatedAt?: boolean
1102
+ agentId?: boolean
1103
+ user?: boolean | Prisma.UserDefaultArgs<ExtArgs>
1104
+ agent?: boolean | Prisma.ChatThread$agentArgs<ExtArgs>
1105
+ }, ExtArgs["result"]["chatThread"]>
1106
+
1107
+ export type ChatThreadSelectUpdateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
1108
+ id?: boolean
1109
+ userId?: boolean
1110
+ title?: boolean
1111
+ isArchived?: boolean
1112
+ createdAt?: boolean
1113
+ updatedAt?: boolean
1114
+ agentId?: boolean
1115
+ user?: boolean | Prisma.UserDefaultArgs<ExtArgs>
1116
+ agent?: boolean | Prisma.ChatThread$agentArgs<ExtArgs>
1117
+ }, ExtArgs["result"]["chatThread"]>
1118
+
1119
+ export type ChatThreadSelectScalar = {
1120
+ id?: boolean
1121
+ userId?: boolean
1122
+ title?: boolean
1123
+ isArchived?: boolean
1124
+ createdAt?: boolean
1125
+ updatedAt?: boolean
1126
+ agentId?: boolean
1127
+ }
1128
+
1129
+ export type ChatThreadOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"id" | "userId" | "title" | "isArchived" | "createdAt" | "updatedAt" | "agentId", ExtArgs["result"]["chatThread"]>
1130
+ export type ChatThreadInclude<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1131
+ user?: boolean | Prisma.UserDefaultArgs<ExtArgs>
1132
+ messages?: boolean | Prisma.ChatThread$messagesArgs<ExtArgs>
1133
+ runs?: boolean | Prisma.ChatThread$runsArgs<ExtArgs>
1134
+ interrupts?: boolean | Prisma.ChatThread$interruptsArgs<ExtArgs>
1135
+ generations?: boolean | Prisma.ChatThread$generationsArgs<ExtArgs>
1136
+ agent?: boolean | Prisma.ChatThread$agentArgs<ExtArgs>
1137
+ _count?: boolean | Prisma.ChatThreadCountOutputTypeDefaultArgs<ExtArgs>
1138
+ }
1139
+ export type ChatThreadIncludeCreateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1140
+ user?: boolean | Prisma.UserDefaultArgs<ExtArgs>
1141
+ agent?: boolean | Prisma.ChatThread$agentArgs<ExtArgs>
1142
+ }
1143
+ export type ChatThreadIncludeUpdateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1144
+ user?: boolean | Prisma.UserDefaultArgs<ExtArgs>
1145
+ agent?: boolean | Prisma.ChatThread$agentArgs<ExtArgs>
1146
+ }
1147
+
1148
+ export type $ChatThreadPayload<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1149
+ name: "ChatThread"
1150
+ objects: {
1151
+ user: Prisma.$UserPayload<ExtArgs>
1152
+ messages: Prisma.$ChatMessagePayload<ExtArgs>[]
1153
+ runs: Prisma.$ChatRunPayload<ExtArgs>[]
1154
+ interrupts: Prisma.$ChatInterruptPayload<ExtArgs>[]
1155
+ generations: Prisma.$GenerationRunPayload<ExtArgs>[]
1156
+ agent: Prisma.$UserAgentPayload<ExtArgs> | null
1157
+ }
1158
+ scalars: runtime.Types.Extensions.GetPayloadResult<{
1159
+ id: string
1160
+ userId: string
1161
+ title: string | null
1162
+ isArchived: boolean
1163
+ createdAt: Date
1164
+ updatedAt: Date
1165
+ agentId: string | null
1166
+ }, ExtArgs["result"]["chatThread"]>
1167
+ composites: {}
1168
+ }
1169
+
1170
+ export type ChatThreadGetPayload<S extends boolean | null | undefined | ChatThreadDefaultArgs> = runtime.Types.Result.GetResult<Prisma.$ChatThreadPayload, S>
1171
+
1172
+ export type ChatThreadCountArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> =
1173
+ Omit<ChatThreadFindManyArgs, 'select' | 'include' | 'distinct' | 'omit'> & {
1174
+ select?: ChatThreadCountAggregateInputType | true
1175
+ }
1176
+
1177
+ export interface ChatThreadDelegate<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> {
1178
+ [K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['ChatThread'], meta: { name: 'ChatThread' } }
1179
+ /**
1180
+ * Find zero or one ChatThread that matches the filter.
1181
+ * @param {ChatThreadFindUniqueArgs} args - Arguments to find a ChatThread
1182
+ * @example
1183
+ * // Get one ChatThread
1184
+ * const chatThread = await prisma.chatThread.findUnique({
1185
+ * where: {
1186
+ * // ... provide filter here
1187
+ * }
1188
+ * })
1189
+ */
1190
+ findUnique<T extends ChatThreadFindUniqueArgs>(args: Prisma.SelectSubset<T, ChatThreadFindUniqueArgs<ExtArgs>>): Prisma.Prisma__ChatThreadClient<runtime.Types.Result.GetResult<Prisma.$ChatThreadPayload<ExtArgs>, T, "findUnique", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
1191
+
1192
+ /**
1193
+ * Find one ChatThread that matches the filter or throw an error with `error.code='P2025'`
1194
+ * if no matches were found.
1195
+ * @param {ChatThreadFindUniqueOrThrowArgs} args - Arguments to find a ChatThread
1196
+ * @example
1197
+ * // Get one ChatThread
1198
+ * const chatThread = await prisma.chatThread.findUniqueOrThrow({
1199
+ * where: {
1200
+ * // ... provide filter here
1201
+ * }
1202
+ * })
1203
+ */
1204
+ findUniqueOrThrow<T extends ChatThreadFindUniqueOrThrowArgs>(args: Prisma.SelectSubset<T, ChatThreadFindUniqueOrThrowArgs<ExtArgs>>): Prisma.Prisma__ChatThreadClient<runtime.Types.Result.GetResult<Prisma.$ChatThreadPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
1205
+
1206
+ /**
1207
+ * Find the first ChatThread that matches the filter.
1208
+ * Note, that providing `undefined` is treated as the value not being there.
1209
+ * Read more here: https://pris.ly/d/null-undefined
1210
+ * @param {ChatThreadFindFirstArgs} args - Arguments to find a ChatThread
1211
+ * @example
1212
+ * // Get one ChatThread
1213
+ * const chatThread = await prisma.chatThread.findFirst({
1214
+ * where: {
1215
+ * // ... provide filter here
1216
+ * }
1217
+ * })
1218
+ */
1219
+ findFirst<T extends ChatThreadFindFirstArgs>(args?: Prisma.SelectSubset<T, ChatThreadFindFirstArgs<ExtArgs>>): Prisma.Prisma__ChatThreadClient<runtime.Types.Result.GetResult<Prisma.$ChatThreadPayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
1220
+
1221
+ /**
1222
+ * Find the first ChatThread that matches the filter or
1223
+ * throw `PrismaKnownClientError` with `P2025` code if no matches were found.
1224
+ * Note, that providing `undefined` is treated as the value not being there.
1225
+ * Read more here: https://pris.ly/d/null-undefined
1226
+ * @param {ChatThreadFindFirstOrThrowArgs} args - Arguments to find a ChatThread
1227
+ * @example
1228
+ * // Get one ChatThread
1229
+ * const chatThread = await prisma.chatThread.findFirstOrThrow({
1230
+ * where: {
1231
+ * // ... provide filter here
1232
+ * }
1233
+ * })
1234
+ */
1235
+ findFirstOrThrow<T extends ChatThreadFindFirstOrThrowArgs>(args?: Prisma.SelectSubset<T, ChatThreadFindFirstOrThrowArgs<ExtArgs>>): Prisma.Prisma__ChatThreadClient<runtime.Types.Result.GetResult<Prisma.$ChatThreadPayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
1236
+
1237
+ /**
1238
+ * Find zero or more ChatThreads that matches the filter.
1239
+ * Note, that providing `undefined` is treated as the value not being there.
1240
+ * Read more here: https://pris.ly/d/null-undefined
1241
+ * @param {ChatThreadFindManyArgs} args - Arguments to filter and select certain fields only.
1242
+ * @example
1243
+ * // Get all ChatThreads
1244
+ * const chatThreads = await prisma.chatThread.findMany()
1245
+ *
1246
+ * // Get first 10 ChatThreads
1247
+ * const chatThreads = await prisma.chatThread.findMany({ take: 10 })
1248
+ *
1249
+ * // Only select the `id`
1250
+ * const chatThreadWithIdOnly = await prisma.chatThread.findMany({ select: { id: true } })
1251
+ *
1252
+ */
1253
+ findMany<T extends ChatThreadFindManyArgs>(args?: Prisma.SelectSubset<T, ChatThreadFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$ChatThreadPayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>
1254
+
1255
+ /**
1256
+ * Create a ChatThread.
1257
+ * @param {ChatThreadCreateArgs} args - Arguments to create a ChatThread.
1258
+ * @example
1259
+ * // Create one ChatThread
1260
+ * const ChatThread = await prisma.chatThread.create({
1261
+ * data: {
1262
+ * // ... data to create a ChatThread
1263
+ * }
1264
+ * })
1265
+ *
1266
+ */
1267
+ create<T extends ChatThreadCreateArgs>(args: Prisma.SelectSubset<T, ChatThreadCreateArgs<ExtArgs>>): Prisma.Prisma__ChatThreadClient<runtime.Types.Result.GetResult<Prisma.$ChatThreadPayload<ExtArgs>, T, "create", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
1268
+
1269
+ /**
1270
+ * Create many ChatThreads.
1271
+ * @param {ChatThreadCreateManyArgs} args - Arguments to create many ChatThreads.
1272
+ * @example
1273
+ * // Create many ChatThreads
1274
+ * const chatThread = await prisma.chatThread.createMany({
1275
+ * data: [
1276
+ * // ... provide data here
1277
+ * ]
1278
+ * })
1279
+ *
1280
+ */
1281
+ createMany<T extends ChatThreadCreateManyArgs>(args?: Prisma.SelectSubset<T, ChatThreadCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>
1282
+
1283
+ /**
1284
+ * Create many ChatThreads and returns the data saved in the database.
1285
+ * @param {ChatThreadCreateManyAndReturnArgs} args - Arguments to create many ChatThreads.
1286
+ * @example
1287
+ * // Create many ChatThreads
1288
+ * const chatThread = await prisma.chatThread.createManyAndReturn({
1289
+ * data: [
1290
+ * // ... provide data here
1291
+ * ]
1292
+ * })
1293
+ *
1294
+ * // Create many ChatThreads and only return the `id`
1295
+ * const chatThreadWithIdOnly = await prisma.chatThread.createManyAndReturn({
1296
+ * select: { id: true },
1297
+ * data: [
1298
+ * // ... provide data here
1299
+ * ]
1300
+ * })
1301
+ * Note, that providing `undefined` is treated as the value not being there.
1302
+ * Read more here: https://pris.ly/d/null-undefined
1303
+ *
1304
+ */
1305
+ createManyAndReturn<T extends ChatThreadCreateManyAndReturnArgs>(args?: Prisma.SelectSubset<T, ChatThreadCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$ChatThreadPayload<ExtArgs>, T, "createManyAndReturn", GlobalOmitOptions>>
1306
+
1307
+ /**
1308
+ * Delete a ChatThread.
1309
+ * @param {ChatThreadDeleteArgs} args - Arguments to delete one ChatThread.
1310
+ * @example
1311
+ * // Delete one ChatThread
1312
+ * const ChatThread = await prisma.chatThread.delete({
1313
+ * where: {
1314
+ * // ... filter to delete one ChatThread
1315
+ * }
1316
+ * })
1317
+ *
1318
+ */
1319
+ delete<T extends ChatThreadDeleteArgs>(args: Prisma.SelectSubset<T, ChatThreadDeleteArgs<ExtArgs>>): Prisma.Prisma__ChatThreadClient<runtime.Types.Result.GetResult<Prisma.$ChatThreadPayload<ExtArgs>, T, "delete", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
1320
+
1321
+ /**
1322
+ * Update one ChatThread.
1323
+ * @param {ChatThreadUpdateArgs} args - Arguments to update one ChatThread.
1324
+ * @example
1325
+ * // Update one ChatThread
1326
+ * const chatThread = await prisma.chatThread.update({
1327
+ * where: {
1328
+ * // ... provide filter here
1329
+ * },
1330
+ * data: {
1331
+ * // ... provide data here
1332
+ * }
1333
+ * })
1334
+ *
1335
+ */
1336
+ update<T extends ChatThreadUpdateArgs>(args: Prisma.SelectSubset<T, ChatThreadUpdateArgs<ExtArgs>>): Prisma.Prisma__ChatThreadClient<runtime.Types.Result.GetResult<Prisma.$ChatThreadPayload<ExtArgs>, T, "update", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
1337
+
1338
+ /**
1339
+ * Delete zero or more ChatThreads.
1340
+ * @param {ChatThreadDeleteManyArgs} args - Arguments to filter ChatThreads to delete.
1341
+ * @example
1342
+ * // Delete a few ChatThreads
1343
+ * const { count } = await prisma.chatThread.deleteMany({
1344
+ * where: {
1345
+ * // ... provide filter here
1346
+ * }
1347
+ * })
1348
+ *
1349
+ */
1350
+ deleteMany<T extends ChatThreadDeleteManyArgs>(args?: Prisma.SelectSubset<T, ChatThreadDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>
1351
+
1352
+ /**
1353
+ * Update zero or more ChatThreads.
1354
+ * Note, that providing `undefined` is treated as the value not being there.
1355
+ * Read more here: https://pris.ly/d/null-undefined
1356
+ * @param {ChatThreadUpdateManyArgs} args - Arguments to update one or more rows.
1357
+ * @example
1358
+ * // Update many ChatThreads
1359
+ * const chatThread = await prisma.chatThread.updateMany({
1360
+ * where: {
1361
+ * // ... provide filter here
1362
+ * },
1363
+ * data: {
1364
+ * // ... provide data here
1365
+ * }
1366
+ * })
1367
+ *
1368
+ */
1369
+ updateMany<T extends ChatThreadUpdateManyArgs>(args: Prisma.SelectSubset<T, ChatThreadUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>
1370
+
1371
+ /**
1372
+ * Update zero or more ChatThreads and returns the data updated in the database.
1373
+ * @param {ChatThreadUpdateManyAndReturnArgs} args - Arguments to update many ChatThreads.
1374
+ * @example
1375
+ * // Update many ChatThreads
1376
+ * const chatThread = await prisma.chatThread.updateManyAndReturn({
1377
+ * where: {
1378
+ * // ... provide filter here
1379
+ * },
1380
+ * data: [
1381
+ * // ... provide data here
1382
+ * ]
1383
+ * })
1384
+ *
1385
+ * // Update zero or more ChatThreads and only return the `id`
1386
+ * const chatThreadWithIdOnly = await prisma.chatThread.updateManyAndReturn({
1387
+ * select: { id: true },
1388
+ * where: {
1389
+ * // ... provide filter here
1390
+ * },
1391
+ * data: [
1392
+ * // ... provide data here
1393
+ * ]
1394
+ * })
1395
+ * Note, that providing `undefined` is treated as the value not being there.
1396
+ * Read more here: https://pris.ly/d/null-undefined
1397
+ *
1398
+ */
1399
+ updateManyAndReturn<T extends ChatThreadUpdateManyAndReturnArgs>(args: Prisma.SelectSubset<T, ChatThreadUpdateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$ChatThreadPayload<ExtArgs>, T, "updateManyAndReturn", GlobalOmitOptions>>
1400
+
1401
+ /**
1402
+ * Create or update one ChatThread.
1403
+ * @param {ChatThreadUpsertArgs} args - Arguments to update or create a ChatThread.
1404
+ * @example
1405
+ * // Update or create a ChatThread
1406
+ * const chatThread = await prisma.chatThread.upsert({
1407
+ * create: {
1408
+ * // ... data to create a ChatThread
1409
+ * },
1410
+ * update: {
1411
+ * // ... in case it already exists, update
1412
+ * },
1413
+ * where: {
1414
+ * // ... the filter for the ChatThread we want to update
1415
+ * }
1416
+ * })
1417
+ */
1418
+ upsert<T extends ChatThreadUpsertArgs>(args: Prisma.SelectSubset<T, ChatThreadUpsertArgs<ExtArgs>>): Prisma.Prisma__ChatThreadClient<runtime.Types.Result.GetResult<Prisma.$ChatThreadPayload<ExtArgs>, T, "upsert", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
1419
+
1420
+
1421
+ /**
1422
+ * Count the number of ChatThreads.
1423
+ * Note, that providing `undefined` is treated as the value not being there.
1424
+ * Read more here: https://pris.ly/d/null-undefined
1425
+ * @param {ChatThreadCountArgs} args - Arguments to filter ChatThreads to count.
1426
+ * @example
1427
+ * // Count the number of ChatThreads
1428
+ * const count = await prisma.chatThread.count({
1429
+ * where: {
1430
+ * // ... the filter for the ChatThreads we want to count
1431
+ * }
1432
+ * })
1433
+ **/
1434
+ count<T extends ChatThreadCountArgs>(
1435
+ args?: Prisma.Subset<T, ChatThreadCountArgs>,
1436
+ ): Prisma.PrismaPromise<
1437
+ T extends runtime.Types.Utils.Record<'select', any>
1438
+ ? T['select'] extends true
1439
+ ? number
1440
+ : Prisma.GetScalarType<T['select'], ChatThreadCountAggregateOutputType>
1441
+ : number
1442
+ >
1443
+
1444
+ /**
1445
+ * Allows you to perform aggregations operations on a ChatThread.
1446
+ * Note, that providing `undefined` is treated as the value not being there.
1447
+ * Read more here: https://pris.ly/d/null-undefined
1448
+ * @param {ChatThreadAggregateArgs} args - Select which aggregations you would like to apply and on what fields.
1449
+ * @example
1450
+ * // Ordered by age ascending
1451
+ * // Where email contains prisma.io
1452
+ * // Limited to the 10 users
1453
+ * const aggregations = await prisma.user.aggregate({
1454
+ * _avg: {
1455
+ * age: true,
1456
+ * },
1457
+ * where: {
1458
+ * email: {
1459
+ * contains: "prisma.io",
1460
+ * },
1461
+ * },
1462
+ * orderBy: {
1463
+ * age: "asc",
1464
+ * },
1465
+ * take: 10,
1466
+ * })
1467
+ **/
1468
+ aggregate<T extends ChatThreadAggregateArgs>(args: Prisma.Subset<T, ChatThreadAggregateArgs>): Prisma.PrismaPromise<GetChatThreadAggregateType<T>>
1469
+
1470
+ /**
1471
+ * Group by ChatThread.
1472
+ * Note, that providing `undefined` is treated as the value not being there.
1473
+ * Read more here: https://pris.ly/d/null-undefined
1474
+ * @param {ChatThreadGroupByArgs} args - Group by arguments.
1475
+ * @example
1476
+ * // Group by city, order by createdAt, get count
1477
+ * const result = await prisma.user.groupBy({
1478
+ * by: ['city', 'createdAt'],
1479
+ * orderBy: {
1480
+ * createdAt: true
1481
+ * },
1482
+ * _count: {
1483
+ * _all: true
1484
+ * },
1485
+ * })
1486
+ *
1487
+ **/
1488
+ groupBy<
1489
+ T extends ChatThreadGroupByArgs,
1490
+ HasSelectOrTake extends Prisma.Or<
1491
+ Prisma.Extends<'skip', Prisma.Keys<T>>,
1492
+ Prisma.Extends<'take', Prisma.Keys<T>>
1493
+ >,
1494
+ OrderByArg extends Prisma.True extends HasSelectOrTake
1495
+ ? { orderBy: ChatThreadGroupByArgs['orderBy'] }
1496
+ : { orderBy?: ChatThreadGroupByArgs['orderBy'] },
1497
+ OrderFields extends Prisma.ExcludeUnderscoreKeys<Prisma.Keys<Prisma.MaybeTupleToUnion<T['orderBy']>>>,
1498
+ ByFields extends Prisma.MaybeTupleToUnion<T['by']>,
1499
+ ByValid extends Prisma.Has<ByFields, OrderFields>,
1500
+ HavingFields extends Prisma.GetHavingFields<T['having']>,
1501
+ HavingValid extends Prisma.Has<ByFields, HavingFields>,
1502
+ ByEmpty extends T['by'] extends never[] ? Prisma.True : Prisma.False,
1503
+ InputErrors extends ByEmpty extends Prisma.True
1504
+ ? `Error: "by" must not be empty.`
1505
+ : HavingValid extends Prisma.False
1506
+ ? {
1507
+ [P in HavingFields]: P extends ByFields
1508
+ ? never
1509
+ : P extends string
1510
+ ? `Error: Field "${P}" used in "having" needs to be provided in "by".`
1511
+ : [
1512
+ Error,
1513
+ 'Field ',
1514
+ P,
1515
+ ` in "having" needs to be provided in "by"`,
1516
+ ]
1517
+ }[HavingFields]
1518
+ : 'take' extends Prisma.Keys<T>
1519
+ ? 'orderBy' extends Prisma.Keys<T>
1520
+ ? ByValid extends Prisma.True
1521
+ ? {}
1522
+ : {
1523
+ [P in OrderFields]: P extends ByFields
1524
+ ? never
1525
+ : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
1526
+ }[OrderFields]
1527
+ : 'Error: If you provide "take", you also need to provide "orderBy"'
1528
+ : 'skip' extends Prisma.Keys<T>
1529
+ ? 'orderBy' extends Prisma.Keys<T>
1530
+ ? ByValid extends Prisma.True
1531
+ ? {}
1532
+ : {
1533
+ [P in OrderFields]: P extends ByFields
1534
+ ? never
1535
+ : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
1536
+ }[OrderFields]
1537
+ : 'Error: If you provide "skip", you also need to provide "orderBy"'
1538
+ : ByValid extends Prisma.True
1539
+ ? {}
1540
+ : {
1541
+ [P in OrderFields]: P extends ByFields
1542
+ ? never
1543
+ : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
1544
+ }[OrderFields]
1545
+ >(args: Prisma.SubsetIntersection<T, ChatThreadGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetChatThreadGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
1546
+ /**
1547
+ * Fields of the ChatThread model
1548
+ */
1549
+ readonly fields: ChatThreadFieldRefs;
1550
+ }
1551
+
1552
+ /**
1553
+ * The delegate class that acts as a "Promise-like" for ChatThread.
1554
+ * Why is this prefixed with `Prisma__`?
1555
+ * Because we want to prevent naming conflicts as mentioned in
1556
+ * https://github.com/prisma/prisma-client-js/issues/707
1557
+ */
1558
+ export interface Prisma__ChatThreadClient<T, Null = never, ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
1559
+ readonly [Symbol.toStringTag]: "PrismaPromise"
1560
+ user<T extends Prisma.UserDefaultArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.UserDefaultArgs<ExtArgs>>): Prisma.Prisma__UserClient<runtime.Types.Result.GetResult<Prisma.$UserPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | Null, Null, ExtArgs, GlobalOmitOptions>
1561
+ messages<T extends Prisma.ChatThread$messagesArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.ChatThread$messagesArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$ChatMessagePayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
1562
+ runs<T extends Prisma.ChatThread$runsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.ChatThread$runsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$ChatRunPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
1563
+ interrupts<T extends Prisma.ChatThread$interruptsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.ChatThread$interruptsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$ChatInterruptPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
1564
+ generations<T extends Prisma.ChatThread$generationsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.ChatThread$generationsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$GenerationRunPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
1565
+ agent<T extends Prisma.ChatThread$agentArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.ChatThread$agentArgs<ExtArgs>>): Prisma.Prisma__UserAgentClient<runtime.Types.Result.GetResult<Prisma.$UserAgentPayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
1566
+ /**
1567
+ * Attaches callbacks for the resolution and/or rejection of the Promise.
1568
+ * @param onfulfilled The callback to execute when the Promise is resolved.
1569
+ * @param onrejected The callback to execute when the Promise is rejected.
1570
+ * @returns A Promise for the completion of which ever callback is executed.
1571
+ */
1572
+ then<TResult1 = T, TResult2 = never>(onfulfilled?: ((value: T) => TResult1 | PromiseLike<TResult1>) | undefined | null, onrejected?: ((reason: any) => TResult2 | PromiseLike<TResult2>) | undefined | null): runtime.Types.Utils.JsPromise<TResult1 | TResult2>
1573
+ /**
1574
+ * Attaches a callback for only the rejection of the Promise.
1575
+ * @param onrejected The callback to execute when the Promise is rejected.
1576
+ * @returns A Promise for the completion of the callback.
1577
+ */
1578
+ catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): runtime.Types.Utils.JsPromise<T | TResult>
1579
+ /**
1580
+ * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The
1581
+ * resolved value cannot be modified from the callback.
1582
+ * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected).
1583
+ * @returns A Promise for the completion of the callback.
1584
+ */
1585
+ finally(onfinally?: (() => void) | undefined | null): runtime.Types.Utils.JsPromise<T>
1586
+ }
1587
+
1588
+
1589
+
1590
+
1591
+ /**
1592
+ * Fields of the ChatThread model
1593
+ */
1594
+ export interface ChatThreadFieldRefs {
1595
+ readonly id: Prisma.FieldRef<"ChatThread", 'String'>
1596
+ readonly userId: Prisma.FieldRef<"ChatThread", 'String'>
1597
+ readonly title: Prisma.FieldRef<"ChatThread", 'String'>
1598
+ readonly isArchived: Prisma.FieldRef<"ChatThread", 'Boolean'>
1599
+ readonly createdAt: Prisma.FieldRef<"ChatThread", 'DateTime'>
1600
+ readonly updatedAt: Prisma.FieldRef<"ChatThread", 'DateTime'>
1601
+ readonly agentId: Prisma.FieldRef<"ChatThread", 'String'>
1602
+ }
1603
+
1604
+
1605
+ // Custom InputTypes
1606
+ /**
1607
+ * ChatThread findUnique
1608
+ */
1609
+ export type ChatThreadFindUniqueArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1610
+ /**
1611
+ * Select specific fields to fetch from the ChatThread
1612
+ */
1613
+ select?: Prisma.ChatThreadSelect<ExtArgs> | null
1614
+ /**
1615
+ * Omit specific fields from the ChatThread
1616
+ */
1617
+ omit?: Prisma.ChatThreadOmit<ExtArgs> | null
1618
+ /**
1619
+ * Choose, which related nodes to fetch as well
1620
+ */
1621
+ include?: Prisma.ChatThreadInclude<ExtArgs> | null
1622
+ /**
1623
+ * Filter, which ChatThread to fetch.
1624
+ */
1625
+ where: Prisma.ChatThreadWhereUniqueInput
1626
+ }
1627
+
1628
+ /**
1629
+ * ChatThread findUniqueOrThrow
1630
+ */
1631
+ export type ChatThreadFindUniqueOrThrowArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1632
+ /**
1633
+ * Select specific fields to fetch from the ChatThread
1634
+ */
1635
+ select?: Prisma.ChatThreadSelect<ExtArgs> | null
1636
+ /**
1637
+ * Omit specific fields from the ChatThread
1638
+ */
1639
+ omit?: Prisma.ChatThreadOmit<ExtArgs> | null
1640
+ /**
1641
+ * Choose, which related nodes to fetch as well
1642
+ */
1643
+ include?: Prisma.ChatThreadInclude<ExtArgs> | null
1644
+ /**
1645
+ * Filter, which ChatThread to fetch.
1646
+ */
1647
+ where: Prisma.ChatThreadWhereUniqueInput
1648
+ }
1649
+
1650
+ /**
1651
+ * ChatThread findFirst
1652
+ */
1653
+ export type ChatThreadFindFirstArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1654
+ /**
1655
+ * Select specific fields to fetch from the ChatThread
1656
+ */
1657
+ select?: Prisma.ChatThreadSelect<ExtArgs> | null
1658
+ /**
1659
+ * Omit specific fields from the ChatThread
1660
+ */
1661
+ omit?: Prisma.ChatThreadOmit<ExtArgs> | null
1662
+ /**
1663
+ * Choose, which related nodes to fetch as well
1664
+ */
1665
+ include?: Prisma.ChatThreadInclude<ExtArgs> | null
1666
+ /**
1667
+ * Filter, which ChatThread to fetch.
1668
+ */
1669
+ where?: Prisma.ChatThreadWhereInput
1670
+ /**
1671
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
1672
+ *
1673
+ * Determine the order of ChatThreads to fetch.
1674
+ */
1675
+ orderBy?: Prisma.ChatThreadOrderByWithRelationInput | Prisma.ChatThreadOrderByWithRelationInput[]
1676
+ /**
1677
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
1678
+ *
1679
+ * Sets the position for searching for ChatThreads.
1680
+ */
1681
+ cursor?: Prisma.ChatThreadWhereUniqueInput
1682
+ /**
1683
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
1684
+ *
1685
+ * Take `±n` ChatThreads from the position of the cursor.
1686
+ */
1687
+ take?: number
1688
+ /**
1689
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
1690
+ *
1691
+ * Skip the first `n` ChatThreads.
1692
+ */
1693
+ skip?: number
1694
+ /**
1695
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
1696
+ *
1697
+ * Filter by unique combinations of ChatThreads.
1698
+ */
1699
+ distinct?: Prisma.ChatThreadScalarFieldEnum | Prisma.ChatThreadScalarFieldEnum[]
1700
+ }
1701
+
1702
+ /**
1703
+ * ChatThread findFirstOrThrow
1704
+ */
1705
+ export type ChatThreadFindFirstOrThrowArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1706
+ /**
1707
+ * Select specific fields to fetch from the ChatThread
1708
+ */
1709
+ select?: Prisma.ChatThreadSelect<ExtArgs> | null
1710
+ /**
1711
+ * Omit specific fields from the ChatThread
1712
+ */
1713
+ omit?: Prisma.ChatThreadOmit<ExtArgs> | null
1714
+ /**
1715
+ * Choose, which related nodes to fetch as well
1716
+ */
1717
+ include?: Prisma.ChatThreadInclude<ExtArgs> | null
1718
+ /**
1719
+ * Filter, which ChatThread to fetch.
1720
+ */
1721
+ where?: Prisma.ChatThreadWhereInput
1722
+ /**
1723
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
1724
+ *
1725
+ * Determine the order of ChatThreads to fetch.
1726
+ */
1727
+ orderBy?: Prisma.ChatThreadOrderByWithRelationInput | Prisma.ChatThreadOrderByWithRelationInput[]
1728
+ /**
1729
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
1730
+ *
1731
+ * Sets the position for searching for ChatThreads.
1732
+ */
1733
+ cursor?: Prisma.ChatThreadWhereUniqueInput
1734
+ /**
1735
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
1736
+ *
1737
+ * Take `±n` ChatThreads from the position of the cursor.
1738
+ */
1739
+ take?: number
1740
+ /**
1741
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
1742
+ *
1743
+ * Skip the first `n` ChatThreads.
1744
+ */
1745
+ skip?: number
1746
+ /**
1747
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
1748
+ *
1749
+ * Filter by unique combinations of ChatThreads.
1750
+ */
1751
+ distinct?: Prisma.ChatThreadScalarFieldEnum | Prisma.ChatThreadScalarFieldEnum[]
1752
+ }
1753
+
1754
+ /**
1755
+ * ChatThread findMany
1756
+ */
1757
+ export type ChatThreadFindManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1758
+ /**
1759
+ * Select specific fields to fetch from the ChatThread
1760
+ */
1761
+ select?: Prisma.ChatThreadSelect<ExtArgs> | null
1762
+ /**
1763
+ * Omit specific fields from the ChatThread
1764
+ */
1765
+ omit?: Prisma.ChatThreadOmit<ExtArgs> | null
1766
+ /**
1767
+ * Choose, which related nodes to fetch as well
1768
+ */
1769
+ include?: Prisma.ChatThreadInclude<ExtArgs> | null
1770
+ /**
1771
+ * Filter, which ChatThreads to fetch.
1772
+ */
1773
+ where?: Prisma.ChatThreadWhereInput
1774
+ /**
1775
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
1776
+ *
1777
+ * Determine the order of ChatThreads to fetch.
1778
+ */
1779
+ orderBy?: Prisma.ChatThreadOrderByWithRelationInput | Prisma.ChatThreadOrderByWithRelationInput[]
1780
+ /**
1781
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
1782
+ *
1783
+ * Sets the position for listing ChatThreads.
1784
+ */
1785
+ cursor?: Prisma.ChatThreadWhereUniqueInput
1786
+ /**
1787
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
1788
+ *
1789
+ * Take `±n` ChatThreads from the position of the cursor.
1790
+ */
1791
+ take?: number
1792
+ /**
1793
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
1794
+ *
1795
+ * Skip the first `n` ChatThreads.
1796
+ */
1797
+ skip?: number
1798
+ /**
1799
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
1800
+ *
1801
+ * Filter by unique combinations of ChatThreads.
1802
+ */
1803
+ distinct?: Prisma.ChatThreadScalarFieldEnum | Prisma.ChatThreadScalarFieldEnum[]
1804
+ }
1805
+
1806
+ /**
1807
+ * ChatThread create
1808
+ */
1809
+ export type ChatThreadCreateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1810
+ /**
1811
+ * Select specific fields to fetch from the ChatThread
1812
+ */
1813
+ select?: Prisma.ChatThreadSelect<ExtArgs> | null
1814
+ /**
1815
+ * Omit specific fields from the ChatThread
1816
+ */
1817
+ omit?: Prisma.ChatThreadOmit<ExtArgs> | null
1818
+ /**
1819
+ * Choose, which related nodes to fetch as well
1820
+ */
1821
+ include?: Prisma.ChatThreadInclude<ExtArgs> | null
1822
+ /**
1823
+ * The data needed to create a ChatThread.
1824
+ */
1825
+ data: Prisma.XOR<Prisma.ChatThreadCreateInput, Prisma.ChatThreadUncheckedCreateInput>
1826
+ }
1827
+
1828
+ /**
1829
+ * ChatThread createMany
1830
+ */
1831
+ export type ChatThreadCreateManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1832
+ /**
1833
+ * The data used to create many ChatThreads.
1834
+ */
1835
+ data: Prisma.ChatThreadCreateManyInput | Prisma.ChatThreadCreateManyInput[]
1836
+ skipDuplicates?: boolean
1837
+ }
1838
+
1839
+ /**
1840
+ * ChatThread createManyAndReturn
1841
+ */
1842
+ export type ChatThreadCreateManyAndReturnArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1843
+ /**
1844
+ * Select specific fields to fetch from the ChatThread
1845
+ */
1846
+ select?: Prisma.ChatThreadSelectCreateManyAndReturn<ExtArgs> | null
1847
+ /**
1848
+ * Omit specific fields from the ChatThread
1849
+ */
1850
+ omit?: Prisma.ChatThreadOmit<ExtArgs> | null
1851
+ /**
1852
+ * The data used to create many ChatThreads.
1853
+ */
1854
+ data: Prisma.ChatThreadCreateManyInput | Prisma.ChatThreadCreateManyInput[]
1855
+ skipDuplicates?: boolean
1856
+ /**
1857
+ * Choose, which related nodes to fetch as well
1858
+ */
1859
+ include?: Prisma.ChatThreadIncludeCreateManyAndReturn<ExtArgs> | null
1860
+ }
1861
+
1862
+ /**
1863
+ * ChatThread update
1864
+ */
1865
+ export type ChatThreadUpdateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1866
+ /**
1867
+ * Select specific fields to fetch from the ChatThread
1868
+ */
1869
+ select?: Prisma.ChatThreadSelect<ExtArgs> | null
1870
+ /**
1871
+ * Omit specific fields from the ChatThread
1872
+ */
1873
+ omit?: Prisma.ChatThreadOmit<ExtArgs> | null
1874
+ /**
1875
+ * Choose, which related nodes to fetch as well
1876
+ */
1877
+ include?: Prisma.ChatThreadInclude<ExtArgs> | null
1878
+ /**
1879
+ * The data needed to update a ChatThread.
1880
+ */
1881
+ data: Prisma.XOR<Prisma.ChatThreadUpdateInput, Prisma.ChatThreadUncheckedUpdateInput>
1882
+ /**
1883
+ * Choose, which ChatThread to update.
1884
+ */
1885
+ where: Prisma.ChatThreadWhereUniqueInput
1886
+ }
1887
+
1888
+ /**
1889
+ * ChatThread updateMany
1890
+ */
1891
+ export type ChatThreadUpdateManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1892
+ /**
1893
+ * The data used to update ChatThreads.
1894
+ */
1895
+ data: Prisma.XOR<Prisma.ChatThreadUpdateManyMutationInput, Prisma.ChatThreadUncheckedUpdateManyInput>
1896
+ /**
1897
+ * Filter which ChatThreads to update
1898
+ */
1899
+ where?: Prisma.ChatThreadWhereInput
1900
+ /**
1901
+ * Limit how many ChatThreads to update.
1902
+ */
1903
+ limit?: number
1904
+ }
1905
+
1906
+ /**
1907
+ * ChatThread updateManyAndReturn
1908
+ */
1909
+ export type ChatThreadUpdateManyAndReturnArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1910
+ /**
1911
+ * Select specific fields to fetch from the ChatThread
1912
+ */
1913
+ select?: Prisma.ChatThreadSelectUpdateManyAndReturn<ExtArgs> | null
1914
+ /**
1915
+ * Omit specific fields from the ChatThread
1916
+ */
1917
+ omit?: Prisma.ChatThreadOmit<ExtArgs> | null
1918
+ /**
1919
+ * The data used to update ChatThreads.
1920
+ */
1921
+ data: Prisma.XOR<Prisma.ChatThreadUpdateManyMutationInput, Prisma.ChatThreadUncheckedUpdateManyInput>
1922
+ /**
1923
+ * Filter which ChatThreads to update
1924
+ */
1925
+ where?: Prisma.ChatThreadWhereInput
1926
+ /**
1927
+ * Limit how many ChatThreads to update.
1928
+ */
1929
+ limit?: number
1930
+ /**
1931
+ * Choose, which related nodes to fetch as well
1932
+ */
1933
+ include?: Prisma.ChatThreadIncludeUpdateManyAndReturn<ExtArgs> | null
1934
+ }
1935
+
1936
+ /**
1937
+ * ChatThread upsert
1938
+ */
1939
+ export type ChatThreadUpsertArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1940
+ /**
1941
+ * Select specific fields to fetch from the ChatThread
1942
+ */
1943
+ select?: Prisma.ChatThreadSelect<ExtArgs> | null
1944
+ /**
1945
+ * Omit specific fields from the ChatThread
1946
+ */
1947
+ omit?: Prisma.ChatThreadOmit<ExtArgs> | null
1948
+ /**
1949
+ * Choose, which related nodes to fetch as well
1950
+ */
1951
+ include?: Prisma.ChatThreadInclude<ExtArgs> | null
1952
+ /**
1953
+ * The filter to search for the ChatThread to update in case it exists.
1954
+ */
1955
+ where: Prisma.ChatThreadWhereUniqueInput
1956
+ /**
1957
+ * In case the ChatThread found by the `where` argument doesn't exist, create a new ChatThread with this data.
1958
+ */
1959
+ create: Prisma.XOR<Prisma.ChatThreadCreateInput, Prisma.ChatThreadUncheckedCreateInput>
1960
+ /**
1961
+ * In case the ChatThread was found with the provided `where` argument, update it with this data.
1962
+ */
1963
+ update: Prisma.XOR<Prisma.ChatThreadUpdateInput, Prisma.ChatThreadUncheckedUpdateInput>
1964
+ }
1965
+
1966
+ /**
1967
+ * ChatThread delete
1968
+ */
1969
+ export type ChatThreadDeleteArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1970
+ /**
1971
+ * Select specific fields to fetch from the ChatThread
1972
+ */
1973
+ select?: Prisma.ChatThreadSelect<ExtArgs> | null
1974
+ /**
1975
+ * Omit specific fields from the ChatThread
1976
+ */
1977
+ omit?: Prisma.ChatThreadOmit<ExtArgs> | null
1978
+ /**
1979
+ * Choose, which related nodes to fetch as well
1980
+ */
1981
+ include?: Prisma.ChatThreadInclude<ExtArgs> | null
1982
+ /**
1983
+ * Filter which ChatThread to delete.
1984
+ */
1985
+ where: Prisma.ChatThreadWhereUniqueInput
1986
+ }
1987
+
1988
+ /**
1989
+ * ChatThread deleteMany
1990
+ */
1991
+ export type ChatThreadDeleteManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1992
+ /**
1993
+ * Filter which ChatThreads to delete
1994
+ */
1995
+ where?: Prisma.ChatThreadWhereInput
1996
+ /**
1997
+ * Limit how many ChatThreads to delete.
1998
+ */
1999
+ limit?: number
2000
+ }
2001
+
2002
+ /**
2003
+ * ChatThread.messages
2004
+ */
2005
+ export type ChatThread$messagesArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
2006
+ /**
2007
+ * Select specific fields to fetch from the ChatMessage
2008
+ */
2009
+ select?: Prisma.ChatMessageSelect<ExtArgs> | null
2010
+ /**
2011
+ * Omit specific fields from the ChatMessage
2012
+ */
2013
+ omit?: Prisma.ChatMessageOmit<ExtArgs> | null
2014
+ /**
2015
+ * Choose, which related nodes to fetch as well
2016
+ */
2017
+ include?: Prisma.ChatMessageInclude<ExtArgs> | null
2018
+ where?: Prisma.ChatMessageWhereInput
2019
+ orderBy?: Prisma.ChatMessageOrderByWithRelationInput | Prisma.ChatMessageOrderByWithRelationInput[]
2020
+ cursor?: Prisma.ChatMessageWhereUniqueInput
2021
+ take?: number
2022
+ skip?: number
2023
+ distinct?: Prisma.ChatMessageScalarFieldEnum | Prisma.ChatMessageScalarFieldEnum[]
2024
+ }
2025
+
2026
+ /**
2027
+ * ChatThread.runs
2028
+ */
2029
+ export type ChatThread$runsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
2030
+ /**
2031
+ * Select specific fields to fetch from the ChatRun
2032
+ */
2033
+ select?: Prisma.ChatRunSelect<ExtArgs> | null
2034
+ /**
2035
+ * Omit specific fields from the ChatRun
2036
+ */
2037
+ omit?: Prisma.ChatRunOmit<ExtArgs> | null
2038
+ /**
2039
+ * Choose, which related nodes to fetch as well
2040
+ */
2041
+ include?: Prisma.ChatRunInclude<ExtArgs> | null
2042
+ where?: Prisma.ChatRunWhereInput
2043
+ orderBy?: Prisma.ChatRunOrderByWithRelationInput | Prisma.ChatRunOrderByWithRelationInput[]
2044
+ cursor?: Prisma.ChatRunWhereUniqueInput
2045
+ take?: number
2046
+ skip?: number
2047
+ distinct?: Prisma.ChatRunScalarFieldEnum | Prisma.ChatRunScalarFieldEnum[]
2048
+ }
2049
+
2050
+ /**
2051
+ * ChatThread.interrupts
2052
+ */
2053
+ export type ChatThread$interruptsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
2054
+ /**
2055
+ * Select specific fields to fetch from the ChatInterrupt
2056
+ */
2057
+ select?: Prisma.ChatInterruptSelect<ExtArgs> | null
2058
+ /**
2059
+ * Omit specific fields from the ChatInterrupt
2060
+ */
2061
+ omit?: Prisma.ChatInterruptOmit<ExtArgs> | null
2062
+ /**
2063
+ * Choose, which related nodes to fetch as well
2064
+ */
2065
+ include?: Prisma.ChatInterruptInclude<ExtArgs> | null
2066
+ where?: Prisma.ChatInterruptWhereInput
2067
+ orderBy?: Prisma.ChatInterruptOrderByWithRelationInput | Prisma.ChatInterruptOrderByWithRelationInput[]
2068
+ cursor?: Prisma.ChatInterruptWhereUniqueInput
2069
+ take?: number
2070
+ skip?: number
2071
+ distinct?: Prisma.ChatInterruptScalarFieldEnum | Prisma.ChatInterruptScalarFieldEnum[]
2072
+ }
2073
+
2074
+ /**
2075
+ * ChatThread.generations
2076
+ */
2077
+ export type ChatThread$generationsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
2078
+ /**
2079
+ * Select specific fields to fetch from the GenerationRun
2080
+ */
2081
+ select?: Prisma.GenerationRunSelect<ExtArgs> | null
2082
+ /**
2083
+ * Omit specific fields from the GenerationRun
2084
+ */
2085
+ omit?: Prisma.GenerationRunOmit<ExtArgs> | null
2086
+ /**
2087
+ * Choose, which related nodes to fetch as well
2088
+ */
2089
+ include?: Prisma.GenerationRunInclude<ExtArgs> | null
2090
+ where?: Prisma.GenerationRunWhereInput
2091
+ orderBy?: Prisma.GenerationRunOrderByWithRelationInput | Prisma.GenerationRunOrderByWithRelationInput[]
2092
+ cursor?: Prisma.GenerationRunWhereUniqueInput
2093
+ take?: number
2094
+ skip?: number
2095
+ distinct?: Prisma.GenerationRunScalarFieldEnum | Prisma.GenerationRunScalarFieldEnum[]
2096
+ }
2097
+
2098
+ /**
2099
+ * ChatThread.agent
2100
+ */
2101
+ export type ChatThread$agentArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
2102
+ /**
2103
+ * Select specific fields to fetch from the UserAgent
2104
+ */
2105
+ select?: Prisma.UserAgentSelect<ExtArgs> | null
2106
+ /**
2107
+ * Omit specific fields from the UserAgent
2108
+ */
2109
+ omit?: Prisma.UserAgentOmit<ExtArgs> | null
2110
+ /**
2111
+ * Choose, which related nodes to fetch as well
2112
+ */
2113
+ include?: Prisma.UserAgentInclude<ExtArgs> | null
2114
+ where?: Prisma.UserAgentWhereInput
2115
+ }
2116
+
2117
+ /**
2118
+ * ChatThread without action
2119
+ */
2120
+ export type ChatThreadDefaultArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
2121
+ /**
2122
+ * Select specific fields to fetch from the ChatThread
2123
+ */
2124
+ select?: Prisma.ChatThreadSelect<ExtArgs> | null
2125
+ /**
2126
+ * Omit specific fields from the ChatThread
2127
+ */
2128
+ omit?: Prisma.ChatThreadOmit<ExtArgs> | null
2129
+ /**
2130
+ * Choose, which related nodes to fetch as well
2131
+ */
2132
+ include?: Prisma.ChatThreadInclude<ExtArgs> | null
2133
+ }