@oneuptime/common 11.5.4 → 11.5.5

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 (505) hide show
  1. package/Models/DatabaseModels/AIAgentTaskPullRequest.ts +56 -45
  2. package/Models/DatabaseModels/AIInsight.ts +748 -0
  3. package/Models/DatabaseModels/AIRun.ts +262 -0
  4. package/Models/DatabaseModels/CodeRepository.ts +42 -0
  5. package/Models/DatabaseModels/GlobalConfig.ts +105 -0
  6. package/Models/DatabaseModels/Index.ts +4 -8
  7. package/Models/DatabaseModels/InstanceHealthLog.ts +277 -0
  8. package/Models/DatabaseModels/LlmLog.ts +33 -0
  9. package/Models/DatabaseModels/Project.ts +123 -6
  10. package/Models/DatabaseModels/Runbook.ts +1 -1
  11. package/Server/API/AIAgentDataAPI.ts +802 -140
  12. package/Server/API/AIAgentTaskAPI.ts +132 -69
  13. package/Server/API/AIAgentTaskLogAPI.ts +65 -41
  14. package/Server/API/AIAgentTaskPullRequestAPI.ts +41 -0
  15. package/Server/API/AIInsightAPI.ts +220 -0
  16. package/Server/API/AIInvestigationAPI.ts +363 -1
  17. package/Server/API/CodeFixRunAPI.ts +251 -0
  18. package/Server/API/GitHubAPI.ts +246 -3
  19. package/Server/API/TelemetryExceptionAPI.ts +193 -48
  20. package/Server/EnvironmentConfig.ts +1 -1
  21. package/Server/Infrastructure/Postgres/SchemaMigrations/1783943300000-DropServiceCodeRepository.ts +26 -0
  22. package/Server/Infrastructure/Postgres/SchemaMigrations/1783947444597-CodeFixRunsOnAIRun.ts +73 -0
  23. package/Server/Infrastructure/Postgres/SchemaMigrations/1783950962813-AddCodeFixTaskType.ts +29 -0
  24. package/Server/Infrastructure/Postgres/SchemaMigrations/1783954040984-AddInstrumentationFixTasksFlag.ts +31 -0
  25. package/Server/Infrastructure/Postgres/SchemaMigrations/1783957160597-MigrationName.ts +51 -0
  26. package/Server/Infrastructure/Postgres/SchemaMigrations/1783958542237-AddTaskContextToAIRun.ts +25 -0
  27. package/Server/Infrastructure/Postgres/SchemaMigrations/1783965945957-AddInvestigationVerdictAndGrade.ts +47 -0
  28. package/Server/Infrastructure/Postgres/SchemaMigrations/1783970619301-AddFixGuardrailColumns.ts +53 -0
  29. package/Server/Infrastructure/Postgres/SchemaMigrations/1783970619302-DropLegacyAIAgentTaskTables.ts +31 -0
  30. package/Server/Infrastructure/Postgres/SchemaMigrations/1783977781677-AddCiStatusToFixPullRequests.ts +37 -0
  31. package/Server/Infrastructure/Postgres/SchemaMigrations/1783990000000-AddCompletionTokensToLlmLog.ts +25 -0
  32. package/Server/Infrastructure/Postgres/SchemaMigrations/1784010274993-AddSentinelInsight.ts +75 -0
  33. package/Server/Infrastructure/Postgres/SchemaMigrations/1784010274994-AddSentinelInsightFlags.ts +37 -0
  34. package/Server/Infrastructure/Postgres/SchemaMigrations/1784030612266-RenameSentinelToAI.ts +203 -0
  35. package/Server/Infrastructure/Postgres/SchemaMigrations/1784033837629-MigrationName.ts +163 -0
  36. package/Server/Infrastructure/Postgres/SchemaMigrations/Index.ts +30 -0
  37. package/Server/Infrastructure/Queue.ts +82 -4
  38. package/Server/Infrastructure/Semaphore.ts +62 -1
  39. package/Server/Services/AIAgentService.ts +32 -0
  40. package/Server/Services/AIAgentTaskPullRequestService.ts +117 -0
  41. package/Server/Services/AIInsightService.ts +174 -0
  42. package/Server/Services/AIRunEventService.ts +63 -0
  43. package/Server/Services/AIRunService.ts +259 -1
  44. package/Server/Services/AIService.ts +249 -7
  45. package/Server/Services/AlertService.ts +4 -4
  46. package/Server/Services/CodeRepositoryService.ts +209 -0
  47. package/Server/Services/GlobalConfigService.ts +148 -0
  48. package/Server/Services/IncidentService.ts +183 -38
  49. package/Server/Services/IncidentStateTimelineService.ts +24 -4
  50. package/Server/Services/Index.ts +4 -4
  51. package/Server/Services/{AIAgentTaskLogService.ts → InstanceHealthLogService.ts} +1 -1
  52. package/Server/Services/LlmLogService.ts +27 -0
  53. package/Server/Services/LlmProviderService.ts +108 -0
  54. package/Server/Services/MetricBaselineService.ts +123 -0
  55. package/Server/Services/MonitorService.ts +15 -0
  56. package/Server/Services/TelemetryExceptionService.ts +323 -116
  57. package/Server/Services/TraceAggregationService.ts +176 -0
  58. package/Server/Types/Workflow/ComponentCode.ts +6 -0
  59. package/Server/Types/Workflow/Components/AI/GenerateText.ts +326 -0
  60. package/Server/Types/Workflow/Components/Index.ts +2 -0
  61. package/Server/Utils/AI/Chat/ObservabilityAssistant.ts +1 -1
  62. package/Server/Utils/AI/CodeFix/CodeAgentWorkspaceGuard.ts +71 -0
  63. package/Server/Utils/AI/CodeFix/CodeFixAgentCompletion.ts +243 -0
  64. package/Server/Utils/AI/CodeFix/CodeFixRunQueue.ts +131 -0
  65. package/Server/Utils/AI/CodeFix/FixRunBudget.ts +148 -0
  66. package/Server/Utils/AI/CodeFix/OpenPullRequestCap.ts +117 -0
  67. package/Server/Utils/AI/Eval/EvalCorpus.ts +369 -0
  68. package/Server/Utils/AI/Eval/EvalScores.ts +172 -0
  69. package/Server/Utils/AI/Eval/ReplayInvestigation.ts +87 -0
  70. package/Server/Utils/AI/PerfEvidence/SpanTreeAnalyzer.ts +676 -0
  71. package/Server/Utils/AI/{Sentinel/SentinelInvestigationEngine.ts → SRE/AIInvestigationEngine.ts} +58 -37
  72. package/Server/Utils/AI/{Sentinel/SentinelMemory.ts → SRE/AIMemory.ts} +3 -3
  73. package/Server/Utils/AI/{Sentinel → SRE}/AlertInvestigationRunner.ts +50 -20
  74. package/Server/Utils/AI/SRE/ConfidenceSignal.ts +293 -0
  75. package/Server/Utils/AI/SRE/FixFromIncidentTaskTrigger.ts +115 -0
  76. package/Server/Utils/AI/SRE/FixPerformanceTaskTrigger.ts +223 -0
  77. package/Server/Utils/AI/{Sentinel → SRE}/IncidentInvestigationRunner.ts +71 -21
  78. package/Server/Utils/AI/{Sentinel → SRE}/IncidentPostmortemRunner.ts +8 -8
  79. package/Server/Utils/AI/SRE/Insights/Detectors/ErrorLogSpikeDetector.ts +364 -0
  80. package/Server/Utils/AI/SRE/Insights/Detectors/ExceptionSpikeDetector.ts +317 -0
  81. package/Server/Utils/AI/SRE/Insights/Detectors/Index.ts +27 -0
  82. package/Server/Utils/AI/SRE/Insights/Detectors/MetricDriftDetector.ts +221 -0
  83. package/Server/Utils/AI/SRE/Insights/Detectors/NewExceptionDetector.ts +238 -0
  84. package/Server/Utils/AI/SRE/Insights/Detectors/TraceLatencyRegressionDetector.ts +521 -0
  85. package/Server/Utils/AI/SRE/Insights/FixRouting.ts +242 -0
  86. package/Server/Utils/AI/SRE/Insights/InsightScanner.ts +290 -0
  87. package/Server/Utils/AI/SRE/Insights/InsightStore.ts +283 -0
  88. package/Server/Utils/AI/SRE/Insights/InsightTriageRunner.ts +242 -0
  89. package/Server/Utils/AI/SRE/Insights/Triage.ts +162 -0
  90. package/Server/Utils/AI/SRE/Insights/Types.ts +49 -0
  91. package/Server/Utils/AI/SRE/InstrumentationTaskTrigger.ts +212 -0
  92. package/Server/Utils/AI/SRE/InvestigationGrader.ts +282 -0
  93. package/Server/Utils/AI/{Sentinel → SRE}/InvestigationQueue.ts +114 -19
  94. package/Server/Utils/AI/{Sentinel → SRE}/README.md +4 -4
  95. package/Server/Utils/AI/SRE/SubjectCodeFixRun.ts +172 -0
  96. package/Server/Utils/AI/Toolbox/{SentinelActionTools.ts → AIActionTools.ts} +22 -1
  97. package/Server/Utils/AI/Toolbox/Index.ts +2 -2
  98. package/Server/Utils/AnalyticsDatabase/ClickhouseCapacity.ts +526 -0
  99. package/Server/Utils/CodeRepository/GitHub/GitHub.ts +319 -1
  100. package/Server/Utils/CodeRepository/ServiceRepoLinkSuggester.ts +221 -0
  101. package/Server/Utils/CodeRepository/StackTraceRepoResolver.ts +571 -0
  102. package/Server/Utils/Execute.ts +2 -1
  103. package/Server/Utils/LLM/LLMService.ts +160 -30
  104. package/Server/Utils/Monitor/Criteria/SqlMonitorCriteria.ts +152 -0
  105. package/Server/Utils/Monitor/MonitorCriteriaEvaluator.ts +29 -0
  106. package/Tests/Server/Infrastructure/Queue.test.ts +227 -0
  107. package/Tests/Server/Infrastructure/SemaphorePermit.test.ts +159 -0
  108. package/Tests/Server/Services/AIAgentTaskPullRequestOutcomeStats.test.ts +154 -0
  109. package/Tests/Server/Services/AIInsightService.test.ts +324 -0
  110. package/Tests/Server/Services/AIRunCodeFixClaim.test.ts +401 -0
  111. package/Tests/Server/Services/AIRunHumanVerdict.test.ts +161 -0
  112. package/Tests/Server/Services/AIServiceDailyBudget.test.ts +95 -5
  113. package/Tests/Server/Services/AIServiceProjectAccess.test.ts +259 -0
  114. package/Tests/Server/Services/FixFromIncidentTaskTrigger.test.ts +249 -0
  115. package/Tests/Server/Services/FixPerformanceTaskTrigger.test.ts +274 -0
  116. package/Tests/Server/Services/GlobalConfigService.test.ts +80 -0
  117. package/Tests/Server/Services/IncidentInternalNoteAnnouncement.test.ts +1 -1
  118. package/Tests/Server/Services/InstrumentationTaskTrigger.test.ts +313 -0
  119. package/Tests/Server/Services/LlmProviderProjectOwned.test.ts +132 -0
  120. package/Tests/Server/Services/TelemetryExceptionAIFixReadiness.test.ts +405 -0
  121. package/Tests/Server/Services/TelemetryExceptionCodeFixRun.test.ts +322 -0
  122. package/Tests/Server/Services/TraceServiceLatencyProfile.test.ts +278 -0
  123. package/Tests/Server/Types/Workflow/Components/AIGenerateText.test.ts +722 -0
  124. package/Tests/Server/Utils/AI/{SentinelAlertGating.test.ts → AIAlertGating.test.ts} +19 -19
  125. package/Tests/Server/Utils/AI/AIConfidenceSignal.test.ts +362 -0
  126. package/Tests/Server/Utils/AI/{SentinelInvestigationQueue.test.ts → AIInvestigationQueue.test.ts} +19 -19
  127. package/Tests/Server/Utils/AI/CodeAgentWorkspaceGuard.test.ts +138 -0
  128. package/Tests/Server/Utils/AI/CodeFixAgentCompletion.test.ts +335 -0
  129. package/Tests/Server/Utils/AI/CodeFixRunQueue.test.ts +134 -0
  130. package/Tests/Server/Utils/AI/EvalCorpus.test.ts +209 -0
  131. package/Tests/Server/Utils/AI/EvalScores.test.ts +343 -0
  132. package/Tests/Server/Utils/AI/FixRunBudget.test.ts +218 -0
  133. package/Tests/Server/Utils/AI/Insights/ErrorLogSpikeDetector.test.ts +437 -0
  134. package/Tests/Server/Utils/AI/Insights/ExceptionSpikeDetector.test.ts +287 -0
  135. package/Tests/Server/Utils/AI/Insights/InsightDetectorsIndex.test.ts +34 -0
  136. package/Tests/Server/Utils/AI/Insights/InsightFixRouting.test.ts +572 -0
  137. package/Tests/Server/Utils/AI/Insights/InsightNeverThrowsHardening.test.ts +344 -0
  138. package/Tests/Server/Utils/AI/Insights/InsightScanner.test.ts +720 -0
  139. package/Tests/Server/Utils/AI/Insights/InsightStore.test.ts +467 -0
  140. package/Tests/Server/Utils/AI/Insights/InsightStoreHardening.test.ts +370 -0
  141. package/Tests/Server/Utils/AI/Insights/InsightTriage.test.ts +210 -0
  142. package/Tests/Server/Utils/AI/Insights/InsightTriageRunner.test.ts +221 -0
  143. package/Tests/Server/Utils/AI/Insights/InvestigationQueueInsightSubject.test.ts +328 -0
  144. package/Tests/Server/Utils/AI/Insights/MetricBaselineDrift.test.ts +182 -0
  145. package/Tests/Server/Utils/AI/Insights/MetricDriftDetector.test.ts +280 -0
  146. package/Tests/Server/Utils/AI/Insights/NewExceptionDetector.test.ts +259 -0
  147. package/Tests/Server/Utils/AI/Insights/TraceLatencyRegressionDetector.test.ts +770 -0
  148. package/Tests/Server/Utils/AI/InvestigationGrader.test.ts +343 -0
  149. package/Tests/Server/Utils/AI/LLMServiceRequestPolicy.test.ts +307 -0
  150. package/Tests/Server/Utils/AI/OpenPullRequestCap.test.ts +170 -0
  151. package/Tests/Server/Utils/AI/SpanTreeAnalyzer.test.ts +559 -0
  152. package/Tests/Server/Utils/AnalyticsDatabase/ClickhouseCapacity.test.ts +158 -0
  153. package/Tests/Server/Utils/GitHubCheckRunsConclusion.test.ts +100 -0
  154. package/Tests/Server/Utils/GitHubPullRequestStateMapping.test.ts +50 -0
  155. package/Tests/Server/Utils/Monitor/Criteria/SqlMonitorCriteria.test.ts +266 -0
  156. package/Tests/Server/Utils/ServiceRepoLinkSuggester.test.ts +167 -0
  157. package/Tests/Server/Utils/StackTraceRepoResolver.test.ts +527 -0
  158. package/Tests/Types/AI/AIChatPermissionMode.test.ts +112 -0
  159. package/Tests/Types/AI/CodeFixTaskType.test.ts +152 -0
  160. package/Tests/Types/AI/FixPullRequestCiStatus.test.ts +181 -0
  161. package/Tests/Types/Monitor/MonitorStepSqlMonitor.test.ts +110 -0
  162. package/Tests/Types/Monitor/SqlDatabaseType.test.ts +55 -0
  163. package/Tests/Types/Workflow/AIGenerateTextMetadata.test.ts +180 -0
  164. package/Tests/UI/Components/TableBulkCsvExport.test.tsx +168 -0
  165. package/Tests/UI/Utils/TableColumnsToCsv.test.ts +523 -0
  166. package/Types/AI/AIChatTypes.ts +8 -0
  167. package/Types/AI/AIInsightEvidence.ts +77 -0
  168. package/Types/AI/AIInsightHumanVerdict.ts +15 -0
  169. package/Types/AI/AIInsightSeverity.ts +13 -0
  170. package/Types/AI/AIInsightStatus.ts +38 -0
  171. package/Types/AI/AIInsightType.ts +41 -0
  172. package/Types/AI/AIRunAutoGrade.ts +18 -0
  173. package/Types/AI/AIRunEventType.ts +5 -0
  174. package/Types/AI/AIRunHumanVerdict.ts +17 -0
  175. package/Types/AI/AIRunType.ts +6 -0
  176. package/Types/AI/CodeFixTaskContext.ts +88 -0
  177. package/Types/AI/CodeFixTaskType.ts +132 -0
  178. package/Types/AI/FixPullRequestCiStatus.ts +132 -0
  179. package/Types/BaseDatabase/AggregationIntervalUtil.ts +67 -0
  180. package/Types/Incident/IncidentMetricType.ts +7 -0
  181. package/Types/Monitor/CriteriaFilter.ts +8 -0
  182. package/Types/Monitor/MonitorCriteriaInstance.ts +67 -0
  183. package/Types/Monitor/MonitorStep.ts +38 -0
  184. package/Types/Monitor/MonitorStepSqlMonitor.ts +141 -0
  185. package/Types/Monitor/MonitorType.ts +17 -0
  186. package/Types/Monitor/SqlDatabaseType.ts +49 -0
  187. package/Types/Monitor/SqlMonitor/SqlMonitorResponse.ts +28 -0
  188. package/Types/Permission.ts +11 -95
  189. package/Types/Probe/ProbeMonitorResponse.ts +2 -0
  190. package/Types/Runbook/RunbookStep.ts +26 -2
  191. package/Types/Runbook/RunbookStepType.ts +1 -0
  192. package/Types/Workflow/Component.ts +13 -0
  193. package/Types/Workflow/ComponentID.ts +1 -0
  194. package/Types/Workflow/Components/AI.ts +148 -0
  195. package/Types/Workflow/Components.ts +8 -0
  196. package/UI/Components/AI/GenerateFromAIModal.tsx +1 -1
  197. package/UI/Components/Markdown.tsx/MarkdownViewer.tsx +11 -0
  198. package/UI/Components/MoreMenu/MoreMenu.tsx +1 -1
  199. package/UI/Components/Table/Table.tsx +38 -2
  200. package/UI/Utils/TableColumnsToCsv.ts +385 -0
  201. package/Utils/Monitor/MonitorMetricType.ts +1 -0
  202. package/build/dist/Models/DatabaseModels/AIAgentTaskPullRequest.js +59 -45
  203. package/build/dist/Models/DatabaseModels/AIAgentTaskPullRequest.js.map +1 -1
  204. package/build/dist/Models/DatabaseModels/AIInsight.js +795 -0
  205. package/build/dist/Models/DatabaseModels/AIInsight.js.map +1 -0
  206. package/build/dist/Models/DatabaseModels/AIRun.js +274 -0
  207. package/build/dist/Models/DatabaseModels/AIRun.js.map +1 -1
  208. package/build/dist/Models/DatabaseModels/CodeRepository.js +43 -0
  209. package/build/dist/Models/DatabaseModels/CodeRepository.js.map +1 -1
  210. package/build/dist/Models/DatabaseModels/GlobalConfig.js +110 -0
  211. package/build/dist/Models/DatabaseModels/GlobalConfig.js.map +1 -1
  212. package/build/dist/Models/DatabaseModels/Index.js +4 -8
  213. package/build/dist/Models/DatabaseModels/Index.js.map +1 -1
  214. package/build/dist/Models/DatabaseModels/InstanceHealthLog.js +304 -0
  215. package/build/dist/Models/DatabaseModels/InstanceHealthLog.js.map +1 -0
  216. package/build/dist/Models/DatabaseModels/LlmLog.js +35 -0
  217. package/build/dist/Models/DatabaseModels/LlmLog.js.map +1 -1
  218. package/build/dist/Models/DatabaseModels/Project.js +127 -6
  219. package/build/dist/Models/DatabaseModels/Project.js.map +1 -1
  220. package/build/dist/Models/DatabaseModels/Runbook.js +1 -1
  221. package/build/dist/Models/DatabaseModels/Runbook.js.map +1 -1
  222. package/build/dist/Server/API/AIAgentDataAPI.js +568 -85
  223. package/build/dist/Server/API/AIAgentDataAPI.js.map +1 -1
  224. package/build/dist/Server/API/AIAgentTaskAPI.js +100 -44
  225. package/build/dist/Server/API/AIAgentTaskAPI.js.map +1 -1
  226. package/build/dist/Server/API/AIAgentTaskLogAPI.js +49 -25
  227. package/build/dist/Server/API/AIAgentTaskLogAPI.js.map +1 -1
  228. package/build/dist/Server/API/AIAgentTaskPullRequestAPI.js +27 -0
  229. package/build/dist/Server/API/AIAgentTaskPullRequestAPI.js.map +1 -1
  230. package/build/dist/Server/API/AIInsightAPI.js +140 -0
  231. package/build/dist/Server/API/AIInsightAPI.js.map +1 -0
  232. package/build/dist/Server/API/AIInvestigationAPI.js +257 -1
  233. package/build/dist/Server/API/AIInvestigationAPI.js.map +1 -1
  234. package/build/dist/Server/API/CodeFixRunAPI.js +181 -0
  235. package/build/dist/Server/API/CodeFixRunAPI.js.map +1 -0
  236. package/build/dist/Server/API/GitHubAPI.js +164 -2
  237. package/build/dist/Server/API/GitHubAPI.js.map +1 -1
  238. package/build/dist/Server/API/TelemetryExceptionAPI.js +148 -43
  239. package/build/dist/Server/API/TelemetryExceptionAPI.js.map +1 -1
  240. package/build/dist/Server/EnvironmentConfig.js +1 -1
  241. package/build/dist/Server/EnvironmentConfig.js.map +1 -1
  242. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1783943300000-DropServiceCodeRepository.js +23 -0
  243. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1783943300000-DropServiceCodeRepository.js.map +1 -0
  244. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1783947444597-CodeFixRunsOnAIRun.js +32 -0
  245. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1783947444597-CodeFixRunsOnAIRun.js.map +1 -0
  246. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1783950962813-AddCodeFixTaskType.js +16 -0
  247. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1783950962813-AddCodeFixTaskType.js.map +1 -0
  248. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1783954040984-AddInstrumentationFixTasksFlag.js +16 -0
  249. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1783954040984-AddInstrumentationFixTasksFlag.js.map +1 -0
  250. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1783957160597-MigrationName.js +24 -0
  251. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1783957160597-MigrationName.js.map +1 -0
  252. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1783958542237-AddTaskContextToAIRun.js +16 -0
  253. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1783958542237-AddTaskContextToAIRun.js.map +1 -0
  254. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1783965945957-AddInvestigationVerdictAndGrade.js +24 -0
  255. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1783965945957-AddInvestigationVerdictAndGrade.js.map +1 -0
  256. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1783970619301-AddFixGuardrailColumns.js +24 -0
  257. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1783970619301-AddFixGuardrailColumns.js.map +1 -0
  258. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1783970619302-DropLegacyAIAgentTaskTables.js +24 -0
  259. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1783970619302-DropLegacyAIAgentTaskTables.js.map +1 -0
  260. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1783977781677-AddCiStatusToFixPullRequests.js +18 -0
  261. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1783977781677-AddCiStatusToFixPullRequests.js.map +1 -0
  262. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1783990000000-AddCompletionTokensToLlmLog.js +18 -0
  263. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1783990000000-AddCompletionTokensToLlmLog.js.map +1 -0
  264. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784010274993-AddSentinelInsight.js +32 -0
  265. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784010274993-AddSentinelInsight.js.map +1 -0
  266. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784010274994-AddSentinelInsightFlags.js +18 -0
  267. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784010274994-AddSentinelInsightFlags.js.map +1 -0
  268. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784030612266-RenameSentinelToAI.js +125 -0
  269. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784030612266-RenameSentinelToAI.js.map +1 -0
  270. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784033837629-MigrationName.js +62 -0
  271. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/1784033837629-MigrationName.js.map +1 -0
  272. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/Index.js +30 -0
  273. package/build/dist/Server/Infrastructure/Postgres/SchemaMigrations/Index.js.map +1 -1
  274. package/build/dist/Server/Infrastructure/Queue.js +73 -3
  275. package/build/dist/Server/Infrastructure/Queue.js.map +1 -1
  276. package/build/dist/Server/Infrastructure/Semaphore.js +44 -1
  277. package/build/dist/Server/Infrastructure/Semaphore.js.map +1 -1
  278. package/build/dist/Server/Services/AIAgentService.js +29 -0
  279. package/build/dist/Server/Services/AIAgentService.js.map +1 -1
  280. package/build/dist/Server/Services/AIAgentTaskPullRequestService.js +78 -0
  281. package/build/dist/Server/Services/AIAgentTaskPullRequestService.js.map +1 -1
  282. package/build/dist/Server/Services/AIInsightService.js +164 -0
  283. package/build/dist/Server/Services/AIInsightService.js.map +1 -0
  284. package/build/dist/Server/Services/AIRunEventService.js +49 -0
  285. package/build/dist/Server/Services/AIRunEventService.js.map +1 -1
  286. package/build/dist/Server/Services/AIRunService.js +221 -0
  287. package/build/dist/Server/Services/AIRunService.js.map +1 -1
  288. package/build/dist/Server/Services/AIService.js +198 -11
  289. package/build/dist/Server/Services/AIService.js.map +1 -1
  290. package/build/dist/Server/Services/AlertService.js +4 -4
  291. package/build/dist/Server/Services/AlertService.js.map +1 -1
  292. package/build/dist/Server/Services/CodeRepositoryService.js +180 -0
  293. package/build/dist/Server/Services/CodeRepositoryService.js.map +1 -1
  294. package/build/dist/Server/Services/GlobalConfigService.js +84 -0
  295. package/build/dist/Server/Services/GlobalConfigService.js.map +1 -1
  296. package/build/dist/Server/Services/IncidentService.js +149 -37
  297. package/build/dist/Server/Services/IncidentService.js.map +1 -1
  298. package/build/dist/Server/Services/IncidentStateTimelineService.js +24 -4
  299. package/build/dist/Server/Services/IncidentStateTimelineService.js.map +1 -1
  300. package/build/dist/Server/Services/Index.js +4 -4
  301. package/build/dist/Server/Services/Index.js.map +1 -1
  302. package/build/dist/Server/Services/{AIAgentTaskLogService.js → InstanceHealthLogService.js} +2 -2
  303. package/build/dist/Server/Services/InstanceHealthLogService.js.map +1 -0
  304. package/build/dist/Server/Services/LlmLogService.js +23 -0
  305. package/build/dist/Server/Services/LlmLogService.js.map +1 -1
  306. package/build/dist/Server/Services/LlmProviderService.js +96 -0
  307. package/build/dist/Server/Services/LlmProviderService.js.map +1 -1
  308. package/build/dist/Server/Services/MetricBaselineService.js +65 -0
  309. package/build/dist/Server/Services/MetricBaselineService.js.map +1 -1
  310. package/build/dist/Server/Services/MonitorService.js +9 -1
  311. package/build/dist/Server/Services/MonitorService.js.map +1 -1
  312. package/build/dist/Server/Services/TelemetryExceptionService.js +243 -82
  313. package/build/dist/Server/Services/TelemetryExceptionService.js.map +1 -1
  314. package/build/dist/Server/Services/TraceAggregationService.js +124 -0
  315. package/build/dist/Server/Services/TraceAggregationService.js.map +1 -1
  316. package/build/dist/Server/Types/Workflow/ComponentCode.js.map +1 -1
  317. package/build/dist/Server/Types/Workflow/Components/AI/GenerateText.js +240 -0
  318. package/build/dist/Server/Types/Workflow/Components/AI/GenerateText.js.map +1 -0
  319. package/build/dist/Server/Types/Workflow/Components/Index.js +2 -0
  320. package/build/dist/Server/Types/Workflow/Components/Index.js.map +1 -1
  321. package/build/dist/Server/Utils/AI/CodeFix/CodeAgentWorkspaceGuard.js +48 -0
  322. package/build/dist/Server/Utils/AI/CodeFix/CodeAgentWorkspaceGuard.js.map +1 -0
  323. package/build/dist/Server/Utils/AI/CodeFix/CodeFixAgentCompletion.js +174 -0
  324. package/build/dist/Server/Utils/AI/CodeFix/CodeFixAgentCompletion.js.map +1 -0
  325. package/build/dist/Server/Utils/AI/CodeFix/CodeFixRunQueue.js +126 -0
  326. package/build/dist/Server/Utils/AI/CodeFix/CodeFixRunQueue.js.map +1 -0
  327. package/build/dist/Server/Utils/AI/CodeFix/FixRunBudget.js +131 -0
  328. package/build/dist/Server/Utils/AI/CodeFix/FixRunBudget.js.map +1 -0
  329. package/build/dist/Server/Utils/AI/CodeFix/OpenPullRequestCap.js +99 -0
  330. package/build/dist/Server/Utils/AI/CodeFix/OpenPullRequestCap.js.map +1 -0
  331. package/build/dist/Server/Utils/AI/Eval/EvalCorpus.js +245 -0
  332. package/build/dist/Server/Utils/AI/Eval/EvalCorpus.js.map +1 -0
  333. package/build/dist/Server/Utils/AI/Eval/EvalScores.js +83 -0
  334. package/build/dist/Server/Utils/AI/Eval/EvalScores.js.map +1 -0
  335. package/build/dist/Server/Utils/AI/Eval/ReplayInvestigation.js +12 -0
  336. package/build/dist/Server/Utils/AI/Eval/ReplayInvestigation.js.map +1 -0
  337. package/build/dist/Server/Utils/AI/PerfEvidence/SpanTreeAnalyzer.js +439 -0
  338. package/build/dist/Server/Utils/AI/PerfEvidence/SpanTreeAnalyzer.js.map +1 -0
  339. package/build/dist/Server/Utils/AI/{Sentinel/SentinelInvestigationEngine.js → SRE/AIInvestigationEngine.js} +47 -31
  340. package/build/dist/Server/Utils/AI/SRE/AIInvestigationEngine.js.map +1 -0
  341. package/build/dist/Server/Utils/AI/{Sentinel/SentinelMemory.js → SRE/AIMemory.js} +5 -5
  342. package/build/dist/Server/Utils/AI/SRE/AIMemory.js.map +1 -0
  343. package/build/dist/Server/Utils/AI/{Sentinel → SRE}/AlertInvestigationRunner.js +42 -19
  344. package/build/dist/Server/Utils/AI/SRE/AlertInvestigationRunner.js.map +1 -0
  345. package/build/dist/Server/Utils/AI/SRE/ConfidenceSignal.js +226 -0
  346. package/build/dist/Server/Utils/AI/SRE/ConfidenceSignal.js.map +1 -0
  347. package/build/dist/Server/Utils/AI/SRE/FixFromIncidentTaskTrigger.js +100 -0
  348. package/build/dist/Server/Utils/AI/SRE/FixFromIncidentTaskTrigger.js.map +1 -0
  349. package/build/dist/Server/Utils/AI/SRE/FixPerformanceTaskTrigger.js +174 -0
  350. package/build/dist/Server/Utils/AI/SRE/FixPerformanceTaskTrigger.js.map +1 -0
  351. package/build/dist/Server/Utils/AI/{Sentinel → SRE}/IncidentInvestigationRunner.js +60 -22
  352. package/build/dist/Server/Utils/AI/SRE/IncidentInvestigationRunner.js.map +1 -0
  353. package/build/dist/Server/Utils/AI/{Sentinel → SRE}/IncidentPostmortemRunner.js +9 -9
  354. package/build/dist/Server/Utils/AI/SRE/IncidentPostmortemRunner.js.map +1 -0
  355. package/build/dist/Server/Utils/AI/SRE/Insights/Detectors/ErrorLogSpikeDetector.js +268 -0
  356. package/build/dist/Server/Utils/AI/SRE/Insights/Detectors/ErrorLogSpikeDetector.js.map +1 -0
  357. package/build/dist/Server/Utils/AI/SRE/Insights/Detectors/ExceptionSpikeDetector.js +226 -0
  358. package/build/dist/Server/Utils/AI/SRE/Insights/Detectors/ExceptionSpikeDetector.js.map +1 -0
  359. package/build/dist/Server/Utils/AI/SRE/Insights/Detectors/Index.js +26 -0
  360. package/build/dist/Server/Utils/AI/SRE/Insights/Detectors/Index.js.map +1 -0
  361. package/build/dist/Server/Utils/AI/SRE/Insights/Detectors/MetricDriftDetector.js +159 -0
  362. package/build/dist/Server/Utils/AI/SRE/Insights/Detectors/MetricDriftDetector.js.map +1 -0
  363. package/build/dist/Server/Utils/AI/SRE/Insights/Detectors/NewExceptionDetector.js +177 -0
  364. package/build/dist/Server/Utils/AI/SRE/Insights/Detectors/NewExceptionDetector.js.map +1 -0
  365. package/build/dist/Server/Utils/AI/SRE/Insights/Detectors/TraceLatencyRegressionDetector.js +384 -0
  366. package/build/dist/Server/Utils/AI/SRE/Insights/Detectors/TraceLatencyRegressionDetector.js.map +1 -0
  367. package/build/dist/Server/Utils/AI/SRE/Insights/FixRouting.js +180 -0
  368. package/build/dist/Server/Utils/AI/SRE/Insights/FixRouting.js.map +1 -0
  369. package/build/dist/Server/Utils/AI/SRE/Insights/InsightScanner.js +269 -0
  370. package/build/dist/Server/Utils/AI/SRE/Insights/InsightScanner.js.map +1 -0
  371. package/build/dist/Server/Utils/AI/SRE/Insights/InsightStore.js +231 -0
  372. package/build/dist/Server/Utils/AI/SRE/Insights/InsightStore.js.map +1 -0
  373. package/build/dist/Server/Utils/AI/SRE/Insights/InsightTriageRunner.js +206 -0
  374. package/build/dist/Server/Utils/AI/SRE/Insights/InsightTriageRunner.js.map +1 -0
  375. package/build/dist/Server/Utils/AI/SRE/Insights/Triage.js +121 -0
  376. package/build/dist/Server/Utils/AI/SRE/Insights/Triage.js.map +1 -0
  377. package/build/dist/Server/Utils/AI/SRE/Insights/Types.js +2 -0
  378. package/build/dist/Server/Utils/AI/SRE/Insights/Types.js.map +1 -0
  379. package/build/dist/Server/Utils/AI/SRE/InstrumentationTaskTrigger.js +148 -0
  380. package/build/dist/Server/Utils/AI/SRE/InstrumentationTaskTrigger.js.map +1 -0
  381. package/build/dist/Server/Utils/AI/SRE/InvestigationGrader.js +231 -0
  382. package/build/dist/Server/Utils/AI/SRE/InvestigationGrader.js.map +1 -0
  383. package/build/dist/Server/Utils/AI/{Sentinel → SRE}/InvestigationQueue.js +102 -23
  384. package/build/dist/Server/Utils/AI/SRE/InvestigationQueue.js.map +1 -0
  385. package/build/dist/Server/Utils/AI/SRE/SubjectCodeFixRun.js +167 -0
  386. package/build/dist/Server/Utils/AI/SRE/SubjectCodeFixRun.js.map +1 -0
  387. package/build/dist/Server/Utils/AI/Toolbox/{SentinelActionTools.js → AIActionTools.js} +18 -2
  388. package/build/dist/Server/Utils/AI/Toolbox/AIActionTools.js.map +1 -0
  389. package/build/dist/Server/Utils/AI/Toolbox/Index.js +2 -2
  390. package/build/dist/Server/Utils/AI/Toolbox/Index.js.map +1 -1
  391. package/build/dist/Server/Utils/AnalyticsDatabase/ClickhouseCapacity.js +301 -0
  392. package/build/dist/Server/Utils/AnalyticsDatabase/ClickhouseCapacity.js.map +1 -0
  393. package/build/dist/Server/Utils/CodeRepository/GitHub/GitHub.js +240 -2
  394. package/build/dist/Server/Utils/CodeRepository/GitHub/GitHub.js.map +1 -1
  395. package/build/dist/Server/Utils/CodeRepository/ServiceRepoLinkSuggester.js +127 -0
  396. package/build/dist/Server/Utils/CodeRepository/ServiceRepoLinkSuggester.js.map +1 -0
  397. package/build/dist/Server/Utils/CodeRepository/StackTraceRepoResolver.js +336 -0
  398. package/build/dist/Server/Utils/CodeRepository/StackTraceRepoResolver.js.map +1 -0
  399. package/build/dist/Server/Utils/Execute.js.map +1 -1
  400. package/build/dist/Server/Utils/LLM/LLMService.js +125 -25
  401. package/build/dist/Server/Utils/LLM/LLMService.js.map +1 -1
  402. package/build/dist/Server/Utils/Monitor/Criteria/SqlMonitorCriteria.js +120 -0
  403. package/build/dist/Server/Utils/Monitor/Criteria/SqlMonitorCriteria.js.map +1 -0
  404. package/build/dist/Server/Utils/Monitor/MonitorCriteriaEvaluator.js +21 -0
  405. package/build/dist/Server/Utils/Monitor/MonitorCriteriaEvaluator.js.map +1 -1
  406. package/build/dist/Types/AI/AIInsightEvidence.js +2 -0
  407. package/build/dist/Types/AI/AIInsightEvidence.js.map +1 -0
  408. package/build/dist/Types/AI/AIInsightHumanVerdict.js +16 -0
  409. package/build/dist/Types/AI/AIInsightHumanVerdict.js.map +1 -0
  410. package/build/dist/Types/AI/AIInsightSeverity.js +14 -0
  411. package/build/dist/Types/AI/AIInsightSeverity.js.map +1 -0
  412. package/build/dist/Types/AI/AIInsightStatus.js +36 -0
  413. package/build/dist/Types/AI/AIInsightStatus.js.map +1 -0
  414. package/build/dist/Types/AI/AIInsightType.js +42 -0
  415. package/build/dist/Types/AI/AIInsightType.js.map +1 -0
  416. package/build/dist/Types/AI/AIRunAutoGrade.js +19 -0
  417. package/build/dist/Types/AI/AIRunAutoGrade.js.map +1 -0
  418. package/build/dist/Types/AI/AIRunEventType.js +5 -0
  419. package/build/dist/Types/AI/AIRunEventType.js.map +1 -1
  420. package/build/dist/Types/AI/AIRunHumanVerdict.js +18 -0
  421. package/build/dist/Types/AI/AIRunHumanVerdict.js.map +1 -0
  422. package/build/dist/Types/AI/AIRunType.js +6 -0
  423. package/build/dist/Types/AI/AIRunType.js.map +1 -1
  424. package/build/dist/Types/AI/CodeFixTaskContext.js +29 -0
  425. package/build/dist/Types/AI/CodeFixTaskContext.js.map +1 -0
  426. package/build/dist/Types/AI/CodeFixTaskType.js +122 -0
  427. package/build/dist/Types/AI/CodeFixTaskType.js.map +1 -0
  428. package/build/dist/Types/AI/FixPullRequestCiStatus.js +102 -0
  429. package/build/dist/Types/AI/FixPullRequestCiStatus.js.map +1 -0
  430. package/build/dist/Types/BaseDatabase/AggregationIntervalUtil.js +55 -0
  431. package/build/dist/Types/BaseDatabase/AggregationIntervalUtil.js.map +1 -1
  432. package/build/dist/Types/Incident/IncidentMetricType.js +7 -0
  433. package/build/dist/Types/Incident/IncidentMetricType.js.map +1 -1
  434. package/build/dist/Types/Monitor/CriteriaFilter.js +7 -0
  435. package/build/dist/Types/Monitor/CriteriaFilter.js.map +1 -1
  436. package/build/dist/Types/Monitor/MonitorCriteriaInstance.js +62 -0
  437. package/build/dist/Types/Monitor/MonitorCriteriaInstance.js.map +1 -1
  438. package/build/dist/Types/Monitor/MonitorStep.js +28 -0
  439. package/build/dist/Types/Monitor/MonitorStep.js.map +1 -1
  440. package/build/dist/Types/Monitor/MonitorStepSqlMonitor.js +93 -0
  441. package/build/dist/Types/Monitor/MonitorStepSqlMonitor.js.map +1 -0
  442. package/build/dist/Types/Monitor/MonitorType.js +15 -0
  443. package/build/dist/Types/Monitor/MonitorType.js.map +1 -1
  444. package/build/dist/Types/Monitor/SqlDatabaseType.js +47 -0
  445. package/build/dist/Types/Monitor/SqlDatabaseType.js.map +1 -0
  446. package/build/dist/Types/Monitor/SqlMonitor/SqlMonitorResponse.js +2 -0
  447. package/build/dist/Types/Monitor/SqlMonitor/SqlMonitorResponse.js.map +1 -0
  448. package/build/dist/Types/Permission.js +10 -84
  449. package/build/dist/Types/Permission.js.map +1 -1
  450. package/build/dist/Types/Runbook/RunbookStepType.js +1 -0
  451. package/build/dist/Types/Runbook/RunbookStepType.js.map +1 -1
  452. package/build/dist/Types/Workflow/ComponentID.js +1 -0
  453. package/build/dist/Types/Workflow/ComponentID.js.map +1 -1
  454. package/build/dist/Types/Workflow/Components/AI.js +135 -0
  455. package/build/dist/Types/Workflow/Components/AI.js.map +1 -0
  456. package/build/dist/Types/Workflow/Components.js +7 -0
  457. package/build/dist/Types/Workflow/Components.js.map +1 -1
  458. package/build/dist/UI/Components/AI/GenerateFromAIModal.js +1 -1
  459. package/build/dist/UI/Components/AI/GenerateFromAIModal.js.map +1 -1
  460. package/build/dist/UI/Components/Markdown.tsx/MarkdownViewer.js +9 -0
  461. package/build/dist/UI/Components/Markdown.tsx/MarkdownViewer.js.map +1 -1
  462. package/build/dist/UI/Components/MoreMenu/MoreMenu.js +1 -1
  463. package/build/dist/UI/Components/Table/Table.js +28 -2
  464. package/build/dist/UI/Components/Table/Table.js.map +1 -1
  465. package/build/dist/UI/Utils/TableColumnsToCsv.js +291 -0
  466. package/build/dist/UI/Utils/TableColumnsToCsv.js.map +1 -0
  467. package/build/dist/Utils/Monitor/MonitorMetricType.js +1 -0
  468. package/build/dist/Utils/Monitor/MonitorMetricType.js.map +1 -1
  469. package/package.json +1 -1
  470. package/Models/DatabaseModels/AIAgentTask.ts +0 -660
  471. package/Models/DatabaseModels/AIAgentTaskLog.ts +0 -426
  472. package/Models/DatabaseModels/AIAgentTaskTelemetryException.ts +0 -399
  473. package/Models/DatabaseModels/ServiceCodeRepository.ts +0 -647
  474. package/Server/Services/AIAgentTaskService.ts +0 -240
  475. package/Server/Services/AIAgentTaskTelemetryExceptionService.ts +0 -39
  476. package/Server/Services/ServiceCodeRepositoryService.ts +0 -55
  477. package/Tests/Server/Services/AIAgentTaskServiceClaim.test.ts +0 -146
  478. package/Types/AI/AIAgentTaskMetadata.ts +0 -25
  479. package/Types/AI/AIAgentTaskType.ts +0 -40
  480. package/build/dist/Models/DatabaseModels/AIAgentTask.js +0 -691
  481. package/build/dist/Models/DatabaseModels/AIAgentTask.js.map +0 -1
  482. package/build/dist/Models/DatabaseModels/AIAgentTaskLog.js +0 -447
  483. package/build/dist/Models/DatabaseModels/AIAgentTaskLog.js.map +0 -1
  484. package/build/dist/Models/DatabaseModels/AIAgentTaskTelemetryException.js +0 -415
  485. package/build/dist/Models/DatabaseModels/AIAgentTaskTelemetryException.js.map +0 -1
  486. package/build/dist/Models/DatabaseModels/ServiceCodeRepository.js +0 -665
  487. package/build/dist/Models/DatabaseModels/ServiceCodeRepository.js.map +0 -1
  488. package/build/dist/Server/Services/AIAgentTaskLogService.js.map +0 -1
  489. package/build/dist/Server/Services/AIAgentTaskService.js +0 -217
  490. package/build/dist/Server/Services/AIAgentTaskService.js.map +0 -1
  491. package/build/dist/Server/Services/AIAgentTaskTelemetryExceptionService.js +0 -36
  492. package/build/dist/Server/Services/AIAgentTaskTelemetryExceptionService.js.map +0 -1
  493. package/build/dist/Server/Services/ServiceCodeRepositoryService.js +0 -54
  494. package/build/dist/Server/Services/ServiceCodeRepositoryService.js.map +0 -1
  495. package/build/dist/Server/Utils/AI/Sentinel/AlertInvestigationRunner.js.map +0 -1
  496. package/build/dist/Server/Utils/AI/Sentinel/IncidentInvestigationRunner.js.map +0 -1
  497. package/build/dist/Server/Utils/AI/Sentinel/IncidentPostmortemRunner.js.map +0 -1
  498. package/build/dist/Server/Utils/AI/Sentinel/InvestigationQueue.js.map +0 -1
  499. package/build/dist/Server/Utils/AI/Sentinel/SentinelInvestigationEngine.js.map +0 -1
  500. package/build/dist/Server/Utils/AI/Sentinel/SentinelMemory.js.map +0 -1
  501. package/build/dist/Server/Utils/AI/Toolbox/SentinelActionTools.js.map +0 -1
  502. package/build/dist/Types/AI/AIAgentTaskMetadata.js +0 -6
  503. package/build/dist/Types/AI/AIAgentTaskMetadata.js.map +0 -1
  504. package/build/dist/Types/AI/AIAgentTaskType.js +0 -29
  505. package/build/dist/Types/AI/AIAgentTaskType.js.map +0 -1
