@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,1668 @@
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 `KnowledgeBase` 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 KnowledgeBase
17
+ *
18
+ */
19
+ export type KnowledgeBaseModel = runtime.Types.Result.DefaultSelection<Prisma.$KnowledgeBasePayload>
20
+
21
+ export type AggregateKnowledgeBase = {
22
+ _count: KnowledgeBaseCountAggregateOutputType | null
23
+ _min: KnowledgeBaseMinAggregateOutputType | null
24
+ _max: KnowledgeBaseMaxAggregateOutputType | null
25
+ }
26
+
27
+ export type KnowledgeBaseMinAggregateOutputType = {
28
+ id: string | null
29
+ name: string | null
30
+ description: string | null
31
+ icon: string | null
32
+ visibility: string | null
33
+ userId: string | null
34
+ isDeleted: boolean | null
35
+ createdAt: Date | null
36
+ updatedAt: Date | null
37
+ }
38
+
39
+ export type KnowledgeBaseMaxAggregateOutputType = {
40
+ id: string | null
41
+ name: string | null
42
+ description: string | null
43
+ icon: string | null
44
+ visibility: string | null
45
+ userId: string | null
46
+ isDeleted: boolean | null
47
+ createdAt: Date | null
48
+ updatedAt: Date | null
49
+ }
50
+
51
+ export type KnowledgeBaseCountAggregateOutputType = {
52
+ id: number
53
+ name: number
54
+ description: number
55
+ icon: number
56
+ tags: number
57
+ visibility: number
58
+ userId: number
59
+ isDeleted: number
60
+ createdAt: number
61
+ updatedAt: number
62
+ _all: number
63
+ }
64
+
65
+
66
+ export type KnowledgeBaseMinAggregateInputType = {
67
+ id?: true
68
+ name?: true
69
+ description?: true
70
+ icon?: true
71
+ visibility?: true
72
+ userId?: true
73
+ isDeleted?: true
74
+ createdAt?: true
75
+ updatedAt?: true
76
+ }
77
+
78
+ export type KnowledgeBaseMaxAggregateInputType = {
79
+ id?: true
80
+ name?: true
81
+ description?: true
82
+ icon?: true
83
+ visibility?: true
84
+ userId?: true
85
+ isDeleted?: true
86
+ createdAt?: true
87
+ updatedAt?: true
88
+ }
89
+
90
+ export type KnowledgeBaseCountAggregateInputType = {
91
+ id?: true
92
+ name?: true
93
+ description?: true
94
+ icon?: true
95
+ tags?: true
96
+ visibility?: true
97
+ userId?: true
98
+ isDeleted?: true
99
+ createdAt?: true
100
+ updatedAt?: true
101
+ _all?: true
102
+ }
103
+
104
+ export type KnowledgeBaseAggregateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
105
+ /**
106
+ * Filter which KnowledgeBase to aggregate.
107
+ */
108
+ where?: Prisma.KnowledgeBaseWhereInput
109
+ /**
110
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
111
+ *
112
+ * Determine the order of KnowledgeBases to fetch.
113
+ */
114
+ orderBy?: Prisma.KnowledgeBaseOrderByWithRelationInput | Prisma.KnowledgeBaseOrderByWithRelationInput[]
115
+ /**
116
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
117
+ *
118
+ * Sets the start position
119
+ */
120
+ cursor?: Prisma.KnowledgeBaseWhereUniqueInput
121
+ /**
122
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
123
+ *
124
+ * Take `±n` KnowledgeBases from the position of the cursor.
125
+ */
126
+ take?: number
127
+ /**
128
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
129
+ *
130
+ * Skip the first `n` KnowledgeBases.
131
+ */
132
+ skip?: number
133
+ /**
134
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
135
+ *
136
+ * Count returned KnowledgeBases
137
+ **/
138
+ _count?: true | KnowledgeBaseCountAggregateInputType
139
+ /**
140
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
141
+ *
142
+ * Select which fields to find the minimum value
143
+ **/
144
+ _min?: KnowledgeBaseMinAggregateInputType
145
+ /**
146
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/aggregations Aggregation Docs}
147
+ *
148
+ * Select which fields to find the maximum value
149
+ **/
150
+ _max?: KnowledgeBaseMaxAggregateInputType
151
+ }
152
+
153
+ export type GetKnowledgeBaseAggregateType<T extends KnowledgeBaseAggregateArgs> = {
154
+ [P in keyof T & keyof AggregateKnowledgeBase]: P extends '_count' | 'count'
155
+ ? T[P] extends true
156
+ ? number
157
+ : Prisma.GetScalarType<T[P], AggregateKnowledgeBase[P]>
158
+ : Prisma.GetScalarType<T[P], AggregateKnowledgeBase[P]>
159
+ }
160
+
161
+
162
+
163
+
164
+ export type KnowledgeBaseGroupByArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
165
+ where?: Prisma.KnowledgeBaseWhereInput
166
+ orderBy?: Prisma.KnowledgeBaseOrderByWithAggregationInput | Prisma.KnowledgeBaseOrderByWithAggregationInput[]
167
+ by: Prisma.KnowledgeBaseScalarFieldEnum[] | Prisma.KnowledgeBaseScalarFieldEnum
168
+ having?: Prisma.KnowledgeBaseScalarWhereWithAggregatesInput
169
+ take?: number
170
+ skip?: number
171
+ _count?: KnowledgeBaseCountAggregateInputType | true
172
+ _min?: KnowledgeBaseMinAggregateInputType
173
+ _max?: KnowledgeBaseMaxAggregateInputType
174
+ }
175
+
176
+ export type KnowledgeBaseGroupByOutputType = {
177
+ id: string
178
+ name: string
179
+ description: string | null
180
+ icon: string
181
+ tags: runtime.JsonValue
182
+ visibility: string
183
+ userId: string
184
+ isDeleted: boolean
185
+ createdAt: Date
186
+ updatedAt: Date
187
+ _count: KnowledgeBaseCountAggregateOutputType | null
188
+ _min: KnowledgeBaseMinAggregateOutputType | null
189
+ _max: KnowledgeBaseMaxAggregateOutputType | null
190
+ }
191
+
192
+ export type GetKnowledgeBaseGroupByPayload<T extends KnowledgeBaseGroupByArgs> = Prisma.PrismaPromise<
193
+ Array<
194
+ Prisma.PickEnumerable<KnowledgeBaseGroupByOutputType, T['by']> &
195
+ {
196
+ [P in ((keyof T) & (keyof KnowledgeBaseGroupByOutputType))]: P extends '_count'
197
+ ? T[P] extends boolean
198
+ ? number
199
+ : Prisma.GetScalarType<T[P], KnowledgeBaseGroupByOutputType[P]>
200
+ : Prisma.GetScalarType<T[P], KnowledgeBaseGroupByOutputType[P]>
201
+ }
202
+ >
203
+ >
204
+
205
+
206
+
207
+ export type KnowledgeBaseWhereInput = {
208
+ AND?: Prisma.KnowledgeBaseWhereInput | Prisma.KnowledgeBaseWhereInput[]
209
+ OR?: Prisma.KnowledgeBaseWhereInput[]
210
+ NOT?: Prisma.KnowledgeBaseWhereInput | Prisma.KnowledgeBaseWhereInput[]
211
+ id?: Prisma.StringFilter<"KnowledgeBase"> | string
212
+ name?: Prisma.StringFilter<"KnowledgeBase"> | string
213
+ description?: Prisma.StringNullableFilter<"KnowledgeBase"> | string | null
214
+ icon?: Prisma.StringFilter<"KnowledgeBase"> | string
215
+ tags?: Prisma.JsonFilter<"KnowledgeBase">
216
+ visibility?: Prisma.StringFilter<"KnowledgeBase"> | string
217
+ userId?: Prisma.StringFilter<"KnowledgeBase"> | string
218
+ isDeleted?: Prisma.BoolFilter<"KnowledgeBase"> | boolean
219
+ createdAt?: Prisma.DateTimeFilter<"KnowledgeBase"> | Date | string
220
+ updatedAt?: Prisma.DateTimeFilter<"KnowledgeBase"> | Date | string
221
+ user?: Prisma.XOR<Prisma.UserScalarRelationFilter, Prisma.UserWhereInput>
222
+ documents?: Prisma.KnowledgeDocumentListRelationFilter
223
+ }
224
+
225
+ export type KnowledgeBaseOrderByWithRelationInput = {
226
+ id?: Prisma.SortOrder
227
+ name?: Prisma.SortOrder
228
+ description?: Prisma.SortOrderInput | Prisma.SortOrder
229
+ icon?: Prisma.SortOrder
230
+ tags?: Prisma.SortOrder
231
+ visibility?: Prisma.SortOrder
232
+ userId?: Prisma.SortOrder
233
+ isDeleted?: Prisma.SortOrder
234
+ createdAt?: Prisma.SortOrder
235
+ updatedAt?: Prisma.SortOrder
236
+ user?: Prisma.UserOrderByWithRelationInput
237
+ documents?: Prisma.KnowledgeDocumentOrderByRelationAggregateInput
238
+ }
239
+
240
+ export type KnowledgeBaseWhereUniqueInput = Prisma.AtLeast<{
241
+ id?: string
242
+ AND?: Prisma.KnowledgeBaseWhereInput | Prisma.KnowledgeBaseWhereInput[]
243
+ OR?: Prisma.KnowledgeBaseWhereInput[]
244
+ NOT?: Prisma.KnowledgeBaseWhereInput | Prisma.KnowledgeBaseWhereInput[]
245
+ name?: Prisma.StringFilter<"KnowledgeBase"> | string
246
+ description?: Prisma.StringNullableFilter<"KnowledgeBase"> | string | null
247
+ icon?: Prisma.StringFilter<"KnowledgeBase"> | string
248
+ tags?: Prisma.JsonFilter<"KnowledgeBase">
249
+ visibility?: Prisma.StringFilter<"KnowledgeBase"> | string
250
+ userId?: Prisma.StringFilter<"KnowledgeBase"> | string
251
+ isDeleted?: Prisma.BoolFilter<"KnowledgeBase"> | boolean
252
+ createdAt?: Prisma.DateTimeFilter<"KnowledgeBase"> | Date | string
253
+ updatedAt?: Prisma.DateTimeFilter<"KnowledgeBase"> | Date | string
254
+ user?: Prisma.XOR<Prisma.UserScalarRelationFilter, Prisma.UserWhereInput>
255
+ documents?: Prisma.KnowledgeDocumentListRelationFilter
256
+ }, "id">
257
+
258
+ export type KnowledgeBaseOrderByWithAggregationInput = {
259
+ id?: Prisma.SortOrder
260
+ name?: Prisma.SortOrder
261
+ description?: Prisma.SortOrderInput | Prisma.SortOrder
262
+ icon?: Prisma.SortOrder
263
+ tags?: Prisma.SortOrder
264
+ visibility?: Prisma.SortOrder
265
+ userId?: Prisma.SortOrder
266
+ isDeleted?: Prisma.SortOrder
267
+ createdAt?: Prisma.SortOrder
268
+ updatedAt?: Prisma.SortOrder
269
+ _count?: Prisma.KnowledgeBaseCountOrderByAggregateInput
270
+ _max?: Prisma.KnowledgeBaseMaxOrderByAggregateInput
271
+ _min?: Prisma.KnowledgeBaseMinOrderByAggregateInput
272
+ }
273
+
274
+ export type KnowledgeBaseScalarWhereWithAggregatesInput = {
275
+ AND?: Prisma.KnowledgeBaseScalarWhereWithAggregatesInput | Prisma.KnowledgeBaseScalarWhereWithAggregatesInput[]
276
+ OR?: Prisma.KnowledgeBaseScalarWhereWithAggregatesInput[]
277
+ NOT?: Prisma.KnowledgeBaseScalarWhereWithAggregatesInput | Prisma.KnowledgeBaseScalarWhereWithAggregatesInput[]
278
+ id?: Prisma.StringWithAggregatesFilter<"KnowledgeBase"> | string
279
+ name?: Prisma.StringWithAggregatesFilter<"KnowledgeBase"> | string
280
+ description?: Prisma.StringNullableWithAggregatesFilter<"KnowledgeBase"> | string | null
281
+ icon?: Prisma.StringWithAggregatesFilter<"KnowledgeBase"> | string
282
+ tags?: Prisma.JsonWithAggregatesFilter<"KnowledgeBase">
283
+ visibility?: Prisma.StringWithAggregatesFilter<"KnowledgeBase"> | string
284
+ userId?: Prisma.StringWithAggregatesFilter<"KnowledgeBase"> | string
285
+ isDeleted?: Prisma.BoolWithAggregatesFilter<"KnowledgeBase"> | boolean
286
+ createdAt?: Prisma.DateTimeWithAggregatesFilter<"KnowledgeBase"> | Date | string
287
+ updatedAt?: Prisma.DateTimeWithAggregatesFilter<"KnowledgeBase"> | Date | string
288
+ }
289
+
290
+ export type KnowledgeBaseCreateInput = {
291
+ id?: string
292
+ name: string
293
+ description?: string | null
294
+ icon?: string
295
+ tags?: Prisma.JsonNullValueInput | runtime.InputJsonValue
296
+ visibility?: string
297
+ isDeleted?: boolean
298
+ createdAt?: Date | string
299
+ updatedAt?: Date | string
300
+ user: Prisma.UserCreateNestedOneWithoutKnowledgeBasesInput
301
+ documents?: Prisma.KnowledgeDocumentCreateNestedManyWithoutKbInput
302
+ }
303
+
304
+ export type KnowledgeBaseUncheckedCreateInput = {
305
+ id?: string
306
+ name: string
307
+ description?: string | null
308
+ icon?: string
309
+ tags?: Prisma.JsonNullValueInput | runtime.InputJsonValue
310
+ visibility?: string
311
+ userId: string
312
+ isDeleted?: boolean
313
+ createdAt?: Date | string
314
+ updatedAt?: Date | string
315
+ documents?: Prisma.KnowledgeDocumentUncheckedCreateNestedManyWithoutKbInput
316
+ }
317
+
318
+ export type KnowledgeBaseUpdateInput = {
319
+ id?: Prisma.StringFieldUpdateOperationsInput | string
320
+ name?: Prisma.StringFieldUpdateOperationsInput | string
321
+ description?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
322
+ icon?: Prisma.StringFieldUpdateOperationsInput | string
323
+ tags?: Prisma.JsonNullValueInput | runtime.InputJsonValue
324
+ visibility?: Prisma.StringFieldUpdateOperationsInput | string
325
+ isDeleted?: Prisma.BoolFieldUpdateOperationsInput | boolean
326
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
327
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
328
+ user?: Prisma.UserUpdateOneRequiredWithoutKnowledgeBasesNestedInput
329
+ documents?: Prisma.KnowledgeDocumentUpdateManyWithoutKbNestedInput
330
+ }
331
+
332
+ export type KnowledgeBaseUncheckedUpdateInput = {
333
+ id?: Prisma.StringFieldUpdateOperationsInput | string
334
+ name?: Prisma.StringFieldUpdateOperationsInput | string
335
+ description?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
336
+ icon?: Prisma.StringFieldUpdateOperationsInput | string
337
+ tags?: Prisma.JsonNullValueInput | runtime.InputJsonValue
338
+ visibility?: Prisma.StringFieldUpdateOperationsInput | string
339
+ userId?: Prisma.StringFieldUpdateOperationsInput | string
340
+ isDeleted?: Prisma.BoolFieldUpdateOperationsInput | boolean
341
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
342
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
343
+ documents?: Prisma.KnowledgeDocumentUncheckedUpdateManyWithoutKbNestedInput
344
+ }
345
+
346
+ export type KnowledgeBaseCreateManyInput = {
347
+ id?: string
348
+ name: string
349
+ description?: string | null
350
+ icon?: string
351
+ tags?: Prisma.JsonNullValueInput | runtime.InputJsonValue
352
+ visibility?: string
353
+ userId: string
354
+ isDeleted?: boolean
355
+ createdAt?: Date | string
356
+ updatedAt?: Date | string
357
+ }
358
+
359
+ export type KnowledgeBaseUpdateManyMutationInput = {
360
+ id?: Prisma.StringFieldUpdateOperationsInput | string
361
+ name?: Prisma.StringFieldUpdateOperationsInput | string
362
+ description?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
363
+ icon?: Prisma.StringFieldUpdateOperationsInput | string
364
+ tags?: Prisma.JsonNullValueInput | runtime.InputJsonValue
365
+ visibility?: Prisma.StringFieldUpdateOperationsInput | string
366
+ isDeleted?: Prisma.BoolFieldUpdateOperationsInput | boolean
367
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
368
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
369
+ }
370
+
371
+ export type KnowledgeBaseUncheckedUpdateManyInput = {
372
+ id?: Prisma.StringFieldUpdateOperationsInput | string
373
+ name?: Prisma.StringFieldUpdateOperationsInput | string
374
+ description?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
375
+ icon?: Prisma.StringFieldUpdateOperationsInput | string
376
+ tags?: Prisma.JsonNullValueInput | runtime.InputJsonValue
377
+ visibility?: Prisma.StringFieldUpdateOperationsInput | string
378
+ userId?: Prisma.StringFieldUpdateOperationsInput | string
379
+ isDeleted?: Prisma.BoolFieldUpdateOperationsInput | boolean
380
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
381
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
382
+ }
383
+
384
+ export type KnowledgeBaseListRelationFilter = {
385
+ every?: Prisma.KnowledgeBaseWhereInput
386
+ some?: Prisma.KnowledgeBaseWhereInput
387
+ none?: Prisma.KnowledgeBaseWhereInput
388
+ }
389
+
390
+ export type KnowledgeBaseOrderByRelationAggregateInput = {
391
+ _count?: Prisma.SortOrder
392
+ }
393
+
394
+ export type KnowledgeBaseCountOrderByAggregateInput = {
395
+ id?: Prisma.SortOrder
396
+ name?: Prisma.SortOrder
397
+ description?: Prisma.SortOrder
398
+ icon?: Prisma.SortOrder
399
+ tags?: Prisma.SortOrder
400
+ visibility?: Prisma.SortOrder
401
+ userId?: Prisma.SortOrder
402
+ isDeleted?: Prisma.SortOrder
403
+ createdAt?: Prisma.SortOrder
404
+ updatedAt?: Prisma.SortOrder
405
+ }
406
+
407
+ export type KnowledgeBaseMaxOrderByAggregateInput = {
408
+ id?: Prisma.SortOrder
409
+ name?: Prisma.SortOrder
410
+ description?: Prisma.SortOrder
411
+ icon?: Prisma.SortOrder
412
+ visibility?: Prisma.SortOrder
413
+ userId?: Prisma.SortOrder
414
+ isDeleted?: Prisma.SortOrder
415
+ createdAt?: Prisma.SortOrder
416
+ updatedAt?: Prisma.SortOrder
417
+ }
418
+
419
+ export type KnowledgeBaseMinOrderByAggregateInput = {
420
+ id?: Prisma.SortOrder
421
+ name?: Prisma.SortOrder
422
+ description?: Prisma.SortOrder
423
+ icon?: Prisma.SortOrder
424
+ visibility?: Prisma.SortOrder
425
+ userId?: Prisma.SortOrder
426
+ isDeleted?: Prisma.SortOrder
427
+ createdAt?: Prisma.SortOrder
428
+ updatedAt?: Prisma.SortOrder
429
+ }
430
+
431
+ export type KnowledgeBaseScalarRelationFilter = {
432
+ is?: Prisma.KnowledgeBaseWhereInput
433
+ isNot?: Prisma.KnowledgeBaseWhereInput
434
+ }
435
+
436
+ export type KnowledgeBaseCreateNestedManyWithoutUserInput = {
437
+ create?: Prisma.XOR<Prisma.KnowledgeBaseCreateWithoutUserInput, Prisma.KnowledgeBaseUncheckedCreateWithoutUserInput> | Prisma.KnowledgeBaseCreateWithoutUserInput[] | Prisma.KnowledgeBaseUncheckedCreateWithoutUserInput[]
438
+ connectOrCreate?: Prisma.KnowledgeBaseCreateOrConnectWithoutUserInput | Prisma.KnowledgeBaseCreateOrConnectWithoutUserInput[]
439
+ createMany?: Prisma.KnowledgeBaseCreateManyUserInputEnvelope
440
+ connect?: Prisma.KnowledgeBaseWhereUniqueInput | Prisma.KnowledgeBaseWhereUniqueInput[]
441
+ }
442
+
443
+ export type KnowledgeBaseUncheckedCreateNestedManyWithoutUserInput = {
444
+ create?: Prisma.XOR<Prisma.KnowledgeBaseCreateWithoutUserInput, Prisma.KnowledgeBaseUncheckedCreateWithoutUserInput> | Prisma.KnowledgeBaseCreateWithoutUserInput[] | Prisma.KnowledgeBaseUncheckedCreateWithoutUserInput[]
445
+ connectOrCreate?: Prisma.KnowledgeBaseCreateOrConnectWithoutUserInput | Prisma.KnowledgeBaseCreateOrConnectWithoutUserInput[]
446
+ createMany?: Prisma.KnowledgeBaseCreateManyUserInputEnvelope
447
+ connect?: Prisma.KnowledgeBaseWhereUniqueInput | Prisma.KnowledgeBaseWhereUniqueInput[]
448
+ }
449
+
450
+ export type KnowledgeBaseUpdateManyWithoutUserNestedInput = {
451
+ create?: Prisma.XOR<Prisma.KnowledgeBaseCreateWithoutUserInput, Prisma.KnowledgeBaseUncheckedCreateWithoutUserInput> | Prisma.KnowledgeBaseCreateWithoutUserInput[] | Prisma.KnowledgeBaseUncheckedCreateWithoutUserInput[]
452
+ connectOrCreate?: Prisma.KnowledgeBaseCreateOrConnectWithoutUserInput | Prisma.KnowledgeBaseCreateOrConnectWithoutUserInput[]
453
+ upsert?: Prisma.KnowledgeBaseUpsertWithWhereUniqueWithoutUserInput | Prisma.KnowledgeBaseUpsertWithWhereUniqueWithoutUserInput[]
454
+ createMany?: Prisma.KnowledgeBaseCreateManyUserInputEnvelope
455
+ set?: Prisma.KnowledgeBaseWhereUniqueInput | Prisma.KnowledgeBaseWhereUniqueInput[]
456
+ disconnect?: Prisma.KnowledgeBaseWhereUniqueInput | Prisma.KnowledgeBaseWhereUniqueInput[]
457
+ delete?: Prisma.KnowledgeBaseWhereUniqueInput | Prisma.KnowledgeBaseWhereUniqueInput[]
458
+ connect?: Prisma.KnowledgeBaseWhereUniqueInput | Prisma.KnowledgeBaseWhereUniqueInput[]
459
+ update?: Prisma.KnowledgeBaseUpdateWithWhereUniqueWithoutUserInput | Prisma.KnowledgeBaseUpdateWithWhereUniqueWithoutUserInput[]
460
+ updateMany?: Prisma.KnowledgeBaseUpdateManyWithWhereWithoutUserInput | Prisma.KnowledgeBaseUpdateManyWithWhereWithoutUserInput[]
461
+ deleteMany?: Prisma.KnowledgeBaseScalarWhereInput | Prisma.KnowledgeBaseScalarWhereInput[]
462
+ }
463
+
464
+ export type KnowledgeBaseUncheckedUpdateManyWithoutUserNestedInput = {
465
+ create?: Prisma.XOR<Prisma.KnowledgeBaseCreateWithoutUserInput, Prisma.KnowledgeBaseUncheckedCreateWithoutUserInput> | Prisma.KnowledgeBaseCreateWithoutUserInput[] | Prisma.KnowledgeBaseUncheckedCreateWithoutUserInput[]
466
+ connectOrCreate?: Prisma.KnowledgeBaseCreateOrConnectWithoutUserInput | Prisma.KnowledgeBaseCreateOrConnectWithoutUserInput[]
467
+ upsert?: Prisma.KnowledgeBaseUpsertWithWhereUniqueWithoutUserInput | Prisma.KnowledgeBaseUpsertWithWhereUniqueWithoutUserInput[]
468
+ createMany?: Prisma.KnowledgeBaseCreateManyUserInputEnvelope
469
+ set?: Prisma.KnowledgeBaseWhereUniqueInput | Prisma.KnowledgeBaseWhereUniqueInput[]
470
+ disconnect?: Prisma.KnowledgeBaseWhereUniqueInput | Prisma.KnowledgeBaseWhereUniqueInput[]
471
+ delete?: Prisma.KnowledgeBaseWhereUniqueInput | Prisma.KnowledgeBaseWhereUniqueInput[]
472
+ connect?: Prisma.KnowledgeBaseWhereUniqueInput | Prisma.KnowledgeBaseWhereUniqueInput[]
473
+ update?: Prisma.KnowledgeBaseUpdateWithWhereUniqueWithoutUserInput | Prisma.KnowledgeBaseUpdateWithWhereUniqueWithoutUserInput[]
474
+ updateMany?: Prisma.KnowledgeBaseUpdateManyWithWhereWithoutUserInput | Prisma.KnowledgeBaseUpdateManyWithWhereWithoutUserInput[]
475
+ deleteMany?: Prisma.KnowledgeBaseScalarWhereInput | Prisma.KnowledgeBaseScalarWhereInput[]
476
+ }
477
+
478
+ export type KnowledgeBaseCreateNestedOneWithoutDocumentsInput = {
479
+ create?: Prisma.XOR<Prisma.KnowledgeBaseCreateWithoutDocumentsInput, Prisma.KnowledgeBaseUncheckedCreateWithoutDocumentsInput>
480
+ connectOrCreate?: Prisma.KnowledgeBaseCreateOrConnectWithoutDocumentsInput
481
+ connect?: Prisma.KnowledgeBaseWhereUniqueInput
482
+ }
483
+
484
+ export type KnowledgeBaseUpdateOneRequiredWithoutDocumentsNestedInput = {
485
+ create?: Prisma.XOR<Prisma.KnowledgeBaseCreateWithoutDocumentsInput, Prisma.KnowledgeBaseUncheckedCreateWithoutDocumentsInput>
486
+ connectOrCreate?: Prisma.KnowledgeBaseCreateOrConnectWithoutDocumentsInput
487
+ upsert?: Prisma.KnowledgeBaseUpsertWithoutDocumentsInput
488
+ connect?: Prisma.KnowledgeBaseWhereUniqueInput
489
+ update?: Prisma.XOR<Prisma.XOR<Prisma.KnowledgeBaseUpdateToOneWithWhereWithoutDocumentsInput, Prisma.KnowledgeBaseUpdateWithoutDocumentsInput>, Prisma.KnowledgeBaseUncheckedUpdateWithoutDocumentsInput>
490
+ }
491
+
492
+ export type KnowledgeBaseCreateWithoutUserInput = {
493
+ id?: string
494
+ name: string
495
+ description?: string | null
496
+ icon?: string
497
+ tags?: Prisma.JsonNullValueInput | runtime.InputJsonValue
498
+ visibility?: string
499
+ isDeleted?: boolean
500
+ createdAt?: Date | string
501
+ updatedAt?: Date | string
502
+ documents?: Prisma.KnowledgeDocumentCreateNestedManyWithoutKbInput
503
+ }
504
+
505
+ export type KnowledgeBaseUncheckedCreateWithoutUserInput = {
506
+ id?: string
507
+ name: string
508
+ description?: string | null
509
+ icon?: string
510
+ tags?: Prisma.JsonNullValueInput | runtime.InputJsonValue
511
+ visibility?: string
512
+ isDeleted?: boolean
513
+ createdAt?: Date | string
514
+ updatedAt?: Date | string
515
+ documents?: Prisma.KnowledgeDocumentUncheckedCreateNestedManyWithoutKbInput
516
+ }
517
+
518
+ export type KnowledgeBaseCreateOrConnectWithoutUserInput = {
519
+ where: Prisma.KnowledgeBaseWhereUniqueInput
520
+ create: Prisma.XOR<Prisma.KnowledgeBaseCreateWithoutUserInput, Prisma.KnowledgeBaseUncheckedCreateWithoutUserInput>
521
+ }
522
+
523
+ export type KnowledgeBaseCreateManyUserInputEnvelope = {
524
+ data: Prisma.KnowledgeBaseCreateManyUserInput | Prisma.KnowledgeBaseCreateManyUserInput[]
525
+ }
526
+
527
+ export type KnowledgeBaseUpsertWithWhereUniqueWithoutUserInput = {
528
+ where: Prisma.KnowledgeBaseWhereUniqueInput
529
+ update: Prisma.XOR<Prisma.KnowledgeBaseUpdateWithoutUserInput, Prisma.KnowledgeBaseUncheckedUpdateWithoutUserInput>
530
+ create: Prisma.XOR<Prisma.KnowledgeBaseCreateWithoutUserInput, Prisma.KnowledgeBaseUncheckedCreateWithoutUserInput>
531
+ }
532
+
533
+ export type KnowledgeBaseUpdateWithWhereUniqueWithoutUserInput = {
534
+ where: Prisma.KnowledgeBaseWhereUniqueInput
535
+ data: Prisma.XOR<Prisma.KnowledgeBaseUpdateWithoutUserInput, Prisma.KnowledgeBaseUncheckedUpdateWithoutUserInput>
536
+ }
537
+
538
+ export type KnowledgeBaseUpdateManyWithWhereWithoutUserInput = {
539
+ where: Prisma.KnowledgeBaseScalarWhereInput
540
+ data: Prisma.XOR<Prisma.KnowledgeBaseUpdateManyMutationInput, Prisma.KnowledgeBaseUncheckedUpdateManyWithoutUserInput>
541
+ }
542
+
543
+ export type KnowledgeBaseScalarWhereInput = {
544
+ AND?: Prisma.KnowledgeBaseScalarWhereInput | Prisma.KnowledgeBaseScalarWhereInput[]
545
+ OR?: Prisma.KnowledgeBaseScalarWhereInput[]
546
+ NOT?: Prisma.KnowledgeBaseScalarWhereInput | Prisma.KnowledgeBaseScalarWhereInput[]
547
+ id?: Prisma.StringFilter<"KnowledgeBase"> | string
548
+ name?: Prisma.StringFilter<"KnowledgeBase"> | string
549
+ description?: Prisma.StringNullableFilter<"KnowledgeBase"> | string | null
550
+ icon?: Prisma.StringFilter<"KnowledgeBase"> | string
551
+ tags?: Prisma.JsonFilter<"KnowledgeBase">
552
+ visibility?: Prisma.StringFilter<"KnowledgeBase"> | string
553
+ userId?: Prisma.StringFilter<"KnowledgeBase"> | string
554
+ isDeleted?: Prisma.BoolFilter<"KnowledgeBase"> | boolean
555
+ createdAt?: Prisma.DateTimeFilter<"KnowledgeBase"> | Date | string
556
+ updatedAt?: Prisma.DateTimeFilter<"KnowledgeBase"> | Date | string
557
+ }
558
+
559
+ export type KnowledgeBaseCreateWithoutDocumentsInput = {
560
+ id?: string
561
+ name: string
562
+ description?: string | null
563
+ icon?: string
564
+ tags?: Prisma.JsonNullValueInput | runtime.InputJsonValue
565
+ visibility?: string
566
+ isDeleted?: boolean
567
+ createdAt?: Date | string
568
+ updatedAt?: Date | string
569
+ user: Prisma.UserCreateNestedOneWithoutKnowledgeBasesInput
570
+ }
571
+
572
+ export type KnowledgeBaseUncheckedCreateWithoutDocumentsInput = {
573
+ id?: string
574
+ name: string
575
+ description?: string | null
576
+ icon?: string
577
+ tags?: Prisma.JsonNullValueInput | runtime.InputJsonValue
578
+ visibility?: string
579
+ userId: string
580
+ isDeleted?: boolean
581
+ createdAt?: Date | string
582
+ updatedAt?: Date | string
583
+ }
584
+
585
+ export type KnowledgeBaseCreateOrConnectWithoutDocumentsInput = {
586
+ where: Prisma.KnowledgeBaseWhereUniqueInput
587
+ create: Prisma.XOR<Prisma.KnowledgeBaseCreateWithoutDocumentsInput, Prisma.KnowledgeBaseUncheckedCreateWithoutDocumentsInput>
588
+ }
589
+
590
+ export type KnowledgeBaseUpsertWithoutDocumentsInput = {
591
+ update: Prisma.XOR<Prisma.KnowledgeBaseUpdateWithoutDocumentsInput, Prisma.KnowledgeBaseUncheckedUpdateWithoutDocumentsInput>
592
+ create: Prisma.XOR<Prisma.KnowledgeBaseCreateWithoutDocumentsInput, Prisma.KnowledgeBaseUncheckedCreateWithoutDocumentsInput>
593
+ where?: Prisma.KnowledgeBaseWhereInput
594
+ }
595
+
596
+ export type KnowledgeBaseUpdateToOneWithWhereWithoutDocumentsInput = {
597
+ where?: Prisma.KnowledgeBaseWhereInput
598
+ data: Prisma.XOR<Prisma.KnowledgeBaseUpdateWithoutDocumentsInput, Prisma.KnowledgeBaseUncheckedUpdateWithoutDocumentsInput>
599
+ }
600
+
601
+ export type KnowledgeBaseUpdateWithoutDocumentsInput = {
602
+ id?: Prisma.StringFieldUpdateOperationsInput | string
603
+ name?: Prisma.StringFieldUpdateOperationsInput | string
604
+ description?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
605
+ icon?: Prisma.StringFieldUpdateOperationsInput | string
606
+ tags?: Prisma.JsonNullValueInput | runtime.InputJsonValue
607
+ visibility?: Prisma.StringFieldUpdateOperationsInput | string
608
+ isDeleted?: Prisma.BoolFieldUpdateOperationsInput | boolean
609
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
610
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
611
+ user?: Prisma.UserUpdateOneRequiredWithoutKnowledgeBasesNestedInput
612
+ }
613
+
614
+ export type KnowledgeBaseUncheckedUpdateWithoutDocumentsInput = {
615
+ id?: Prisma.StringFieldUpdateOperationsInput | string
616
+ name?: Prisma.StringFieldUpdateOperationsInput | string
617
+ description?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
618
+ icon?: Prisma.StringFieldUpdateOperationsInput | string
619
+ tags?: Prisma.JsonNullValueInput | runtime.InputJsonValue
620
+ visibility?: Prisma.StringFieldUpdateOperationsInput | string
621
+ userId?: Prisma.StringFieldUpdateOperationsInput | string
622
+ isDeleted?: Prisma.BoolFieldUpdateOperationsInput | boolean
623
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
624
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
625
+ }
626
+
627
+ export type KnowledgeBaseCreateManyUserInput = {
628
+ id?: string
629
+ name: string
630
+ description?: string | null
631
+ icon?: string
632
+ tags?: Prisma.JsonNullValueInput | runtime.InputJsonValue
633
+ visibility?: string
634
+ isDeleted?: boolean
635
+ createdAt?: Date | string
636
+ updatedAt?: Date | string
637
+ }
638
+
639
+ export type KnowledgeBaseUpdateWithoutUserInput = {
640
+ id?: Prisma.StringFieldUpdateOperationsInput | string
641
+ name?: Prisma.StringFieldUpdateOperationsInput | string
642
+ description?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
643
+ icon?: Prisma.StringFieldUpdateOperationsInput | string
644
+ tags?: Prisma.JsonNullValueInput | runtime.InputJsonValue
645
+ visibility?: Prisma.StringFieldUpdateOperationsInput | string
646
+ isDeleted?: Prisma.BoolFieldUpdateOperationsInput | boolean
647
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
648
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
649
+ documents?: Prisma.KnowledgeDocumentUpdateManyWithoutKbNestedInput
650
+ }
651
+
652
+ export type KnowledgeBaseUncheckedUpdateWithoutUserInput = {
653
+ id?: Prisma.StringFieldUpdateOperationsInput | string
654
+ name?: Prisma.StringFieldUpdateOperationsInput | string
655
+ description?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
656
+ icon?: Prisma.StringFieldUpdateOperationsInput | string
657
+ tags?: Prisma.JsonNullValueInput | runtime.InputJsonValue
658
+ visibility?: Prisma.StringFieldUpdateOperationsInput | string
659
+ isDeleted?: Prisma.BoolFieldUpdateOperationsInput | boolean
660
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
661
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
662
+ documents?: Prisma.KnowledgeDocumentUncheckedUpdateManyWithoutKbNestedInput
663
+ }
664
+
665
+ export type KnowledgeBaseUncheckedUpdateManyWithoutUserInput = {
666
+ id?: Prisma.StringFieldUpdateOperationsInput | string
667
+ name?: Prisma.StringFieldUpdateOperationsInput | string
668
+ description?: Prisma.NullableStringFieldUpdateOperationsInput | string | null
669
+ icon?: Prisma.StringFieldUpdateOperationsInput | string
670
+ tags?: Prisma.JsonNullValueInput | runtime.InputJsonValue
671
+ visibility?: Prisma.StringFieldUpdateOperationsInput | string
672
+ isDeleted?: Prisma.BoolFieldUpdateOperationsInput | boolean
673
+ createdAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
674
+ updatedAt?: Prisma.DateTimeFieldUpdateOperationsInput | Date | string
675
+ }
676
+
677
+
678
+ /**
679
+ * Count Type KnowledgeBaseCountOutputType
680
+ */
681
+
682
+ export type KnowledgeBaseCountOutputType = {
683
+ documents: number
684
+ }
685
+
686
+ export type KnowledgeBaseCountOutputTypeSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
687
+ documents?: boolean | KnowledgeBaseCountOutputTypeCountDocumentsArgs
688
+ }
689
+
690
+ /**
691
+ * KnowledgeBaseCountOutputType without action
692
+ */
693
+ export type KnowledgeBaseCountOutputTypeDefaultArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
694
+ /**
695
+ * Select specific fields to fetch from the KnowledgeBaseCountOutputType
696
+ */
697
+ select?: Prisma.KnowledgeBaseCountOutputTypeSelect<ExtArgs> | null
698
+ }
699
+
700
+ /**
701
+ * KnowledgeBaseCountOutputType without action
702
+ */
703
+ export type KnowledgeBaseCountOutputTypeCountDocumentsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
704
+ where?: Prisma.KnowledgeDocumentWhereInput
705
+ }
706
+
707
+
708
+ export type KnowledgeBaseSelect<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
709
+ id?: boolean
710
+ name?: boolean
711
+ description?: boolean
712
+ icon?: boolean
713
+ tags?: boolean
714
+ visibility?: boolean
715
+ userId?: boolean
716
+ isDeleted?: boolean
717
+ createdAt?: boolean
718
+ updatedAt?: boolean
719
+ user?: boolean | Prisma.UserDefaultArgs<ExtArgs>
720
+ documents?: boolean | Prisma.KnowledgeBase$documentsArgs<ExtArgs>
721
+ _count?: boolean | Prisma.KnowledgeBaseCountOutputTypeDefaultArgs<ExtArgs>
722
+ }, ExtArgs["result"]["knowledgeBase"]>
723
+
724
+ export type KnowledgeBaseSelectCreateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
725
+ id?: boolean
726
+ name?: boolean
727
+ description?: boolean
728
+ icon?: boolean
729
+ tags?: boolean
730
+ visibility?: boolean
731
+ userId?: boolean
732
+ isDeleted?: boolean
733
+ createdAt?: boolean
734
+ updatedAt?: boolean
735
+ user?: boolean | Prisma.UserDefaultArgs<ExtArgs>
736
+ }, ExtArgs["result"]["knowledgeBase"]>
737
+
738
+ export type KnowledgeBaseSelectUpdateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetSelect<{
739
+ id?: boolean
740
+ name?: boolean
741
+ description?: boolean
742
+ icon?: boolean
743
+ tags?: boolean
744
+ visibility?: boolean
745
+ userId?: boolean
746
+ isDeleted?: boolean
747
+ createdAt?: boolean
748
+ updatedAt?: boolean
749
+ user?: boolean | Prisma.UserDefaultArgs<ExtArgs>
750
+ }, ExtArgs["result"]["knowledgeBase"]>
751
+
752
+ export type KnowledgeBaseSelectScalar = {
753
+ id?: boolean
754
+ name?: boolean
755
+ description?: boolean
756
+ icon?: boolean
757
+ tags?: boolean
758
+ visibility?: boolean
759
+ userId?: boolean
760
+ isDeleted?: boolean
761
+ createdAt?: boolean
762
+ updatedAt?: boolean
763
+ }
764
+
765
+ export type KnowledgeBaseOmit<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = runtime.Types.Extensions.GetOmit<"id" | "name" | "description" | "icon" | "tags" | "visibility" | "userId" | "isDeleted" | "createdAt" | "updatedAt", ExtArgs["result"]["knowledgeBase"]>
766
+ export type KnowledgeBaseInclude<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
767
+ user?: boolean | Prisma.UserDefaultArgs<ExtArgs>
768
+ documents?: boolean | Prisma.KnowledgeBase$documentsArgs<ExtArgs>
769
+ _count?: boolean | Prisma.KnowledgeBaseCountOutputTypeDefaultArgs<ExtArgs>
770
+ }
771
+ export type KnowledgeBaseIncludeCreateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
772
+ user?: boolean | Prisma.UserDefaultArgs<ExtArgs>
773
+ }
774
+ export type KnowledgeBaseIncludeUpdateManyAndReturn<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
775
+ user?: boolean | Prisma.UserDefaultArgs<ExtArgs>
776
+ }
777
+
778
+ export type $KnowledgeBasePayload<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
779
+ name: "KnowledgeBase"
780
+ objects: {
781
+ user: Prisma.$UserPayload<ExtArgs>
782
+ documents: Prisma.$KnowledgeDocumentPayload<ExtArgs>[]
783
+ }
784
+ scalars: runtime.Types.Extensions.GetPayloadResult<{
785
+ id: string
786
+ name: string
787
+ description: string | null
788
+ icon: string
789
+ tags: runtime.JsonValue
790
+ visibility: string
791
+ userId: string
792
+ isDeleted: boolean
793
+ createdAt: Date
794
+ updatedAt: Date
795
+ }, ExtArgs["result"]["knowledgeBase"]>
796
+ composites: {}
797
+ }
798
+
799
+ export type KnowledgeBaseGetPayload<S extends boolean | null | undefined | KnowledgeBaseDefaultArgs> = runtime.Types.Result.GetResult<Prisma.$KnowledgeBasePayload, S>
800
+
801
+ export type KnowledgeBaseCountArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> =
802
+ Omit<KnowledgeBaseFindManyArgs, 'select' | 'include' | 'distinct' | 'omit'> & {
803
+ select?: KnowledgeBaseCountAggregateInputType | true
804
+ }
805
+
806
+ export interface KnowledgeBaseDelegate<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> {
807
+ [K: symbol]: { types: Prisma.TypeMap<ExtArgs>['model']['KnowledgeBase'], meta: { name: 'KnowledgeBase' } }
808
+ /**
809
+ * Find zero or one KnowledgeBase that matches the filter.
810
+ * @param {KnowledgeBaseFindUniqueArgs} args - Arguments to find a KnowledgeBase
811
+ * @example
812
+ * // Get one KnowledgeBase
813
+ * const knowledgeBase = await prisma.knowledgeBase.findUnique({
814
+ * where: {
815
+ * // ... provide filter here
816
+ * }
817
+ * })
818
+ */
819
+ findUnique<T extends KnowledgeBaseFindUniqueArgs>(args: Prisma.SelectSubset<T, KnowledgeBaseFindUniqueArgs<ExtArgs>>): Prisma.Prisma__KnowledgeBaseClient<runtime.Types.Result.GetResult<Prisma.$KnowledgeBasePayload<ExtArgs>, T, "findUnique", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
820
+
821
+ /**
822
+ * Find one KnowledgeBase that matches the filter or throw an error with `error.code='P2025'`
823
+ * if no matches were found.
824
+ * @param {KnowledgeBaseFindUniqueOrThrowArgs} args - Arguments to find a KnowledgeBase
825
+ * @example
826
+ * // Get one KnowledgeBase
827
+ * const knowledgeBase = await prisma.knowledgeBase.findUniqueOrThrow({
828
+ * where: {
829
+ * // ... provide filter here
830
+ * }
831
+ * })
832
+ */
833
+ findUniqueOrThrow<T extends KnowledgeBaseFindUniqueOrThrowArgs>(args: Prisma.SelectSubset<T, KnowledgeBaseFindUniqueOrThrowArgs<ExtArgs>>): Prisma.Prisma__KnowledgeBaseClient<runtime.Types.Result.GetResult<Prisma.$KnowledgeBasePayload<ExtArgs>, T, "findUniqueOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
834
+
835
+ /**
836
+ * Find the first KnowledgeBase that matches the filter.
837
+ * Note, that providing `undefined` is treated as the value not being there.
838
+ * Read more here: https://pris.ly/d/null-undefined
839
+ * @param {KnowledgeBaseFindFirstArgs} args - Arguments to find a KnowledgeBase
840
+ * @example
841
+ * // Get one KnowledgeBase
842
+ * const knowledgeBase = await prisma.knowledgeBase.findFirst({
843
+ * where: {
844
+ * // ... provide filter here
845
+ * }
846
+ * })
847
+ */
848
+ findFirst<T extends KnowledgeBaseFindFirstArgs>(args?: Prisma.SelectSubset<T, KnowledgeBaseFindFirstArgs<ExtArgs>>): Prisma.Prisma__KnowledgeBaseClient<runtime.Types.Result.GetResult<Prisma.$KnowledgeBasePayload<ExtArgs>, T, "findFirst", GlobalOmitOptions> | null, null, ExtArgs, GlobalOmitOptions>
849
+
850
+ /**
851
+ * Find the first KnowledgeBase that matches the filter or
852
+ * throw `PrismaKnownClientError` with `P2025` code if no matches were found.
853
+ * Note, that providing `undefined` is treated as the value not being there.
854
+ * Read more here: https://pris.ly/d/null-undefined
855
+ * @param {KnowledgeBaseFindFirstOrThrowArgs} args - Arguments to find a KnowledgeBase
856
+ * @example
857
+ * // Get one KnowledgeBase
858
+ * const knowledgeBase = await prisma.knowledgeBase.findFirstOrThrow({
859
+ * where: {
860
+ * // ... provide filter here
861
+ * }
862
+ * })
863
+ */
864
+ findFirstOrThrow<T extends KnowledgeBaseFindFirstOrThrowArgs>(args?: Prisma.SelectSubset<T, KnowledgeBaseFindFirstOrThrowArgs<ExtArgs>>): Prisma.Prisma__KnowledgeBaseClient<runtime.Types.Result.GetResult<Prisma.$KnowledgeBasePayload<ExtArgs>, T, "findFirstOrThrow", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
865
+
866
+ /**
867
+ * Find zero or more KnowledgeBases that matches the filter.
868
+ * Note, that providing `undefined` is treated as the value not being there.
869
+ * Read more here: https://pris.ly/d/null-undefined
870
+ * @param {KnowledgeBaseFindManyArgs} args - Arguments to filter and select certain fields only.
871
+ * @example
872
+ * // Get all KnowledgeBases
873
+ * const knowledgeBases = await prisma.knowledgeBase.findMany()
874
+ *
875
+ * // Get first 10 KnowledgeBases
876
+ * const knowledgeBases = await prisma.knowledgeBase.findMany({ take: 10 })
877
+ *
878
+ * // Only select the `id`
879
+ * const knowledgeBaseWithIdOnly = await prisma.knowledgeBase.findMany({ select: { id: true } })
880
+ *
881
+ */
882
+ findMany<T extends KnowledgeBaseFindManyArgs>(args?: Prisma.SelectSubset<T, KnowledgeBaseFindManyArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$KnowledgeBasePayload<ExtArgs>, T, "findMany", GlobalOmitOptions>>
883
+
884
+ /**
885
+ * Create a KnowledgeBase.
886
+ * @param {KnowledgeBaseCreateArgs} args - Arguments to create a KnowledgeBase.
887
+ * @example
888
+ * // Create one KnowledgeBase
889
+ * const KnowledgeBase = await prisma.knowledgeBase.create({
890
+ * data: {
891
+ * // ... data to create a KnowledgeBase
892
+ * }
893
+ * })
894
+ *
895
+ */
896
+ create<T extends KnowledgeBaseCreateArgs>(args: Prisma.SelectSubset<T, KnowledgeBaseCreateArgs<ExtArgs>>): Prisma.Prisma__KnowledgeBaseClient<runtime.Types.Result.GetResult<Prisma.$KnowledgeBasePayload<ExtArgs>, T, "create", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
897
+
898
+ /**
899
+ * Create many KnowledgeBases.
900
+ * @param {KnowledgeBaseCreateManyArgs} args - Arguments to create many KnowledgeBases.
901
+ * @example
902
+ * // Create many KnowledgeBases
903
+ * const knowledgeBase = await prisma.knowledgeBase.createMany({
904
+ * data: [
905
+ * // ... provide data here
906
+ * ]
907
+ * })
908
+ *
909
+ */
910
+ createMany<T extends KnowledgeBaseCreateManyArgs>(args?: Prisma.SelectSubset<T, KnowledgeBaseCreateManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>
911
+
912
+ /**
913
+ * Create many KnowledgeBases and returns the data saved in the database.
914
+ * @param {KnowledgeBaseCreateManyAndReturnArgs} args - Arguments to create many KnowledgeBases.
915
+ * @example
916
+ * // Create many KnowledgeBases
917
+ * const knowledgeBase = await prisma.knowledgeBase.createManyAndReturn({
918
+ * data: [
919
+ * // ... provide data here
920
+ * ]
921
+ * })
922
+ *
923
+ * // Create many KnowledgeBases and only return the `id`
924
+ * const knowledgeBaseWithIdOnly = await prisma.knowledgeBase.createManyAndReturn({
925
+ * select: { id: true },
926
+ * data: [
927
+ * // ... provide data here
928
+ * ]
929
+ * })
930
+ * Note, that providing `undefined` is treated as the value not being there.
931
+ * Read more here: https://pris.ly/d/null-undefined
932
+ *
933
+ */
934
+ createManyAndReturn<T extends KnowledgeBaseCreateManyAndReturnArgs>(args?: Prisma.SelectSubset<T, KnowledgeBaseCreateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$KnowledgeBasePayload<ExtArgs>, T, "createManyAndReturn", GlobalOmitOptions>>
935
+
936
+ /**
937
+ * Delete a KnowledgeBase.
938
+ * @param {KnowledgeBaseDeleteArgs} args - Arguments to delete one KnowledgeBase.
939
+ * @example
940
+ * // Delete one KnowledgeBase
941
+ * const KnowledgeBase = await prisma.knowledgeBase.delete({
942
+ * where: {
943
+ * // ... filter to delete one KnowledgeBase
944
+ * }
945
+ * })
946
+ *
947
+ */
948
+ delete<T extends KnowledgeBaseDeleteArgs>(args: Prisma.SelectSubset<T, KnowledgeBaseDeleteArgs<ExtArgs>>): Prisma.Prisma__KnowledgeBaseClient<runtime.Types.Result.GetResult<Prisma.$KnowledgeBasePayload<ExtArgs>, T, "delete", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
949
+
950
+ /**
951
+ * Update one KnowledgeBase.
952
+ * @param {KnowledgeBaseUpdateArgs} args - Arguments to update one KnowledgeBase.
953
+ * @example
954
+ * // Update one KnowledgeBase
955
+ * const knowledgeBase = await prisma.knowledgeBase.update({
956
+ * where: {
957
+ * // ... provide filter here
958
+ * },
959
+ * data: {
960
+ * // ... provide data here
961
+ * }
962
+ * })
963
+ *
964
+ */
965
+ update<T extends KnowledgeBaseUpdateArgs>(args: Prisma.SelectSubset<T, KnowledgeBaseUpdateArgs<ExtArgs>>): Prisma.Prisma__KnowledgeBaseClient<runtime.Types.Result.GetResult<Prisma.$KnowledgeBasePayload<ExtArgs>, T, "update", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
966
+
967
+ /**
968
+ * Delete zero or more KnowledgeBases.
969
+ * @param {KnowledgeBaseDeleteManyArgs} args - Arguments to filter KnowledgeBases to delete.
970
+ * @example
971
+ * // Delete a few KnowledgeBases
972
+ * const { count } = await prisma.knowledgeBase.deleteMany({
973
+ * where: {
974
+ * // ... provide filter here
975
+ * }
976
+ * })
977
+ *
978
+ */
979
+ deleteMany<T extends KnowledgeBaseDeleteManyArgs>(args?: Prisma.SelectSubset<T, KnowledgeBaseDeleteManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>
980
+
981
+ /**
982
+ * Update zero or more KnowledgeBases.
983
+ * Note, that providing `undefined` is treated as the value not being there.
984
+ * Read more here: https://pris.ly/d/null-undefined
985
+ * @param {KnowledgeBaseUpdateManyArgs} args - Arguments to update one or more rows.
986
+ * @example
987
+ * // Update many KnowledgeBases
988
+ * const knowledgeBase = await prisma.knowledgeBase.updateMany({
989
+ * where: {
990
+ * // ... provide filter here
991
+ * },
992
+ * data: {
993
+ * // ... provide data here
994
+ * }
995
+ * })
996
+ *
997
+ */
998
+ updateMany<T extends KnowledgeBaseUpdateManyArgs>(args: Prisma.SelectSubset<T, KnowledgeBaseUpdateManyArgs<ExtArgs>>): Prisma.PrismaPromise<Prisma.BatchPayload>
999
+
1000
+ /**
1001
+ * Update zero or more KnowledgeBases and returns the data updated in the database.
1002
+ * @param {KnowledgeBaseUpdateManyAndReturnArgs} args - Arguments to update many KnowledgeBases.
1003
+ * @example
1004
+ * // Update many KnowledgeBases
1005
+ * const knowledgeBase = await prisma.knowledgeBase.updateManyAndReturn({
1006
+ * where: {
1007
+ * // ... provide filter here
1008
+ * },
1009
+ * data: [
1010
+ * // ... provide data here
1011
+ * ]
1012
+ * })
1013
+ *
1014
+ * // Update zero or more KnowledgeBases and only return the `id`
1015
+ * const knowledgeBaseWithIdOnly = await prisma.knowledgeBase.updateManyAndReturn({
1016
+ * select: { id: true },
1017
+ * where: {
1018
+ * // ... provide filter here
1019
+ * },
1020
+ * data: [
1021
+ * // ... provide data here
1022
+ * ]
1023
+ * })
1024
+ * Note, that providing `undefined` is treated as the value not being there.
1025
+ * Read more here: https://pris.ly/d/null-undefined
1026
+ *
1027
+ */
1028
+ updateManyAndReturn<T extends KnowledgeBaseUpdateManyAndReturnArgs>(args: Prisma.SelectSubset<T, KnowledgeBaseUpdateManyAndReturnArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$KnowledgeBasePayload<ExtArgs>, T, "updateManyAndReturn", GlobalOmitOptions>>
1029
+
1030
+ /**
1031
+ * Create or update one KnowledgeBase.
1032
+ * @param {KnowledgeBaseUpsertArgs} args - Arguments to update or create a KnowledgeBase.
1033
+ * @example
1034
+ * // Update or create a KnowledgeBase
1035
+ * const knowledgeBase = await prisma.knowledgeBase.upsert({
1036
+ * create: {
1037
+ * // ... data to create a KnowledgeBase
1038
+ * },
1039
+ * update: {
1040
+ * // ... in case it already exists, update
1041
+ * },
1042
+ * where: {
1043
+ * // ... the filter for the KnowledgeBase we want to update
1044
+ * }
1045
+ * })
1046
+ */
1047
+ upsert<T extends KnowledgeBaseUpsertArgs>(args: Prisma.SelectSubset<T, KnowledgeBaseUpsertArgs<ExtArgs>>): Prisma.Prisma__KnowledgeBaseClient<runtime.Types.Result.GetResult<Prisma.$KnowledgeBasePayload<ExtArgs>, T, "upsert", GlobalOmitOptions>, never, ExtArgs, GlobalOmitOptions>
1048
+
1049
+
1050
+ /**
1051
+ * Count the number of KnowledgeBases.
1052
+ * Note, that providing `undefined` is treated as the value not being there.
1053
+ * Read more here: https://pris.ly/d/null-undefined
1054
+ * @param {KnowledgeBaseCountArgs} args - Arguments to filter KnowledgeBases to count.
1055
+ * @example
1056
+ * // Count the number of KnowledgeBases
1057
+ * const count = await prisma.knowledgeBase.count({
1058
+ * where: {
1059
+ * // ... the filter for the KnowledgeBases we want to count
1060
+ * }
1061
+ * })
1062
+ **/
1063
+ count<T extends KnowledgeBaseCountArgs>(
1064
+ args?: Prisma.Subset<T, KnowledgeBaseCountArgs>,
1065
+ ): Prisma.PrismaPromise<
1066
+ T extends runtime.Types.Utils.Record<'select', any>
1067
+ ? T['select'] extends true
1068
+ ? number
1069
+ : Prisma.GetScalarType<T['select'], KnowledgeBaseCountAggregateOutputType>
1070
+ : number
1071
+ >
1072
+
1073
+ /**
1074
+ * Allows you to perform aggregations operations on a KnowledgeBase.
1075
+ * Note, that providing `undefined` is treated as the value not being there.
1076
+ * Read more here: https://pris.ly/d/null-undefined
1077
+ * @param {KnowledgeBaseAggregateArgs} args - Select which aggregations you would like to apply and on what fields.
1078
+ * @example
1079
+ * // Ordered by age ascending
1080
+ * // Where email contains prisma.io
1081
+ * // Limited to the 10 users
1082
+ * const aggregations = await prisma.user.aggregate({
1083
+ * _avg: {
1084
+ * age: true,
1085
+ * },
1086
+ * where: {
1087
+ * email: {
1088
+ * contains: "prisma.io",
1089
+ * },
1090
+ * },
1091
+ * orderBy: {
1092
+ * age: "asc",
1093
+ * },
1094
+ * take: 10,
1095
+ * })
1096
+ **/
1097
+ aggregate<T extends KnowledgeBaseAggregateArgs>(args: Prisma.Subset<T, KnowledgeBaseAggregateArgs>): Prisma.PrismaPromise<GetKnowledgeBaseAggregateType<T>>
1098
+
1099
+ /**
1100
+ * Group by KnowledgeBase.
1101
+ * Note, that providing `undefined` is treated as the value not being there.
1102
+ * Read more here: https://pris.ly/d/null-undefined
1103
+ * @param {KnowledgeBaseGroupByArgs} args - Group by arguments.
1104
+ * @example
1105
+ * // Group by city, order by createdAt, get count
1106
+ * const result = await prisma.user.groupBy({
1107
+ * by: ['city', 'createdAt'],
1108
+ * orderBy: {
1109
+ * createdAt: true
1110
+ * },
1111
+ * _count: {
1112
+ * _all: true
1113
+ * },
1114
+ * })
1115
+ *
1116
+ **/
1117
+ groupBy<
1118
+ T extends KnowledgeBaseGroupByArgs,
1119
+ HasSelectOrTake extends Prisma.Or<
1120
+ Prisma.Extends<'skip', Prisma.Keys<T>>,
1121
+ Prisma.Extends<'take', Prisma.Keys<T>>
1122
+ >,
1123
+ OrderByArg extends Prisma.True extends HasSelectOrTake
1124
+ ? { orderBy: KnowledgeBaseGroupByArgs['orderBy'] }
1125
+ : { orderBy?: KnowledgeBaseGroupByArgs['orderBy'] },
1126
+ OrderFields extends Prisma.ExcludeUnderscoreKeys<Prisma.Keys<Prisma.MaybeTupleToUnion<T['orderBy']>>>,
1127
+ ByFields extends Prisma.MaybeTupleToUnion<T['by']>,
1128
+ ByValid extends Prisma.Has<ByFields, OrderFields>,
1129
+ HavingFields extends Prisma.GetHavingFields<T['having']>,
1130
+ HavingValid extends Prisma.Has<ByFields, HavingFields>,
1131
+ ByEmpty extends T['by'] extends never[] ? Prisma.True : Prisma.False,
1132
+ InputErrors extends ByEmpty extends Prisma.True
1133
+ ? `Error: "by" must not be empty.`
1134
+ : HavingValid extends Prisma.False
1135
+ ? {
1136
+ [P in HavingFields]: P extends ByFields
1137
+ ? never
1138
+ : P extends string
1139
+ ? `Error: Field "${P}" used in "having" needs to be provided in "by".`
1140
+ : [
1141
+ Error,
1142
+ 'Field ',
1143
+ P,
1144
+ ` in "having" needs to be provided in "by"`,
1145
+ ]
1146
+ }[HavingFields]
1147
+ : 'take' extends Prisma.Keys<T>
1148
+ ? 'orderBy' extends Prisma.Keys<T>
1149
+ ? ByValid extends Prisma.True
1150
+ ? {}
1151
+ : {
1152
+ [P in OrderFields]: P extends ByFields
1153
+ ? never
1154
+ : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
1155
+ }[OrderFields]
1156
+ : 'Error: If you provide "take", you also need to provide "orderBy"'
1157
+ : 'skip' extends Prisma.Keys<T>
1158
+ ? 'orderBy' extends Prisma.Keys<T>
1159
+ ? ByValid extends Prisma.True
1160
+ ? {}
1161
+ : {
1162
+ [P in OrderFields]: P extends ByFields
1163
+ ? never
1164
+ : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
1165
+ }[OrderFields]
1166
+ : 'Error: If you provide "skip", you also need to provide "orderBy"'
1167
+ : ByValid extends Prisma.True
1168
+ ? {}
1169
+ : {
1170
+ [P in OrderFields]: P extends ByFields
1171
+ ? never
1172
+ : `Error: Field "${P}" in "orderBy" needs to be provided in "by"`
1173
+ }[OrderFields]
1174
+ >(args: Prisma.SubsetIntersection<T, KnowledgeBaseGroupByArgs, OrderByArg> & InputErrors): {} extends InputErrors ? GetKnowledgeBaseGroupByPayload<T> : Prisma.PrismaPromise<InputErrors>
1175
+ /**
1176
+ * Fields of the KnowledgeBase model
1177
+ */
1178
+ readonly fields: KnowledgeBaseFieldRefs;
1179
+ }
1180
+
1181
+ /**
1182
+ * The delegate class that acts as a "Promise-like" for KnowledgeBase.
1183
+ * Why is this prefixed with `Prisma__`?
1184
+ * Because we want to prevent naming conflicts as mentioned in
1185
+ * https://github.com/prisma/prisma-client-js/issues/707
1186
+ */
1187
+ export interface Prisma__KnowledgeBaseClient<T, Null = never, ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs, GlobalOmitOptions = {}> extends Prisma.PrismaPromise<T> {
1188
+ readonly [Symbol.toStringTag]: "PrismaPromise"
1189
+ 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>
1190
+ documents<T extends Prisma.KnowledgeBase$documentsArgs<ExtArgs> = {}>(args?: Prisma.Subset<T, Prisma.KnowledgeBase$documentsArgs<ExtArgs>>): Prisma.PrismaPromise<runtime.Types.Result.GetResult<Prisma.$KnowledgeDocumentPayload<ExtArgs>, T, "findMany", GlobalOmitOptions> | Null>
1191
+ /**
1192
+ * Attaches callbacks for the resolution and/or rejection of the Promise.
1193
+ * @param onfulfilled The callback to execute when the Promise is resolved.
1194
+ * @param onrejected The callback to execute when the Promise is rejected.
1195
+ * @returns A Promise for the completion of which ever callback is executed.
1196
+ */
1197
+ 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>
1198
+ /**
1199
+ * Attaches a callback for only the rejection of the Promise.
1200
+ * @param onrejected The callback to execute when the Promise is rejected.
1201
+ * @returns A Promise for the completion of the callback.
1202
+ */
1203
+ catch<TResult = never>(onrejected?: ((reason: any) => TResult | PromiseLike<TResult>) | undefined | null): runtime.Types.Utils.JsPromise<T | TResult>
1204
+ /**
1205
+ * Attaches a callback that is invoked when the Promise is settled (fulfilled or rejected). The
1206
+ * resolved value cannot be modified from the callback.
1207
+ * @param onfinally The callback to execute when the Promise is settled (fulfilled or rejected).
1208
+ * @returns A Promise for the completion of the callback.
1209
+ */
1210
+ finally(onfinally?: (() => void) | undefined | null): runtime.Types.Utils.JsPromise<T>
1211
+ }
1212
+
1213
+
1214
+
1215
+
1216
+ /**
1217
+ * Fields of the KnowledgeBase model
1218
+ */
1219
+ export interface KnowledgeBaseFieldRefs {
1220
+ readonly id: Prisma.FieldRef<"KnowledgeBase", 'String'>
1221
+ readonly name: Prisma.FieldRef<"KnowledgeBase", 'String'>
1222
+ readonly description: Prisma.FieldRef<"KnowledgeBase", 'String'>
1223
+ readonly icon: Prisma.FieldRef<"KnowledgeBase", 'String'>
1224
+ readonly tags: Prisma.FieldRef<"KnowledgeBase", 'Json'>
1225
+ readonly visibility: Prisma.FieldRef<"KnowledgeBase", 'String'>
1226
+ readonly userId: Prisma.FieldRef<"KnowledgeBase", 'String'>
1227
+ readonly isDeleted: Prisma.FieldRef<"KnowledgeBase", 'Boolean'>
1228
+ readonly createdAt: Prisma.FieldRef<"KnowledgeBase", 'DateTime'>
1229
+ readonly updatedAt: Prisma.FieldRef<"KnowledgeBase", 'DateTime'>
1230
+ }
1231
+
1232
+
1233
+ // Custom InputTypes
1234
+ /**
1235
+ * KnowledgeBase findUnique
1236
+ */
1237
+ export type KnowledgeBaseFindUniqueArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1238
+ /**
1239
+ * Select specific fields to fetch from the KnowledgeBase
1240
+ */
1241
+ select?: Prisma.KnowledgeBaseSelect<ExtArgs> | null
1242
+ /**
1243
+ * Omit specific fields from the KnowledgeBase
1244
+ */
1245
+ omit?: Prisma.KnowledgeBaseOmit<ExtArgs> | null
1246
+ /**
1247
+ * Choose, which related nodes to fetch as well
1248
+ */
1249
+ include?: Prisma.KnowledgeBaseInclude<ExtArgs> | null
1250
+ /**
1251
+ * Filter, which KnowledgeBase to fetch.
1252
+ */
1253
+ where: Prisma.KnowledgeBaseWhereUniqueInput
1254
+ }
1255
+
1256
+ /**
1257
+ * KnowledgeBase findUniqueOrThrow
1258
+ */
1259
+ export type KnowledgeBaseFindUniqueOrThrowArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1260
+ /**
1261
+ * Select specific fields to fetch from the KnowledgeBase
1262
+ */
1263
+ select?: Prisma.KnowledgeBaseSelect<ExtArgs> | null
1264
+ /**
1265
+ * Omit specific fields from the KnowledgeBase
1266
+ */
1267
+ omit?: Prisma.KnowledgeBaseOmit<ExtArgs> | null
1268
+ /**
1269
+ * Choose, which related nodes to fetch as well
1270
+ */
1271
+ include?: Prisma.KnowledgeBaseInclude<ExtArgs> | null
1272
+ /**
1273
+ * Filter, which KnowledgeBase to fetch.
1274
+ */
1275
+ where: Prisma.KnowledgeBaseWhereUniqueInput
1276
+ }
1277
+
1278
+ /**
1279
+ * KnowledgeBase findFirst
1280
+ */
1281
+ export type KnowledgeBaseFindFirstArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1282
+ /**
1283
+ * Select specific fields to fetch from the KnowledgeBase
1284
+ */
1285
+ select?: Prisma.KnowledgeBaseSelect<ExtArgs> | null
1286
+ /**
1287
+ * Omit specific fields from the KnowledgeBase
1288
+ */
1289
+ omit?: Prisma.KnowledgeBaseOmit<ExtArgs> | null
1290
+ /**
1291
+ * Choose, which related nodes to fetch as well
1292
+ */
1293
+ include?: Prisma.KnowledgeBaseInclude<ExtArgs> | null
1294
+ /**
1295
+ * Filter, which KnowledgeBase to fetch.
1296
+ */
1297
+ where?: Prisma.KnowledgeBaseWhereInput
1298
+ /**
1299
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
1300
+ *
1301
+ * Determine the order of KnowledgeBases to fetch.
1302
+ */
1303
+ orderBy?: Prisma.KnowledgeBaseOrderByWithRelationInput | Prisma.KnowledgeBaseOrderByWithRelationInput[]
1304
+ /**
1305
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
1306
+ *
1307
+ * Sets the position for searching for KnowledgeBases.
1308
+ */
1309
+ cursor?: Prisma.KnowledgeBaseWhereUniqueInput
1310
+ /**
1311
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
1312
+ *
1313
+ * Take `±n` KnowledgeBases from the position of the cursor.
1314
+ */
1315
+ take?: number
1316
+ /**
1317
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
1318
+ *
1319
+ * Skip the first `n` KnowledgeBases.
1320
+ */
1321
+ skip?: number
1322
+ /**
1323
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
1324
+ *
1325
+ * Filter by unique combinations of KnowledgeBases.
1326
+ */
1327
+ distinct?: Prisma.KnowledgeBaseScalarFieldEnum | Prisma.KnowledgeBaseScalarFieldEnum[]
1328
+ }
1329
+
1330
+ /**
1331
+ * KnowledgeBase findFirstOrThrow
1332
+ */
1333
+ export type KnowledgeBaseFindFirstOrThrowArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1334
+ /**
1335
+ * Select specific fields to fetch from the KnowledgeBase
1336
+ */
1337
+ select?: Prisma.KnowledgeBaseSelect<ExtArgs> | null
1338
+ /**
1339
+ * Omit specific fields from the KnowledgeBase
1340
+ */
1341
+ omit?: Prisma.KnowledgeBaseOmit<ExtArgs> | null
1342
+ /**
1343
+ * Choose, which related nodes to fetch as well
1344
+ */
1345
+ include?: Prisma.KnowledgeBaseInclude<ExtArgs> | null
1346
+ /**
1347
+ * Filter, which KnowledgeBase to fetch.
1348
+ */
1349
+ where?: Prisma.KnowledgeBaseWhereInput
1350
+ /**
1351
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
1352
+ *
1353
+ * Determine the order of KnowledgeBases to fetch.
1354
+ */
1355
+ orderBy?: Prisma.KnowledgeBaseOrderByWithRelationInput | Prisma.KnowledgeBaseOrderByWithRelationInput[]
1356
+ /**
1357
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
1358
+ *
1359
+ * Sets the position for searching for KnowledgeBases.
1360
+ */
1361
+ cursor?: Prisma.KnowledgeBaseWhereUniqueInput
1362
+ /**
1363
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
1364
+ *
1365
+ * Take `±n` KnowledgeBases from the position of the cursor.
1366
+ */
1367
+ take?: number
1368
+ /**
1369
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
1370
+ *
1371
+ * Skip the first `n` KnowledgeBases.
1372
+ */
1373
+ skip?: number
1374
+ /**
1375
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
1376
+ *
1377
+ * Filter by unique combinations of KnowledgeBases.
1378
+ */
1379
+ distinct?: Prisma.KnowledgeBaseScalarFieldEnum | Prisma.KnowledgeBaseScalarFieldEnum[]
1380
+ }
1381
+
1382
+ /**
1383
+ * KnowledgeBase findMany
1384
+ */
1385
+ export type KnowledgeBaseFindManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1386
+ /**
1387
+ * Select specific fields to fetch from the KnowledgeBase
1388
+ */
1389
+ select?: Prisma.KnowledgeBaseSelect<ExtArgs> | null
1390
+ /**
1391
+ * Omit specific fields from the KnowledgeBase
1392
+ */
1393
+ omit?: Prisma.KnowledgeBaseOmit<ExtArgs> | null
1394
+ /**
1395
+ * Choose, which related nodes to fetch as well
1396
+ */
1397
+ include?: Prisma.KnowledgeBaseInclude<ExtArgs> | null
1398
+ /**
1399
+ * Filter, which KnowledgeBases to fetch.
1400
+ */
1401
+ where?: Prisma.KnowledgeBaseWhereInput
1402
+ /**
1403
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/sorting Sorting Docs}
1404
+ *
1405
+ * Determine the order of KnowledgeBases to fetch.
1406
+ */
1407
+ orderBy?: Prisma.KnowledgeBaseOrderByWithRelationInput | Prisma.KnowledgeBaseOrderByWithRelationInput[]
1408
+ /**
1409
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination#cursor-based-pagination Cursor Docs}
1410
+ *
1411
+ * Sets the position for listing KnowledgeBases.
1412
+ */
1413
+ cursor?: Prisma.KnowledgeBaseWhereUniqueInput
1414
+ /**
1415
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
1416
+ *
1417
+ * Take `±n` KnowledgeBases from the position of the cursor.
1418
+ */
1419
+ take?: number
1420
+ /**
1421
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/pagination Pagination Docs}
1422
+ *
1423
+ * Skip the first `n` KnowledgeBases.
1424
+ */
1425
+ skip?: number
1426
+ /**
1427
+ * {@link https://www.prisma.io/docs/concepts/components/prisma-client/distinct Distinct Docs}
1428
+ *
1429
+ * Filter by unique combinations of KnowledgeBases.
1430
+ */
1431
+ distinct?: Prisma.KnowledgeBaseScalarFieldEnum | Prisma.KnowledgeBaseScalarFieldEnum[]
1432
+ }
1433
+
1434
+ /**
1435
+ * KnowledgeBase create
1436
+ */
1437
+ export type KnowledgeBaseCreateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1438
+ /**
1439
+ * Select specific fields to fetch from the KnowledgeBase
1440
+ */
1441
+ select?: Prisma.KnowledgeBaseSelect<ExtArgs> | null
1442
+ /**
1443
+ * Omit specific fields from the KnowledgeBase
1444
+ */
1445
+ omit?: Prisma.KnowledgeBaseOmit<ExtArgs> | null
1446
+ /**
1447
+ * Choose, which related nodes to fetch as well
1448
+ */
1449
+ include?: Prisma.KnowledgeBaseInclude<ExtArgs> | null
1450
+ /**
1451
+ * The data needed to create a KnowledgeBase.
1452
+ */
1453
+ data: Prisma.XOR<Prisma.KnowledgeBaseCreateInput, Prisma.KnowledgeBaseUncheckedCreateInput>
1454
+ }
1455
+
1456
+ /**
1457
+ * KnowledgeBase createMany
1458
+ */
1459
+ export type KnowledgeBaseCreateManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1460
+ /**
1461
+ * The data used to create many KnowledgeBases.
1462
+ */
1463
+ data: Prisma.KnowledgeBaseCreateManyInput | Prisma.KnowledgeBaseCreateManyInput[]
1464
+ }
1465
+
1466
+ /**
1467
+ * KnowledgeBase createManyAndReturn
1468
+ */
1469
+ export type KnowledgeBaseCreateManyAndReturnArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1470
+ /**
1471
+ * Select specific fields to fetch from the KnowledgeBase
1472
+ */
1473
+ select?: Prisma.KnowledgeBaseSelectCreateManyAndReturn<ExtArgs> | null
1474
+ /**
1475
+ * Omit specific fields from the KnowledgeBase
1476
+ */
1477
+ omit?: Prisma.KnowledgeBaseOmit<ExtArgs> | null
1478
+ /**
1479
+ * The data used to create many KnowledgeBases.
1480
+ */
1481
+ data: Prisma.KnowledgeBaseCreateManyInput | Prisma.KnowledgeBaseCreateManyInput[]
1482
+ /**
1483
+ * Choose, which related nodes to fetch as well
1484
+ */
1485
+ include?: Prisma.KnowledgeBaseIncludeCreateManyAndReturn<ExtArgs> | null
1486
+ }
1487
+
1488
+ /**
1489
+ * KnowledgeBase update
1490
+ */
1491
+ export type KnowledgeBaseUpdateArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1492
+ /**
1493
+ * Select specific fields to fetch from the KnowledgeBase
1494
+ */
1495
+ select?: Prisma.KnowledgeBaseSelect<ExtArgs> | null
1496
+ /**
1497
+ * Omit specific fields from the KnowledgeBase
1498
+ */
1499
+ omit?: Prisma.KnowledgeBaseOmit<ExtArgs> | null
1500
+ /**
1501
+ * Choose, which related nodes to fetch as well
1502
+ */
1503
+ include?: Prisma.KnowledgeBaseInclude<ExtArgs> | null
1504
+ /**
1505
+ * The data needed to update a KnowledgeBase.
1506
+ */
1507
+ data: Prisma.XOR<Prisma.KnowledgeBaseUpdateInput, Prisma.KnowledgeBaseUncheckedUpdateInput>
1508
+ /**
1509
+ * Choose, which KnowledgeBase to update.
1510
+ */
1511
+ where: Prisma.KnowledgeBaseWhereUniqueInput
1512
+ }
1513
+
1514
+ /**
1515
+ * KnowledgeBase updateMany
1516
+ */
1517
+ export type KnowledgeBaseUpdateManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1518
+ /**
1519
+ * The data used to update KnowledgeBases.
1520
+ */
1521
+ data: Prisma.XOR<Prisma.KnowledgeBaseUpdateManyMutationInput, Prisma.KnowledgeBaseUncheckedUpdateManyInput>
1522
+ /**
1523
+ * Filter which KnowledgeBases to update
1524
+ */
1525
+ where?: Prisma.KnowledgeBaseWhereInput
1526
+ /**
1527
+ * Limit how many KnowledgeBases to update.
1528
+ */
1529
+ limit?: number
1530
+ }
1531
+
1532
+ /**
1533
+ * KnowledgeBase updateManyAndReturn
1534
+ */
1535
+ export type KnowledgeBaseUpdateManyAndReturnArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1536
+ /**
1537
+ * Select specific fields to fetch from the KnowledgeBase
1538
+ */
1539
+ select?: Prisma.KnowledgeBaseSelectUpdateManyAndReturn<ExtArgs> | null
1540
+ /**
1541
+ * Omit specific fields from the KnowledgeBase
1542
+ */
1543
+ omit?: Prisma.KnowledgeBaseOmit<ExtArgs> | null
1544
+ /**
1545
+ * The data used to update KnowledgeBases.
1546
+ */
1547
+ data: Prisma.XOR<Prisma.KnowledgeBaseUpdateManyMutationInput, Prisma.KnowledgeBaseUncheckedUpdateManyInput>
1548
+ /**
1549
+ * Filter which KnowledgeBases to update
1550
+ */
1551
+ where?: Prisma.KnowledgeBaseWhereInput
1552
+ /**
1553
+ * Limit how many KnowledgeBases to update.
1554
+ */
1555
+ limit?: number
1556
+ /**
1557
+ * Choose, which related nodes to fetch as well
1558
+ */
1559
+ include?: Prisma.KnowledgeBaseIncludeUpdateManyAndReturn<ExtArgs> | null
1560
+ }
1561
+
1562
+ /**
1563
+ * KnowledgeBase upsert
1564
+ */
1565
+ export type KnowledgeBaseUpsertArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1566
+ /**
1567
+ * Select specific fields to fetch from the KnowledgeBase
1568
+ */
1569
+ select?: Prisma.KnowledgeBaseSelect<ExtArgs> | null
1570
+ /**
1571
+ * Omit specific fields from the KnowledgeBase
1572
+ */
1573
+ omit?: Prisma.KnowledgeBaseOmit<ExtArgs> | null
1574
+ /**
1575
+ * Choose, which related nodes to fetch as well
1576
+ */
1577
+ include?: Prisma.KnowledgeBaseInclude<ExtArgs> | null
1578
+ /**
1579
+ * The filter to search for the KnowledgeBase to update in case it exists.
1580
+ */
1581
+ where: Prisma.KnowledgeBaseWhereUniqueInput
1582
+ /**
1583
+ * In case the KnowledgeBase found by the `where` argument doesn't exist, create a new KnowledgeBase with this data.
1584
+ */
1585
+ create: Prisma.XOR<Prisma.KnowledgeBaseCreateInput, Prisma.KnowledgeBaseUncheckedCreateInput>
1586
+ /**
1587
+ * In case the KnowledgeBase was found with the provided `where` argument, update it with this data.
1588
+ */
1589
+ update: Prisma.XOR<Prisma.KnowledgeBaseUpdateInput, Prisma.KnowledgeBaseUncheckedUpdateInput>
1590
+ }
1591
+
1592
+ /**
1593
+ * KnowledgeBase delete
1594
+ */
1595
+ export type KnowledgeBaseDeleteArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1596
+ /**
1597
+ * Select specific fields to fetch from the KnowledgeBase
1598
+ */
1599
+ select?: Prisma.KnowledgeBaseSelect<ExtArgs> | null
1600
+ /**
1601
+ * Omit specific fields from the KnowledgeBase
1602
+ */
1603
+ omit?: Prisma.KnowledgeBaseOmit<ExtArgs> | null
1604
+ /**
1605
+ * Choose, which related nodes to fetch as well
1606
+ */
1607
+ include?: Prisma.KnowledgeBaseInclude<ExtArgs> | null
1608
+ /**
1609
+ * Filter which KnowledgeBase to delete.
1610
+ */
1611
+ where: Prisma.KnowledgeBaseWhereUniqueInput
1612
+ }
1613
+
1614
+ /**
1615
+ * KnowledgeBase deleteMany
1616
+ */
1617
+ export type KnowledgeBaseDeleteManyArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1618
+ /**
1619
+ * Filter which KnowledgeBases to delete
1620
+ */
1621
+ where?: Prisma.KnowledgeBaseWhereInput
1622
+ /**
1623
+ * Limit how many KnowledgeBases to delete.
1624
+ */
1625
+ limit?: number
1626
+ }
1627
+
1628
+ /**
1629
+ * KnowledgeBase.documents
1630
+ */
1631
+ export type KnowledgeBase$documentsArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1632
+ /**
1633
+ * Select specific fields to fetch from the KnowledgeDocument
1634
+ */
1635
+ select?: Prisma.KnowledgeDocumentSelect<ExtArgs> | null
1636
+ /**
1637
+ * Omit specific fields from the KnowledgeDocument
1638
+ */
1639
+ omit?: Prisma.KnowledgeDocumentOmit<ExtArgs> | null
1640
+ /**
1641
+ * Choose, which related nodes to fetch as well
1642
+ */
1643
+ include?: Prisma.KnowledgeDocumentInclude<ExtArgs> | null
1644
+ where?: Prisma.KnowledgeDocumentWhereInput
1645
+ orderBy?: Prisma.KnowledgeDocumentOrderByWithRelationInput | Prisma.KnowledgeDocumentOrderByWithRelationInput[]
1646
+ cursor?: Prisma.KnowledgeDocumentWhereUniqueInput
1647
+ take?: number
1648
+ skip?: number
1649
+ distinct?: Prisma.KnowledgeDocumentScalarFieldEnum | Prisma.KnowledgeDocumentScalarFieldEnum[]
1650
+ }
1651
+
1652
+ /**
1653
+ * KnowledgeBase without action
1654
+ */
1655
+ export type KnowledgeBaseDefaultArgs<ExtArgs extends runtime.Types.Extensions.InternalArgs = runtime.Types.Extensions.DefaultArgs> = {
1656
+ /**
1657
+ * Select specific fields to fetch from the KnowledgeBase
1658
+ */
1659
+ select?: Prisma.KnowledgeBaseSelect<ExtArgs> | null
1660
+ /**
1661
+ * Omit specific fields from the KnowledgeBase
1662
+ */
1663
+ omit?: Prisma.KnowledgeBaseOmit<ExtArgs> | null
1664
+ /**
1665
+ * Choose, which related nodes to fetch as well
1666
+ */
1667
+ include?: Prisma.KnowledgeBaseInclude<ExtArgs> | null
1668
+ }