@@ -0,0 +1,36 @@
1
+ /*
2
+ * Lifecycle of a AIInsight. Stored on AIInsight.status and
3
+ * filtered on in the dashboard, so these strings are a wire contract — do
4
+ * not rename them.
5
+ *
6
+ * Detected is the defensive initial state — the scanner routes every newly
7
+ * created insight to ActionRequired or FixOpened in the same tick, so a row
8
+ * only stays Detected if routing crashed mid-scan. Resolved and Dismissed
9
+ * are human actions (the terminal states).
10
+ */
11
+ var AIInsightStatus;
12
+ (function (AIInsightStatus) {
13
+ // Just created by a detector; routed onward in the same scanner tick.
14
+ AIInsightStatus["Detected"] = "Detected";
15
+ // Waiting on a human: no automatic fix was opened for this insight.
16
+ AIInsightStatus["ActionRequired"] = "ActionRequired";
17
+ // An AI fix task was queued for this insight (see fixAiRunId).
18
+ AIInsightStatus["FixOpened"] = "FixOpened";
19
+ // A human marked the insight as handled. Terminal.
20
+ AIInsightStatus["Resolved"] = "Resolved";
21
+ // A human dismissed the insight as noise/not actionable. Terminal.
22
+ AIInsightStatus["Dismissed"] = "Dismissed";
23
+ })(AIInsightStatus || (AIInsightStatus = {}));
24
+ export default AIInsightStatus;
25
+ export class AIInsightStatusHelper {
26
+ /*
27
+ * Terminal = Resolved | Dismissed — the two human end states. The scanner
28
+ * only refreshes (dedupes into) NON-terminal insights; a terminal insight
29
+ * is never reopened by a detector.
30
+ */
31
+ static isTerminalStatus(status) {
32
+ return (status === AIInsightStatus.Resolved ||
33
+ status === AIInsightStatus.Dismissed);
34
+ }
35
+ }
36
+ //# sourceMappingURL=AIInsightStatus.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AIInsightStatus.js","sourceRoot":"","sources":["../../../../Types/AI/AIInsightStatus.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,IAAK,eAWJ;AAXD,WAAK,eAAe;IAClB,sEAAsE;IACtE,wCAAqB,CAAA;IACrB,oEAAoE;IACpE,oDAAiC,CAAA;IACjC,+DAA+D;IAC/D,0CAAuB,CAAA;IACvB,mDAAmD;IACnD,wCAAqB,CAAA;IACrB,mEAAmE;IACnE,0CAAuB,CAAA;AACzB,CAAC,EAXI,eAAe,KAAf,eAAe,QAWnB;AAED,eAAe,eAAe,CAAC;AAE/B,MAAM,OAAO,qBAAqB;IAChC;;;;OAIG;IACI,MAAM,CAAC,gBAAgB,CAAC,MAAuB;QACpD,OAAO,CACL,MAAM,KAAK,eAAe,CAAC,QAAQ;YACnC,MAAM,KAAK,eAAe,CAAC,SAAS,CACrC,CAAC;IACJ,CAAC;CACF"}
@@ -0,0 +1,42 @@
1
+ /*
2
+ * Which deterministic AI detector produced an insight. Detectors are
3
+ * statistical sensors over the project's telemetry — no LLM is involved in
4
+ * detection. These strings are stored on AIInsight.insightType and
5
+ * rendered/filtered in the dashboard, so they are a wire contract — do not
6
+ * rename them.
7
+ */
8
+ var AIInsightType;
9
+ (function (AIInsightType) {
10
+ /*
11
+ * A telemetry exception first seen within the last 24 hours that is
12
+ * already recurring (not resolved, not archived) — a brand-new failure
13
+ * mode in the code.
14
+ */
15
+ AIInsightType["NewException"] = "NewException";
16
+ /*
17
+ * An established telemetry exception whose recent hourly occurrence rate
18
+ * spiked well above its own 24-hour baseline (including dormant
19
+ * exceptions suddenly waking up).
20
+ */
21
+ AIInsightType["ExceptionSpike"] = "ExceptionSpike";
22
+ /*
23
+ * The project's Error/Fatal log volume in the last hour spiked well above
24
+ * its average hourly rate over the prior 24 hours, attributed to the top
25
+ * contributing services.
26
+ */
27
+ AIInsightType["ErrorLogSpike"] = "ErrorLogSpike";
28
+ /*
29
+ * A service's recent p99 span latency regressed to a multiple of its own
30
+ * 24-hour baseline, with span-tree findings drilled from a representative
31
+ * slow trace.
32
+ */
33
+ AIInsightType["TraceLatencyRegression"] = "TraceLatencyRegression";
34
+ /*
35
+ * A metric's mean over the last 7 days drifted substantially from its
36
+ * mean over the prior 7 days (week-over-week comparison per metric name
37
+ * and entity).
38
+ */
39
+ AIInsightType["MetricDrift"] = "MetricDrift";
40
+ })(AIInsightType || (AIInsightType = {}));
41
+ export default AIInsightType;
42
+ //# sourceMappingURL=AIInsightType.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AIInsightType.js","sourceRoot":"","sources":["../../../../Types/AI/AIInsightType.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AACH,IAAK,aA+BJ;AA/BD,WAAK,aAAa;IAChB;;;;OAIG;IACH,8CAA6B,CAAA;IAC7B;;;;OAIG;IACH,kDAAiC,CAAA;IACjC;;;;OAIG;IACH,gDAA+B,CAAA;IAC/B;;;;OAIG;IACH,kEAAiD,CAAA;IACjD;;;;OAIG;IACH,4CAA2B,CAAA;AAC7B,CAAC,EA/BI,aAAa,KAAb,aAAa,QA+BjB;AAED,eAAe,aAAa,CAAC"}
@@ -0,0 +1,19 @@
1
+ /*
2
+ * The automatic grade assigned to a completed AI investigation when its
3
+ * incident resolves with a human-recorded root cause (Phase 2 measurement
4
+ * layer): one constrained LLM call compares the investigation's posted
5
+ * analysis with Incident.rootCause and stores the verdict on the run
6
+ * (AIRun.autoGrade). See
7
+ * Common/Server/Utils/AI/SRE/InvestigationGrader.ts.
8
+ */
9
+ var AIRunAutoGrade;
10
+ (function (AIRunAutoGrade) {
11
+ // The analysis identified the same root cause the humans recorded.
12
+ AIRunAutoGrade["Match"] = "Match";
13
+ // Part of the cause, or a closely related cause.
14
+ AIRunAutoGrade["Partial"] = "Partial";
15
+ // The analysis pointed somewhere else.
16
+ AIRunAutoGrade["Mismatch"] = "Mismatch";
17
+ })(AIRunAutoGrade || (AIRunAutoGrade = {}));
18
+ export default AIRunAutoGrade;
19
+ //# sourceMappingURL=AIRunAutoGrade.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AIRunAutoGrade.js","sourceRoot":"","sources":["../../../../Types/AI/AIRunAutoGrade.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AACH,IAAK,cAOJ;AAPD,WAAK,cAAc;IACjB,mEAAmE;IACnE,iCAAe,CAAA;IACf,iDAAiD;IACjD,qCAAmB,CAAA;IACnB,uCAAuC;IACvC,uCAAqB,CAAA;AACvB,CAAC,EAPI,cAAc,KAAd,cAAc,QAOlB;AAED,eAAe,cAAc,CAAC"}
@@ -11,6 +11,11 @@ var AIRunEventType;
11
11
  // A mutating action the user approved was executed (or denied and skipped).
12
12
  AIRunEventType["ActionExecuted"] = "ActionExecuted";
13
13
  AIRunEventType["ActionDenied"] = "ActionDenied";
14
+ /*
15
+ * A plain progress/log line reported by an external executor (e.g. the
16
+ * code-fix agent container). The message lives in resultSummary.message.
17
+ */
18
+ AIRunEventType["ProgressLog"] = "ProgressLog";
14
19
  AIRunEventType["RunCompleted"] = "RunCompleted";
15
20
  AIRunEventType["RunFailed"] = "RunFailed";
16
21
  })(AIRunEventType || (AIRunEventType = {}));
@@ -1 +1 @@
1
- {"version":3,"file":"AIRunEventType.js","sourceRoot":"","sources":["../../../../Types/AI/AIRunEventType.ts"],"names":[],"mappings":"AAAA,IAAK,cAcJ;AAdD,WAAK,cAAc;IACjB,2CAAyB,CAAA;IACzB,mDAAiC,CAAA;IACjC,uDAAqC,CAAA;IACrC,qDAAmC,CAAA;IACnC,yDAAuC,CAAA;IACvC,mDAAiC,CAAA;IACjC,0EAA0E;IAC1E,yDAAuC,CAAA;IACvC,4EAA4E;IAC5E,mDAAiC,CAAA;IACjC,+CAA6B,CAAA;IAC7B,+CAA6B,CAAA;IAC7B,yCAAuB,CAAA;AACzB,CAAC,EAdI,cAAc,KAAd,cAAc,QAclB;AAED,eAAe,cAAc,CAAC"}
1
+ {"version":3,"file":"AIRunEventType.js","sourceRoot":"","sources":["../../../../Types/AI/AIRunEventType.ts"],"names":[],"mappings":"AAAA,IAAK,cAmBJ;AAnBD,WAAK,cAAc;IACjB,2CAAyB,CAAA;IACzB,mDAAiC,CAAA;IACjC,uDAAqC,CAAA;IACrC,qDAAmC,CAAA;IACnC,yDAAuC,CAAA;IACvC,mDAAiC,CAAA;IACjC,0EAA0E;IAC1E,yDAAuC,CAAA;IACvC,4EAA4E;IAC5E,mDAAiC,CAAA;IACjC,+CAA6B,CAAA;IAC7B;;;OAGG;IACH,6CAA2B,CAAA;IAC3B,+CAA6B,CAAA;IAC7B,yCAAuB,CAAA;AACzB,CAAC,EAnBI,cAAc,KAAd,cAAc,QAmBlB;AAED,eAAe,cAAc,CAAC"}
@@ -0,0 +1,18 @@
1
+ /*
2
+ * The one-click human verdict on a completed AI investigation's posted
3
+ * analysis (Phase 2 measurement layer). Captured via
4
+ * POST /ai-investigation/verdict from the investigation panel and stored on
5
+ * the run (AIRun.humanVerdict).
6
+ *
7
+ * The roadmap's "confirmed/edited/rejected" trichotomy is deliberately a
8
+ * two-button UI: "edited" is not something a human declares up front — it is
9
+ * detected later by the grading side (comparing the analysis with the final
10
+ * recorded root cause), so the human control stays a binary confirm/reject.
11
+ */
12
+ var AIRunHumanVerdict;
13
+ (function (AIRunHumanVerdict) {
14
+ AIRunHumanVerdict["Confirmed"] = "Confirmed";
15
+ AIRunHumanVerdict["Rejected"] = "Rejected";
16
+ })(AIRunHumanVerdict || (AIRunHumanVerdict = {}));
17
+ export default AIRunHumanVerdict;
18
+ //# sourceMappingURL=AIRunHumanVerdict.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"AIRunHumanVerdict.js","sourceRoot":"","sources":["../../../../Types/AI/AIRunHumanVerdict.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AACH,IAAK,iBAGJ;AAHD,WAAK,iBAAiB;IACpB,4CAAuB,CAAA;IACvB,0CAAqB,CAAA;AACvB,CAAC,EAHI,iBAAiB,KAAjB,iBAAiB,QAGrB;AAED,eAAe,iBAAiB,CAAC"}
@@ -2,6 +2,12 @@ var AIRunType;
2
2
  (function (AIRunType) {
3
3
  AIRunType["Chat"] = "Chat";
4
4
  AIRunType["Investigation"] = "Investigation";
5
+ /*
6
+ * An exception-fix run executed by an external AI agent container: it
7
+ * claims the run over HTTP, works in the project's code repository and
8
+ * opens a pull request. Replaces the legacy AIAgentTask substrate.
9
+ */
10
+ AIRunType["CodeFix"] = "CodeFix";
5
11
  })(AIRunType || (AIRunType = {}));
6
12
  export default AIRunType;
7
13
  //# sourceMappingURL=AIRunType.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"AIRunType.js","sourceRoot":"","sources":["../../../../Types/AI/AIRunType.ts"],"names":[],"mappings":"AAAA,IAAK,SAGJ;AAHD,WAAK,SAAS;IACZ,0BAAa,CAAA;IACb,4CAA+B,CAAA;AACjC,CAAC,EAHI,SAAS,KAAT,SAAS,QAGb;AAED,eAAe,SAAS,CAAC"}
1
+ {"version":3,"file":"AIRunType.js","sourceRoot":"","sources":["../../../../Types/AI/AIRunType.ts"],"names":[],"mappings":"AAAA,IAAK,SASJ;AATD,WAAK,SAAS;IACZ,0BAAa,CAAA;IACb,4CAA+B,CAAA;IAC/B;;;;OAIG;IACH,gCAAmB,CAAA;AACrB,CAAC,EATI,SAAS,KAAT,SAAS,QASb;AAED,eAAe,SAAS,CAAC"}
@@ -0,0 +1,29 @@
1
+ /*
2
+ * The JSON persisted on AIRun.taskContext for CodeFix recipes whose entire
3
+ * working context is captured at trigger time rather than referenced by a
4
+ * subject id (incident/alert) or a telemetry exception.
5
+ *
6
+ * First user: the FixPerformance recipe. Its evidence is computed
7
+ * DETERMINISTICALLY from a trace's span tree when the user clicks "Fix
8
+ * performance with AI" (see Common/Server/Utils/AI/PerfEvidence/
9
+ * SpanTreeAnalyzer.ts) and stored here verbatim — ClickHouse span retention
10
+ * is short, so by the time the agent worker claims the run the spans may
11
+ * already be gone. The stored findings ARE the task's context.
12
+ *
13
+ * These shapes are a wire contract with the agent worker
14
+ * (/ai-agent-data/get-instrumentation-task-details serves them back) — do
15
+ * not rename fields.
16
+ */
17
+ export var PerformanceFindingType;
18
+ (function (PerformanceFindingType) {
19
+ // >=5 near-identical sibling spans under one parent (classic N+1).
20
+ PerformanceFindingType["NPlusOneQuery"] = "NPlusOneQuery";
21
+ // A single span whose self time is >=60% of the trace's total duration.
22
+ PerformanceFindingType["DominantSpan"] = "DominantSpan";
23
+ /*
24
+ * >=3 same-name siblings executing strictly one-after-another whose
25
+ * combined duration is >=50% of their parent — parallelizable work.
26
+ */
27
+ PerformanceFindingType["SequentialSiblings"] = "SequentialSiblings";
28
+ })(PerformanceFindingType || (PerformanceFindingType = {}));
29
+ //# sourceMappingURL=CodeFixTaskContext.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CodeFixTaskContext.js","sourceRoot":"","sources":["../../../../Types/AI/CodeFixTaskContext.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;GAeG;AAEH,MAAM,CAAN,IAAY,sBAUX;AAVD,WAAY,sBAAsB;IAChC,mEAAmE;IACnE,yDAA+B,CAAA;IAC/B,wEAAwE;IACxE,uDAA6B,CAAA;IAC7B;;;OAGG;IACH,mEAAyC,CAAA;AAC3C,CAAC,EAVW,sBAAsB,KAAtB,sBAAsB,QAUjC"}
@@ -0,0 +1,122 @@
1
+ /*
2
+ * Which task recipe a CodeFix AIRun executes. The agent worker dispatches on
3
+ * this value (returned as `taskType` by /ai-agent-task/get-pending-task), so
4
+ * these strings are a wire contract — do not rename them.
5
+ *
6
+ * A null AIRun.codeFixTaskType column means FixException: every CodeFix run
7
+ * created before the column existed was an exception fix. Server responses
8
+ * normalize null to FixException so clients never see the legacy null.
9
+ */
10
+ var CodeFixTaskType;
11
+ (function (CodeFixTaskType) {
12
+ // Analyze an exception's stack trace and open a PR that fixes the bug.
13
+ CodeFixTaskType["FixException"] = "FixException";
14
+ // Write a failing-then-passing regression test that reproduces the exception.
15
+ CodeFixTaskType["WriteRegressionTest"] = "WriteRegressionTest";
16
+ /*
17
+ * Add the observability an INCONCLUSIVE AI investigation was missing
18
+ * (structured logs, spans, metric counters on the implicated code paths).
19
+ * NOT user-triggerable from the exception page — it has its own automatic
20
+ * trigger: an inconclusive investigation on a project that opted in via
21
+ * Project.enableInstrumentationFixTasks (see Common/Server/Utils/AI/
22
+ * AI/InstrumentationTaskTrigger.ts). Its subject is the triggering
23
+ * incident/alert, NOT a telemetry exception.
24
+ */
25
+ CodeFixTaskType["ImproveInstrumentation"] = "ImproveInstrumentation";
26
+ /*
27
+ * Fix a deterministically-detected performance pattern in a trace (N+1
28
+ * queries, one dominant slow span, sequential-that-could-be-parallel
29
+ * siblings). Human-triggered from the trace view (POST /ai-investigation/
30
+ * create-performance-fix-task), NOT from the exception page: it has no
31
+ * subject row at all — its entire context (the SpanTreeAnalyzer findings)
32
+ * is captured at trigger time into AIRun.taskContext (see
33
+ * Common/Server/Utils/AI/SRE/FixPerformanceTaskTrigger.ts).
34
+ */
35
+ CodeFixTaskType["FixPerformance"] = "FixPerformance";
36
+ /*
37
+ * Fix the root cause a completed AI investigation identified. Human-
38
+ * triggered from the investigation panel (POST /ai-investigation/
39
+ * create-fix-task), NOT from the exception page: its subject is the
40
+ * investigated incident/alert, and its context is the posted analysis (see
41
+ * Common/Server/Utils/AI/SRE/FixFromIncidentTaskTrigger.ts).
42
+ */
43
+ CodeFixTaskType["FixFromIncident"] = "FixFromIncident";
44
+ })(CodeFixTaskType || (CodeFixTaskType = {}));
45
+ export default CodeFixTaskType;
46
+ /*
47
+ * What a queued run of a recipe must CARRY to be executable — the claim
48
+ * guard and the task-details endpoint both group recipes by this, so a new
49
+ * recipe declares its context kind exactly once.
50
+ */
51
+ export var CodeFixContextKind;
52
+ (function (CodeFixContextKind) {
53
+ // Executes against AIRun.triggeredByTelemetryExceptionId.
54
+ CodeFixContextKind["TelemetryException"] = "TelemetryException";
55
+ // Executes against AIRun.triggeredByIncidentId / triggeredByAlertId.
56
+ CodeFixContextKind["IncidentOrAlertSubject"] = "IncidentOrAlertSubject";
57
+ /*
58
+ * Executes against evidence captured at trigger time into
59
+ * AIRun.taskContext (FixPerformance: traceId + span-tree findings) — no
60
+ * subject row exists at all.
61
+ */
62
+ CodeFixContextKind["TaskContext"] = "TaskContext";
63
+ })(CodeFixContextKind || (CodeFixContextKind = {}));
64
+ export class CodeFixTaskTypeHelper {
65
+ /*
66
+ * The recipes a user may start today FROM THE EXCEPTION PAGE. Recipes
67
+ * outside this list exist as enum values so the worker/UI can already
68
+ * dispatch on them, but creation via the exception-page endpoint is
69
+ * server-rejected. ImproveInstrumentation, FixFromIncident and
70
+ * FixPerformance stay off this list by design — they are not
71
+ * exception-triggered at all: ImproveInstrumentation's trigger is an
72
+ * inconclusive AI investigation on an opted-in project,
73
+ * FixFromIncident is user-triggered from the investigation panel
74
+ * (POST /ai-investigation/create-fix-task), and FixPerformance is
75
+ * user-triggered from the trace view
76
+ * (POST /ai-investigation/create-performance-fix-task).
77
+ */
78
+ static getUserTriggerableTaskTypes() {
79
+ return [CodeFixTaskType.FixException, CodeFixTaskType.WriteRegressionTest];
80
+ }
81
+ static isUserTriggerable(taskType) {
82
+ return this.getUserTriggerableTaskTypes().includes(taskType);
83
+ }
84
+ /*
85
+ * Which context record a queued run of this recipe must carry to be
86
+ * executable. The claim guard rejects runs missing their kind's record,
87
+ * and the task-details endpoint dispatches its response shape on it.
88
+ * Unlisted (and legacy-null-normalized) recipes are exception-based —
89
+ * the safe default, since an exception-less claim of one is unexecutable.
90
+ */
91
+ static getContextKind(taskType) {
92
+ switch (taskType) {
93
+ case CodeFixTaskType.ImproveInstrumentation:
94
+ case CodeFixTaskType.FixFromIncident:
95
+ return CodeFixContextKind.IncidentOrAlertSubject;
96
+ case CodeFixTaskType.FixPerformance:
97
+ return CodeFixContextKind.TaskContext;
98
+ default:
99
+ return CodeFixContextKind.TelemetryException;
100
+ }
101
+ }
102
+ /*
103
+ * Whether the recipe executes against a telemetry exception
104
+ * (AIRun.triggeredByTelemetryExceptionId). Kept as sugar over
105
+ * getContextKind — the claim guard and the task-details endpoint now
106
+ * dispatch on the full context kind.
107
+ */
108
+ static requiresTelemetryException(taskType) {
109
+ return (this.getContextKind(taskType) === CodeFixContextKind.TelemetryException);
110
+ }
111
+ static isValidTaskType(value) {
112
+ return Object.values(CodeFixTaskType).includes(value);
113
+ }
114
+ // Null means FixException: rows created before the column existed.
115
+ static fromDatabaseValue(value) {
116
+ if (value && this.isValidTaskType(value.toString())) {
117
+ return value;
118
+ }
119
+ return CodeFixTaskType.FixException;
120
+ }
121
+ }
122
+ //# sourceMappingURL=CodeFixTaskType.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"CodeFixTaskType.js","sourceRoot":"","sources":["../../../../Types/AI/CodeFixTaskType.ts"],"names":[],"mappings":"AAAA;;;;;;;;GAQG;AACH,IAAK,eAiCJ;AAjCD,WAAK,eAAe;IAClB,uEAAuE;IACvE,gDAA6B,CAAA;IAC7B,8EAA8E;IAC9E,8DAA2C,CAAA;IAC3C;;;;;;;;OAQG;IACH,oEAAiD,CAAA;IACjD;;;;;;;;OAQG;IACH,oDAAiC,CAAA;IACjC;;;;;;OAMG;IACH,sDAAmC,CAAA;AACrC,CAAC,EAjCI,eAAe,KAAf,eAAe,QAiCnB;AAED,eAAe,eAAe,CAAC;AAE/B;;;;GAIG;AACH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AC,KAAK,CAAC,QAAQ,EAAE,CAAC,EAAE,CAAC;YACpD,OAAO,KAAwB,CAAC;QAClC,CAAC;QAED,OAAO,eAAe,CAAC,YAAY,CAAC;IACtC,CAAC;CACF"}
@@ -0,0 +1,102 @@
1
+ import CodeFixTaskType from "./CodeFixTaskType";
2
+ /*
3
+ * The rolled-up CI conclusion recorded on an AI fix pull request
4
+ * (AIAgentTaskPullRequest.ciStatus) — B4 Tier 1: verification via the
5
+ * customer's OWN CI on the draft PRs. We read check-run conclusions through
6
+ * the GitHub App; we never re-run or gate the customer's CI.
7
+ *
8
+ * G9 honesty rule: only Green and ExpectedFailureObserved ever count as
9
+ * "CI-verified". NoCiConfigured (and a null column — not yet polled) read as
10
+ * unverified, never verified — a repo without CI verifies nothing.
11
+ */
12
+ var FixPullRequestCiStatus;
13
+ (function (FixPullRequestCiStatus) {
14
+ // Check runs exist and at least one has not completed yet.
15
+ FixPullRequestCiStatus["Pending"] = "Pending";
16
+ // Every check run completed and none failed.
17
+ FixPullRequestCiStatus["Green"] = "Green";
18
+ // Every check run completed and at least one failed.
19
+ FixPullRequestCiStatus["Red"] = "Red";
20
+ /*
21
+ * A WriteRegressionTest PR whose checks concluded RED: the PR's whole
22
+ * point is a test that SHOULD FAIL until the bug is fixed, so a failing
23
+ * check is the desired signal, not a defect. Honest caveat: at check-run
24
+ * granularity we cannot tell WHICH job failed — a repo whose lint breaks
25
+ * on the PR also reads as expected-failure. Job-level discrimination
26
+ * (inspecting check names) is a tracked Tier 1 residual in the roadmap.
27
+ */
28
+ FixPullRequestCiStatus["ExpectedFailureObserved"] = "ExpectedFailureObserved";
29
+ /*
30
+ * The PR's head branch has zero check runs — the repository runs no CI on
31
+ * this PR. Per G9 this is "unverified", never "verified".
32
+ */
33
+ FixPullRequestCiStatus["NoCiConfigured"] = "NoCiConfigured";
34
+ })(FixPullRequestCiStatus || (FixPullRequestCiStatus = {}));
35
+ export default FixPullRequestCiStatus;
36
+ export class FixPullRequestCiStatusHelper {
37
+ /*
38
+ * Roll one PR's check-run counts into a single conclusion. The order is
39
+ * deliberate:
40
+ * 1. no check runs at all -> NoCiConfigured (nothing ran; G9: unverified)
41
+ * 2. any run still pending -> Pending (we report only FINAL
42
+ * conclusions — a failure observed while other checks still run is
43
+ * not yet the branch's conclusion)
44
+ * 3. any completed run failed -> Red
45
+ * 4. otherwise -> Green
46
+ */
47
+ static rollUpConclusion(counts) {
48
+ if (counts.total === 0) {
49
+ return FixPullRequestCiStatus.NoCiConfigured;
50
+ }
51
+ if (counts.pending > 0) {
52
+ return FixPullRequestCiStatus.Pending;
53
+ }
54
+ if (counts.failed > 0) {
55
+ return FixPullRequestCiStatus.Red;
56
+ }
57
+ return FixPullRequestCiStatus.Green;
58
+ }
59
+ /*
60
+ * The SHOULD-FAIL rule: a WriteRegressionTest PR exists to prove a bug
61
+ * with a test that fails until the bug is fixed, so a RED conclusion on
62
+ * such a PR is the expected outcome and is recorded as
63
+ * ExpectedFailureObserved. Every other conclusion, and every other task
64
+ * type, passes through unchanged. (Caveat documented on the enum member:
65
+ * we cannot tell which job failed — a broken lint also reads as
66
+ * expected-failure until job-level discrimination ships.)
67
+ */
68
+ static applyTaskType(data) {
69
+ if (data.conclusion === FixPullRequestCiStatus.Red &&
70
+ data.taskType === CodeFixTaskType.WriteRegressionTest) {
71
+ return FixPullRequestCiStatus.ExpectedFailureObserved;
72
+ }
73
+ return data.conclusion;
74
+ }
75
+ /*
76
+ * The G9 verification predicate, defined ONCE: a PR counts as CI-verified
77
+ * only on Green or ExpectedFailureObserved. NoCiConfigured, Pending, Red
78
+ * and null all read as unverified.
79
+ */
80
+ static isVerified(status) {
81
+ return (status === FixPullRequestCiStatus.Green ||
82
+ status === FixPullRequestCiStatus.ExpectedFailureObserved);
83
+ }
84
+ // Human-readable line for the run's glass-box ProgressLog trail.
85
+ static describeForProgressLog(data) {
86
+ switch (data.ciStatus) {
87
+ case FixPullRequestCiStatus.Green:
88
+ return `CI on the fix PR: Green (${data.counts.completed}/${data.counts.total} checks passed)`;
89
+ case FixPullRequestCiStatus.Red:
90
+ return `CI on the fix PR: Red (${data.counts.failed}/${data.counts.total} checks failed)`;
91
+ case FixPullRequestCiStatus.ExpectedFailureObserved:
92
+ return `Regression-test PR: expected failure observed (${data.counts.failed}/${data.counts.total} checks failed — a failing check is the desired signal for a should-fail test)`;
93
+ case FixPullRequestCiStatus.Pending:
94
+ return `CI on the fix PR: Pending (${data.counts.completed}/${data.counts.total} checks completed)`;
95
+ case FixPullRequestCiStatus.NoCiConfigured:
96
+ return "CI on the fix PR: no check runs found — the repository runs no CI on this branch, so the fix is unverified";
97
+ default:
98
+ return `CI on the fix PR: ${data.ciStatus}`;
99
+ }
100
+ }
101
+ }
102
+ //# sourceMappingURL=FixPullRequestCiStatus.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"FixPullRequestCiStatus.js","sourceRoot":"","sources":["../../../../Types/AI/FixPullRequestCiStatus.ts"],"names":[],"mappings":"AAAA,OAAO,eAAe,MAAM,mBAAmB,CAAC;AAEhD;;;;;;;;;GASG;AACH,IAAK,sBAqBJ;AArBD,WAAK,sBAAsB;IACzB,2DAA2D;IAC3D,6CAAmB,CAAA;IACnB,6CAA6C;IAC7C,yCAAe,CAAA;IACf,qDAAqD;IACrD,qCAAW,CAAA;IACX;;;;;;;OAOG;IACH,6EAAmD,CAAA;IACnD;;;OAGG;IACH,2DAAiC,CAAA;AACnC,CAAC,EArBI,sBAAsB,KAAtB,sBAAsB,QAqB1B;AAED,eAAe,sBAAsB,CAAC;AAUtC,MAAM,OAAO,4BAA4B;IACvC;;;;;;;;;OASG;IACI,MAAM,CAAC,gBAAgB,CAC5B,MAAsC;QAEtC,IAAI,MAAM,CAAC,KAAK,KAAK,CAAC,EAAE,CAAC;YACvB,OAAO,sBAAsB,CAAC,cAAc,CAAC;QAC/C,CAAC;QAED,IAAI,MAAM,CAAC,OAAO,GAAG,CAAC,EAAE,CAAC;YACvB,OAAO,sBAAsB,CAAC,OAAO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C,KAAK,oBAAoB,CAAC;YACtG,KAAK,sBAAsB,CAAC,cAAc;gBACxC,OAAO,4GAA4G,CAAC;YACtH;gBACE,OAAO,qBAAqB,IAAI,CAAC,QAAQ,EAAE,CAAC;QAChD,CAAC;IACH,CAAC;CACF"}
@@ -77,6 +77,61 @@ export class AggregationIntervalUtil {
77
77
  return 1000 * 60;
78
78
  }
79
79
  }
80
+ /*
81
+ * Floor a timestamp DOWN to the start of its aggregation bucket, matching
82
+ * the server's `toStartOfInterval(time, INTERVAL 1 <interval>)` grid. This
83
+ * lets a chart align its query window to the bucket grid so the leading
84
+ * edge lands on a real bucket boundary instead of mid-bucket — a
85
+ * mid-bucket start renders as an empty gap before the first plotted point
86
+ * (the first bucket is partial and its timestamp falls before the axis
87
+ * origin).
88
+ *
89
+ * Only Minute/Hour/Day are aligned: for those the fixed-ms epoch grid is
90
+ * an EXACT match for ClickHouse's UTC bucketing (epoch-day == UTC
91
+ * midnight), and these are the windows where the leading gap is actually
92
+ * visible. Week/Month/Year snap to calendar boundaries (Monday / 1st /
93
+ * Jan-1) server-side, which a fixed-ms grid can't reproduce, so those (and
94
+ * `Total`) are returned UNCHANGED rather than risk shifting the gap for
95
+ * long windows — their pre-existing behavior is preserved.
96
+ */
97
+ static floorDateToIntervalGrid(date, interval) {
98
+ const ms = OneUptimeDate.fromString(date).getTime();
99
+ const alignableIntervals = [
100
+ AggregationInterval.Minute,
101
+ AggregationInterval.Hour,
102
+ AggregationInterval.Day,
103
+ ];
104
+ if (!alignableIntervals.includes(interval)) {
105
+ return new Date(ms);
106
+ }
107
+ const bucketMs = this.getAggregationIntervalMs(interval);
108
+ if (!Number.isFinite(bucketMs) || bucketMs <= 0) {
109
+ return new Date(ms);
110
+ }
111
+ return new Date(Math.floor(ms / bucketMs) * bucketMs);
112
+ }
113
+ /*
114
+ * Align a query window to the aggregation-bucket grid. The bucket size is
115
+ * derived from the RAW window and returned alongside the aligned dates so
116
+ * the caller can PIN it (AggregateBy.aggregationInterval): flooring the
117
+ * start slightly widens the window, and without pinning that could bump a
118
+ * window sitting exactly on a tier threshold (e.g. a 3h window) into the
119
+ * next-coarser interval and change the whole chart's resolution. The start
120
+ * is floored DOWN so the first bucket is complete and lands on the axis
121
+ * origin (removing the leading gap); the end is left untouched so the
122
+ * latest, still-in-progress bucket and its live data continue to show.
123
+ */
124
+ static getIntervalAlignedWindow(data) {
125
+ const interval = this.getAggregationIntervalForWindow({
126
+ startDate: data.startDate,
127
+ endDate: data.endDate,
128
+ });
129
+ return {
130
+ startDate: this.floorDateToIntervalGrid(data.startDate, interval),
131
+ endDate: OneUptimeDate.fromString(data.endDate),
132
+ interval,
133
+ };
134
+ }
80
135
  }
81
136
  export default AggregationIntervalUtil;
82
137
  //# sourceMappingURL=AggregationIntervalUtil.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"AggregationIntervalUtil.js","sourceRoot":"","sources":["../../../../Types/BaseDatabase/AggregationIntervalUtil.ts"],"names":[],"mappings":"AAAA,OAAO,mBAAmB,MAAM,uBAAuB,CAAC;AACxD,OAAO,aAAa,MAAM,SAAS,CAAC;AAEpC;;;;;;;;;;GAUG;AACH,MAAM,OAAO,uBAAuB;IAC3B,MAAM,CAAC,+BAA+B,CAAC,IAU7C;QACC,IACE,IAAI,CAAC,mBAAmB;YACxB,MAAM,CAAC,MAAM,CAAC,mBAAmB,CAAC,CAAC,QAAQ,CAAC,IAAI,CAAC,mBAAmB,CAAC,EACrE,CAAC;YACD,OAAO,IAAI,CAAC,mBAAmB,CAAC;QAClC,CAAC;QAED,MAAM,SAAS,GAAS,aAAa,CAAC,UAAU,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC;QACjE,MAAM,OAAO,GAAS,aAAa,CAAC,UAAU,CAAC,IAAI,CAAC,OAAO,CAAC,CAAC;QAE7D,MAAM,IAAI,GAAW,OAAO,CAAC,OAAO,EAAE,GAAG,SAAS,CAAC,OAAO,EAAE,CAAC;QAE7D,IAAI,IAAI,IAAI,IAAI,GAAG,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AQ,GAAwB,IAAI,CAAC,+BAA+B,CAAC;YACzE,SAAS,EAAE,IAAI,CAAC,SAAS;YACzB,OAAO,EAAE,IAAI,CAAC,OAAO;SACtB,CAAC,CAAC;QACH,OAAO;YACL,SAAS,EAAE,IAAI,CAAC,uBAAuB,CAAC,IAAI,CAAC,SAAS,EAAE,QAAQ,CAAC;YACjE,OAAO,EAAE,aAAa,CAAC,UAAU,CAAC,IAAI,CAAC,OAAO,CAAC;YAC/C,QAAQ;SACT,CAAC;IACJ,CAAC;CACF;AAED,eAAe,uBAAuB,CAAC"}
@@ -7,6 +7,13 @@ var IncidentMetricType;
7
7
  IncidentMetricType["TimeInState"] = "oneuptime.incident.time-in-state";
8
8
  IncidentMetricType["SeverityChange"] = "oneuptime.incident.severity-change";
9
9
  IncidentMetricType["PostmortemCompletionTime"] = "oneuptime.incident.postmortem-completion-time";
10
+ /*
11
+ * Seconds from incident creation to the moment the AI investigation
12
+ * posted its root-cause analysis. Written once from the investigation
13
+ * runner (not from refreshIncidentMetrics — the refresh replace-list
14
+ * deliberately excludes this name so refreshes never tombstone it).
15
+ */
16
+ IncidentMetricType["TimeToRootCausePosted"] = "oneuptime.incident.time-to-rca";
10
17
  })(IncidentMetricType || (IncidentMetricType = {}));
11
18
  export default IncidentMetricType;
12
19
  //# sourceMappingURL=IncidentMetricType.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"IncidentMetricType.js","sourceRoot":"","sources":["../../../../Types/Incident/IncidentMetricType.ts"],"names":[],"mappings":"AAAA,IAAK,kBAQJ;AARD,WAAK,kBAAkB;IACrB,kFAA4D,CAAA;IAC5D,0EAAoD,CAAA;IACpD,gEAA0C,CAAA;IAC1C,sEAAgD,CAAA;IAChD,sEAAgD,CAAA;IAChD,2EAAqD,CAAA;IACrD,gGAA0E,CAAA;AAC5E,CAAC,EARI,kBAAkB,KAAlB,kBAAkB,QAQtB;AAED,eAAe,kBAAkB,CAAC"}
1
+ {"version":3,"file":"IncidentMetricType.js","sourceRoot":"","sources":["../../../../Types/Incident/IncidentMetricType.ts"],"names":[],"mappings":"AAAA,IAAK,kBAeJ;AAfD,WAAK,kBAAkB;IACrB,kFAA4D,CAAA;IAC5D,0EAAoD,CAAA;IACpD,gEAA0C,CAAA;IAC1C,sEAAgD,CAAA;IAChD,sEAAgD,CAAA;IAChD,2EAAqD,CAAA;IACrD,gGAA0E,CAAA;IAC1E;;;;;OAKG;IACH,8EAAwD,CAAA;AAC1D,CAAC,EAfI,kBAAkB,KAAlB,kBAAkB,QAetB;AAED,eAAe,kBAAkB,CAAC"}
@@ -83,6 +83,12 @@ export var CheckOn;
83
83
  CheckOn["DnssecSignatureExpiresInDays"] = "DNSSEC Signature Expires In Days";
84
84
  CheckOn["DnssecResolverConsensus"] = "DNSSEC Resolver Consensus (AD Flag)";
85
85
  CheckOn["DnssecNameserverConsistent"] = "DNSSEC Nameservers Are Consistent";
86
+ // SQL Query monitors.
87
+ CheckOn["SqlIsOnline"] = "SQL Is Online";
88
+ CheckOn["SqlQueryRowCount"] = "SQL Query Row Count";
89
+ CheckOn["SqlQueryScalarValue"] = "SQL Query Scalar Value";
90
+ CheckOn["SqlQueryExecutionTime"] = "SQL Query Execution Time (in ms)";
91
+ CheckOn["SqlQueryError"] = "SQL Query Error";
86
92
  // External Status Page monitors.
87
93
  CheckOn["ExternalStatusPageIsOnline"] = "External Status Page Is Online";
88
94
  CheckOn["ExternalStatusPageOverallStatus"] = "External Status Page Overall Status";
@@ -209,6 +215,7 @@ export class CriteriaFilterUtil {
209
215
  checkOn === CheckOn.DnssecDsExists ||
210
216
  checkOn === CheckOn.DnssecResolverConsensus ||
211
217
  checkOn === CheckOn.DnssecNameserverConsistent ||
218
+ checkOn === CheckOn.SqlIsOnline ||
212
219
  checkOn === CheckOn.ExternalStatusPageIsOnline) {
213
220
  return false;
214
221
  }
@@ -1 +1 @@
1
- {"version":3,"file":"CriteriaFilter.js","sourceRoot":"","sources":["../../../../Types/Monitor/CriteriaFilter.ts"],"names":[],"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