graphdb-workbench 3.2.0-TR2 → 3.2.0-TR4

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 (246) hide show
  1. package/dist/12358.4be185f89eebea9c35bf.bundle.js +3 -0
  2. package/dist/12358.4be185f89eebea9c35bf.bundle.js.map +1 -0
  3. package/dist/{12396.9a7f2862146b6f9adcb1.bundle.js → 12396.a1b7856e86d52282f34c.bundle.js} +2 -2
  4. package/dist/{12396.9a7f2862146b6f9adcb1.bundle.js.map → 12396.a1b7856e86d52282f34c.bundle.js.map} +1 -1
  5. package/dist/{15535.7b170e17ee0a58970ab6.bundle.js → 15535.c58319cba275ee5baa90.bundle.js} +2 -2
  6. package/dist/{15535.7b170e17ee0a58970ab6.bundle.js.map → 15535.c58319cba275ee5baa90.bundle.js.map} +1 -1
  7. package/dist/{16162.67e7c1f5f313481b1e80.bundle.js → 16162.2dc986d04777c8ae9489.bundle.js} +2 -2
  8. package/dist/{16162.67e7c1f5f313481b1e80.bundle.js.map → 16162.2dc986d04777c8ae9489.bundle.js.map} +1 -1
  9. package/dist/19402.7f6ea977348338acc824.bundle.js +2 -0
  10. package/dist/19402.7f6ea977348338acc824.bundle.js.map +1 -0
  11. package/dist/{20287.dd5bc263fe26adf34965.bundle.js → 20287.7cfc312df157f5bdea97.bundle.js} +2 -2
  12. package/dist/{20287.dd5bc263fe26adf34965.bundle.js.map → 20287.7cfc312df157f5bdea97.bundle.js.map} +1 -1
  13. package/dist/{21136.b7efcb40fb956ff1109c.bundle.js → 21136.67a9bcf4bb0c201d3fd1.bundle.js} +2 -2
  14. package/dist/{21136.b7efcb40fb956ff1109c.bundle.js.map → 21136.67a9bcf4bb0c201d3fd1.bundle.js.map} +1 -1
  15. package/dist/21142.7f8327c28d939fa26009.bundle.js +2 -0
  16. package/dist/21142.7f8327c28d939fa26009.bundle.js.map +1 -0
  17. package/dist/{21170.7832554eab9eaade6ffb.bundle.js → 21170.cecdf25699f68d4cf749.bundle.js} +2 -2
  18. package/dist/{21170.7832554eab9eaade6ffb.bundle.js.map → 21170.cecdf25699f68d4cf749.bundle.js.map} +1 -1
  19. package/dist/21195.e2c1fc69631041b97f8e.bundle.js +2 -0
  20. package/dist/21195.e2c1fc69631041b97f8e.bundle.js.map +1 -0
  21. package/dist/{25747.c01110e23b922cdd3d9e.bundle.js → 25747.c3dc5503ad696af5d5a3.bundle.js} +2 -2
  22. package/dist/{25747.c01110e23b922cdd3d9e.bundle.js.map → 25747.c3dc5503ad696af5d5a3.bundle.js.map} +1 -1
  23. package/dist/{27580.5a421770ab66d2dedc37.bundle.js → 27580.d038d43102a3e9eec97d.bundle.js} +2 -2
  24. package/dist/{27580.5a421770ab66d2dedc37.bundle.js.map → 27580.d038d43102a3e9eec97d.bundle.js.map} +1 -1
  25. package/dist/29350.d2791feedf54d2e4b7b6.bundle.js +2 -0
  26. package/dist/29350.d2791feedf54d2e4b7b6.bundle.js.map +1 -0
  27. package/dist/{31636.54e2817f8ae3998a34b3.bundle.js → 31636.fc6eba63d6d985d31673.bundle.js} +2 -2
  28. package/dist/{31636.54e2817f8ae3998a34b3.bundle.js.map → 31636.fc6eba63d6d985d31673.bundle.js.map} +1 -1
  29. package/dist/{32489.f7a2dc39cd61c2cd8874.bundle.js → 32489.e9af1ec463e2d4136732.bundle.js} +2 -2
  30. package/dist/{32489.f7a2dc39cd61c2cd8874.bundle.js.map → 32489.e9af1ec463e2d4136732.bundle.js.map} +1 -1
  31. package/dist/{34330.4b46c3a52d19f05fc0b2.bundle.js → 34330.990c99ea37f6cca46bad.bundle.js} +2 -2
  32. package/dist/34330.990c99ea37f6cca46bad.bundle.js.map +1 -0
  33. package/dist/{34495.be67c06c39909114bbe4.bundle.js → 34495.06c9997d58d0b0ba7152.bundle.js} +2 -2
  34. package/dist/{34495.be67c06c39909114bbe4.bundle.js.map → 34495.06c9997d58d0b0ba7152.bundle.js.map} +1 -1
  35. package/dist/36633.eba4270db7fdcf1aad4c.bundle.js +2 -0
  36. package/dist/36633.eba4270db7fdcf1aad4c.bundle.js.map +1 -0
  37. package/dist/36665.69d43b057bcfc55df3b5.bundle.js +2 -0
  38. package/dist/36665.69d43b057bcfc55df3b5.bundle.js.map +1 -0
  39. package/dist/{38360.efec913bb97c3b8588a4.bundle.js → 38360.ca92a04a1afcf9cfea7f.bundle.js} +2 -2
  40. package/dist/{38360.efec913bb97c3b8588a4.bundle.js.map → 38360.ca92a04a1afcf9cfea7f.bundle.js.map} +1 -1
  41. package/dist/{38644.800252af49cd67310834.bundle.js → 38644.29dbfb38e4089efa6697.bundle.js} +2 -2
  42. package/dist/{38644.800252af49cd67310834.bundle.js.map → 38644.29dbfb38e4089efa6697.bundle.js.map} +1 -1
  43. package/dist/{38843.29e34a5e5293cee51566.bundle.js → 38843.4b11f56e93f60fbe4e0a.bundle.js} +2 -2
  44. package/dist/{38843.29e34a5e5293cee51566.bundle.js.map → 38843.4b11f56e93f60fbe4e0a.bundle.js.map} +1 -1
  45. package/dist/{39518.0ca97879b92271d7c5e2.bundle.js → 39518.c577d83ed591fada064c.bundle.js} +2 -2
  46. package/dist/{39518.0ca97879b92271d7c5e2.bundle.js.map → 39518.c577d83ed591fada064c.bundle.js.map} +1 -1
  47. package/dist/{39539.7cea6717cc3a5ba91617.bundle.js → 39539.463ec29e136b100c0abe.bundle.js} +2 -2
  48. package/dist/{39539.7cea6717cc3a5ba91617.bundle.js.map → 39539.463ec29e136b100c0abe.bundle.js.map} +1 -1
  49. package/dist/40516.3cfaf1ff4704c038f944.bundle.js +2 -0
  50. package/dist/40516.3cfaf1ff4704c038f944.bundle.js.map +1 -0
  51. package/dist/{41453.4ae219d972a187c36bfc.bundle.js → 41453.241761ce8ff75036e5e0.bundle.js} +2 -2
  52. package/dist/{41453.4ae219d972a187c36bfc.bundle.js.map → 41453.241761ce8ff75036e5e0.bundle.js.map} +1 -1
  53. package/dist/{42129.0314e45b4b818b01b71f.bundle.js → 42129.f67dc6029cdab567bf54.bundle.js} +2 -2
  54. package/dist/{42129.0314e45b4b818b01b71f.bundle.js.map → 42129.f67dc6029cdab567bf54.bundle.js.map} +1 -1
  55. package/dist/42143.6c37997677f5ec643731.bundle.js +2 -0
  56. package/dist/42143.6c37997677f5ec643731.bundle.js.map +1 -0
  57. package/dist/{44444.02026ff20e2a843dc05b.bundle.js → 44444.a1b29c2329c7d4a39cc5.bundle.js} +2 -2
  58. package/dist/{44444.02026ff20e2a843dc05b.bundle.js.map → 44444.a1b29c2329c7d4a39cc5.bundle.js.map} +1 -1
  59. package/dist/44874.b16be286176dfe4aa766.bundle.js +2 -0
  60. package/dist/44874.b16be286176dfe4aa766.bundle.js.map +1 -0
  61. package/dist/49539.63984d5b37bc8b9a7244.bundle.js +2 -0
  62. package/dist/49539.63984d5b37bc8b9a7244.bundle.js.map +1 -0
  63. package/dist/{51087.b072d1c0e53403535283.bundle.js → 51087.1e118e7fe32a8c09d6cb.bundle.js} +2 -2
  64. package/dist/51087.1e118e7fe32a8c09d6cb.bundle.js.map +1 -0
  65. package/dist/{55217.4769c1f0615e364d8c2a.bundle.js → 55217.98a70cf01c4b7a826e82.bundle.js} +2 -2
  66. package/dist/55217.98a70cf01c4b7a826e82.bundle.js.map +1 -0
  67. package/dist/{55862.5e8602827fbf72e60cc2.bundle.js → 55862.1c3f1e807c8a05b1b6ed.bundle.js} +2 -2
  68. package/dist/{55862.5e8602827fbf72e60cc2.bundle.js.map → 55862.1c3f1e807c8a05b1b6ed.bundle.js.map} +1 -1
  69. package/dist/{58306.94b9336f68d11bdd72f0.bundle.js → 58306.a45182d200e3f8793644.bundle.js} +2 -2
  70. package/dist/{58306.94b9336f68d11bdd72f0.bundle.js.map → 58306.a45182d200e3f8793644.bundle.js.map} +1 -1
  71. package/dist/60039.5f9e955234f5eaf33372.bundle.js +2 -0
  72. package/dist/60039.5f9e955234f5eaf33372.bundle.js.map +1 -0
  73. package/dist/63415.7a4dfa072b5665c5995b.bundle.js +2 -0
  74. package/dist/63415.7a4dfa072b5665c5995b.bundle.js.map +1 -0
  75. package/dist/64118.edc8ed6671017d09ff4e.bundle.js +2 -0
  76. package/dist/64118.edc8ed6671017d09ff4e.bundle.js.map +1 -0
  77. package/dist/67232.bc980f2f0df606493105.bundle.js +2 -0
  78. package/dist/67232.bc980f2f0df606493105.bundle.js.map +1 -0
  79. package/dist/{67888.772326168aed83cbad9c.bundle.js → 67888.e21c0e4c70be6214fcd7.bundle.js} +2 -2
  80. package/dist/{67888.772326168aed83cbad9c.bundle.js.map → 67888.e21c0e4c70be6214fcd7.bundle.js.map} +1 -1
  81. package/dist/70938.c489d3ca5b00ad297139.bundle.js +2 -0
  82. package/dist/70938.c489d3ca5b00ad297139.bundle.js.map +1 -0
  83. package/dist/71920.c171884910616d02e2c6.bundle.js +2 -0
  84. package/dist/71920.c171884910616d02e2c6.bundle.js.map +1 -0
  85. package/dist/{72379.8a3290df05f18f8c65bd.bundle.js → 72379.cb41e26c33271a25816e.bundle.js} +2 -2
  86. package/dist/{72379.8a3290df05f18f8c65bd.bundle.js.map → 72379.cb41e26c33271a25816e.bundle.js.map} +1 -1
  87. package/dist/{73667.52fdbdadddafe9e9559b.bundle.js → 73667.ad957853dba08fd3be30.bundle.js} +2 -2
  88. package/dist/{73667.52fdbdadddafe9e9559b.bundle.js.map → 73667.ad957853dba08fd3be30.bundle.js.map} +1 -1
  89. package/dist/{73793.7e812bab1754ddd5efb5.bundle.js → 73793.79a311b387e5db776506.bundle.js} +2 -2
  90. package/dist/{73793.7e812bab1754ddd5efb5.bundle.js.map → 73793.79a311b387e5db776506.bundle.js.map} +1 -1
  91. package/dist/73964.7a3038b5726d50c1a051.bundle.js +2 -0
  92. package/dist/73964.7a3038b5726d50c1a051.bundle.js.map +1 -0
  93. package/dist/{75282.2f97d3a7d7f3fdd7aebf.bundle.js → 75282.8be5dde957dc6452c86a.bundle.js} +2 -2
  94. package/dist/{75282.2f97d3a7d7f3fdd7aebf.bundle.js.map → 75282.8be5dde957dc6452c86a.bundle.js.map} +1 -1
  95. package/dist/75849.0f6bab8b5749be998286.bundle.js +2 -0
  96. package/dist/75849.0f6bab8b5749be998286.bundle.js.map +1 -0
  97. package/dist/76013.9e71103dbb91bd9a558c.bundle.js +2 -0
  98. package/dist/76013.9e71103dbb91bd9a558c.bundle.js.map +1 -0
  99. package/dist/{78250.73e3013c5b2ebdddbf38.bundle.js → 78250.dd9bdc3db3ca0c84b25a.bundle.js} +2 -2
  100. package/dist/{78250.73e3013c5b2ebdddbf38.bundle.js.map → 78250.dd9bdc3db3ca0c84b25a.bundle.js.map} +1 -1
  101. package/dist/7928.9ab4b363abb28bfc6bd5.bundle.js +2 -0
  102. package/dist/7928.9ab4b363abb28bfc6bd5.bundle.js.map +1 -0
  103. package/dist/{79329.3d912887ba7e96090fb4.bundle.js → 79329.24a5e42cccee5055311a.bundle.js} +2 -2
  104. package/dist/{79329.3d912887ba7e96090fb4.bundle.js.map → 79329.24a5e42cccee5055311a.bundle.js.map} +1 -1
  105. package/dist/{82926.93a59d42bf8d49aaac8e.bundle.js → 82926.02f08566fe1f948d9e1f.bundle.js} +2 -2
  106. package/dist/{82926.93a59d42bf8d49aaac8e.bundle.js.map → 82926.02f08566fe1f948d9e1f.bundle.js.map} +1 -1
  107. package/dist/85609.68438b4955212d5fcb84.bundle.js +2 -0
  108. package/dist/85609.68438b4955212d5fcb84.bundle.js.map +1 -0
  109. package/dist/85788.501c7244b890d519f8cf.bundle.js +2 -0
  110. package/dist/85788.501c7244b890d519f8cf.bundle.js.map +1 -0
  111. package/dist/86142.04f4e4759998d4c37ccd.bundle.js +2 -0
  112. package/dist/86142.04f4e4759998d4c37ccd.bundle.js.map +1 -0
  113. package/dist/{89695.4ee87c52d4088115c51e.bundle.js → 89695.b7e90a123bc2875ccae4.bundle.js} +2 -2
  114. package/dist/89695.b7e90a123bc2875ccae4.bundle.js.map +1 -0
  115. package/dist/{9062.3541de664710a36fdac7.bundle.js → 9062.e1ad16e157f04b8c9dd8.bundle.js} +2 -2
  116. package/dist/{9062.3541de664710a36fdac7.bundle.js.map → 9062.e1ad16e157f04b8c9dd8.bundle.js.map} +1 -1
  117. package/dist/96089.4317e132ef8cc0033f83.bundle.js +2 -0
  118. package/dist/96089.4317e132ef8cc0033f83.bundle.js.map +1 -0
  119. package/dist/{99448.384b74c734331e5f8909.bundle.js → 99448.93e01a6a24e4a1cb0546.bundle.js} +2 -2
  120. package/dist/{99448.384b74c734331e5f8909.bundle.js.map → 99448.93e01a6a24e4a1cb0546.bundle.js.map} +1 -1
  121. package/dist/css/ttyg/chat-item-details.css +1 -1
  122. package/dist/css/ttyg/chat-panel.css +1 -1
  123. package/dist/i18n/locale-en.json +5 -1
  124. package/dist/i18n/locale-fr.json +5 -1
  125. package/dist/index.html +8 -8
  126. package/dist/js/angular/clustermanagement/templates/cluster-nodes-configuration.html +1 -1
  127. package/dist/js/angular/core/directives/autocomplete/templates/autocomplete.html +1 -1
  128. package/dist/js/angular/core/directives/dynamic-form/templates/dynamic-form.html +1 -1
  129. package/dist/js/angular/core/directives/operations-statuses-monitor/templates/operations-statuses-monitor.html +1 -1
  130. package/dist/js/angular/core/directives/rdfresourcesearch/templates/rdfResourceSearchTemplate.html +1 -1
  131. package/dist/js/angular/core/directives/shuttle-multiselect/templates/shuttle-multiselect.html +1 -1
  132. package/dist/js/angular/core/directives/yasgui-component/templates/yasgui-component.html +1 -1
  133. package/dist/js/angular/core/templates/cookie-policy/cookie-consent.html +1 -1
  134. package/dist/js/angular/core/templates/cookie-policy/cookie-policy.html +1 -1
  135. package/dist/js/angular/core/templates/editable-content/editable-content.html +1 -1
  136. package/dist/js/angular/core/templates/markdown-content/markdown-content.html +1 -1
  137. package/dist/js/angular/core/templates/search-resource-input.html +1 -1
  138. package/dist/js/angular/graphql/templates/create-graphql-endpoint.html +2 -2
  139. package/dist/js/angular/graphql/templates/graphql-endpoint-management.html +1 -1
  140. package/dist/js/angular/graphql/templates/graphql-playground.html +1 -1
  141. package/dist/js/angular/graphql/templates/modal/endpoint-configuration-modal.html +1 -1
  142. package/dist/js/angular/graphql/templates/modal/endpoint-generation-failure-result-modal.html +1 -1
  143. package/dist/js/angular/graphql/templates/modal/import-endpoint-definition-modal.html +1 -1
  144. package/dist/js/angular/security/templates/user.html +2 -2
  145. package/dist/js/angular/ttyg/templates/agent-list.html +1 -1
  146. package/dist/js/angular/ttyg/templates/agent-select-menu.html +1 -1
  147. package/dist/js/angular/ttyg/templates/chat-item-detail.html +5 -5
  148. package/dist/js/angular/ttyg/templates/chat-list.html +2 -2
  149. package/dist/js/angular/ttyg/templates/chat-panel.html +12 -7
  150. package/dist/js/angular/ttyg/templates/modal/agent-instructions-explain-modal.html +1 -1
  151. package/dist/js/angular/ttyg/templates/modal/agent-settings-modal.html +2 -2
  152. package/dist/js/angular/ttyg/templates/modal/external-integration-configuration-modal.html +1 -1
  153. package/dist/js/angular/ttyg/templates/no-agents-view.html +1 -1
  154. package/dist/js/angular/ttyg/templates/ttyg.html +1 -1
  155. package/dist/{legacyWorkbench.2bd696723af2573e8bb7.js → legacyWorkbench.ecf6300fd72cfffbcdb6.js} +3 -3
  156. package/dist/{legacyWorkbench.2bd696723af2573e8bb7.js.map → legacyWorkbench.ecf6300fd72cfffbcdb6.js.map} +1 -1
  157. package/dist/pages/aclmanagement.html +2 -2
  158. package/dist/pages/autocomplete.html +1 -1
  159. package/dist/pages/choose-repository-type.html +1 -1
  160. package/dist/pages/cluster-management/clusterInfo.html +3 -3
  161. package/dist/pages/create-index.html +1 -1
  162. package/dist/pages/dependencies.html +1 -1
  163. package/dist/pages/domainRangeInfo.html +2 -2
  164. package/dist/pages/edit.html +1 -1
  165. package/dist/pages/explore.html +1 -1
  166. package/dist/pages/export.html +1 -1
  167. package/dist/pages/find.html +1 -1
  168. package/dist/pages/graph-config/saveGraphConfig.html +8 -8
  169. package/dist/pages/graphs-visualizations.html +7 -7
  170. package/dist/pages/guides.html +1 -1
  171. package/dist/pages/import.html +2 -2
  172. package/dist/pages/jdbc-create.html +1 -1
  173. package/dist/pages/login.html +1 -1
  174. package/dist/pages/monitor/backup-and-restore.html +1 -1
  175. package/dist/pages/monitor/queries.html +1 -1
  176. package/dist/pages/monitor/resources.html +1 -1
  177. package/dist/pages/namespaces.html +2 -2
  178. package/dist/pages/plugins.html +1 -1
  179. package/dist/pages/rdfClassHierarchyInfo.html +7 -7
  180. package/dist/pages/rdfrank.html +2 -2
  181. package/dist/pages/repositories.html +1 -1
  182. package/dist/pages/repository.html +1 -1
  183. package/dist/pages/similarity-indexes.html +1 -1
  184. package/dist/pages/sparql-editor.html +1 -1
  185. package/dist/pages/sparql-template-create.html +1 -1
  186. package/dist/pages/ux-test1.html +2 -2
  187. package/dist/pages/webapi.html +2 -2
  188. package/dist/plugins.js +1 -1
  189. package/dist/res/swagger5/index.html +11 -11
  190. package/package.json +1 -1
  191. package/dist/12358.2061f29dc113149946a3.bundle.js +0 -3
  192. package/dist/12358.2061f29dc113149946a3.bundle.js.map +0 -1
  193. package/dist/19402.07424b4b7c9dd775d860.bundle.js +0 -2
  194. package/dist/19402.07424b4b7c9dd775d860.bundle.js.map +0 -1
  195. package/dist/21142.ec45fad4d52b36961d17.bundle.js +0 -2
  196. package/dist/21142.ec45fad4d52b36961d17.bundle.js.map +0 -1
  197. package/dist/21195.caae6cc33d755ad52df4.bundle.js +0 -2
  198. package/dist/21195.caae6cc33d755ad52df4.bundle.js.map +0 -1
  199. package/dist/29350.9976c09d5cdaa48ecb19.bundle.js +0 -2
  200. package/dist/29350.9976c09d5cdaa48ecb19.bundle.js.map +0 -1
  201. package/dist/34330.4b46c3a52d19f05fc0b2.bundle.js.map +0 -1
  202. package/dist/36633.bd17a2028ef302870ec4.bundle.js +0 -2
  203. package/dist/36633.bd17a2028ef302870ec4.bundle.js.map +0 -1
  204. package/dist/36665.eda6cfdf545f2608a6c7.bundle.js +0 -2
  205. package/dist/36665.eda6cfdf545f2608a6c7.bundle.js.map +0 -1
  206. package/dist/40516.734b24eead67142c4045.bundle.js +0 -2
  207. package/dist/40516.734b24eead67142c4045.bundle.js.map +0 -1
  208. package/dist/42143.c11e5c28f2b8e9952dbb.bundle.js +0 -2
  209. package/dist/42143.c11e5c28f2b8e9952dbb.bundle.js.map +0 -1
  210. package/dist/44874.5854c207bbe2c4f2438e.bundle.js +0 -2
  211. package/dist/44874.5854c207bbe2c4f2438e.bundle.js.map +0 -1
  212. package/dist/49539.d253a79e8b9710776e48.bundle.js +0 -2
  213. package/dist/49539.d253a79e8b9710776e48.bundle.js.map +0 -1
  214. package/dist/51087.b072d1c0e53403535283.bundle.js.map +0 -1
  215. package/dist/55217.4769c1f0615e364d8c2a.bundle.js.map +0 -1
  216. package/dist/60039.cb9262af0bc63b635c76.bundle.js +0 -2
  217. package/dist/60039.cb9262af0bc63b635c76.bundle.js.map +0 -1
  218. package/dist/63415.81af22cc29be1144e07f.bundle.js +0 -2
  219. package/dist/63415.81af22cc29be1144e07f.bundle.js.map +0 -1
  220. package/dist/64118.fb6952c8ef6fc9117f35.bundle.js +0 -2
  221. package/dist/64118.fb6952c8ef6fc9117f35.bundle.js.map +0 -1
  222. package/dist/67232.e76f40f9d09e64ebb365.bundle.js +0 -2
  223. package/dist/67232.e76f40f9d09e64ebb365.bundle.js.map +0 -1
  224. package/dist/70938.6d0055f916f6d1bc91bb.bundle.js +0 -2
  225. package/dist/70938.6d0055f916f6d1bc91bb.bundle.js.map +0 -1
  226. package/dist/71920.46e7b0ec1d22adcd8e55.bundle.js +0 -2
  227. package/dist/71920.46e7b0ec1d22adcd8e55.bundle.js.map +0 -1
  228. package/dist/73964.fd1ad5e7aa228ad4cbbb.bundle.js +0 -2
  229. package/dist/73964.fd1ad5e7aa228ad4cbbb.bundle.js.map +0 -1
  230. package/dist/75849.bd0bdefa903741034a71.bundle.js +0 -2
  231. package/dist/75849.bd0bdefa903741034a71.bundle.js.map +0 -1
  232. package/dist/76013.3211939a02cf4fb2529e.bundle.js +0 -2
  233. package/dist/76013.3211939a02cf4fb2529e.bundle.js.map +0 -1
  234. package/dist/7928.7900a3911c83495d74dd.bundle.js +0 -2
  235. package/dist/7928.7900a3911c83495d74dd.bundle.js.map +0 -1
  236. package/dist/85609.680b755726c66ea1de34.bundle.js +0 -2
  237. package/dist/85609.680b755726c66ea1de34.bundle.js.map +0 -1
  238. package/dist/85788.4e0818c48b6f29153db4.bundle.js +0 -2
  239. package/dist/85788.4e0818c48b6f29153db4.bundle.js.map +0 -1
  240. package/dist/86142.c29959b68edc59a9b696.bundle.js +0 -2
  241. package/dist/86142.c29959b68edc59a9b696.bundle.js.map +0 -1
  242. package/dist/89695.4ee87c52d4088115c51e.bundle.js.map +0 -1
  243. package/dist/96089.7e28823f34c450de1f7e.bundle.js +0 -2
  244. package/dist/96089.7e28823f34c450de1f7e.bundle.js.map +0 -1
  245. /package/dist/{12358.2061f29dc113149946a3.bundle.js.LICENSE.txt → 12358.4be185f89eebea9c35bf.bundle.js.LICENSE.txt} +0 -0
  246. /package/dist/{legacyWorkbench.2bd696723af2573e8bb7.js.LICENSE.txt → legacyWorkbench.ecf6300fd72cfffbcdb6.js.LICENSE.txt} +0 -0
@@ -1 +0,0 @@
1
- {"version":3,"file":"64118.fb6952c8ef6fc9117f35.bundle.js","mappings":"6NAKA,MAAMA,EAAgC,CAClCC,YAAa,4DAGXC,EAASC,EAAAA,eAAeD,OAa9B,SAASE,EAAgBC,GACrB,MAAMC,GAAmBC,EAAAA,EAAAA,KACpBC,IAAIC,EAAAA,wBACJD,IAAIE,EAAAA,iCAAkCV,GAiC3C,MAAO,CACHW,eAXmBA,CAACC,EAAMC,KAC1B,IACI,OAAOR,EAAKS,YAjBCD,IACbA,GACON,EAAAA,EAAAA,KACFC,IAAIC,EAAAA,uBAAwBI,GAC5BL,IAAIE,EAAAA,iCAAkCK,EAAEC,MAAM,CAAC,EAAGhB,EAA+Ba,IAEnFP,EAWqBW,CAAYJ,GAAQK,OAAON,GACvD,CAAE,MAAOO,GAGL,OAFAjB,EAAOkB,MAAM,4BAA6BD,GAEnCd,E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IC,MAAOnM,EAAWgC,QAAQ,kBAC1BoK,SAASC,EAAAA,EAAAA,IAAWrM,EAAWgC,QAAQ,wDAAyD,CAACxC,aAAcsB,EAAOtB,gBACtH8M,iBAAkB,qCAEtB,KACId,EAAce,cAAcf,EAAcgB,cAAc1L,EAAOtB,eAC/DyM,EAA2BnL,EAAO0B,UAgBlD,MAAMyJ,EAA8BzJ,IAEhCkJ,EAAQe,KAAK,iBAAiBC,mBAAmBlK,cAAkBqJ,IAAW,UAEtF,EAER,CApFAzN,QACKC,OAAO,0DAA2D,IAClEmG,UAAU,qBAAsB+G,GAErCA,EAA4BhN,QAAU,CAAC,gBAAiB,aAAc,eAAgB,U","sources":["webpack://root-config/./packages/legacy-workbench/src/js/angular/core/services/markdown/markdown.service.js","webpack://root-config/./packages/legacy-workbench/src/js/angular/core/services/markdown/plugins/markdown-open-in-sparql-editor-plugin.js","webpack://root-config/./packages/legacy-workbench/src/js/angular/ttyg/directives/chat-item-detail.directive.js","webpack://root-config/./packages/legacy-workbench/src/js/angular/ttyg/services/ttyg.utils.js","webpack://root-config/./packages/legacy-workbench/src/js/angular/ttyg/services/ttyg-context.service.js","webpack://root-config/./packages/legacy-workbench/src/js/angular/core/services/markdown/plugins/markdown-code-copy-plugin.js","webpack://root-config/./packages/legacy-workbench/src/js/angular/core/directives/markdown-content/markdown-content.js","webpack://root-config/./packages/legacy-workbench/src/js/angular/core/directives/open-in-sparql-editor/open-in-sparql-editor.directive.js"],"sourcesContent":["import markdownIt from 'markdown-it';\nimport {markdownCodeCopyPlugin} from \"./plugins/markdown-code-copy-plugin\";\nimport {markdownOpenInSparqlEditorPlugin} from \"./plugins/markdown-open-in-sparql-editor-plugin\";\nimport {LoggerProvider} from \"../logger-provider\";\n\nconst OPEN_IN_SPARQL_PLUGIN_OPTIONS = {\n buttonStyle: 'position: absolute; top: 0; right: 0; margin-right: 24px',\n};\n\nconst logger = LoggerProvider.logger;\n\n/**\n * AngularJS service that provides methods for rendering Markdown text.\n * @class MarkdownService\n * @param {$sce} $sce - AngularJS service for Strict Contextual Escaping.\n */\nangular\n .module('graphdb.framework.core.services.markdown-service', [])\n .service('MarkdownService', MarkdownService);\n\nMarkdownService.$inject = ['$sce'];\n\nfunction MarkdownService($sce) {\n const markdownInstance = markdownIt()\n .use(markdownCodeCopyPlugin)\n .use(markdownOpenInSparqlEditorPlugin, OPEN_IN_SPARQL_PLUGIN_OPTIONS);\n\n /**\n * Retrieves a Markdown-it instance with optional custom configuration.\n * @function getMarkdown\n * @param {Object} [config] - Optional custom configuration for Markdown-it.\n * @return {Object} The Markdown instance.\n */\n const getMarkdown = (config) => {\n if (config) {\n return markdownIt()\n .use(markdownCodeCopyPlugin, config)\n .use(markdownOpenInSparqlEditorPlugin, _.merge({}, OPEN_IN_SPARQL_PLUGIN_OPTIONS, config));\n }\n return markdownInstance;\n };\n\n /**\n * Renders Markdown text into HTML.\n * @function renderMarkdown\n * @param {string} text - The Markdown text to render.\n * @return {string} The rendered HTML, or the original text in case of an error.\n */\n const renderMarkdown = (text, config) => {\n try {\n return $sce.trustAsHtml(getMarkdown(config).render(text));\n } catch (e) {\n logger.error('Error rendering markdown:', e);\n // Return the original text in case of an error\n return $sce.trustAsHtml(text);\n }\n };\n\n return {\n renderMarkdown,\n };\n}\n","const DEFAULT_MARKDOWN_CONFIGURATION = {\n buttonStyle: \"position: absolute; top: 0; right: 0;\",\n buttonClass: \"\"\n};\n\n/**\n * This function enhances the rendering of fenced code blocks in markdown that contain SPARQL queries\n * by appending an \"open in SPARQL editor\" button to each SPARQL code block.\n *\n * @param {Function} origRule The original rule function responsible for rendering code blocks.\n * @param {Object} options The options to customize the rendering. These will be merged with the default configuration.\n * Options model description:\n * ```JSON\n * {\n * // Inline CSS styles applied to position the button inside the code block. Defaults to positioning the button at the top-right of the block.\n * buttonStyle: \"position: absolute; top: 0; right: 0;\",\n * // The CSS class for styling the button.\n * buttonClass: \"\",\n * // A flag that determines whether the SPARQL query should be automatically executed when opened in the SPARQL editor. Defaults to `false`.\n * executeQuery: false,\n * // The ID of the repository that the SPARQL query will be executed against.\n * repositoryId: ''\n * }\n * ```\n *\n * @return {Function} A function that renders a fenced code block with an \"open in SPARQL editor\" button when the block is recognized as containing SPARQL code.\n */\nfunction renderCode(origRule, options) {\n options = _.merge({}, DEFAULT_MARKDOWN_CONFIGURATION, options);\n return (...args) => {\n const [tokens, idx] = args;\n const token = tokens[idx];\n\n const content = tokens[idx].content\n .replaceAll('\"', '&quot;')\n .replaceAll(\"'\", \"&apos;\");\n const origRendered = origRule(...args);\n\n if (token.type === 'fence' && token.info === 'sparql' && origRendered.trim()) {\n return `<div style=\"position: relative\">\n ${origRendered}\n <open-in-sparql-editor\n style=\"${options.buttonStyle}\"\n class=\"${options.buttonClass}\"\n execute-query=\"${options.executeQuery}\"\n repository-id=\"${options.repositoryId}\"\n query=\"${content}\">\n </open-in-sparql-editor>\n </div>`;\n } else {\n return origRendered;\n }\n };\n}\n\nexport const markdownOpenInSparqlEditorPlugin = (md, options) => {\n md.renderer.rules.code_block = renderCode(md.renderer.rules.code_block, options);\n md.renderer.rules.fence = renderCode(md.renderer.rules.fence, options);\n};\n","import 'angular/core/directives/markdown-content/markdown-content';\nimport 'angular/core/directives/open-in-sparql-editor/open-in-sparql-editor.directive';\nimport {TTYGEventName} from \"../services/ttyg-context.service\";\nimport {ExplainQueryType} from \"../../models/ttyg/explain-response\";\nimport {getHumanReadableTimestamp} from \"../services/ttyg.utils\";\n\nconst modules = [\n 'graphdb.framework.core.directives.open-in-sparql-editor',\n 'graphdb.framework.core.directives.markdown-content'\n];\n\nangular\n .module('graphdb.framework.ttyg.directives.chat-item-detail', modules)\n .directive('chatItemDetail', ChatItemDetailComponent);\n\nChatItemDetailComponent.$inject = ['toastr', '$translate', 'TTYGContextService', 'TTYGService', '$filter'];\n\n/**\n * @ngdoc directive\n * @name graphdb.framework.ttyg.directives.chat-detail:chatItemDetail\n * @restrict E\n * @description\n *\n * This directive represents a component that displays a chat data.\n *\n * @example\n * <chat-item-detail chat-item=\"chatItem\"></chat-item-detail>\n */\nfunction ChatItemDetailComponent(toastr, $translate, TTYGContextService, TTYGService, $filter) {\n return {\n restrict: 'E',\n templateUrl: 'js/angular/ttyg/templates/chat-item-detail.html',\n scope: {\n chatItemDetail: '=',\n showActions: '=',\n asking: '=',\n disabled: '=',\n onRegenerateQuestion: '&',\n onAskHowDeliveredAnswer: '&'\n },\n link: ($scope, element, attrs) => {\n\n // =========================\n // Public variables\n // =========================\n\n $scope.ExplainQueryType = ExplainQueryType;\n $scope.repositoryId = undefined;\n $scope.markdownContentOptions = undefined;\n\n /**\n * Mapping of agent id to agent name which is used to display the agent name in the UI.\n * @type {{[key: string]: string}}\n */\n $scope.agentNameByIdMap = {};\n\n /**\n * @type {{[key: string]: ExplainResponseModel}}\n */\n $scope.explainResponseModel = {};\n\n /**\n * Mapping of answer id to a boolean value indicating whether the explanation of how the answer was\n * generated is being loaded.\n * @type {{[key: string]: boolean}}\n */\n $scope.loadingExplainResponse = {};\n\n // =========================\n // Private variables\n // =========================\n\n // =========================\n // Public functions\n // =========================\n $scope.regenerateQuestion = () => {\n $scope.onRegenerateQuestion({chatItem: $scope.chatItemDetail});\n };\n\n /**\n * Extract the explanation of how the answer was generated.\n * @param {string} answerId\n */\n $scope.explainResponse = (answerId) => {\n if (TTYGContextService.hasExplainResponse(answerId)) {\n TTYGContextService.toggleExplainResponse(answerId);\n } else {\n $scope.loadingExplainResponse[answerId] = true;\n TTYGService.explainResponse($scope.chatItemDetail, answerId)\n .then((explainResponse) => {\n TTYGContextService.addExplainResponseCache(explainResponse);\n })\n .catch(() => {\n toastr.error($translate.instant('ttyg.chat_panel.messages.explain_response_failure'));\n })\n .finally(() => $scope.loadingExplainResponse[answerId] = false);\n }\n };\n\n /**\n * Triggers an asking how the answer was generated.\n */\n $scope.onAskHowAnswerWasDerived = () => {\n $scope.onAskHowDeliveredAnswer();\n };\n\n /**\n * Handles the click event on the token usage info button.\n * No additional actions are needed at this time; the handler simply prevents\n * the default button behavior and stops the event from bubbling up.\n *\n * @param {Event} event - The click event object.\n */\n $scope.onTokenUsageInfo = (event) => {\n event.preventDefault();\n event.stopPropagation();\n };\n\n /**\n * Opens <code>query</code> in sparql editor.\n * @param {string} query\n */\n $scope.onOpenInSparqlEditor = (query) => {\n if ($scope.chatItemDetail.agentId) {\n TTYGContextService.emit(TTYGEventName.GO_TO_SPARQL_EDITOR, {\n query,\n repositoryId: $scope.repositoryId\n });\n }\n };\n\n $scope.showRawQuery = (queryMethod) => {\n // TODO: Create a chat panel model and move this check there when the model is updated.\n const rawQueryNoSpaces = queryMethod.rawQuery.replace(/\\s+/g, '');\n const queryNoSpaces = queryMethod.query.replace(/\\s+/g, '');\n return rawQueryNoSpaces && rawQueryNoSpaces !== queryNoSpaces;\n };\n\n $scope.getRepositoryId = (f) => {\n const agent = TTYGContextService.getAgent($scope.chatItemDetail.agentId);\n return agent ? agent.repositoryId : '';\n };\n\n $scope.getHumanReadableQuestionTimestamp = (timestamp) => {\n return getHumanReadableTimestamp($translate, $filter, timestamp);\n };\n\n // =========================\n // Private functions\n // =========================\n const init = () => {\n $scope.repositoryId = $scope.getRepositoryId();\n $scope.markdownContentOptions = {repositoryId: $scope.repositoryId};\n updateExplainResponseModel();\n };\n\n const onExplainResponseCacheUpdated = () => {\n updateExplainResponseModel();\n };\n\n const updateExplainResponseModel = () => {\n $scope.chatItemDetail.answers.forEach((answer) => {\n $scope.explainResponseModel[answer.id] = TTYGContextService.getExplainResponse(answer.id);\n });\n };\n\n const onAgentsListChanged = () => {\n $scope.agentNameByIdMap = TTYGContextService.getAgents().agentNameByIdMap;\n };\n\n // =========================\n // Subscriptions\n // =========================\n const subscriptions = [];\n\n const removeAllSubscribers = () => {\n subscriptions.forEach((subscription) => subscription());\n };\n\n subscriptions.push(TTYGContextService.onExplainResponseCacheUpdated(onExplainResponseCacheUpdated));\n subscriptions.push(TTYGContextService.onAgentsListChanged(onAgentsListChanged));\n\n // Deregister the watcher when the scope/directive is destroyed\n $scope.$on('$destroy', removeAllSubscribers);\n\n // =========================\n // Initialization\n // =========================\n init();\n }\n };\n}\n","export const getHumanReadableTimestamp = ($translate, $filter, timestamp, options = {}) => {\n\n if (!timestamp) {\n return '';\n }\n\n const date = new Date(timestamp);\n const today = new Date();\n\n // Get start of today\n const todayStart = new Date(today.getFullYear(), today.getMonth(), today.getDate());\n\n // Get start of yesterday\n const yesterdayStart = new Date(todayStart);\n yesterdayStart.setDate(todayStart.getDate() - 1);\n\n // Get start of the timestamp's day\n const dateStart = new Date(date.getFullYear(), date.getMonth(), date.getDate());\n const time = options.timeFormat ? $filter('date')(date, options.timeFormat) : '';\n\n if (dateStart.getTime() === todayStart.getTime()) {\n return $translate.instant('common.dates.today') + time;\n } else if (dateStart.getTime() === yesterdayStart.getTime()) {\n return $translate.instant('common.dates.yesterday') + time;\n } else {\n // ISO format is the least ambiguous if no date format is passed.\n const dateFormat = options.dateFormat || 'yyyy-MM-dd';\n return $filter('date')(date, dateFormat) + time;\n }\n};\n","import {cloneDeep} from 'lodash';\n\nangular\n .module('graphdb.framework.ttyg.services.ttygcontext', [])\n .factory('TTYGContextService', TTYGContextService);\n\nTTYGContextService.$inject = ['EventEmitterService', 'TTYGService'];\n\nfunction TTYGContextService(EventEmitterService) {\n\n /**\n * The list of agents.\n * @type {AgentListModel}\n * @private\n */\n let _agents = undefined;\n\n /**\n * The ChatsListModel.\n * @type {ChatsListModel}\n * @private\n */\n let _chats = undefined;\n\n /**\n * The currently selected in the UI chat which is used for conversation.\n * @type {ChatModel|undefined}\n * @private\n */\n let _selectedChat = undefined;\n\n /**\n * The currently selected in the UI agent which is used for conversation.\n * @type {AgentModel|undefined}\n * @private\n */\n let _selectedAgent = undefined;\n\n /**\n * Stores information about loaded explain responses.\n * The key is the answer ID, and the value is an instance of {@see ExplainResponseModel} that holds the explanation message.\n *\n * @type {{[key: string]: ExplainResponseModel}}\n */\n let _explainCache = {};\n\n /**\n * The default agent values.\n * @type {AgentModel|undefined}\n * @private\n */\n let _defaultAgent = undefined;\n\n let _canModifyAgent = false;\n\n const resetContext = () => {\n _agents = undefined;\n _chats = undefined;\n _selectedChat = undefined;\n _selectedAgent = undefined;\n _explainCache = {};\n _defaultAgent = undefined;\n _canModifyAgent = false;\n };\n\n /**\n * @return {Promise<AgentModel>}\n */\n const getDefaultAgent = () => {\n return cloneDeep(_defaultAgent);\n };\n\n const setDefaultAgent = (agent) => {\n _defaultAgent = agent;\n };\n\n /**\n * @return {AgentListModel}\n */\n const getAgents = () => {\n return cloneDeep(_agents);\n };\n\n const getAgent = (agentId) => {\n if (_agents) {\n return cloneDeep(_agents.getAgent(agentId));\n }\n };\n\n /**\n * @return {ChatsListModel}\n */\n const getChats = () => {\n return cloneDeep(_chats);\n };\n\n /**\n * @param {ChatsListModel} chats\n */\n const updateChats = (chats) => {\n _chats = cloneDeep(chats);\n emit(TTYGEventName.CHAT_LIST_UPDATED, getChats());\n };\n\n /**\n * Deletes the chat with the provided <code>chatId</code>.\n * @param {ChatModel} chat\n */\n const deleteChat = (chat) => {\n _chats.deleteChat(chat);\n updateChats(_chats);\n };\n\n const addChat = (newChat) => {\n _chats.appendChat(newChat);\n updateChats(_chats);\n };\n\n const replaceChat = (newChat, oldChat) => {\n _chats.replaceChat(newChat, oldChat);\n updateChats(_chats);\n };\n\n /** Subscribes to the 'chatListUpdated' event.\n * @param {function} callback - The callback to be called when the event is fired.\n *\n * @return {function} unsubscribe function.\n */\n const onChatsListChanged = (callback) => {\n if (_chats && angular.isFunction(callback)) {\n callback(getChats());\n }\n return subscribe(TTYGEventName.CHAT_LIST_UPDATED, (chats) => callback(chats));\n };\n\n /**\n * @return {ChatModel}\n */\n const getSelectedChat = () => {\n return cloneDeep(_selectedChat);\n };\n\n /**\n * Updates the selected chat with the provided <code>selectedChat</code> and emits the 'selectChat' event\n * to notify listeners that a new chat has been selected.\n *\n * @param {ChatModel} selectedChat - The chat object to select.\n */\n const selectChat = (selectedChat) => {\n if (!_selectedChat || _selectedChat.id !== selectedChat.id) {\n _selectedChat = cloneDeep(selectedChat);\n emit(TTYGEventName.SELECT_CHAT, getSelectedChat());\n }\n };\n\n const deselectChat = () => {\n _selectedChat = undefined;\n emit(TTYGEventName.SELECT_CHAT, getSelectedChat());\n };\n\n /**\n * Subscribes to the 'selectChat' event.\n * @param {function} callback - The callback to be called when the event is fired.\n *\n * @return {function} unsubscribe function.\n */\n const onSelectedChatChanged = (callback) => {\n if (angular.isFunction(callback)) {\n callback(getSelectedChat());\n }\n return subscribe(TTYGEventName.SELECT_CHAT, (selectedChat) => callback(selectedChat));\n };\n\n /**\n * Updates the selected chat and emits the 'selectChatUpdated' event to notify listeners that a property\n * of the selected chat has changed.\n *\n * If the ID of the passed chat differs from the current selected chat, no action will occur.\n *\n * The selected chat can be updated through {@link TTYGContextService#selectChat}.\n *\n * @param {ChatModel} chat - The chat object that is being updated.\n */\n const updateSelectedChat = (chat) => {\n if (!_selectedChat || !_selectedChat.id || !chat || _selectedChat.id === chat.id) {\n _selectedChat = cloneDeep(chat);\n emit(TTYGEventName.SELECTED_CHAT_UPDATED, getSelectedChat());\n }\n };\n\n /** Subscribes to the 'selectChat' event.\n * @param {function} callback - The callback to be called when the event is fired.\n *\n * @return {function} unsubscribe function.\n */\n const onSelectedChatUpdated = (callback) => {\n if (_selectedChat && angular.isFunction(callback)) {\n callback(getSelectedChat());\n }\n return subscribe(TTYGEventName.SELECTED_CHAT_UPDATED, (selectedChat) => callback(selectedChat));\n };\n\n /** Subscribes to the 'lastMessageReceived' event.\n * @param {function} callback - The callback to be called when the event is fired.\n *\n * @return {function} unsubscribe function.\n */\n const onLastMessageReceived = (callback) => {\n if (_selectedChat && angular.isFunction(callback)) {\n callback(getSelectedChat());\n }\n return subscribe(TTYGEventName.LAST_MESSAGE_RECEIVED, (selectedChat) => callback(selectedChat));\n };\n\n /**\n * @param {AgentListModel} agents\n */\n const updateAgents = (agents) => {\n _agents = cloneDeep(agents);\n emit(TTYGEventName.AGENT_LIST_UPDATED, getAgents());\n };\n\n /**\n * Subscribes to the 'agentListUpdated' event.\n * @param {function} callback - The callback to be called when the event is fired.\n *\n * @return {function} unsubscribe function.\n */\n const onAgentsListChanged = (callback) => {\n if (_agents && angular.isFunction(callback)) {\n callback(getAgents());\n }\n return subscribe(TTYGEventName.AGENT_LIST_UPDATED, (selectedChat) => callback(selectedChat));\n };\n\n /**\n * @return {AgentModel}\n */\n const getSelectedAgent = () => {\n return cloneDeep(_selectedAgent);\n };\n\n /**\n * Updates the selected agent with the provided <code>selectedAgent</code> and emits the 'agentSelected' event\n * to notify listeners that a new agent has been selected.\n *\n * @param {AgentModel} selectedAgent - The instance of selected agent.\n */\n const selectAgent = (selectedAgent) => {\n _selectedAgent = cloneDeep(selectedAgent);\n emit(TTYGEventName.AGENT_SELECTED, getSelectedAgent());\n };\n\n const _getExplainResponseCache = () => {\n return cloneDeep(_explainCache);\n };\n\n /**\n * Gets the explain response.\n * @param {string} answerId\n * @return {ExplainResponseModel}\n */\n const getExplainResponse = (answerId) => {\n return cloneDeep(_explainCache[answerId]);\n };\n\n /**\n * Adds the <code>explainResponse</code> into the explain response cache.\n *\n * @param {ExplainResponseModel} explainResponse\n */\n const addExplainResponseCache = (explainResponse) => {\n _explainCache[explainResponse.answerId] = cloneDeep(explainResponse);\n emit(TTYGEventName.EXPLAIN_RESPONSE_CACHE_UPDATED, _getExplainResponseCache());\n };\n\n const hasExplainResponse = (answerId) => {\n return !!_explainCache[answerId];\n };\n\n const toggleExplainResponse = (answerId) => {\n if (hasExplainResponse(answerId)) {\n _explainCache[answerId].expanded = !_explainCache[answerId].expanded;\n emit(TTYGEventName.EXPLAIN_RESPONSE_CACHE_UPDATED, _getExplainResponseCache());\n }\n };\n\n /**\n * Subscribes to the 'explainResponseCacheUpdated' event.\n * @param {function} callback - The callback to be called when the event is fired.\n *\n * @return {function} unsubscribe function.\n */\n const onExplainResponseCacheUpdated = (callback) => {\n if (angular.isFunction(callback)) {\n callback(_getExplainResponseCache());\n }\n return subscribe(TTYGEventName.EXPLAIN_RESPONSE_CACHE_UPDATED, (explainResponses) => callback(explainResponses));\n };\n\n /**\n * Subscribes to the 'agentSelected' event.\n * @param {function} callback - The callback to be called when the event is fired.\n *\n * @return {function} unsubscribe function.\n */\n const onSelectedAgentChanged = (callback) => {\n if (_selectedAgent && angular.isFunction(callback)) {\n callback(getSelectedAgent());\n }\n return subscribe(TTYGEventName.AGENT_SELECTED, (selectedChat) => callback(selectedChat));\n };\n\n /**\n * Updates the \"canModifyAgent\" flag and emits the 'canModifyAgentUpdated' event to notify listeners that the canModifyAgent flag is changed.\n *\n * @param {boolean} canModifyAgent\n */\n const setCanModifyAgent = (canModifyAgent) => {\n _canModifyAgent = cloneDeep(canModifyAgent);\n emit(TTYGEventName.CAN_MODIFY_AGENT_UPDATED, getCanModifyAgent());\n };\n\n const getCanModifyAgent = () => {\n return _canModifyAgent;\n };\n\n /**\n * Subscribes to the 'canModifyAgentUpdated' event.\n * @param {function} callback - The callback to be called when the event is fired.\n *\n * @return {function} unsubscribe function.\n */\n const onCanUpdateAgentUpdated = (callback) => {\n if (angular.isFunction(callback)) {\n callback(getCanModifyAgent());\n }\n return subscribe(TTYGEventName.CAN_MODIFY_AGENT_UPDATED, (canModifyAgent) => callback(canModifyAgent));\n };\n\n /**\n * Emits an event with a deep-cloned payload using the EventEmitterService.\n *\n * @param {string} tTYGEventName - The name of the event to emit. It must be a value from {@link TTYGEventName}.\n * @param {*} payload - The data to emit with the event. The payload is deep-cloned before emission.\n */\n const emit = (tTYGEventName, payload) => {\n EventEmitterService.emitSync(tTYGEventName, cloneDeep(payload));\n };\n\n /**\n * Subscribes to an event with the specified callback using the EventEmitterService.\n *\n * @param {string} tTYGEventName - The name of the event to subscribe to. It must be a value from {@link TTYGEventName}.\n * @param {function} callback - The function to call when the event is emitted.\n * @return {function} - Returns a function that can be called to unsubscribe from the event.\n */\n const subscribe = (tTYGEventName, callback) => {\n return EventEmitterService.subscribeSync(tTYGEventName, (payload) => callback(payload));\n };\n\n return {\n resetContext,\n emit,\n subscribe,\n // chats\n getChats,\n updateChats,\n addChat,\n replaceChat,\n onChatsListChanged,\n getSelectedChat,\n selectChat,\n deselectChat,\n deleteChat,\n onSelectedChatChanged,\n updateSelectedChat,\n onSelectedChatUpdated,\n onLastMessageReceived,\n // agents\n updateAgents,\n onAgentsListChanged,\n getAgents,\n getAgent,\n selectAgent,\n getSelectedAgent,\n onSelectedAgentChanged,\n getDefaultAgent,\n setDefaultAgent,\n setCanModifyAgent,\n getCanModifyAgent,\n onCanUpdateAgentUpdated,\n // chat explain\n hasExplainResponse,\n toggleExplainResponse,\n getExplainResponse,\n addExplainResponseCache,\n onExplainResponseCacheUpdated\n };\n}\n\nexport const TTYGEventName = {\n /**\n * Emitting the \"createChat\" event triggers a backend request to create a new chat.\n */\n CREATE_CHAT: 'createChat',\n\n /**\n * This event is emitted when a chat is successfully created.\n */\n CREATE_CHAT_SUCCESSFUL: 'chatCreated',\n\n /**\n * This event is emitted when the creation of a chat fails.\n */\n CREATE_CHAT_FAILURE: 'chatCreationFailed',\n\n RENAME_CHAT: 'renameChat',\n RENAME_CHAT_SUCCESSFUL: 'chatRenamed',\n RENAME_CHAT_FAILURE: 'chatRenamedFailure',\n\n /**\n * Emitting the \"selectChat\" event when the selected chat has been changed.\n */\n SELECT_CHAT: 'selectChat',\n\n /**\n * Emitting the \"selectChatUpdated\" event when the selected chat has been updated.\n */\n SELECTED_CHAT_UPDATED: 'selectChatUpdated',\n\n /**\n * Emitting the \"lastMessageReceived\" event when the final answer message has been received.\n */\n LAST_MESSAGE_RECEIVED: 'lastMessageReceived',\n\n /**\n * This event will be emitted when the chat delete request is in progress. The payload will contain the chat ID\n * and a boolean indicating if the deletion is in progress.\n */\n DELETING_CHAT: 'deletingChat',\n\n /**\n * This event will be emitted when the delete chat process is triggered but before the chat delete request is sent.\n */\n DELETE_CHAT: 'deleteChat',\n\n /**\n * This event will be emitted when the chat was successfully deleted.\n */\n DELETE_CHAT_SUCCESSFUL: 'chatDeleted',\n\n /**\n * This event will be emitted when the attempt to answer the question fails.\n */\n\n /**\n * This event is emitted when the deletion of a chat fails.\n */\n DELETE_CHAT_FAILURE: 'chatDeletedFailure',\n\n CHAT_EXPORT: 'chatExport',\n CHAT_EXPORT_SUCCESSFUL: 'chatExportSuccess',\n CHAT_EXPORT_FAILURE: 'chatExportFailure',\n CHAT_LIST_UPDATED: 'chatListUpdated',\n\n /**\n * Emitting the \"askQuestion\" event triggers a request to the backend to retrieve an answer to a question.\n */\n ASK_QUESTION: 'askQuestion',\n\n /**\n * This event will be emitted when the attempt to answer the question fails.\n */\n ASK_QUESTION_FAILURE: 'askQuestionFailure',\n\n /**\n * Emitting the \"continueChatRun\" event triggers a request to the backend to retrieve more remaining answers from the same chat run.\n */\n CONTINUE_CHAT_RUN: 'continueChatRun',\n\n /**\n * Emitting the \"loadChats\" event will trigger an action to loads all chats from backend server.\n */\n LOAD_CHATS: 'loadChats',\n LOAD_CHAT_SUCCESSFUL: 'loadChatSuccess',\n LOAD_CHAT_FAILURE: 'loadChatFailure',\n\n AGENT_LIST_UPDATED: 'agentListUpdated',\n\n /**\n * This event will be emitted when the create agent process is triggered through the UI but before the agent create\n * request is sent. This is used to open the agent settings dialog.\n */\n OPEN_AGENT_SETTINGS: 'openAgentSettings',\n\n /**\n * This event will be emitted when an agent needs to be edited.\n */\n EDIT_AGENT: 'editAgent',\n\n /**\n * This event will be emitted when an agent needs to be cloned.\n */\n CLONE_AGENT: 'cloneAgent',\n\n /**\n * This event will be emitted when the delete agent process is triggered but before the agent delete request is sent.\n */\n DELETE_AGENT: 'deleteAgent',\n\n /**\n * This event will be emitted when the agent was successfully deleted.\n */\n AGENT_DELETED: 'agentDeleted',\n\n /**\n * This event will be emitted when the agent delete request is in progress. The payload will contain the agent ID\n * and a boolean indicating if the deletion is in progress.\n */\n DELETING_AGENT: 'deletingAgent',\n\n /**\n * This event will be emitted when an agent is selected by the user through the UI.\n */\n AGENT_SELECTED: 'agentSelected',\n\n /**\n * This event will trigger the opening of the similarity view.\n */\n GO_TO_CREATE_SIMILARITY_VIEW: \"goToCreateSimilarityView\",\n\n /**\n * This event will trigger the opening of the connectors view.\n */\n GO_TO_CONNECTORS_VIEW: \"goToConnectorsView\",\n\n /**\n * This event will trigger the opening of the \"Autocomplete index\" view.\n */\n GO_TO_AUTOCOMPLETE_INDEX_VIEW: \"goToAutocompleteIndexView\",\n\n /**\n * This event will trigger fetching a new explanation of how the answer was generated.\n */\n EXPLAIN_RESPONSE: \"explainResponse\",\n\n /**\n * This event will be emitted when the cache with explain responses changed.\n */\n EXPLAIN_RESPONSE_CACHE_UPDATED: \"explainResponseCacheUpdated\",\n\n /**\n * This event will trigger the opening of the sparql view.\n */\n GO_TO_SPARQL_EDITOR: \"openQueryInSparqlEditor\",\n\n CAN_MODIFY_AGENT_UPDATED: \"canModifyAgentUpdated\",\n};\n","const DEFAULT_MARKDOWN_CONFIGURATION = {\n buttonStyle: \"position: absolute; top: 0; right: 0;\",\n buttonClass: \"\"\n};\n\n/**\n * This function enhances the rendering of code blocks in markdown by appending a \"copy to clipboard\" button to each code block.\n *\n * @param {Function} origRule The original rule function responsible for rendering code blocks.\n * @param {Object} options The options to customize the rendering. These will be merged with the default configuration.\n * Options model description:\n * ```JSON\n * {\n * // Inline CSS styles applied to position the button inside the code block. Defaults to positioning the button at the top-right of the block.\n * buttonStyle: \"position: absolute; top: 0; right: 0;\",\n * // The CSS class for styling the button. The default applies Bootstrap-like styles with a small button size and a secondary theme\n * buttonClass: \"btn btn-link btn-sm secondary\",\n * }\n * ```\n * @return {Function} A function that renders a code block with a \"copy to clipboard\" button, when a fenced code block is detected.\n */\nfunction renderCode(origRule, options) {\n options = _.merge({}, DEFAULT_MARKDOWN_CONFIGURATION, options);\n return (...args) => {\n const [tokens, idx] = args;\n const token = tokens[idx];\n\n const content = tokens[idx].content\n .replaceAll('\"', '&quot;')\n .replaceAll(\"'\", \"&apos;\");\n const origRendered = origRule(...args);\n\n if (token.type === 'fence' && origRendered.trim()) {\n return `<div style=\"position: relative\">\n ${origRendered}\n <copy-to-clipboard\n style=\"${options.buttonStyle}\"\n class=\"${options.buttonClass}\"\n tooltip-text=\"ttyg.chat_panel.btn.copy_sparql.tooltip\"\n text-to-copy=\"${content}\">\n </copy-to-clipboard>\n </div>`;\n } else {\n return origRendered;\n }\n };\n}\n\nexport const markdownCodeCopyPlugin = (md, options) => {\n md.renderer.rules.code_block = renderCode(md.renderer.rules.code_block, options);\n md.renderer.rules.fence = renderCode(md.renderer.rules.fence, options);\n};\n","import 'angular/core/services/markdown/markdown.service';\n\nconst modules = [\n 'graphdb.framework.core.services.markdown-service'\n];\n\n/**\n * @ngdoc directive\n * @name graphdb.framework.core.directives.markdown-content:markdownContent\n * @restrict E\n *\n * @description\n * The `markdownContent` directive is used to render and compile Markdown content inside AngularJS applications.\n * It dynamically compiles any AngularJS directives within the rendered Markdown content, ensuring that the\n * directives are properly recognized and executed.\n *\n * @param {string=} content The markdown content to be rendered. This can be passed dynamically from the scope.\n * @param {object=} options Optional configuration object to pass to the Markdown rendering engine, providing\n * customization for how the Markdown is rendered.\n *\n * @example\n * Usage:\n * <markdown-content content=\"markdownText\" options=\"markdownOptions\"></markdown-content>\n */\nangular\n .module('graphdb.framework.core.directives.markdown-content', modules)\n .directive('markdownContent', markdownContentDirective);\n\nmarkdownContentDirective.$inject = ['$compile', 'MarkdownService'];\n\nfunction markdownContentDirective($compile, MarkdownService) {\n return {\n templateUrl: 'js/angular/core/templates/markdown-content/markdown-content.html',\n restrict: 'E',\n scope: {\n content: '@',\n options: '='\n },\n link: function ($scope, element) {\n\n // =========================\n // Public variables\n // =========================\n\n /**\n * The rendered HTML content generated from the provided Markdown.\n *\n * @type {string} markdownContent\n */\n $scope.markdownContent = undefined;\n\n // =========================\n // Private functions\n // =========================\n\n const init = () => {\n $scope.markdownContent = MarkdownService.renderMarkdown($scope.content, $scope.options);\n compileMarkdownAnswerContents();\n };\n\n /**\n * Manually compiles AngularJS directives within the dynamically generated markdown HTML content.\n * AngularJS does not automatically detect and compile directives inside HTML that is dynamically\n * inserted, so this function ensures that the content is compiled after it is rendered.\n */\n const compileMarkdownAnswerContents = () => {\n $scope.$evalAsync(() => {\n // Find the dynamically rendered element that needs to be compiled\n const markdownElement = element.find('.markdown-content');\n $compile(angular.element(markdownElement).contents())($scope);\n });\n };\n\n init();\n }\n };\n}\n","import {decodeHTML} from \"../../../../../app\";\n\n/**\n * @ngdoc directive\n * @name graphdb.framework.core.directives.open-in-sparql-editor.directive:openInSparqlEditor\n * @restrict E\n *\n * @description\n * This directive provides a button that allows users to open the SPARQL editor with a pre-defined query.\n * Optionally, it can handle repository switching before opening the editor and executing the query.\n * The directive can also trigger the query execution automatically if specified.\n *\n * @scope\n *\n * @param {string} query The SPARQL query to be opened and optionally executed in the SPARQL editor.\n * @param {string} repositoryId The ID of the repository to be selected before opening the SPARQL editor.\n * @param {string} executeQuery Flag that determines whether the query should be executed upon opening the editor.\n * It accepts 'true' or 'false'. If 'true', the query will be automatically executed.\n *\n * @example\n * <open-in-sparql-editor\n * query=\"SELECT * WHERE {?s ?p ?o}\"\n * repository-id=\"myRepository\"\n * execute-query=\"true\">\n * </open-in-sparql-editor>\n *\n * @requires $repositories\n * @requires $translate\n * @requires ModalService\n * @requires $window\n *\n * @param {string} query The SPARQL query to be executed in the new tab.\n */\n\nangular\n .module('graphdb.framework.core.directives.open-in-sparql-editor', [])\n .directive('openInSparqlEditor', openInSparqlEditorDirective);\n\nopenInSparqlEditorDirective.$inject = ['$repositories', '$translate', 'ModalService', '$window'];\n\nfunction openInSparqlEditorDirective($repositories, $translate, ModalService, $window) {\n return {\n // Note: the line-height of the element must match the line-height of the icon.\n // This defines a composite FontAwesome icon to match the style of the surrounding icons.\n template: `\n <style>\n .open-in-sparql-editor-btn {\n line-height: 0.75;\n }\n .open-in-sparql-editor-btn .fa:nth-child(2) {\n margin-left: -0.2em;\n margin-right: -0.2em;\n font-size: 0.9em;\n }\n </style>\n <button class=\"btn btn-link btn-sm open-in-sparql-editor-btn\" gdb-tooltip=\"{{'ttyg.chat_panel.btn.open_in_sparql_editor.tooltip' | translate}}\" ng-click=\"onGoToSparqlEditorView()\" guide-selector=\"open-in-sparql-editor-btn\">\n <i class=\"fa fa-bracket-curly\"></i><i class=\"fa fa-ellipsis\"></i><i class=\"fa fa-bracket-curly-right\"></i>\n </button>\n `,\n restrict: 'E',\n scope: {\n query: '@',\n repositoryId: '@',\n executeQuery: '@'\n },\n link: function ($scope, element) {\n\n // =========================\n // Public variables\n // =========================\n\n $scope.tooltipText = 'ttyg.chat_panel.btn.open_in_sparql_editor.tooltip';\n // =========================\n // Private functions\n // =========================\n const execute = $scope.executeQuery === 'true';\n\n // =========================\n // Public functions\n // =========================\n\n /**\n * Opens the SPARQL editor in a new browser tab with the specified query and optional execution.\n */\n $scope.onGoToSparqlEditorView = () => {\n const activeRepositoryId = $repositories.getActiveRepository();\n if (!activeRepositoryId || activeRepositoryId !== $scope.repositoryId) {\n // Open a confirmation modal before switching the repository\n ModalService.openConfirmationModal(\n {\n title: $translate.instant('common.confirm'),\n message: decodeHTML($translate.instant('ttyg.chat_panel.dialog.confirm_repository_change.body', {repositoryId: $scope.repositoryId})),\n confirmButtonKey: 'ttyg.chat_panel.btn.proceed.label'\n },\n () => {\n $repositories.setRepository($repositories.getRepository($scope.repositoryId));\n openInSparqlEditorInNewTab($scope.query);\n }\n );\n } else {\n // No repository switch needed, just open the SPARQL editor\n openInSparqlEditorInNewTab($scope.query);\n }\n };\n // =========================\n // Private functions\n // =========================\n\n /**\n * Opens SPARQL editor view with passed query and handles repository switch if necessary.\n * @param {string} query\n */\n const openInSparqlEditorInNewTab = (query) => {\n // Open the SPARQL editor in a new tab and execute the query\n $window.open(`/sparql?query=${encodeURIComponent(query)}&execute=${execute}`, '_blank');\n };\n }\n };\n}\n"],"names":["OPEN_IN_SPARQL_PLUGIN_OPTIONS","buttonStyle","logger","LoggerProvider","MarkdownService","$sce","markdownInstance","markdownIt","use","markdownCodeCopyPlugin","markdownOpenInSparqlEditorPlugin","renderMarkdown","text","config","trustAsHtml","_","merge","getMarkdown","render","e","error","angular","module","service","$inject","DEFAULT_MARKDOWN_CONFIGURATION","buttonClass","renderCode","origRule","options","args","tokens","idx","token","content","replaceAll","origRendered","type","info","trim","executeQuery","repositoryId","md","renderer","rules","code_block","fence","ChatItemDetailComponent","toastr","$translate","TTYGContextService","TTYGService","$filter","restrict","templateUrl","scope","chatItemDetail","showActions","asking","disabled","onRegenerateQuestion","onAskHowDeliveredAnswer","link","$scope","element","attrs","ExplainQueryType","undefined","markdownContentOptions","agentNameByIdMap","explainResponseModel","loadingExplainResponse","regenerateQuestion","chatItem","explainResponse","answerId","hasExplainResponse","toggleExplainResponse","then","addExplainResponseCache","catch","instant","finally","onAskHowAnswerWasDerived","onTokenUsageInfo","event","preventDefault","stopPropagation","onOpenInSparqlEditor","query","agentId","emit","TTYGEventName","GO_TO_SPARQL_EDITOR","showRawQuery","queryMethod","rawQueryNoSpaces","rawQuery","replace","queryNoSpaces","getRepositoryId","f","agent","getAgent","getHumanReadableQuestionTimestamp","timestamp","getHumanReadableTimestamp","updateExplainResponseModel","answers","forEach","answer","id","getExplainResponse","subscriptions","push","onExplainResponseCacheUpdated","onAgentsListChanged","getAgents","$on","removeAllSubscribers","subscription","directive","date","Date","today","todayStart","getFullYear","getMonth","getDate","yesterdayStart","setDate","dateStart","time","timeFormat","getTime","dateFormat","EventEmitterService","_agents","_chats","_selectedChat","_selectedAgent","_defaultAgent","_explainCache","_canModifyAgent","cloneDeep","getChats","updateChats","chats","CHAT_LIST_UPDATED","getSelectedChat","getSelectedAgent","_getExplainResponseCache","getCanModifyAgent","tTYGEventName","payload","emitSync","subscribe","callback","subscribeSync","resetContext","addChat","newChat","appendChat","replaceChat","oldChat","onChatsListChanged","isFunction","selectChat","selectedChat","SELECT_CHAT","deselectChat","deleteChat","chat","onSelectedChatChanged","updateSelectedChat","SELECTED_CHAT_UPDATED","onSelectedChatUpdated","onLastMessageReceived","LAST_MESSAGE_RECEIVED","updateAgents","agents","AGENT_LIST_UPDATED","selectAgent","selectedAgent","AGENT_SELECTED","onSelectedAgentChanged","getDefaultAgent","setDefaultAgent","setCanModifyAgent","canModifyAgent","CAN_MODIFY_AGENT_UPDATED","onCanUpdateAgentUpdated","expanded","EXPLAIN_RESPONSE_CACHE_UPDATED","explainResponses","factory","CREATE_CHAT","CREATE_CHAT_SUCCESSFUL","CREATE_CHAT_FAILURE","RENAME_CHAT","RENAME_CHAT_SUCCESSFUL","RENAME_CHAT_FAILURE","DELETING_CHAT","DELETE_CHAT","DELETE_CHAT_SUCCESSFUL","DELETE_CHAT_FAILURE","CHAT_EXPORT","CHAT_EXPORT_SUCCESSFUL","CHAT_EXPORT_FAILURE","ASK_QUESTION","ASK_QUESTION_FAILURE","CONTINUE_CHAT_RUN","LOAD_CHATS","LOAD_CHAT_SUCCESSFUL","LOAD_CHAT_FAILURE","OPEN_AGENT_SETTINGS","EDIT_AGENT","CLONE_AGENT","DELETE_AGENT","AGENT_DELETED","DELETING_AGENT","GO_TO_CREATE_SIMILARITY_VIEW","GO_TO_CONNECTORS_VIEW","GO_TO_AUTOCOMPLETE_INDEX_VIEW","EXPLAIN_RESPONSE","markdownContentDirective","$compile","markdownContent","$evalAsync","markdownElement","find","contents","openInSparqlEditorDirective","$repositories","ModalService","$window","template","tooltipText","execute","onGoToSparqlEditorView","activeRepositoryId","getActiveRepository","openInSparqlEditorInNewTab","openConfirmationModal","title","message","decodeHTML","confirmButtonKey","setRepository","getRepository","open","encodeURIComponent"],"sourceRoot":""}
@@ -1,2 +0,0 @@
1
- export const __webpack_id__=67232;export const __webpack_ids__=[67232];export const __webpack_modules__={67232:()=>{const e={title:"",content:"",elementSelector:void 0,placement:"bottom",url:void 0,type:"read-only-element",maxWaitTime:3,canBePaused:!0,onNextClick:void 0,disablePreviousFlow:!0,onNextValidate:()=>Promise.resolve(!0),onPreviousClick:void 0,skipPoint:!1,class:""},t=(e,t,i)=>()=>e.GuideUtils.waitFor(t,i).catch(t=>{throw e.toastr.error(e.$translate.instant("guide.unexpected.error.message")),t}),i=["click","dblclick","keydown","keypress","keyup","input","submit","scroll","wheel"],o=["scroll","wheel"],n=(e,t,o,n)=>()=>{o&&n.GuideUtils.getOrWaitFor(o).then(o=>{const n=i.filter(t=>!e.includes(t));t?n.forEach(e=>o.removeEventListener(e,s,!0)):n.forEach(e=>o.addEventListener(e,s,!0))})},l=(e,t)=>n([],!0,e,t),r=(e,t,i)=>n(e,!1,t,i),s=e=>{e.preventDefault(),e.stopPropagation()};PluginRegistry.add("guide.step",[{guideBlockName:"clickable-element",getStep:(i,o)=>{const n=angular.extend({},e,{advanceOn:{selector:i.clickableElementSelector||i.elementSelector,event:"click"},initPreviousStep:o.GuideUtils.defaultInitPreviousStep},i,{type:"clickable"});return n.beforeShowPromise||(n.beforeShowPromise=t(o,n.elementSelector,n.maxWaitTime)),n}},{guideBlockName:"focus-element",getStep:(i,o)=>{const n=angular.extend({},e,{initPreviousStep:o.GuideUtils.defaultInitPreviousStep},i);return n.beforeShowPromise||(n.beforeShowPromise=t(o,n.elementSelector,n.maxWaitTime)),n}},{guideBlockName:"read-only-element",getStep:(i,o)=>{const n=angular.extend({},e,{initPreviousStep:o.GuideUtils.defaultInitPreviousStep},i,{type:"readonly"});return n.beforeShowPromise||(n.beforeShowPromise=t(o,n.elementSelector,n.maxWaitTime)),n}},{guideBlockName:"scroll-only-element",getStep:(i,n)=>{const s={...e,initPreviousStep:n.GuideUtils.defaultInitPreviousStep,show:()=>r(o,i.elementSelector,n),hide:()=>l(i.elementSelector,n),...i};return s.beforeShowPromise||(s.beforeShowPromise=t(n,s.elementSelector,s.maxWaitTime)),s}},{guideBlockName:"input-element",getStep:(i,o)=>{const n=angular.extend({},e,{initPreviousStep:o.GuideUtils.defaultInitPreviousStep},i,{type:"input"});return n.beforeShowPromise||(n.beforeShowPromise=t(o,n.elementSelector,n.maxWaitTime)),n}},{guideBlockName:"copy-text-element",getSteps:(e,t)=>{const i=t.$translate,o=t.GuideUtils,n=e.text,l=document.createElement("code");l.innerText=n;const r=document.createElement("button"),s="guide-copy-to-input-query-button";let u;r.className=`btn btn-sm btn-secondary ${s}`,r.innerText=i.instant("guide.step_plugin.core-steps.copy-text-element.copy-to-input");const a=((e,t)=>i=>{i.preventDefault();const o=document.querySelector(e);o.value=t,o.dispatchEvent(new Event("input",{bubbles:!0}))})(o.getElementSelector(e.elementSelector),n);return[{guideBlockName:"input-element",options:{...e,content:"guide.step_plugin.core-steps.copy-text-element.content",textAsHtmlCodeElement:'<div class="shepherd-code">'+l.outerHTML+r.outerHTML+"</div>",show:e=>()=>{u=e.currentStep.el.querySelector(`.${s}`),u.addEventListener("click",a)},hide:()=>()=>{u&&u.removeEventListener("click",a)}}}]}},{guideBlockName:"info-message",getStep:(t,i)=>angular.extend({},e,{initPreviousStep:i.GuideUtils.defaultInitPreviousStep},t,{type:"readonly"})},{guideBlockName:"hold-and-wait-until-hidden",getStep:(t,i)=>angular.extend({},e,{initPreviousStep:i.GuideUtils.defaultInitPreviousStep,onNextValidate:()=>Promise.resolve(!i.GuideUtils.isVisible(t.elementSelectorToWait)),show:()=>r(o,t.elementSelector,i),hide:()=>l(t.elementSelector,i)},t)},{guideBlockName:"hold-and-wait-until-shown",getStep:(t,i)=>angular.extend({},e,{initPreviousStep:i.GuideUtils.defaultInitPreviousStep,onNextValidate:()=>Promise.resolve(i.GuideUtils.isVisible(t.elementSelectorToWait))},t,{type:"readonly"})},{guideBlockName:"wait-for-element-to-hide",getStep:(t,i)=>angular.extend({},e,{initPreviousStep:i.GuideUtils.defaultInitPreviousStep,beforeShowPromise:e=>i.GuideUtils.waitUntilHidden(t.elementSelectorToHide,t.timeToWait||2).catch(()=>{i.ShepherdService._abortGuide(e)}),show:e=>()=>{setTimeout(()=>e.next())}},t)},{guideBlockName:"wait-for-element-to-show",getStep:(t,i)=>angular.extend({},e,{initPreviousStep:i.GuideUtils.defaultInitPreviousStep,beforeShowPromise:e=>i.GuideUtils.getOrWaitFor(t.elementSelectorToShow,t.timeToWait||2).catch(()=>{i.ShepherdService._abortGuide(e)}),show:e=>()=>{setTimeout(()=>e.next())}},t)},{guideBlockName:"guide-end",getStep:(t,i)=>{const o={type:"readonly",title:t.title||"guide.step_plugin.guide-ended.title",content:t.content||"guide.step_plugin.guide-ended.content",lastStep:!0};return angular.extend({},e,{initPreviousStep:i.GuideUtils.defaultInitPreviousStep},t,o)}}])}};
2
- //# sourceMappingURL=67232.e76f40f9d09e64ebb365.bundle.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"67232.e76f40f9d09e64ebb365.bundle.js","mappings":"oHAAA,MAAMA,EAAa,CACfC,MAAO,GACPC,QAAS,GACTC,qBAAiBC,EACjBC,UAAW,SACXC,SAAKF,EACLG,KAAM,oBACNC,YAAa,EACbC,aAAa,EACbC,iBAAaN,EACbO,qBAAqB,EACrBC,eAAgBA,IAAMC,QAAQC,SAAQ,GACtCC,qBAAiBX,EACjBY,WAAW,EACXC,MAAO,IAULC,EAAoBA,CAACC,EAAUhB,EAAiBK,IAC3C,IACIW,EAASC,WAAWC,QAAQlB,EAAiBK,GAC/Cc,MAAOC,IAIJ,MAFAJ,EAASK,OAAOD,MAAMJ,EAASM,WAAWC,QAAQ,mCAE5CH,IAkBhBI,EAAoB,CACtB,QACA,WACA,UACA,WACA,QACA,QACA,SACA,SACA,SAEEC,EAAgB,CAAC,SAAU,SAW3BC,EAAyBA,CAACC,EAAeC,EAAc5B,EAAiBgB,IAAa,KAClFhB,GAILgB,EAASC,WAAWY,aAAa7B,GAC5B8B,KAAMC,IACH,MAAMC,EAAkBR,EAAkBS,OAAQC,IAAWP,EAAcQ,SAASD,IAChFN,EACAI,EAAgBI,QAASF,GAAUH,EAAQM,oBAAoBH,EAAOI,GAAgB,IAEtFN,EAAgBI,QAASF,GAAUH,EAAQQ,iBAAiBL,EAAOI,GAAgB,OAW7FE,EAAWA,C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UpE,EAASC,WAAWY,aAAakB,EAAQ6C,sBAAuB7C,EAAQwC,YAAc,GAC/GpE,MAAM,KACHH,EAASwE,gBAAgBC,YAAYL,KAE7C5B,KAAO4B,GAAU,KAEbM,WAAW,IAAMN,EAAMO,UAE5B5C,IAGX,CACIF,eAAgB,YAChBC,QAASA,CAACC,EAAS/B,KACf,MAAM6E,EAAiB,CACnBzF,KAAM,WACNN,MAAOiD,EAAQjD,OAAS,sCACxBC,QAASgD,EAAQhD,SAAW,wCAC5B+F,UAAU,GAEd,OAAO7C,QAAQC,OAAO,CAAC,EAAGrD,EAAY,CAClCyD,iBAAkBtC,EAASC,WAAWsC,yBACvCR,EAAS8C,M","sources":["webpack://root-config/./packages/legacy-workbench/src/js/angular/guides/steps/core/plugin.js"],"sourcesContent":["const BASIC_STEP = {\n title: '',\n content: '',\n elementSelector: undefined,\n placement: 'bottom',\n url: undefined,\n type: 'read-only-element',\n maxWaitTime: 3,\n canBePaused: true,\n onNextClick: undefined,\n disablePreviousFlow: true,\n onNextValidate: () => Promise.resolve(true),\n onPreviousClick: undefined,\n skipPoint: false,\n class: '',\n};\n\n/**\n * This function will be called before show a step. Step will be shown after promise is resolve. It waits element of step to be visible on the page.\n * @param {*} services\n * @param {string} elementSelector\n * @param {number} maxWaitTime\n * @return {function(): *}\n */\nconst beforeShowPromise = (services, elementSelector, maxWaitTime) => {\n return () => {\n return services.GuideUtils.waitFor(elementSelector, maxWaitTime)\n .catch((error) => {\n // error is caught just to show notification in generic way.\n services.toastr.error(services.$translate.instant('guide.unexpected.error.message'));\n // throw the error, otherwise guide will continue with the next step.\n throw error;\n });\n };\n};\n\nconst createCopyToInputListener = (elementSelector, text) => {\n return (event) => {\n event.preventDefault();\n const inputElement = document.querySelector(elementSelector);\n inputElement.value = text;\n inputElement.dispatchEvent(new Event('input', {bubbles: true}));\n };\n};\n\n/**\n * List of common DOM events to consider for interaction control.\n * @type {string[]}\n */\nconst COMMON_DOM_EVENTS = [\n 'click',\n 'dblclick',\n 'keydown',\n 'keypress',\n 'keyup',\n 'input',\n 'submit',\n 'scroll',\n 'wheel',\n];\nconst SCROLL_EVENTS = ['scroll', 'wheel'];\n\n/**\n * Configures an element interactability, by consuming events and preventing them from propagating.\n * This allows to keep scrolling, while disallowing interaction with other elements\n * (such as clicking buttons).\n * @param {string[]} allowedEvents - List of event types to allow.\n * @param interactable - true to make the element interactable, false to make it non interactable\n * @param elementSelector - the elementSelector\n * @param services - The services object\n */\nconst _configureInteractions = (allowedEvents, interactable, elementSelector, services) => () => {\n if (!elementSelector) {\n return;\n }\n\n services.GuideUtils.getOrWaitFor(elementSelector)\n .then((element) => {\n const eventsToPrevent = COMMON_DOM_EVENTS.filter((event) => !allowedEvents.includes(event));\n if (interactable) {\n eventsToPrevent.forEach((event) => element.removeEventListener(event, preventDefault, true));\n } else {\n eventsToPrevent.forEach((event) => element.addEventListener(event, preventDefault, true));\n }\n });\n};\n\n/**\n * Enables all interactions on the specified element.\n *\n * @param {string} elementSelector - A CSS selector identifying the target element.\n * @param {Object} services - An object containing utility services, including GuideUtils.\n */\nconst allowAll = (elementSelector, services) => _configureInteractions([], true, elementSelector, services);\n\n/**\n * Restricts the specified element to only process events listed in <code>allowedEvents</code>.\n *\n * @param {string[]} allowedEvents - An array of event types that should remain enabled.\n * @param {string} elementSelector - A CSS selector identifying the target element.\n * @param {Object} services - An object containing utility services, including GuideUtils.\n */\nconst allowEvents = (allowedEvents, elementSelector, services) => _configureInteractions(allowedEvents, false, elementSelector, services);\n\n/**\n * Prevents the default action of an event and stops its propagation.\n * @param {Event} event - The event to prevent.\n */\nconst preventDefault = (event) => {\n event.preventDefault();\n event.stopPropagation();\n};\n\nPluginRegistry.add('guide.step', [\n {\n // An element which is expected to be clicked. If onNextClick is not defined, it will automatically click on the element on next button press\n guideBlockName: 'clickable-element',\n getStep: (options, services) => {\n const notOverridable = {\n type: 'clickable',\n };\n\n const stepDescription = angular.extend({}, BASIC_STEP, {\n advanceOn: {\n selector: options.clickableElementSelector || options.elementSelector,\n event: 'click',\n },\n initPreviousStep: services.GuideUtils.defaultInitPreviousStep,\n }, options, notOverridable);\n\n if (!stepDescription.beforeShowPromise) {\n stepDescription.beforeShowPromise = beforeShowPromise(services, stepDescription.elementSelector, stepDescription.maxWaitTime);\n }\n return stepDescription;\n },\n },\n {\n // An element which is expected to be focused. It allows user interaction.\n guideBlockName: 'focus-element',\n getStep: (options, services) => {\n const stepDescription = angular.extend({}, BASIC_STEP, {\n initPreviousStep: services.GuideUtils.defaultInitPreviousStep,\n }, options);\n\n if (!stepDescription.beforeShowPromise) {\n stepDescription.beforeShowPromise = beforeShowPromise(services, stepDescription.elementSelector, stepDescription.maxWaitTime);\n }\n return stepDescription;\n },\n },\n {\n // An element which is expected to be focused, but interactions are disabled.\n guideBlockName: 'read-only-element',\n getStep: (options, services) => {\n const notOverridable = {\n type: 'readonly',\n };\n const stepDescription = angular.extend({}, BASIC_STEP, {\n initPreviousStep: services.GuideUtils.defaultInitPreviousStep,\n },\n options, notOverridable);\n if (!stepDescription.beforeShowPromise) {\n stepDescription.beforeShowPromise = beforeShowPromise(services, stepDescription.elementSelector, stepDescription.maxWaitTime);\n }\n return stepDescription;\n },\n },\n {\n guideBlockName: 'scroll-only-element',\n getStep: (options, services) => {\n const stepDescription = {\n ...BASIC_STEP,\n initPreviousStep: services.GuideUtils.defaultInitPreviousStep,\n show: () => allowEvents(SCROLL_EVENTS, options.elementSelector, services),\n hide: () => allowAll(options.elementSelector, services),\n ...options,\n };\n if (!stepDescription.beforeShowPromise) {\n stepDescription.beforeShowPromise = beforeShowPromise(services, stepDescription.elementSelector, stepDescription.maxWaitTime);\n }\n return stepDescription;\n },\n },\n {\n guideBlockName: 'input-element',\n getStep: (options, services) => {\n const notOverridable = {\n type: 'input',\n };\n const stepDescription = angular.extend({}, BASIC_STEP, {\n initPreviousStep: services.GuideUtils.defaultInitPreviousStep,\n }, options, notOverridable);\n if (!stepDescription.beforeShowPromise) {\n stepDescription.beforeShowPromise = beforeShowPromise(services, stepDescription.elementSelector, stepDescription.maxWaitTime);\n }\n return stepDescription;\n },\n },\n {\n guideBlockName: 'copy-text-element',\n getSteps: (options, services) => {\n const $translate = services.$translate;\n const GuideUtils = services.GuideUtils;\n\n const text = options.text;\n const code = document.createElement('code');\n code.innerText = text;\n\n const copy = document.createElement('button');\n const copyToInputQueryButtonClass = 'guide-copy-to-input-query-button';\n copy.className = `btn btn-sm btn-secondary ${copyToInputQueryButtonClass}`;\n copy.innerText = $translate.instant('guide.step_plugin.core-steps.copy-text-element.copy-to-input');\n\n\n let stepHTMLElement;\n const copyToInputListener = createCopyToInputListener(GuideUtils.getElementSelector(options.elementSelector), text);\n\n return [\n {\n guideBlockName: 'input-element',\n options: {\n ...options,\n content: 'guide.step_plugin.core-steps.copy-text-element.content',\n textAsHtmlCodeElement: '<div class=\"shepherd-code\">' + code.outerHTML + copy.outerHTML + '</div>',\n show: (_guide) => () => {\n stepHTMLElement = _guide.currentStep.el.querySelector(`.${copyToInputQueryButtonClass}`);\n stepHTMLElement.addEventListener('click', copyToInputListener);\n },\n hide: () => () => {\n if (stepHTMLElement) {\n stepHTMLElement.removeEventListener('click', copyToInputListener);\n }\n },\n },\n },\n ];\n },\n },\n {\n guideBlockName: 'info-message',\n getStep: (options, services) => {\n const notOverridable = {\n type: 'readonly',\n };\n return angular.extend({}, BASIC_STEP, {\n initPreviousStep: services.GuideUtils.defaultInitPreviousStep,\n }, options, notOverridable);\n },\n },\n {\n guideBlockName: 'hold-and-wait-until-hidden',\n getStep: (options, services) => {\n return angular.extend({}, BASIC_STEP, {\n initPreviousStep: services.GuideUtils.defaultInitPreviousStep,\n onNextValidate: () => Promise.resolve(!services.GuideUtils.isVisible(options.elementSelectorToWait)),\n show: () => allowEvents(SCROLL_EVENTS, options.elementSelector, services),\n hide: () => allowAll(options.elementSelector, services),\n }, options);\n },\n },\n {\n guideBlockName: 'hold-and-wait-until-shown',\n getStep: (options, services) => {\n const notOverridable = {\n type: 'readonly',\n };\n return angular.extend({}, BASIC_STEP, {\n initPreviousStep: services.GuideUtils.defaultInitPreviousStep,\n onNextValidate: () => Promise.resolve(services.GuideUtils.isVisible(options.elementSelectorToWait)),\n }, options, notOverridable);\n },\n },\n {\n guideBlockName: 'wait-for-element-to-hide',\n getStep: (options, services) => {\n return angular.extend({}, BASIC_STEP, {\n initPreviousStep: services.GuideUtils.defaultInitPreviousStep,\n beforeShowPromise: (guide) => services.GuideUtils.waitUntilHidden(options.elementSelectorToHide, options.timeToWait || 2)\n .catch(() => {\n services.ShepherdService._abortGuide(guide);\n }),\n show: (guide) => () => {\n // Using a timeout because the library executes async logic\n setTimeout(() => guide.next());\n },\n }, options);\n },\n },\n {\n guideBlockName: 'wait-for-element-to-show',\n getStep: (options, services) => {\n return angular.extend({}, BASIC_STEP, {\n initPreviousStep: services.GuideUtils.defaultInitPreviousStep,\n beforeShowPromise: (guide) => services.GuideUtils.getOrWaitFor(options.elementSelectorToShow, options.timeToWait || 2)\n .catch(() => {\n services.ShepherdService._abortGuide(guide);\n }),\n show: (guide) => () => {\n // Using a timeout because the library executes async logic\n setTimeout(() => guide.next());\n },\n }, options);\n },\n },\n {\n guideBlockName: 'guide-end',\n getStep: (options, services) => {\n const notOverridable = {\n type: 'readonly',\n title: options.title || 'guide.step_plugin.guide-ended.title',\n content: options.content || 'guide.step_plugin.guide-ended.content',\n lastStep: true,\n };\n return angular.extend({}, BASIC_STEP, {\n initPreviousStep: services.GuideUtils.defaultInitPreviousStep,\n }, options, notOverridable);\n },\n },\n]);\n"],"names":["BASIC_STEP","title","content","elementSelector","undefined","placement","url","type","maxWaitTime","canBePaused","onNextClick","disablePreviousFlow","onNextValidate","Promise","resolve","onPreviousClick","skipPoint","class","beforeShowPromise","services","GuideUtils","waitFor","catch","error","toastr","$translate","instant","COMMON_DOM_EVENTS","SCROLL_EVENTS","_configureInteractions","allowedEvents","interactable","getOrWaitFor","then","element","eventsToPrevent","filter","event","includes","forEach","removeEventListener","preventDefault","addEventListener","allowAll","allowEvents","stopPropagation","PluginRegistry","add","guideBlockName","getStep","options","stepDescription","angular","extend","advanceOn","selector","clickableElementSelector","initPreviousStep","defaultInitPreviousStep","show","hide","getSteps","text","code","document","createElement","innerText","copy","copyToInputQueryButtonClass","stepHTMLElement","className","copyToInputListener","createCopyToInputListener","inputElement","querySelector","value","dispatchEvent","Event","bubbles","getElementSelector","textAsHtmlCodeElement","outerHTML","_guide","currentStep","el","isVisible","elementSelectorToWait","guide","waitUntilHidden","elementSelectorToHide","timeToWait","ShepherdService","_abortGuide","setTimeout","next","elementSelectorToShow","notOverridable","lastStep"],"sourceRoot":""}
@@ -1,2 +0,0 @@
1
- export const __webpack_id__=70938;export const __webpack_ids__=[70938];export const __webpack_modules__={70938:()=>{const e="guide.step-action.edit-ttyg-agent";PluginRegistry.add("guide.step",[{guideBlockName:"ttyg-edit-agent-intro-message",getSteps:(t,i)=>[{guideBlockName:"info-message",options:{content:"guide.step_plugin.edit-ttyg-agent.intro",...t.mainAction?{}:{title:e},skipPoint:!0,...t}}]},{guideBlockName:"ttyg-click-to-edit-selected-agent",getSteps:(t,i)=>{const n=i.GuideUtils;return[{guideBlockName:"clickable-element",options:{content:"guide.step_plugin.edit-ttyg-agent.edit-agent",...t.mainAction?{}:{title:e},class:"edit-agent-btn",disableNextFlow:!0,...t,url:"ttyg",elementSelector:n.getGuideElementSelector("edit-current-agent")}}]}},{guideBlockName:"ttyg-edit-agent-click-to-save",getSteps:(t,i)=>{const n=i.GuideUtils;return[{guideBlockName:"clickable-element",options:{content:"guide.step_plugin.edit-ttyg-agent.save-agent-settings",...t.mainAction?{}:{title:e},class:"save-agent",disablePreviousFlow:!1,disableNextFlow:!0,...t,url:"ttyg",elementSelector:n.getGuideElementSelector("save-agent-settings")}}]}},{guideBlockName:"edit-ttyg-agent",getSteps:(e,t)=>{const i=t.GuideUtils,n=t.RoutingUtil;return e.mainAction="edit-ttyg-agent",[{guideBlockName:"click-main-menu",options:{...e,menu:"ttyg",showOn:()=>"ttyg"!==n.getCurrentRoute()}},{guideBlockName:"end-on-api-key-error"},{guideBlockName:"ttyg-edit-agent-intro-message",options:{...e}},{guideBlockName:"info-message",options:angular.extend({},{beforeShowPromise:(e,t)=>{i.isGuideElementVisible("selected-agent")?setTimeout(()=>{e.show(t.id+6)}):setTimeout(()=>{e.next()})}},e)},{guideBlockName:"select-ttyg-agent",options:{...e}},{guideBlockName:"ttyg-click-to-edit-selected-agent",options:{...e}},{guideBlockName:"configure-agent",options:e},{guideBlockName:"ttyg-edit-agent-click-to-save",options:{...e}},{guideBlockName:"wait-for-element-to-hide",options:angular.extend({},{elementSelectorToHide:i.getElementSelector(".agent-settings-modal"),timeToWait:10},e)}]}}])}};
2
- //# sourceMappingURL=70938.6d0055f916f6d1bc91bb.bundle.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"70938.6d0055f916f6d1bc91bb.bundle.js","mappings":"oHAAA,MAAMA,EAAgC,oCAEtCC,eAAeC,IAAI,aAAc,CAC7B,CACIC,eAAgB,gCAChBC,SAAUA,CAACC,EAASC,IACT,CACH,CACIH,eAAgB,eAChBE,QAAS,CACLE,QAAS,6CAELF,EAAQG,WAAa,CAAC,EAAI,CAAEC,MAAOT,GACvCU,WAAW,KACRL,MAMvB,CACEF,eAAgB,oCAChBC,SAAUA,CAACC,EAASC,KAChB,MAAMK,EAAaL,EAASK,WAE5B,MAAO,CACH,CACIR,eAAgB,oBAChBE,QAAS,CACLE,QAAS,kDAELF,EAAQG,WAAa,CAAC,EAAI,CAAEC,MAAOT,GACvCY,MAAO,iBACPC,iBAAiB,KACdR,EACHS,IAAK,OACLC,gBAAiBJ,EAAWK,wBAAwB,2BAMtE,CACEb,eAAgB,gCAChBC,SAAUA,CAACC,EAASC,KAChB,MAAMK,EAAaL,EAASK,WAE5B,MAAO,CACH,CACIR,eAAgB,oBAChBE,QAAS,CACLE,QAAS,2DAELF,EAAQG,WAAa,CAAC,EAAI,CAAEC,MAAOT,GACvCY,MAAO,aACPK,qBAAqB,EACrBJ,iBAAiB,KACdR,EACHS,IAAK,OACLC,gBAAiBJ,EAAWK,wBAAwB,4BAMtE,CACIb,eAAgB,kBAChBC,SAAUA,CAACC,EAASC,KAChB,MAAMK,EAAaL,EAASK,WACtBO,EAAcZ,EAASY,YAG7B,OAFAb,EAAQG,WAAa,kBAEd,CACH,CACIL,eAAgB,kBAChBE,QAAS,IACFA,EACHc,KAAM,OACNC,OAAQA,IAAM,SAAWF,EAAYG,oBAG7C,CACIlB,eAAgB,wBAEpB,CACIA,eAAgB,gCAChBE,QAAS,IAAIA,IAEjB,CAEIF,eAAgB,eAChBE,QAASiB,QAAQC,OAAO,CAAC,EAAG,CACxBC,kBAAmBA,CAACC,EAAOC,KACnBf,EAAWgB,sBAAsB,kBACjCC,WAAW,KAEPH,EAAMI,KAAKH,EAAYI,GAAK,KAGhCF,WAAW,KAEPH,EAAMM,WAInB1B,IAEP,CACIF,eAAgB,oBAChBE,QAAS,IAAIA,IAEjB,CACIF,eAAgB,oCAChBE,QAAS,IAAIA,IAEjB,CACIF,eAAgB,kBAChBE,WAEJ,CACIF,eAAgB,gCAChBE,QAAS,IAAIA,IAEjB,CACIF,eAAgB,2BAChBE,QAASiB,QAAQC,OAAO,CAAC,EAAG,CACxBS,sBAAuBrB,EAAWsB,mBAAmB,yBACrDC,WAAY,IACb7B,Q","sources":["webpack://root-config/./packages/legacy-workbench/src/js/angular/guides/steps/complex/ttyg/edit-ttyg-agent/plugin.js"],"sourcesContent":["const TTYG_EDIT_AGENT_DEFAULT_TITLE = 'guide.step-action.edit-ttyg-agent';\n\nPluginRegistry.add('guide.step', [\n {\n guideBlockName: 'ttyg-edit-agent-intro-message',\n getSteps: (options, services) => {\n return [\n {\n guideBlockName: 'info-message',\n options: {\n content: 'guide.step_plugin.edit-ttyg-agent.intro',\n // If mainAction is set the title will be set automatically\n ...(options.mainAction ? {} : { title: TTYG_EDIT_AGENT_DEFAULT_TITLE }),\n skipPoint: true,\n ...options\n }\n }\n ]\n }\n },\n {\n guideBlockName: 'ttyg-click-to-edit-selected-agent',\n getSteps: (options, services) => {\n const GuideUtils = services.GuideUtils;\n\n return [\n {\n guideBlockName: 'clickable-element',\n options: {\n content: 'guide.step_plugin.edit-ttyg-agent.edit-agent',\n // If mainAction is set the title will be set automatically\n ...(options.mainAction ? {} : { title: TTYG_EDIT_AGENT_DEFAULT_TITLE }),\n class: 'edit-agent-btn',\n disableNextFlow: true,\n ...options,\n url: 'ttyg',\n elementSelector: GuideUtils.getGuideElementSelector('edit-current-agent'),\n }\n }\n ]\n }\n },\n {\n guideBlockName: 'ttyg-edit-agent-click-to-save',\n getSteps: (options, services) => {\n const GuideUtils = services.GuideUtils;\n\n return [\n {\n guideBlockName: 'clickable-element',\n options: {\n content: 'guide.step_plugin.edit-ttyg-agent.save-agent-settings',\n // If mainAction is set the title will be set automatically\n ...(options.mainAction ? {} : { title: TTYG_EDIT_AGENT_DEFAULT_TITLE }),\n class: 'save-agent',\n disablePreviousFlow: false,\n disableNextFlow: true,\n ...options,\n url: 'ttyg',\n elementSelector: GuideUtils.getGuideElementSelector('save-agent-settings'),\n }\n }\n ]\n }\n },\n {\n guideBlockName: 'edit-ttyg-agent',\n getSteps: (options, services) => {\n const GuideUtils = services.GuideUtils;\n const RoutingUtil = services.RoutingUtil;\n options.mainAction = 'edit-ttyg-agent';\n\n return [\n {\n guideBlockName: 'click-main-menu',\n options: {\n ...options,\n menu: 'ttyg',\n showOn: () => 'ttyg' !== RoutingUtil.getCurrentRoute()\n }\n },\n {\n guideBlockName: 'end-on-api-key-error'\n },\n {\n guideBlockName: 'ttyg-edit-agent-intro-message',\n options: {...options}\n },\n {\n // Skip next step (which is actually 5 core steps) if there is a selected agent\n guideBlockName: 'info-message',\n options: angular.extend({}, {\n beforeShowPromise: (guide, currentStep) => {\n if (GuideUtils.isGuideElementVisible('selected-agent')) {\n setTimeout(() => {\n // Using a timeout because the library executes async logic\n guide.show(currentStep.id + 6);\n })\n } else {\n setTimeout(() => {\n // Using a timeout because the library executes async logic\n guide.next()\n });\n }\n }\n }, options)\n },\n {\n guideBlockName: 'select-ttyg-agent',\n options: {...options}\n },\n {\n guideBlockName: 'ttyg-click-to-edit-selected-agent',\n options: {...options}\n },\n {\n guideBlockName: 'configure-agent',\n options\n },\n {\n guideBlockName: 'ttyg-edit-agent-click-to-save',\n options: {...options}\n },\n {\n guideBlockName: 'wait-for-element-to-hide',\n options: angular.extend({}, {\n elementSelectorToHide: GuideUtils.getElementSelector('.agent-settings-modal'),\n timeToWait: 10\n }, options)\n }\n ];\n }\n }\n]);\n\n"],"names":["TTYG_EDIT_AGENT_DEFAULT_TITLE","PluginRegistry","add","guideBlockName","getSteps","options","services","content","mainAction","title","skipPoint","GuideUtils","class","disableNextFlow","url","elementSelector","getGuideElementSelector","disablePreviousFlow","RoutingUtil","menu","showOn","getCurrentRoute","angular","extend","beforeShowPromise","guide","currentStep","isGuideElementVisible","setTimeout","show","id","next","elementSelectorToHide","getElementSelector","timeToWait"],"sourceRoot":""}
@@ -1,2 +0,0 @@
1
- export const __webpack_id__=71920;export const __webpack_ids__=[49539,71920];export const __webpack_modules__={71920:(e,t,E)=>{E.r(t),E.d(t,{TTYGEventName:()=>_});var n=E(98980);function a(e){let t,E,a,A,T,C={},o=!1;const c=()=>(0,n.cloneDeep)(t),d=()=>(0,n.cloneDeep)(E),i=e=>{E=(0,n.cloneDeep)(e),g(_.CHAT_LIST_UPDATED,d())},D=()=>(0,n.cloneDeep)(a),l=()=>(0,n.cloneDeep)(A),S=()=>(0,n.cloneDeep)(C),s=e=>!!C[e],p=()=>o,g=(t,E)=>{e.emitSync(t,(0,n.cloneDeep)(E))},L=(t,E)=>e.subscribeSync(t,e=>E(e));return{resetContext:()=>{t=void 0,E=void 0,a=void 0,A=void 0,C={},T=void 0,o=!1},emit:g,subscribe:L,getChats:d,updateChats:i,addChat:e=>{E.appendChat(e),i(E)},replaceChat:(e,t)=>{E.replaceChat(e,t),i(E)},onChatsListChanged:e=>(E&&angular.isFunction(e)&&e(d()),L(_.CHAT_LIST_UPDATED,t=>e(t))),getSelectedChat:D,selectChat:e=>{a&&a.id===e.id||(a=(0,n.cloneDeep)(e),g(_.SELECT_CHAT,D()))},deselectChat:()=>{a=void 0,g(_.SELECT_CHAT,D())},deleteChat:e=>{E.deleteChat(e),i(E)},onSelectedChatChanged:e=>(angular.isFunction(e)&&e(D()),L(_.SELECT_CHAT,t=>e(t))),updateSelectedChat:e=>{a&&a.id&&e&&a.id!==e.id||(a=(0,n.cloneDeep)(e),g(_.SELECTED_CHAT_UPDATED,D()))},onSelectedChatUpdated:e=>(a&&angular.isFunction(e)&&e(D()),L(_.SELECTED_CHAT_UPDATED,t=>e(t))),onLastMessageReceived:e=>(a&&angular.isFunction(e)&&e(D()),L(_.LAST_MESSAGE_RECEIVED,t=>e(t))),updateAgents:e=>{t=(0,n.cloneDeep)(e),g(_.AGENT_LIST_UPDATED,c())},onAgentsListChanged:e=>(t&&angular.isFunction(e)&&e(c()),L(_.AGENT_LIST_UPDATED,t=>e(t))),getAgents:c,getAgent:e=>{if(t)return(0,n.cloneDeep)(t.getAgent(e))},selectAgent:e=>{A=(0,n.cloneDeep)(e),g(_.AGENT_SELECTED,l())},getSelectedAgent:l,onSelectedAgentChanged:e=>(A&&angular.isFunction(e)&&e(l()),L(_.AGENT_SELECTED,t=>e(t))),getDefaultAgent:()=>(0,n.cloneDeep)(T),setDefaultAgent:e=>{T=e},setCanModifyAgent:e=>{o=(0,n.cloneDeep)(e),g(_.CAN_MODIFY_AGENT_UPDATED,p())},getCanModifyAgent:p,onCanUpdateAgentUpdated:e=>(angular.isFunction(e)&&e(p()),L(_.CAN_MODIFY_AGENT_UPDATED,t=>e(t))),hasExplainResponse:s,toggleExplainResponse:e=>{s(e)&&(C[e].expanded=!C[e].expanded,g(_.EXPLAIN_RESPONSE_CACHE_UPDATED,S()))},getExplainResponse:e=>(0,n.cloneDeep)(C[e]),addExplainResponseCache:e=>{C[e.answerId]=(0,n.cloneDeep)(e),g(_.EXPLAIN_RESPONSE_CACHE_UPDATED,S())},onExplainResponseCacheUpdated:e=>(angular.isFunction(e)&&e(S()),L(_.EXPLAIN_RESPONSE_CACHE_UPDATED,t=>e(t)))}}angular.module("graphdb.framework.ttyg.services.ttygcontext",[]).factory("TTYGContextService",a),a.$inject=["EventEmitterService","TTYGService"];const _={CREATE_CHAT:"createChat",CREATE_CHAT_SUCCESSFUL:"chatCreated",CREATE_CHAT_FAILURE:"chatCreationFailed",RENAME_CHAT:"renameChat",RENAME_CHAT_SUCCESSFUL:"chatRenamed",RENAME_CHAT_FAILURE:"chatRenamedFailure",SELECT_CHAT:"selectChat",SELECTED_CHAT_UPDATED:"selectChatUpdated",LAST_MESSAGE_RECEIVED:"lastMessageReceived",DELETING_CHAT:"deletingChat",DELETE_CHAT:"deleteChat",DELETE_CHAT_SUCCESSFUL:"chatDeleted",DELETE_CHAT_FAILURE:"chatDeletedFailure",CHAT_EXPORT:"chatExport",CHAT_EXPORT_SUCCESSFUL:"chatExportSuccess",CHAT_EXPORT_FAILURE:"chatExportFailure",CHAT_LIST_UPDATED:"chatListUpdated",ASK_QUESTION:"askQuestion",ASK_QUESTION_FAILURE:"askQuestionFailure",CONTINUE_CHAT_RUN:"continueChatRun",LOAD_CHATS:"loadChats",LOAD_CHAT_SUCCESSFUL:"loadChatSuccess",LOAD_CHAT_FAILURE:"loadChatFailure",AGENT_LIST_UPDATED:"agentListUpdated",OPEN_AGENT_SETTINGS:"openAgentSettings",EDIT_AGENT:"editAgent",CLONE_AGENT:"cloneAgent",DELETE_AGENT:"deleteAgent",AGENT_DELETED:"agentDeleted",DELETING_AGENT:"deletingAgent",AGENT_SELECTED:"agentSelected",GO_TO_CREATE_SIMILARITY_VIEW:"goToCreateSimilarityView",GO_TO_CONNECTORS_VIEW:"goToConnectorsView",GO_TO_AUTOCOMPLETE_INDEX_VIEW:"goToAutocompleteIndexView",EXPLAIN_RESPONSE:"explainResponse",EXPLAIN_RESPONSE_CACHE_UPDATED:"explainResponseCacheUpdated",GO_TO_SPARQL_EDITOR:"openQueryInSparqlEditor",CAN_MODIFY_AGENT_UPDATED:"canModifyAgentUpdated"}}};
2
- //# sourceMappingURL=71920.46e7b0ec1d22adcd8e55.bundle.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"71920.46e7b0ec1d22adcd8e55.bundle.js","mappings":"kLAQA,SAASA,EAAmBC,GAOxB,IAAIC,EAOAC,EAOAC,EAOAC,EAeAC,EAPAC,EAAgB,CAAC,EASjBC,GAAkB,EAEtB,MAwBMC,EAAYA,KACPC,EAAAA,EAAAA,WAAUR,GAYfS,EAAWA,KACND,EAAAA,EAAAA,WAAUP,GAMfS,EAAeC,IACjBV,GAASO,EAAAA,EAAAA,WAAUG,GACnBC,EAAKC,EAAcC,kBAAmBL,MAqCpCM,EAAkBA,KACbP,EAAAA,EAAAA,WAAUN,GAmGfc,EAAmBA,KACdR,EAAAA,EAAAA,WAAUL,GAcfc,EAA2BA,KACtBT,EAAAA,EAAAA,WAAUH,GAsBfa,EAAsBC,KACfd,EAAcc,GA8CrBC,EAAoBA,IACfd,EAsBLM,EAAOA,CAACS,EAAeC,KACzBvB,EAAoBwB,SAASF,GAAeb,EAAAA,EAAAA,WAAUc,KAUpDE,EAAYA,CAACH,EAAeI,IACvB1B,EAAoB2B,cAAcL,EAAgBC,GAAYG,EAASH,IAGlF,MAAO,CACHK,aAnTiBA,KACjB3B,OAAU4B,EACV3B,OAAS2B,EACT1B,OAAgB0B,EAChBzB,OAAiByB,EACjBvB,EAAgB,CAAC,EACjBD,OAAgBwB,EAChBtB,GAAkB,GA6SlBM,OACAY,YAEAf,WACAC,cACAmB,QA/PaC,IACb7B,EAAO8B,WAAWD,GAClBpB,EAAYT,IA8PZ+B,YA3PgBA,CAACF,EAASG,KAC1BhC,EAAO+B,YAAYF,EAASG,GAC5BvB,EAAYT,IA0PZiC,mBAlPwBT,IACpBxB,GAAUkC,QAAQC,WAAWX,IAC7BA,EAAShB,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AAmB,kBAKnBC,WAAY,YACZC,qBAAsB,kBACtBC,kBAAmB,kBAEnB5C,mBAAoB,mBAMpB6C,oBAAqB,oBAKrBC,WAAY,YAKZC,YAAa,aAKbC,aAAc,cAKdC,cAAe,eAMfC,eAAgB,gBAKhB5C,eAAgB,gBAKhB6C,6BAA8B,2BAK9BC,sBAAuB,qBAKvBC,8BAA+B,4BAK/BC,iBAAkB,kBAKlBrC,+BAAgC,8BAKhCsC,oBAAqB,0BAErB1C,yBAA0B,wB","sources":["webpack://root-config/./packages/legacy-workbench/src/js/angular/ttyg/services/ttyg-context.service.js"],"sourcesContent":["import {cloneDeep} from 'lodash';\n\nangular\n .module('graphdb.framework.ttyg.services.ttygcontext', [])\n .factory('TTYGContextService', TTYGContextService);\n\nTTYGContextService.$inject = ['EventEmitterService', 'TTYGService'];\n\nfunction TTYGContextService(EventEmitterService) {\n\n /**\n * The list of agents.\n * @type {AgentListModel}\n * @private\n */\n let _agents = undefined;\n\n /**\n * The ChatsListModel.\n * @type {ChatsListModel}\n * @private\n */\n let _chats = undefined;\n\n /**\n * The currently selected in the UI chat which is used for conversation.\n * @type {ChatModel|undefined}\n * @private\n */\n let _selectedChat = undefined;\n\n /**\n * The currently selected in the UI agent which is used for conversation.\n * @type {AgentModel|undefined}\n * @private\n */\n let _selectedAgent = undefined;\n\n /**\n * Stores information about loaded explain responses.\n * The key is the answer ID, and the value is an instance of {@see ExplainResponseModel} that holds the explanation message.\n *\n * @type {{[key: string]: ExplainResponseModel}}\n */\n let _explainCache = {};\n\n /**\n * The default agent values.\n * @type {AgentModel|undefined}\n * @private\n */\n let _defaultAgent = undefined;\n\n let _canModifyAgent = false;\n\n const resetContext = () => {\n _agents = undefined;\n _chats = undefined;\n _selectedChat = undefined;\n _selectedAgent = undefined;\n _explainCache = {};\n _defaultAgent = undefined;\n _canModifyAgent = false;\n };\n\n /**\n * @return {Promise<AgentModel>}\n */\n const getDefaultAgent = () => {\n return cloneDeep(_defaultAgent);\n };\n\n const setDefaultAgent = (agent) => {\n _defaultAgent = agent;\n };\n\n /**\n * @return {AgentListModel}\n */\n const getAgents = () => {\n return cloneDeep(_agents);\n };\n\n const getAgent = (agentId) => {\n if (_agents) {\n return cloneDeep(_agents.getAgent(agentId));\n }\n };\n\n /**\n * @return {ChatsListModel}\n */\n const getChats = () => {\n return cloneDeep(_chats);\n };\n\n /**\n * @param {ChatsListModel} chats\n */\n const updateChats = (chats) => {\n _chats = cloneDeep(chats);\n emit(TTYGEventName.CHAT_LIST_UPDATED, getChats());\n };\n\n /**\n * Deletes the chat with the provided <code>chatId</code>.\n * @param {ChatModel} chat\n */\n const deleteChat = (chat) => {\n _chats.deleteChat(chat);\n updateChats(_chats);\n };\n\n const addChat = (newChat) => {\n _chats.appendChat(newChat);\n updateChats(_chats);\n };\n\n const replaceChat = (newChat, oldChat) => {\n _chats.replaceChat(newChat, oldChat);\n updateChats(_chats);\n };\n\n /** Subscribes to the 'chatListUpdated' event.\n * @param {function} callback - The callback to be called when the event is fired.\n *\n * @return {function} unsubscribe function.\n */\n const onChatsListChanged = (callback) => {\n if (_chats && angular.isFunction(callback)) {\n callback(getChats());\n }\n return subscribe(TTYGEventName.CHAT_LIST_UPDATED, (chats) => callback(chats));\n };\n\n /**\n * @return {ChatModel}\n */\n const getSelectedChat = () => {\n return cloneDeep(_selectedChat);\n };\n\n /**\n * Updates the selected chat with the provided <code>selectedChat</code> and emits the 'selectChat' event\n * to notify listeners that a new chat has been selected.\n *\n * @param {ChatModel} selectedChat - The chat object to select.\n */\n const selectChat = (selectedChat) => {\n if (!_selectedChat || _selectedChat.id !== selectedChat.id) {\n _selectedChat = cloneDeep(selectedChat);\n emit(TTYGEventName.SELECT_CHAT, getSelectedChat());\n }\n };\n\n const deselectChat = () => {\n _selectedChat = undefined;\n emit(TTYGEventName.SELECT_CHAT, getSelectedChat());\n };\n\n /**\n * Subscribes to the 'selectChat' event.\n * @param {function} callback - The callback to be called when the event is fired.\n *\n * @return {function} unsubscribe function.\n */\n const onSelectedChatChanged = (callback) => {\n if (angular.isFunction(callback)) {\n callback(getSelectedChat());\n }\n return subscribe(TTYGEventName.SELECT_CHAT, (selectedChat) => callback(selectedChat));\n };\n\n /**\n * Updates the selected chat and emits the 'selectChatUpdated' event to notify listeners that a property\n * of the selected chat has changed.\n *\n * If the ID of the passed chat differs from the current selected chat, no action will occur.\n *\n * The selected chat can be updated through {@link TTYGContextService#selectChat}.\n *\n * @param {ChatModel} chat - The chat object that is being updated.\n */\n const updateSelectedChat = (chat) => {\n if (!_selectedChat || !_selectedChat.id || !chat || _selectedChat.id === chat.id) {\n _selectedChat = cloneDeep(chat);\n emit(TTYGEventName.SELECTED_CHAT_UPDATED, getSelectedChat());\n }\n };\n\n /** Subscribes to the 'selectChat' event.\n * @param {function} callback - The callback to be called when the event is fired.\n *\n * @return {function} unsubscribe function.\n */\n const onSelectedChatUpdated = (callback) => {\n if (_selectedChat && angular.isFunction(callback)) {\n callback(getSelectedChat());\n }\n return subscribe(TTYGEventName.SELECTED_CHAT_UPDATED, (selectedChat) => callback(selectedChat));\n };\n\n /** Subscribes to the 'lastMessageReceived' event.\n * @param {function} callback - The callback to be called when the event is fired.\n *\n * @return {function} unsubscribe function.\n */\n const onLastMessageReceived = (callback) => {\n if (_selectedChat && angular.isFunction(callback)) {\n callback(getSelectedChat());\n }\n return subscribe(TTYGEventName.LAST_MESSAGE_RECEIVED, (selectedChat) => callback(selectedChat));\n };\n\n /**\n * @param {AgentListModel} agents\n */\n const updateAgents = (agents) => {\n _agents = cloneDeep(agents);\n emit(TTYGEventName.AGENT_LIST_UPDATED, getAgents());\n };\n\n /**\n * Subscribes to the 'agentListUpdated' event.\n * @param {function} callback - The callback to be called when the event is fired.\n *\n * @return {function} unsubscribe function.\n */\n const onAgentsListChanged = (callback) => {\n if (_agents && angular.isFunction(callback)) {\n callback(getAgents());\n }\n return subscribe(TTYGEventName.AGENT_LIST_UPDATED, (selectedChat) => callback(selectedChat));\n };\n\n /**\n * @return {AgentModel}\n */\n const getSelectedAgent = () => {\n return cloneDeep(_selectedAgent);\n };\n\n /**\n * Updates the selected agent with the provided <code>selectedAgent</code> and emits the 'agentSelected' event\n * to notify listeners that a new agent has been selected.\n *\n * @param {AgentModel} selectedAgent - The instance of selected agent.\n */\n const selectAgent = (selectedAgent) => {\n _selectedAgent = cloneDeep(selectedAgent);\n emit(TTYGEventName.AGENT_SELECTED, getSelectedAgent());\n };\n\n const _getExplainResponseCache = () => {\n return cloneDeep(_explainCache);\n };\n\n /**\n * Gets the explain response.\n * @param {string} answerId\n * @return {ExplainResponseModel}\n */\n const getExplainResponse = (answerId) => {\n return cloneDeep(_explainCache[answerId]);\n };\n\n /**\n * Adds the <code>explainResponse</code> into the explain response cache.\n *\n * @param {ExplainResponseModel} explainResponse\n */\n const addExplainResponseCache = (explainResponse) => {\n _explainCache[explainResponse.answerId] = cloneDeep(explainResponse);\n emit(TTYGEventName.EXPLAIN_RESPONSE_CACHE_UPDATED, _getExplainResponseCache());\n };\n\n const hasExplainResponse = (answerId) => {\n return !!_explainCache[answerId];\n };\n\n const toggleExplainResponse = (answerId) => {\n if (hasExplainResponse(answerId)) {\n _explainCache[answerId].expanded = !_explainCache[answerId].expanded;\n emit(TTYGEventName.EXPLAIN_RESPONSE_CACHE_UPDATED, _getExplainResponseCache());\n }\n };\n\n /**\n * Subscribes to the 'explainResponseCacheUpdated' event.\n * @param {function} callback - The callback to be called when the event is fired.\n *\n * @return {function} unsubscribe function.\n */\n const onExplainResponseCacheUpdated = (callback) => {\n if (angular.isFunction(callback)) {\n callback(_getExplainResponseCache());\n }\n return subscribe(TTYGEventName.EXPLAIN_RESPONSE_CACHE_UPDATED, (explainResponses) => callback(explainResponses));\n };\n\n /**\n * Subscribes to the 'agentSelected' event.\n * @param {function} callback - The callback to be called when the event is fired.\n *\n * @return {function} unsubscribe function.\n */\n const onSelectedAgentChanged = (callback) => {\n if (_selectedAgent && angular.isFunction(callback)) {\n callback(getSelectedAgent());\n }\n return subscribe(TTYGEventName.AGENT_SELECTED, (selectedChat) => callback(selectedChat));\n };\n\n /**\n * Updates the \"canModifyAgent\" flag and emits the 'canModifyAgentUpdated' event to notify listeners that the canModifyAgent flag is changed.\n *\n * @param {boolean} canModifyAgent\n */\n const setCanModifyAgent = (canModifyAgent) => {\n _canModifyAgent = cloneDeep(canModifyAgent);\n emit(TTYGEventName.CAN_MODIFY_AGENT_UPDATED, getCanModifyAgent());\n };\n\n const getCanModifyAgent = () => {\n return _canModifyAgent;\n };\n\n /**\n * Subscribes to the 'canModifyAgentUpdated' event.\n * @param {function} callback - The callback to be called when the event is fired.\n *\n * @return {function} unsubscribe function.\n */\n const onCanUpdateAgentUpdated = (callback) => {\n if (angular.isFunction(callback)) {\n callback(getCanModifyAgent());\n }\n return subscribe(TTYGEventName.CAN_MODIFY_AGENT_UPDATED, (canModifyAgent) => callback(canModifyAgent));\n };\n\n /**\n * Emits an event with a deep-cloned payload using the EventEmitterService.\n *\n * @param {string} tTYGEventName - The name of the event to emit. It must be a value from {@link TTYGEventName}.\n * @param {*} payload - The data to emit with the event. The payload is deep-cloned before emission.\n */\n const emit = (tTYGEventName, payload) => {\n EventEmitterService.emitSync(tTYGEventName, cloneDeep(payload));\n };\n\n /**\n * Subscribes to an event with the specified callback using the EventEmitterService.\n *\n * @param {string} tTYGEventName - The name of the event to subscribe to. It must be a value from {@link TTYGEventName}.\n * @param {function} callback - The function to call when the event is emitted.\n * @return {function} - Returns a function that can be called to unsubscribe from the event.\n */\n const subscribe = (tTYGEventName, callback) => {\n return EventEmitterService.subscribeSync(tTYGEventName, (payload) => callback(payload));\n };\n\n return {\n resetContext,\n emit,\n subscribe,\n // chats\n getChats,\n updateChats,\n addChat,\n replaceChat,\n onChatsListChanged,\n getSelectedChat,\n selectChat,\n deselectChat,\n deleteChat,\n onSelectedChatChanged,\n updateSelectedChat,\n onSelectedChatUpdated,\n onLastMessageReceived,\n // agents\n updateAgents,\n onAgentsListChanged,\n getAgents,\n getAgent,\n selectAgent,\n getSelectedAgent,\n onSelectedAgentChanged,\n getDefaultAgent,\n setDefaultAgent,\n setCanModifyAgent,\n getCanModifyAgent,\n onCanUpdateAgentUpdated,\n // chat explain\n hasExplainResponse,\n toggleExplainResponse,\n getExplainResponse,\n addExplainResponseCache,\n onExplainResponseCacheUpdated\n };\n}\n\nexport const TTYGEventName = {\n /**\n * Emitting the \"createChat\" event triggers a backend request to create a new chat.\n */\n CREATE_CHAT: 'createChat',\n\n /**\n * This event is emitted when a chat is successfully created.\n */\n CREATE_CHAT_SUCCESSFUL: 'chatCreated',\n\n /**\n * This event is emitted when the creation of a chat fails.\n */\n CREATE_CHAT_FAILURE: 'chatCreationFailed',\n\n RENAME_CHAT: 'renameChat',\n RENAME_CHAT_SUCCESSFUL: 'chatRenamed',\n RENAME_CHAT_FAILURE: 'chatRenamedFailure',\n\n /**\n * Emitting the \"selectChat\" event when the selected chat has been changed.\n */\n SELECT_CHAT: 'selectChat',\n\n /**\n * Emitting the \"selectChatUpdated\" event when the selected chat has been updated.\n */\n SELECTED_CHAT_UPDATED: 'selectChatUpdated',\n\n /**\n * Emitting the \"lastMessageReceived\" event when the final answer message has been received.\n */\n LAST_MESSAGE_RECEIVED: 'lastMessageReceived',\n\n /**\n * This event will be emitted when the chat delete request is in progress. The payload will contain the chat ID\n * and a boolean indicating if the deletion is in progress.\n */\n DELETING_CHAT: 'deletingChat',\n\n /**\n * This event will be emitted when the delete chat process is triggered but before the chat delete request is sent.\n */\n DELETE_CHAT: 'deleteChat',\n\n /**\n * This event will be emitted when the chat was successfully deleted.\n */\n DELETE_CHAT_SUCCESSFUL: 'chatDeleted',\n\n /**\n * This event will be emitted when the attempt to answer the question fails.\n */\n\n /**\n * This event is emitted when the deletion of a chat fails.\n */\n DELETE_CHAT_FAILURE: 'chatDeletedFailure',\n\n CHAT_EXPORT: 'chatExport',\n CHAT_EXPORT_SUCCESSFUL: 'chatExportSuccess',\n CHAT_EXPORT_FAILURE: 'chatExportFailure',\n CHAT_LIST_UPDATED: 'chatListUpdated',\n\n /**\n * Emitting the \"askQuestion\" event triggers a request to the backend to retrieve an answer to a question.\n */\n ASK_QUESTION: 'askQuestion',\n\n /**\n * This event will be emitted when the attempt to answer the question fails.\n */\n ASK_QUESTION_FAILURE: 'askQuestionFailure',\n\n /**\n * Emitting the \"continueChatRun\" event triggers a request to the backend to retrieve more remaining answers from the same chat run.\n */\n CONTINUE_CHAT_RUN: 'continueChatRun',\n\n /**\n * Emitting the \"loadChats\" event will trigger an action to loads all chats from backend server.\n */\n LOAD_CHATS: 'loadChats',\n LOAD_CHAT_SUCCESSFUL: 'loadChatSuccess',\n LOAD_CHAT_FAILURE: 'loadChatFailure',\n\n AGENT_LIST_UPDATED: 'agentListUpdated',\n\n /**\n * This event will be emitted when the create agent process is triggered through the UI but before the agent create\n * request is sent. This is used to open the agent settings dialog.\n */\n OPEN_AGENT_SETTINGS: 'openAgentSettings',\n\n /**\n * This event will be emitted when an agent needs to be edited.\n */\n EDIT_AGENT: 'editAgent',\n\n /**\n * This event will be emitted when an agent needs to be cloned.\n */\n CLONE_AGENT: 'cloneAgent',\n\n /**\n * This event will be emitted when the delete agent process is triggered but before the agent delete request is sent.\n */\n DELETE_AGENT: 'deleteAgent',\n\n /**\n * This event will be emitted when the agent was successfully deleted.\n */\n AGENT_DELETED: 'agentDeleted',\n\n /**\n * This event will be emitted when the agent delete request is in progress. The payload will contain the agent ID\n * and a boolean indicating if the deletion is in progress.\n */\n DELETING_AGENT: 'deletingAgent',\n\n /**\n * This event will be emitted when an agent is selected by the user through the UI.\n */\n AGENT_SELECTED: 'agentSelected',\n\n /**\n * This event will trigger the opening of the similarity view.\n */\n GO_TO_CREATE_SIMILARITY_VIEW: \"goToCreateSimilarityView\",\n\n /**\n * This event will trigger the opening of the connectors view.\n */\n GO_TO_CONNECTORS_VIEW: \"goToConnectorsView\",\n\n /**\n * This event will trigger the opening of the \"Autocomplete index\" view.\n */\n GO_TO_AUTOCOMPLETE_INDEX_VIEW: \"goToAutocompleteIndexView\",\n\n /**\n * This event will trigger fetching a new explanation of how the answer was generated.\n */\n EXPLAIN_RESPONSE: \"explainResponse\",\n\n /**\n * This event will be emitted when the cache with explain responses changed.\n */\n EXPLAIN_RESPONSE_CACHE_UPDATED: \"explainResponseCacheUpdated\",\n\n /**\n * This event will trigger the opening of the sparql view.\n */\n GO_TO_SPARQL_EDITOR: \"openQueryInSparqlEditor\",\n\n CAN_MODIFY_AGENT_UPDATED: \"canModifyAgentUpdated\",\n};\n"],"names":["TTYGContextService","EventEmitterService","_agents","_chats","_selectedChat","_selectedAgent","_defaultAgent","_explainCache","_canModifyAgent","getAgents","cloneDeep","getChats","updateChats","chats","emit","TTYGEventName","CHAT_LIST_UPDATED","getSelectedChat","getSelectedAgent","_getExplainResponseCache","hasExplainResponse","answerId","getCanModifyAgent","tTYGEventName","payload","emitSync","subscribe","callback","subscribeSync","resetContext","undefined","addChat","newChat","appendChat","replaceChat","oldChat","onChatsListChanged","angular","isFunction","selectChat","selectedChat","id","SELECT_CHAT","deselectChat","deleteChat","chat","onSelectedChatChanged","updateSelectedChat","SELECTED_CHAT_UPDATED","onSelectedChatUpdated","onLastMessageReceived","LAST_MESSAGE_RECEIVED","updateAgents","agents","AGENT_LIST_UPDATED","onAgentsListChanged","getAgent","agentId","selectAgent","selectedAgent","AGENT_SELECTED","onSelectedAgentChanged","getDefaultAgent","setDefaultAgent","agent","setCanModifyAgent","canModifyAgent","CAN_MODIFY_AGENT_UPDATED","onCanUpdateAgentUpdated","toggleExplainResponse","expanded","EXPLAIN_RESPONSE_CACHE_UPDATED","getExplainResponse","addExplainResponseCache","explainResponse","onExplainResponseCacheUpdated","explainResponses","module","factory","$inject","CREATE_CHAT","CREATE_CHAT_SUCCESSFUL","CREATE_CHAT_FAILURE","RENAME_CHAT","RENAME_CHAT_SUCCESSFUL","RENAME_CHAT_FAILURE","DELETING_CHAT","DELETE_CHAT","DELETE_CHAT_SUCCESSFUL","DELETE_CHAT_FAILURE","CHAT_EXPORT","CHAT_EXPORT_SUCCESSFUL","CHAT_EXPORT_FAILURE","ASK_QUESTION","ASK_QUESTION_FAILURE","CONTINUE_CHAT_RUN","LOAD_CHATS","LOAD_CHAT_SUCCESSFUL","LOAD_CHAT_FAILURE","OPEN_AGENT_SETTINGS","EDIT_AGENT","CLONE_AGENT","DELETE_AGENT","AGENT_DELETED","DELETING_AGENT","GO_TO_CREATE_SIMILARITY_VIEW","GO_TO_CONNECTORS_VIEW","GO_TO_AUTOCOMPLETE_INDEX_VIEW","EXPLAIN_RESPONSE","GO_TO_SPARQL_EDITOR"],"sourceRoot":""}
@@ -1,2 +0,0 @@
1
- export const __webpack_id__=73964;export const __webpack_ids__=[36633,73964];export const __webpack_modules__={36633:(e,t,n)=>{n.r(t),n.d(t,{CHAT_MESSAGE_ROLE:()=>s,ChatMessageModel:()=>r});class r{constructor(e){this._id=e.id,this._role=e.role,this._message=e.message,this._timestamp=1e3*e.timestamp,this.tokenUsageInfo=e.tokenUsageInfo}get id(){return this._id}set id(e){this._id=e}get role(){return this._role}set role(e){this._role=e}get message(){return this._message}set message(e){this._message=e}get timestamp(){return this._timestamp}set timestamp(e){this._timestamp=e}}const s={USER:"user",ASSISTANT:"assistant"}},73964:(e,t,n)=>{n.r(t),n.d(t,{TtygRestServiceFakeBackend:()=>o});var r=n(98980),s=n(36633);const a=2e3;class o{constructor(){this.conversations=[...i]}getConversations(){return new Promise(e=>{setTimeout(()=>e({data:(0,r.cloneDeep)(this.conversations)}),2e3)})}getConversation(e){return new Promise(t=>{setTimeout(()=>t({data:(0,r.cloneDeep)(this.conversations.find(t=>t.id===e))}),2e3)})}renameConversation(e,t){const n=this.conversations.find(t=>t.id===e);return n&&(n.name=t.name),Promise.resolve({data:(0,r.cloneDeep)(n)})}exportConversation(e){return console.log("Exporting conversation with id: ",e),Promise.resolve()}askQuestion(e){const t={id:"msg_Bn07kVDCYT1qmgu1G7Zw0KNe",conversationId:e.conversationId,agentId:null,message:`${e.question}`,role:s.CHAT_MESSAGE_ROLE.USER,timestamp:Math.floor(Date.now()/1e3)},n=this.conversations.find(t=>t.id===e.conversationId),r={id:e.conversationId,name:n?n.name:"Han Solo is a character in the Star Wars...",timestamp:Math.floor(Date.now()/1e3),messages:[{id:"msg_Bn07kVDCYT1qmgu1G7Zw0KNe_"+Date.now(),conversationId:e.conversationId,role:s.CHAT_MESSAGE_ROLE.ASSISTANT,agentId:e.agentId,message:'Certainly! Here\'s a random example that incorporates code, JSON, and a SPARQL query:\n\n### Code (Python)\n\n```python\ndef greet(name):\n return f"Hello, {name}!"\n\nprint(greet("World"))\n```\n\n### JSON\n\n```json\n{\n "greeting": "Hello",\n "target": "World",\n "language": "English"\n}\n```\n\n### SPARQL Query\n\n```sparql\nSELECT ?person ?name\nWHERE {\n ?person a ex:Person .\n ?person ex:hasName ?name .\n}\nLIMIT 10\n```\n\nThis example demonstrates a simple Python function for greeting, a JSON object representing a greeting structure, and a SPARQL query to retrieve names of persons from a dataset.',timestamp:Math.floor(Date.now()/1e3),name:null},{id:"msg_Bn07kVDCYT1qmgu1G7Zw0KNeс_"+Date.now(),conversationId:e.conversationId,role:s.CHAT_MESSAGE_ROLE.ASSISTANT,agentId:e.agentId,message:`Reply to '${e.question}' It seems there was an error with the query. Let me rectify this and try again.`,timestamp:Math.floor(Date.now()/1e3),name:null}]};return n&&(n.messages.push(t),n.messages.push(...r.messages)),new Promise(e=>setTimeout(()=>e({data:r}),2e3))}continueChatRun(e){alert("continueChatRun() not implemented")}deleteConversation(e){return this.conversations=this.conversations.filter(t=>t.id!==e),new Promise(e=>setTimeout(()=>e(),2e3))}createConversation(e){const t={id:`thread_${this.conversations.length}`,name:`Thread ${this.conversations.length}`,timestamp:Math.floor(Date.now()/1e3),messages:[]};this.conversations.unshift(t);const n=(0,r.cloneDeep)(e);return n.conversationId=t.id,this.askQuestion(n)}getAgents(){return new Promise(e=>setTimeout(()=>e({data:[...l]}),2e3))}getAgent(e){return Promise.resolve({data:(0,r.cloneDeep)(l.find(t=>t.id===e))})}createAgent(e){return"err"===e.name?new Promise((e,t)=>setTimeout(()=>t({status:500,message:"Internal Server Error"}),a)):(l.push(e),new Promise(t=>setTimeout(()=>t({data:e}),a)))}editAgent(e){return"err"===e.name?new Promise((e,t)=>setTimeout(()=>t({status:500,message:"Internal Server Error"}),2e3)):(l=l.map(t=>t.id===e.id?e:t),new Promise(t=>setTimeout(()=>t({data:e}),a)))}deleteAgent(e){return l=l.filter(t=>t.id!==e),Promise.resolve()}getAgentDefaultValues(){return Promise.resolve({data:u})}explainAgentSettings(){return Promise.resolve({data:{}})}simulateHttpError(){return Promise.reject({status:500,message:"Internal Server Error"})}explainResponse(e){return Promise.resolve({data:{conversationId:e.conversationId,answerId:e.answerId,queryMethods:[{name:"sparql_query",rawQuery:'SELECT ?character ?name ?height WHERE {\n ?character a voc:Character;\n rdfs:label ?name;\n voc:height ?height.\n FILTER(?name = "Luke Skywalker" || ?name = "Leia Organa")\n}',query:'SELECT ?character ?name ?height WHERE {\n ?character a voc:Character;\n rdfs:label ?name;\n voc:height ?height.\n FILTER(?name = "Luke Skywalker" || ?name = "Leia Organa")\n}',queryType:"sparql",errorOutput:"Error: org.eclipse.rdf4j.query.MalformedQueryException: org.eclipse.rdf4j.query.parser.sparql.ast.VisitorException: QName 'voc:Character' uses an undefined prefix"},{name:"retrieval_search",rawQuery:'{"queries":[{"query":"pilots that work with Luke Skywalker","filter":{"document_id":"https://swapi.co/resource/human/1"},"top_k":3}]}',query:'{\n "queries" : [ {\n "query" : "pilots that work with Luke Skywalker",\n "filter" : {\n "document_id" : "https://swapi.co/resource/human/1"\n },\n "top_k" : 3\n } ]\n}',queryType:"json",errorOutput:null},{name:"iri_discovery",rawQuery:"Luke Skywalker",query:"PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>\nPREFIX skos: <http://www.w3.org/2004/02/skos/core#>\nPREFIX onto: <http://www.ontotext.com/>\nSELECT ?label ?iri {\n ?label onto:fts ('''Luke~ Skywalker~''' '*') .\n ?iri rdfs:label|skos:prefLabel ?label .\n}",queryType:"sparql",errorOutput:null},{name:"sparql_query",rawQuery:"SELECT ?height WHERE {\n <https://swapi.co/resource/human/1> voc:height ?height.\n}",query:"SELECT ?height WHERE {\n <https://swapi.co/resource/human/1> voc:height ?height.\n}",queryType:"sparql",errorOutput:"Error: org.eclipse.rdf4j.query.MalformedQueryException: org.eclipse.rdf4j.query.parser.sparql.ast.VisitorException: QName 'voc:height' uses an undefined prefix"},{name:"sparql_query",rawQuery:'PREFIX voc: <https://swapi.co/vocabulary/>\nSELECT ?name ?height WHERE {\n ?character voc:height ?height;\n rdfs:label ?name.\n FILTER(?name = "Luke Skywalker" || ?name = "Leia Organa")\n}',query:'PREFIX voc: <https://swapi.co/vocabulary/>\nSELECT ?name ?height WHERE {\n ?character voc:height ?height;\n rdfs:label ?name.\n FILTER(?name = "Luke Skywalker" || ?name = "Leia Organa")\n}',queryType:"sparql",errorOutput:null},{name:"fts_search",rawQuery:"Second Luke",query:"PREFIX onto: <http://www.ontotext.com/>\nDESCRIBE ?iri {\n\t?x onto:fts '''Second Luke''' .\n\t{\n\t\t?x ?p ?iri .\n\t} union {\n\t\t?iri ?p ?x .\n\t}\n}",queryType:"sparql",errorOutput:null},{name:"similarity_search",rawQuery:"Second Luke",query:"PREFIX onto: <http://www.ontotext.com/>\nDESCRIBE ?iri {\n\t?x onto:fts '''Second Luke''' .\n\t{\n\t\t?x ?p ?iri .\n\t} union {\n\t\t?iri ?p ?x .\n\t}\n}",queryType:"sparql",errorOutput:null},{name:"iri_discovery",rawQuery:"Luke Skywalker",query:"PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>\nPREFIX skos: <http://www.w3.org/2004/02/skos/core#>\nPREFIX onto: <http://www.ontotext.com/>\nSELECT ?label ?iri {\n ?label onto:fts ('''Luke~ Skywalker~''' '*') .\n ?iri rdfs:label|skos:prefLabel ?label .\n}",queryType:"sparql",errorOutput:null},{name:"sparql_query",rawQuery:"SELECT ?name ?height WHERE { ?character voc:name ?name ; voc:height ?height . FILTER (?name = 'Luke Skywalker' || ?name = 'Leia Organa') }",query:"SELECT ?name ?height WHERE { ?character voc:name ?name ; voc:height ?height . FILTER (?name = 'Luke Skywalker' || ?name = 'Leia Organa') }",queryType:"sparql",errorOutput:"Error: java.lang.IllegalArgumentException: The following IRIs are not used in the data stored in GraphDB: https://swapi.co/vocabulary/name"},{name:"sparql_query",rawQuery:"SELECT ?character ?height WHERE { ?character voc:height ?height . FILTER (?character = <https://swapi.co/resource/human/1> || ?character = <https://swapi.co/resource/human/5>) }",query:"SELEdCT ?character ?height WHERE { ?character voc:height ?height . FILTER (?character = <https://swapi.co/resource/human/1> || ?character = <https://swapi.co/resource/human/5>) }",queryType:"sparql",errorOutput:null}]}})}}const i=[{id:"thread_jdQBvbkaU6JPoO48oFbC54dA",name:"Very long chat name which does not fit in the sidebar",timestamp:1725235200,messages:[]},{id:"thread_jdQBvbkaU6JPoO48oQaL76dB",name:"Test chat 2",timestamp:1725238800,messages:[]},{id:"thread_jdQBvbkaU6JPoO48oQaL76dC",name:"Test chat 3",timestamp:1725242400,messages:[]},{id:"thread_jdQBvbkaU6JPoO48oFbC54dD",name:"Test chat 4",timestamp:1697331600,messages:[]}];let l=[{id:"asst_gAPcrHQQ9ZIxD5eXWH2BNFfo",name:"agent-1",model:"gpt-4o",temperature:0,topP:0,seed:null,repositoryId:"starwars",instructions:{systemInstruction:"\n\n",userInstruction:""},assistantExtractionMethods:[{ftsMethod:"fts_search"}],maxNumberOfTriplesPerCall:null},{id:"asst_qMyCpCBmqxV9I2B8UoMfFzc5",name:"agent-2",model:"gpt-4o",temperature:0,topP:0,seed:null,repositoryId:"Non existing repo",instructions:{systemInstruction:"string\n\nstring",userInstruction:"string"},assistantExtractionMethods:[{ftsMethod:"fts_search"}],maxNumberOfTriplesPerCall:null},{id:"asst_Cr0RxobrY07WpOvvyQilEWMI",name:"Databricks-general-unbiased",model:"gpt-4o-2024-08-06",temperature:1,topP:1,seed:null,repositoryId:"starwars",instructions:{systemInstruction:"You are helpful assistant in discovering information regarding diagnostic biomarkers.",userInstruction:null},assistantExtractionMethods:[],maxNumberOfTriplesPerCall:null},{id:"asst_5GxNYTdaOh7Tl6lLl6Pya2aH",name:"Databricks-biomarkers",model:"gpt-3.5-turbo-0125",temperature:1,topP:1,seed:null,repositoryId:"biomarkers",instructions:{systemInstruction:"You're a helpful assistant in discovering new diagnostic biomarkers for given diseases. I'll submit a set of publication abstracts discussing given disease and your task is to find in the abstracts any potential new biomarkers which are not yet listed in the appropriate databases. Each abstract is preceded by identifier - its PubMed id called for short PMID. \n\nReturn the set of biomarkers listed one per row, each marker followed by the | and PMID of the respective abstract if was mentioned in.\n\nExample: \nInput: 36418457\t[Amyotrophic lateral sclerosis (ALS) is a genetically and phenotypically heterogeneous disease results in the loss of motor neurons. Mounting information points to involvement of other systems including cognitive impairment. However, neither the valid biomarker for diagnosis nor effective therapeutic intervention is available for ALS. The present study is aimed at identifying potentially genetic biomarker that improves the diagnosis and treatment of ALS patients based on the data of the Gene Expression Omnibus. We retrieved datasets and conducted a weighted gene co-expression network analysis (WGCNA) to identify ALS-related co-expression genes. Functional enrichment analysis was performed to determine the features and pathways of the main modules. We then constructed an ALS-related model using the least absolute shrinkage and selection operator (LASSO) regression analysis and verified the model by the receiver operating characteristic (ROC) curve. Besides we screened the non-preserved gene modules in FTD and ALS-mimic disorders to distinct ALS-related genes from disorders with overlapping genes and features. Altogether, 4198 common genes between datasets with the most variation were analyzed and 16 distinct modules were identified through WGCNA. Blue module had the most correlation with ALS and functionally enriched in pathways of neurodegeneration-multiple diseases', 'amyotrophic lateral sclerosis', and 'endocytosis' KEGG terms. Further, some of other modules related to ALS were enriched in 'autophagy' and 'amyotrophic lateral sclerosis'. The 30 top of hub genes were recruited to a LASSO regression model and 5 genes (BCLAF1, GNA13, ARL6IP5, ARGLU1, and YPEL5) were identified as potentially diagnostic ALS biomarkers with validating of the ROC curve and AUC value.]\n\nYour response: BCLAF1|36418457\nGNA13|36418457\nARL6IP5|36418457\nARGLU1|36418457\nYPEL5|36418457",userInstruction:null},assistantExtractionMethods:[],maxNumberOfTriplesPerCall:null},{id:"asst_qMyCpCBmqxV9I2B8UoMfFzc555",name:"agent with long name long long long long long long long long long long long long",model:"gpt-4o",temperature:0,topP:0,seed:null,repositoryId:"Non existing repo",instructions:{systemInstruction:"string\n\nstring",userInstruction:"string"},assistantExtractionMethods:[{ftsMethod:"fts_search"}],maxNumberOfTriplesPerCall:null},{id:"asst_qMyCpCBmqxV9I2B8UoMfFzcр555",name:"Long_agent_with_long_name_long_long_long_long_long_long_long_long_long_long_long_long",model:"gpt-4o",temperature:0,topP:0,seed:null,repositoryId:"Non existing repo",instructions:{systemInstruction:"string\n\nstring",userInstruction:"string"},assistantExtractionMethods:[{ftsMethod:"fts_search"}],maxNumberOfTriplesPerCall:null},{id:"asst_qMyCpCBmqxV9I2B8UoMfFzc55д5",name:"agent with long name long long long long long long long long long long long long",model:"gpt-4o",temperature:0,topP:0,seed:null,repositoryId:"starwars",instructions:{systemInstruction:"string\n\nstring",userInstruction:"string"},assistantExtractionMethods:[{ftsMethod:"fts_search"}],maxNumberOfTriplesPerCall:null},{id:"asst_qMyCpCBmqxV9I2B8UoMfFzcя555",name:"Long_agent_with_long_name_long_long_long_long_long_long_long_long_long_long_long_long",model:"gpt-4o",temperature:0,topP:0,seed:null,repositoryId:"starwars",instructions:{systemInstruction:"string\n\nstring",userInstruction:"string"},assistantExtractionMethods:[{ftsMethod:"fts_search"}],maxNumberOfTriplesPerCall:null}];const u={id:"id",name:"Quadro",model:"gpt-4o",api:"openai-completions",contextSize:128e3,temperature:.7,topP:1,seed:0,repositoryId:"test-repository",instructions:{systemInstruction:"You are a helpful, knowledgeable, and friendly assistant. Your goal is to provide clear and accurate information while being polite, respectful, and professional.",userInstruction:"If you need to write a SPARQL query, use only the classes and properties provided in the schema and don't invent or guess any. Always try to return human-readable names or labels and not only the IRIs. If SPARQL fails to provide the necessary information you can try another tool too."},assistantExtractionMethods:[{method:"sparql_search",ontologyGraph:"http://example.com",sparqlQuery:"CONSTRUCT {?s ?p ?o} WHERE {GRAPH <http://example.org/ontology> {?s ?p ?o .}}"},{method:"fts_search",maxNumberOfTriplesPerCall:0},{method:"similarity_search",similarityIndex:"similarity-index",similarityIndexThreshold:.6,maxNumberOfTriplesPerCall:0},{method:"retrieval_search",retrievalConnectorInstance:"retrieval-connector",queryTemplate:'{"query": "string"}',maxNumberOfTriplesPerCall:0}],additionalExtractionMethods:[{method:"iri_discovery_search"}]}}};
2
- //# sourceMappingURL=73964.fd1ad5e7aa228ad4cbbb.bundle.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"73964.fd1ad5e7aa228ad4cbbb.bundle.js","mappings":"8LAAO,MAAMA,EACTC,WAAAA,CAAYC,GAKRC,KAAKC,IAAMF,EAAKG,GAKhBF,KAAKG,MAAQJ,EAAKK,KAKlBJ,KAAKK,SAAWN,EAAKO,QAKrBN,KAAKO,WAA8B,IAAjBR,EAAKS,UAQvBR,KAAKS,eAAiBV,EAAKU,cAC/B,CAEA,MAAIP,GACA,OAAOF,KAAKC,GAChB,CAEA,MAAIC,CAAGQ,GACHV,KAAKC,IAAMS,CACf,CAEA,QAAIN,GACA,OAAOJ,KAAKG,KAChB,CAEA,QAAIC,CAAKM,GACLV,KAAKG,MAAQO,CACjB,CAEA,WAAIJ,GACA,OAAON,KAAKK,QAChB,CAEA,WAAIC,CAAQI,GACRV,KAAKK,SAAWK,CACpB,CAEA,aAAIF,GACA,OAAOR,KAAKO,UAChB,CAEA,aAAIC,CAAUE,GACVV,KAAKO,WAAaG,CACtB,EAGG,MAAMC,EAAoB,CAC7BC,KAAM,OACNC,UAAW,Y,6FC/Df,MAQMC,EAAqB,IAMpB,MAAMC,EAETjB,WAAAA,GACIE,KAAKgB,cAAgB,IAAIC,EAC7B,CAEAC,gBAAAA,GACI,OAAO,IAAIC,QAASC,IAChBC,WAAW,IAAMD,EAAQ,CAACrB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/chat-message.js","webpack://root-config/./packages/legacy-workbench/src/js/angular/rest/ttyg.rest.service.fake.backend.js"],"sourcesContent":["export class ChatMessageModel {\n constructor(data) {\n\n /**\n * @type {string}\n */\n this._id = data.id;\n\n /**\n * @type @type {string} - A value from {@link CHAT_MESSAGE_ROLE}, determining the owner of the message (e.g., user, assistant).\n */\n this._role = data.role;\n\n /**\n * @type {string}\n */\n this._message = data.message;\n\n /**\n * @type {number}\n */\n this._timestamp = data.timestamp * 1000;\n\n /**\n * Holds information about the number of tokens used for this answer, including prompt and completion tokens.\n * It is applicable only to the assistant role ({@link CHAT_MESSAGE_ROLE#ASSISTANT}).\n *\n * @type {TokenUsageInfo}\n */\n this.tokenUsageInfo = data.tokenUsageInfo;\n }\n\n get id() {\n return this._id;\n }\n\n set id(value) {\n this._id = value;\n }\n\n get role() {\n return this._role;\n }\n\n set role(value) {\n this._role = value;\n }\n\n get message() {\n return this._message;\n }\n\n set message(value) {\n this._message = value;\n }\n\n get timestamp() {\n return this._timestamp;\n }\n\n set timestamp(value) {\n this._timestamp = value;\n }\n}\n\nexport const CHAT_MESSAGE_ROLE = {\n USER: 'user',\n ASSISTANT: 'assistant'\n};\n","import {cloneDeep} from \"lodash\";\nimport {CHAT_MESSAGE_ROLE} from \"../models/ttyg/chat-message\";\n\n// Delay for askQuestion()\nconst ASK_DELAY = 2000;\n\n// Delay for getConversations()\nconst LIST_CHATS_DELAY = 2000;\n\n// Delay for getConversation(id)\nconst GET_CHAT_DELAY = 2000;\n\nconst CREATE_AGENT_DELAY = 2000;\nconst EDIT_AGENT_DELAY = 2000;\nconst LOAD_AGENTS_DELAY = 2000;\n\nconst DELETE_DELAY = 2000;\n\nexport class TtygRestServiceFakeBackend {\n\n constructor() {\n this.conversations = [...conversationList];\n }\n\n getConversations() {\n return new Promise((resolve) => {\n setTimeout(() => resolve({data: cloneDeep(this.conversations)}), LIST_CHATS_DELAY);\n });\n }\n\n getConversation(id) {\n return new Promise((resolve) => {\n setTimeout(() => resolve({data: cloneDeep(this.conversations.find((conversation) => conversation.id === id))}),\n GET_CHAT_DELAY);\n });\n }\n\n renameConversation(id, data) {\n const conversation = this.conversations.find((conversation) => conversation.id === id);\n if (conversation) {\n conversation.name = data.name;\n }\n return Promise.resolve({data: cloneDeep(conversation)});\n }\n\n exportConversation(id) {\n console.log(\"Exporting conversation with id: \", id);\n return Promise.resolve();\n }\n\n askQuestion(askRequestData) {\n const question = {\n id: \"msg_Bn07kVDCYT1qmgu1G7Zw0KNe\",\n conversationId: askRequestData.conversationId,\n agentId: null,\n message: `${askRequestData.question}`,\n role: CHAT_MESSAGE_ROLE.USER,\n timestamp: Math.floor(Date.now() / 1000)\n };\n\n const conversation = this.conversations.find((conversation) => conversation.id === askRequestData.conversationId);\n\n const answer = {\n id: askRequestData.conversationId,\n name: conversation ? conversation.name : \"Han Solo is a character in the Star Wars...\",\n timestamp: Math.floor(Date.now() / 1000),\n messages: [\n {\n id: \"msg_Bn07kVDCYT1qmgu1G7Zw0KNe_\" + Date.now(),\n conversationId: askRequestData.conversationId,\n role: CHAT_MESSAGE_ROLE.ASSISTANT,\n agentId: askRequestData.agentId,\n message: \"Certainly! Here's a random example that incorporates code, JSON, and a SPARQL query:\\n\\n### Code (Python)\\n\\n```python\\ndef greet(name):\\n return f\\\"Hello, {name}!\\\"\\n\\nprint(greet(\\\"World\\\"))\\n```\\n\\n### JSON\\n\\n```json\\n{\\n \\\"greeting\\\": \\\"Hello\\\",\\n \\\"target\\\": \\\"World\\\",\\n \\\"language\\\": \\\"English\\\"\\n}\\n```\\n\\n### SPARQL Query\\n\\n```sparql\\nSELECT ?person ?name\\nWHERE {\\n ?person a ex:Person .\\n ?person ex:hasName ?name .\\n}\\nLIMIT 10\\n```\\n\\nThis example demonstrates a simple Python function for greeting, a JSON object representing a greeting structure, and a SPARQL query to retrieve names of persons from a dataset.\",\n timestamp: Math.floor(Date.now() / 1000),\n name: null\n },\n {\n id: \"msg_Bn07kVDCYT1qmgu1G7Zw0KNeс_\" + Date.now(),\n conversationId: askRequestData.conversationId,\n role: CHAT_MESSAGE_ROLE.ASSISTANT,\n agentId: askRequestData.agentId,\n message: `Reply to '${askRequestData.question}' It seems there was an error with the query. Let me rectify this and try again.`,\n timestamp: Math.floor(Date.now() / 1000),\n name: null\n }\n ]\n };\n\n if (conversation) {\n conversation.messages.push(question);\n conversation.messages.push(...answer.messages);\n }\n return new Promise((resolve) => setTimeout(() => resolve({data: answer}), ASK_DELAY));\n // return new Promise((resolve, reject) => setTimeout(() => reject(''), ASK_DELAY));\n }\n\n continueChatRun(data) {\n alert(\"continueChatRun() not implemented\");\n }\n\n deleteConversation(id) {\n this.conversations = this.conversations.filter((conversation) => conversation.id !== id);\n return new Promise((resolve) => setTimeout(() => resolve(), DELETE_DELAY));\n }\n\n createConversation(data) {\n const conversation = {\n id: `thread_${this.conversations.length}`,\n name: `Thread ${this.conversations.length}`,\n timestamp: Math.floor(Date.now() / 1000),\n messages: []\n };\n this.conversations.unshift(conversation);\n\n const askRequestData = cloneDeep(data);\n askRequestData.conversationId = conversation.id;\n return this.askQuestion(askRequestData);\n }\n\n getAgents() {\n return new Promise((resolve) => setTimeout(() => resolve({data: [...agentsList]}), LOAD_AGENTS_DELAY));\n }\n\n getAgent(id) {\n return Promise.resolve({data: cloneDeep(agentsList.find((agent) => agent.id === id))});\n }\n\n createAgent(agent) {\n if (agent.name === 'err') {\n return new Promise((resolve, reject) => setTimeout(() => reject({status: 500, message: 'Internal Server Error'}), CREATE_AGENT_DELAY));\n }\n agentsList.push(agent);\n return new Promise((resolve) => setTimeout(() => resolve({data: agent}), CREATE_AGENT_DELAY));\n }\n\n editAgent(editedAgent) {\n if (editedAgent.name === 'err') {\n return new Promise((resolve, reject) => setTimeout(() => reject({status: 500, message: 'Internal Server Error'}), EDIT_AGENT_DELAY));\n }\n agentsList = agentsList.map((agent) => agent.id === editedAgent.id ? editedAgent : agent);\n return new Promise((resolve) => setTimeout(() => resolve({data: editedAgent}), CREATE_AGENT_DELAY));\n }\n\n deleteAgent(id) {\n agentsList = agentsList.filter((agent) => agent.id !== id);\n return Promise.resolve();\n // return new Promise((resolve) => {\n // setTimeout(() => resolve(), 5000);\n // });\n }\n\n getAgentDefaultValues() {\n return Promise.resolve({data: defaultAgentValues});\n }\n\n explainAgentSettings() {\n return Promise.resolve({data: {}});\n }\n\n // Simulate an HTTP error\n simulateHttpError() {\n return Promise.reject({\n status: 500,\n message: 'Internal Server Error'\n });\n }\n\n explainResponse(data) {\n return Promise.resolve({data: {\n conversationId: data.conversationId,\n answerId: data.answerId,\n queryMethods: [\n {\n name: \"sparql_query\",\n rawQuery: \"SELECT ?character ?name ?height WHERE {\\n ?character a voc:Character;\\n rdfs:label ?name;\\n voc:height ?height.\\n FILTER(?name = \\\"Luke Skywalker\\\" || ?name = \\\"Leia Organa\\\")\\n}\",\n query: \"SELECT ?character ?name ?height WHERE {\\n ?character a voc:Character;\\n rdfs:label ?name;\\n voc:height ?height.\\n FILTER(?name = \\\"Luke Skywalker\\\" || ?name = \\\"Leia Organa\\\")\\n}\",\n queryType: \"sparql\",\n errorOutput: \"Error: org.eclipse.rdf4j.query.MalformedQueryException: org.eclipse.rdf4j.query.parser.sparql.ast.VisitorException: QName 'voc:Character' uses an undefined prefix\"\n }, {\n name: \"retrieval_search\",\n rawQuery: \"{\\\"queries\\\":[{\\\"query\\\":\\\"pilots that work with Luke Skywalker\\\",\\\"filter\\\":{\\\"document_id\\\":\\\"https://swapi.co/resource/human/1\\\"},\\\"top_k\\\":3}]}\",\n query: \"{\\n \\\"queries\\\" : [ {\\n \\\"query\\\" : \\\"pilots that work with Luke Skywalker\\\",\\n \\\"filter\\\" : {\\n \\\"document_id\\\" : \\\"https://swapi.co/resource/human/1\\\"\\n },\\n \\\"top_k\\\" : 3\\n } ]\\n}\",\n queryType: \"json\",\n errorOutput: null\n },\n {\n name: \"iri_discovery\",\n rawQuery: \"Luke Skywalker\",\n query: \"PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>\\nPREFIX skos: <http://www.w3.org/2004/02/skos/core#>\\nPREFIX onto: <http://www.ontotext.com/>\\nSELECT ?label ?iri {\\n ?label onto:fts ('''Luke~ Skywalker~''' '*') .\\n ?iri rdfs:label|skos:prefLabel ?label .\\n}\",\n queryType: \"sparql\",\n errorOutput: null\n },\n {\n name: \"sparql_query\",\n rawQuery: \"SELECT ?height WHERE {\\n <https://swapi.co/resource/human/1> voc:height ?height.\\n}\",\n query: \"SELECT ?height WHERE {\\n <https://swapi.co/resource/human/1> voc:height ?height.\\n}\",\n queryType: \"sparql\",\n errorOutput: \"Error: org.eclipse.rdf4j.query.MalformedQueryException: org.eclipse.rdf4j.query.parser.sparql.ast.VisitorException: QName 'voc:height' uses an undefined prefix\"\n },\n {\n name: \"sparql_query\",\n rawQuery: \"PREFIX voc: <https://swapi.co/vocabulary/>\\nSELECT ?name ?height WHERE {\\n ?character voc:height ?height;\\n rdfs:label ?name.\\n FILTER(?name = \\\"Luke Skywalker\\\" || ?name = \\\"Leia Organa\\\")\\n}\",\n query: \"PREFIX voc: <https://swapi.co/vocabulary/>\\nSELECT ?name ?height WHERE {\\n ?character voc:height ?height;\\n rdfs:label ?name.\\n FILTER(?name = \\\"Luke Skywalker\\\" || ?name = \\\"Leia Organa\\\")\\n}\",\n queryType: \"sparql\",\n errorOutput: null\n },\n {\n name: 'fts_search',\n rawQuery: 'Second Luke',\n query: 'PREFIX onto: <http://www.ontotext.com/>\\nDESCRIBE ?iri {\\n\\t?x onto:fts \\'\\'\\'Second Luke\\'\\'\\' .\\n\\t{\\n\\t\\t?x ?p ?iri .\\n\\t} union {\\n\\t\\t?iri ?p ?x .\\n\\t}\\n}',\n queryType: \"sparql\",\n errorOutput: null\n }, {\n name: 'similarity_search',\n rawQuery: 'Second Luke',\n query: 'PREFIX onto: <http://www.ontotext.com/>\\nDESCRIBE ?iri {\\n\\t?x onto:fts \\'\\'\\'Second Luke\\'\\'\\' .\\n\\t{\\n\\t\\t?x ?p ?iri .\\n\\t} union {\\n\\t\\t?iri ?p ?x .\\n\\t}\\n}',\n queryType: \"sparql\",\n errorOutput: null\n }, {\n name: \"iri_discovery\",\n rawQuery: \"Luke Skywalker\",\n query: \"PREFIX rdfs: <http://www.w3.org/2000/01/rdf-schema#>\\nPREFIX skos: <http://www.w3.org/2004/02/skos/core#>\\nPREFIX onto: <http://www.ontotext.com/>\\nSELECT ?label ?iri {\\n ?label onto:fts ('''Luke~ Skywalker~''' '*') .\\n ?iri rdfs:label|skos:prefLabel ?label .\\n}\",\n queryType: \"sparql\",\n errorOutput: null\n }, {\n name: \"sparql_query\",\n rawQuery: \"SELECT ?name ?height WHERE { ?character voc:name ?name ; voc:height ?height . FILTER (?name = 'Luke Skywalker' || ?name = 'Leia Organa') }\",\n query: \"SELECT ?name ?height WHERE { ?character voc:name ?name ; voc:height ?height . FILTER (?name = 'Luke Skywalker' || ?name = 'Leia Organa') }\",\n queryType: \"sparql\",\n errorOutput: \"Error: java.lang.IllegalArgumentException: The following IRIs are not used in the data stored in GraphDB: https://swapi.co/vocabulary/name\"\n }, {\n name: \"sparql_query\",\n rawQuery: \"SELECT ?character ?height WHERE { ?character voc:height ?height . FILTER (?character = <https://swapi.co/resource/human/1> || ?character = <https://swapi.co/resource/human/5>) }\",\n query: \"SELEdCT ?character ?height WHERE { ?character voc:height ?height . FILTER (?character = <https://swapi.co/resource/human/1> || ?character = <https://swapi.co/resource/human/5>) }\",\n queryType: \"sparql\",\n errorOutput: null\n }\n ]\n }});\n }\n}\n\nconst conversationList = [\n {\n \"id\": \"thread_jdQBvbkaU6JPoO48oFbC54dA\",\n \"name\": \"Very long chat name which does not fit in the sidebar\",\n \"timestamp\": 1725235200,\n \"messages\": []\n },\n {\n \"id\": \"thread_jdQBvbkaU6JPoO48oQaL76dB\",\n \"name\": \"Test chat 2\",\n \"timestamp\": 1725238800,\n \"messages\": []\n },\n {\n \"id\": \"thread_jdQBvbkaU6JPoO48oQaL76dC\",\n \"name\": \"Test chat 3\",\n \"timestamp\": 1725242400,\n \"messages\": []\n },\n {\n \"id\": \"thread_jdQBvbkaU6JPoO48oFbC54dD\",\n \"name\": \"Test chat 4\",\n \"timestamp\": 1697331600,\n \"messages\": []\n }\n];\n\nlet agentsList = [\n {\n \"id\": \"asst_gAPcrHQQ9ZIxD5eXWH2BNFfo\",\n \"name\": \"agent-1\",\n \"model\": \"gpt-4o\",\n \"temperature\": 0.0,\n \"topP\": 0.0,\n \"seed\": null,\n \"repositoryId\": 'starwars',\n \"instructions\": {\n \"systemInstruction\": \"\\n\\n\",\n \"userInstruction\": \"\"\n },\n \"assistantExtractionMethods\": [\n {\n \"ftsMethod\": \"fts_search\"\n }\n ],\n \"maxNumberOfTriplesPerCall\": null\n },\n {\n \"id\": \"asst_qMyCpCBmqxV9I2B8UoMfFzc5\",\n \"name\": \"agent-2\",\n \"model\": \"gpt-4o\",\n \"temperature\": 0.0,\n \"topP\": 0.0,\n \"seed\": null,\n \"repositoryId\": \"Non existing repo\",\n \"instructions\": {\n \"systemInstruction\": \"string\\n\\nstring\",\n \"userInstruction\": \"string\"\n },\n \"assistantExtractionMethods\": [\n {\n \"ftsMethod\": \"fts_search\"\n }\n ],\n \"maxNumberOfTriplesPerCall\": null\n },\n {\n \"id\": \"asst_Cr0RxobrY07WpOvvyQilEWMI\",\n \"name\": \"Databricks-general-unbiased\",\n \"model\": \"gpt-4o-2024-08-06\",\n \"temperature\": 1.0,\n \"topP\": 1.0,\n \"seed\": null,\n \"repositoryId\": 'starwars',\n \"instructions\": {\n \"systemInstruction\": \"You are helpful assistant in discovering information regarding diagnostic biomarkers.\",\n \"userInstruction\": null\n },\n \"assistantExtractionMethods\": [],\n \"maxNumberOfTriplesPerCall\": null\n },\n {\n \"id\": \"asst_5GxNYTdaOh7Tl6lLl6Pya2aH\",\n \"name\": \"Databricks-biomarkers\",\n \"model\": \"gpt-3.5-turbo-0125\",\n \"temperature\": 1.0,\n \"topP\": 1.0,\n \"seed\": null,\n \"repositoryId\": 'biomarkers',\n \"instructions\": {\n \"systemInstruction\": \"You're a helpful assistant in discovering new diagnostic biomarkers for given diseases. I'll submit a set of publication abstracts discussing given disease and your task is to find in the abstracts any potential new biomarkers which are not yet listed in the appropriate databases. Each abstract is preceded by identifier - its PubMed id called for short PMID. \\n\\nReturn the set of biomarkers listed one per row, each marker followed by the | and PMID of the respective abstract if was mentioned in.\\n\\nExample: \\nInput: 36418457\\t[Amyotrophic lateral sclerosis (ALS) is a genetically and phenotypically heterogeneous disease results in the loss of motor neurons. Mounting information points to involvement of other systems including cognitive impairment. However, neither the valid biomarker for diagnosis nor effective therapeutic intervention is available for ALS. The present study is aimed at identifying potentially genetic biomarker that improves the diagnosis and treatment of ALS patients based on the data of the Gene Expression Omnibus. We retrieved datasets and conducted a weighted gene co-expression network analysis (WGCNA) to identify ALS-related co-expression genes. Functional enrichment analysis was performed to determine the features and pathways of the main modules. We then constructed an ALS-related model using the least absolute shrinkage and selection operator (LASSO) regression analysis and verified the model by the receiver operating characteristic (ROC) curve. Besides we screened the non-preserved gene modules in FTD and ALS-mimic disorders to distinct ALS-related genes from disorders with overlapping genes and features. Altogether, 4198 common genes between datasets with the most variation were analyzed and 16 distinct modules were identified through WGCNA. Blue module had the most correlation with ALS and functionally enriched in pathways of neurodegeneration-multiple diseases', 'amyotrophic lateral sclerosis', and 'endocytosis' KEGG terms. Further, some of other modules related to ALS were enriched in 'autophagy' and 'amyotrophic lateral sclerosis'. The 30 top of hub genes were recruited to a LASSO regression model and 5 genes (BCLAF1, GNA13, ARL6IP5, ARGLU1, and YPEL5) were identified as potentially diagnostic ALS biomarkers with validating of the ROC curve and AUC value.]\\n\\nYour response: BCLAF1|36418457\\nGNA13|36418457\\nARL6IP5|36418457\\nARGLU1|36418457\\nYPEL5|36418457\",\n \"userInstruction\": null\n },\n \"assistantExtractionMethods\": [],\n \"maxNumberOfTriplesPerCall\": null\n },\n {\n \"id\": \"asst_qMyCpCBmqxV9I2B8UoMfFzc555\",\n \"name\": \"agent with long name long long long long long long long long long long long long\",\n \"model\": \"gpt-4o\",\n \"temperature\": 0.0,\n \"topP\": 0.0,\n \"seed\": null,\n \"repositoryId\": \"Non existing repo\",\n \"instructions\": {\n \"systemInstruction\": \"string\\n\\nstring\",\n \"userInstruction\": \"string\"\n },\n \"assistantExtractionMethods\": [\n {\n \"ftsMethod\": \"fts_search\"\n }\n ],\n \"maxNumberOfTriplesPerCall\": null\n },\n {\n \"id\": \"asst_qMyCpCBmqxV9I2B8UoMfFzcр555\",\n \"name\": \"Long_agent_with_long_name_long_long_long_long_long_long_long_long_long_long_long_long\",\n \"model\": \"gpt-4o\",\n \"temperature\": 0.0,\n \"topP\": 0.0,\n \"seed\": null,\n \"repositoryId\": \"Non existing repo\",\n \"instructions\": {\n \"systemInstruction\": \"string\\n\\nstring\",\n \"userInstruction\": \"string\"\n },\n \"assistantExtractionMethods\": [\n {\n \"ftsMethod\": \"fts_search\"\n }\n ],\n \"maxNumberOfTriplesPerCall\": null\n },\n {\n \"id\": \"asst_qMyCpCBmqxV9I2B8UoMfFzc55д5\",\n \"name\": \"agent with long name long long long long long long long long long long long long\",\n \"model\": \"gpt-4o\",\n \"temperature\": 0.0,\n \"topP\": 0.0,\n \"seed\": null,\n \"repositoryId\": \"starwars\",\n \"instructions\": {\n \"systemInstruction\": \"string\\n\\nstring\",\n \"userInstruction\": \"string\"\n },\n \"assistantExtractionMethods\": [\n {\n \"ftsMethod\": \"fts_search\"\n }\n ],\n \"maxNumberOfTriplesPerCall\": null\n },\n {\n \"id\": \"asst_qMyCpCBmqxV9I2B8UoMfFzcя555\",\n \"name\": \"Long_agent_with_long_name_long_long_long_long_long_long_long_long_long_long_long_long\",\n \"model\": \"gpt-4o\",\n \"temperature\": 0.0,\n \"topP\": 0.0,\n \"seed\": null,\n \"repositoryId\": \"starwars\",\n \"instructions\": {\n \"systemInstruction\": \"string\\n\\nstring\",\n \"userInstruction\": \"string\"\n },\n \"assistantExtractionMethods\": [\n {\n \"ftsMethod\": \"fts_search\"\n }\n ],\n \"maxNumberOfTriplesPerCall\": null\n }\n];\n\nconst defaultAgentValues = {\n \"id\": \"id\",\n \"name\": \"Quadro\",\n \"model\": \"gpt-4o\",\n \"api\": \"openai-completions\",\n \"contextSize\": 128000,\n \"temperature\": 0.7,\n \"topP\": 1,\n \"seed\": 0,\n \"repositoryId\": \"test-repository\",\n \"instructions\": {\n \"systemInstruction\": \"You are a helpful, knowledgeable, and friendly assistant. Your goal is to provide clear and accurate information while being polite, respectful, and professional.\",\n \"userInstruction\": \"If you need to write a SPARQL query, use only the classes and properties provided in the schema and don't invent or guess any. Always try to return human-readable names or labels and not only the IRIs. If SPARQL fails to provide the necessary information you can try another tool too.\"\n },\n \"assistantExtractionMethods\": [\n {\n \"method\": \"sparql_search\",\n \"ontologyGraph\": \"http://example.com\",\n \"sparqlQuery\": \"CONSTRUCT {?s ?p ?o} WHERE {GRAPH <http://example.org/ontology> {?s ?p ?o .}}\"\n },\n {\n \"method\": \"fts_search\",\n \"maxNumberOfTriplesPerCall\": 0\n },\n {\n \"method\": \"similarity_search\",\n \"similarityIndex\": \"similarity-index\",\n \"similarityIndexThreshold\": 0.6,\n \"maxNumberOfTriplesPerCall\": 0\n },\n {\n \"method\": \"retrieval_search\",\n \"retrievalConnectorInstance\": \"retrieval-connector\",\n \"queryTemplate\": \"{\\\"query\\\": \\\"string\\\"}\",\n \"maxNumberOfTriplesPerCall\": 0\n }\n ],\n \"additionalExtractionMethods\": [\n {\n \"method\": \"iri_discovery_search\"\n }\n ]\n};\n"],"names":["ChatMessageModel","constructor","data","this","_id","id","_role","role","_message","message","_timestamp","timestamp","tokenUsageInfo","value","CHAT_MESSAGE_ROLE","USER","ASSISTANT","CREATE_AGENT_DELAY","TtygRestServiceFakeBackend","conversations","conversationList","getConversations","Promise","resolve","setTimeout","cloneDeep","getConversation","find","conversation","renameConversation","name","exportConversation","console","log","askQuestion","askRequestData","question","conversationId","agentId","Math","floor","Date","now","answer","messages","push","continueChatRun","alert","deleteConversation","filter","createConversation","length","unshift","getAgents","agentsList","getAgent","agent","createAgent","reject","status","editAgent","editedAgent","map","deleteAgent","getAgentDefaultValues","defaultAgentValues","explainAgentSettings","simulateHttpError","explainResponse","answerId","queryMethods","rawQuery","query","queryType","errorOutput"],"sourceRoot":""}
@@ -1,2 +0,0 @@
1
- export const __webpack_id__=75849;export const __webpack_ids__=[75849];export const __webpack_modules__={75849:(t,a,e)=>{e.r(a),e.d(a,{default:()=>n});const n='<link href="css/ttyg/chat-list.css?v=3.2.0-TR2" rel="stylesheet"/> <div class="chat-list-component"> <div class="chat-list"> <div ng-repeat="chatGroup in chatList.chatsByDay" class="chat-group"> <label>{{ getHumanReadableChatGroupTimestamp(chatGroup.timestamp) }}</label> <ul> <li ng-repeat="chat in chatGroup.chats track by chat.hash" class="chat-item" ng-class="{\'selected\': chat.id === selectedChat.id, \'edited\': renamedChat && chat.id === renamedChat.id}"> <div ng-if="!deletingChat || deletingChat.chatId !== chat.id" class="chat-detail"> <div class="chat-name"> <inline-editable-text field-name="name" source="chat" is-editing="chat.id && renamedChat && chat.id === renamedChat.id" on-save="onRenameChat(newText, source)" on-cancel="onCancelChatRenaming()" on-dblclick="onSelectChatForRenaming(chat)" on-click="onSelectChat(source)" title="{{chat.name}}" show-tooltip-on-overflow> </inline-editable-text> </div> <div ng-if="chat.id && (!renamedChat || chat.id !== renamedChat.id)" class="btn-group"> <button class="btn btn-link secondary btn-sm open-chat-actions-btn" data-toggle="dropdown" aria-expanded="false" ng-if="true" ng-click="openChatActionMenu()" ng-disabled="false"> <i class="fa fa-ellipsis"></i> </button> <div class="dropdown-menu dropdown-menu-right chat-actions-menu"> <button class="dropdown-item export-chat-btn" type="button" ng-click="onExportChat(chat)"> <i class="fa fa-arrow-down-to-line"></i> <span>{{\'ttyg.chat.btn.export_chat.label\' | translate}}</span> </button> <button class="dropdown-item rename-chat-btn" type="button" ng-click="onSelectChatForRenaming(chat)"> <i class="fa fa-pen"></i> <span>{{\'ttyg.chat.btn.rename_chat.label\' | translate}}</span> </button> <div class="dropdown-divider"></div> <button class="dropdown-item delete-chat-btn" type="button" ng-click="onDeleteChat(chat)"> <i class="fa fa-trash-can"></i> <span>{{\'ttyg.chat.btn.delete_chat.label\' | translate}}</span> </button> </div> </div> </div> <div class="deleting-chat-loader" ng-if="deletingChat && deletingChat.chatId === chat.id && deletingChat.inProgress" onto-loader-fancy message="{{\'ttyg.chat.deleting_chat\' | translate}}" size="25"></div> </li> </ul> </div> </div> </div> '}};
2
- //# sourceMappingURL=75849.bd0bdefa903741034a71.bundle.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"75849.bd0bdefa903741034a71.bundle.js","mappings":"uJAGA,QAFW,2pE","sources":["webpack://root-config/./packages/legacy-workbench/src/js/angular/ttyg/templates/chat-list.html"],"sourcesContent":["// Module\nvar code = `<link href=\"css/ttyg/chat-list.css?v=3.2.0-TR2\" rel=\"stylesheet\"/> <div class=\"chat-list-component\"> <div class=\"chat-list\"> <div ng-repeat=\"chatGroup in chatList.chatsByDay\" class=\"chat-group\"> <label>{{ getHumanReadableChatGroupTimestamp(chatGroup.timestamp) }}</label> <ul> <li ng-repeat=\"chat in chatGroup.chats track by chat.hash\" class=\"chat-item\" ng-class=\"{'selected': chat.id === selectedChat.id, 'edited': renamedChat && chat.id === renamedChat.id}\"> <div ng-if=\"!deletingChat || deletingChat.chatId !== chat.id\" class=\"chat-detail\"> <div class=\"chat-name\"> <inline-editable-text field-name=\"name\" source=\"chat\" is-editing=\"chat.id && renamedChat && chat.id === renamedChat.id\" on-save=\"onRenameChat(newText, source)\" on-cancel=\"onCancelChatRenaming()\" on-dblclick=\"onSelectChatForRenaming(chat)\" on-click=\"onSelectChat(source)\" title=\"{{chat.name}}\" show-tooltip-on-overflow> </inline-editable-text> </div> <div ng-if=\"chat.id && (!renamedChat || chat.id !== renamedChat.id)\" class=\"btn-group\"> <button class=\"btn btn-link secondary btn-sm open-chat-actions-btn\" data-toggle=\"dropdown\" aria-expanded=\"false\" ng-if=\"true\" ng-click=\"openChatActionMenu()\" ng-disabled=\"false\"> <i class=\"fa fa-ellipsis\"></i> </button> <div class=\"dropdown-menu dropdown-menu-right chat-actions-menu\"> <button class=\"dropdown-item export-chat-btn\" type=\"button\" ng-click=\"onExportChat(chat)\"> <i class=\"fa fa-arrow-down-to-line\"></i> <span>{{'ttyg.chat.btn.export_chat.label' | translate}}</span> </button> <button class=\"dropdown-item rename-chat-btn\" type=\"button\" ng-click=\"onSelectChatForRenaming(chat)\"> <i class=\"fa fa-pen\"></i> <span>{{'ttyg.chat.btn.rename_chat.label' | translate}}</span> </button> <div class=\"dropdown-divider\"></div> <button class=\"dropdown-item delete-chat-btn\" type=\"button\" ng-click=\"onDeleteChat(chat)\"> <i class=\"fa fa-trash-can\"></i> <span>{{'ttyg.chat.btn.delete_chat.label' | translate}}</span> </button> </div> </div> </div> <div class=\"deleting-chat-loader\" ng-if=\"deletingChat && deletingChat.chatId === chat.id && deletingChat.inProgress\" onto-loader-fancy message=\"{{'ttyg.chat.deleting_chat' | translate}}\" size=\"25\"></div> </li> </ul> </div> </div> </div> `;\n// Exports\nexport default code;"],"names":[],"sourceRoot":""}
@@ -1,2 +0,0 @@
1
- export const __webpack_id__=76013;export const __webpack_ids__=[76013];export const __webpack_modules__={76013:()=>{const e=(e,t)=>e.$repositories.getRepositories().find(e=>e.id===t.repositoryId)?t.repositoryId:t.repositoryIdBase,t=(t,o)=>t.GuideUtils.getGuideElementSelector(`repository-id-${e(t,o)}`),o=e=>{const t=document.querySelector(".onto-repository-selector");t&&(t.autoClose=e)};PluginRegistry.add("guide.step",[{guideBlockName:"select-repository-dropdown",getSteps:(i,s)=>{const r=s.GuideUtils;return i.mainAction="select-repository",i.getRepositoryId=()=>e(s,i),[{guideBlockName:"clickable-element",options:angular.extend({},{skipPoint:!0,content:"guide.step_plugin.choose-repository.content",elementSelector:".onto-repository-selector",class:"repositories-group-button",onNextClick:r.clickOnElement(".onto-repository-selector .onto-dropdown-button")},i)},{guideBlockName:"clickable-element",options:angular.extend({},{content:"guide.step_plugin.select-repository.content",elementSelector:()=>t(s,i),class:"repository-select-button",advanceOn:void 0,beforeShowPromise:()=>s.GuideUtils.waitFor(t(s,i),1).catch(e=>{throw s.toastr.error(s.$translate.instant("guide.unexpected.error.message")),e}),show:e=>()=>{o(!1),$(t(s,i)).on("mouseup.selectRepositoryButtonClick",function(){e.next()})},onNextClick:e=>{$(t(s,i)).off("mouseup.selectRepositoryButtonClick"),r.clickOnElement(t(s,i))().then(()=>e.next())},hide:()=>()=>{o(!0),$(t(s,i)).off("mouseup.selectRepositoryButtonClick")},canBePaused:!1},i)}]}},{guideBlockName:"repositories-select-repository",getSteps:(t,o)=>{const i=o.GuideUtils,s=t.repositoryIdToSelect??e(o,t),r=`${i.getGuideElementSelector(`repository-${s}`)} ${i.getGuideElementSelector("select-repository-button-wrapper")}`,n=`${r} ${i.getGuideElementSelector("select-repository-button")}`;return[{guideBlockName:"clickable-element",options:{content:"guide.step_plugin.repositories.select-repository.content",...t.mainAction?{}:{title:"guide.step_plugin.repositories.default-title"},url:"repository",elementSelector:r,class:"repositories-select-repository",onNextClick:()=>i.clickOnElement(n)(),...t}}]}}])}};
2
- //# sourceMappingURL=76013.3211939a02cf4fb2529e.bundle.js.map
@@ -1 +0,0 @@
1
- {"version":3,"file":"76013.3211939a02cf4fb2529e.bundle.js","mappings":"oHAAA,MAAMA,EAAoBA,CAACC,EAAUC,IAC1BD,EAASE,cAAcC,kBAAkBC,KAAMC,GAASA,EAAKC,KAAOL,EAAQM,cAAgBN,EAAQM,aAAeN,EAAQO,iBAGhIC,EAA+BA,CAACT,EAAUC,IACrCD,EAASU,WAAWC,wBAAwB,iBAAiBZ,EAAkBC,EAAUC,MAG9FW,EAAkCC,IACpC,MAAMC,EAAYC,SAASC,cAAc,6BACrCF,IAEAA,EAAUD,UAAYA,IAM9BI,eAAeC,IAAI,aAAc,CAC7B,CACIC,eAAgB,6BAChBC,SAAUA,CAACnB,EAASD,KACh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oB,WAAa,CAAC,EAAI,CAAC+B,MAtEpB,gDAuEXC,IAAK,aACL1B,gBAAiBuB,EACjBtB,MAAO,iCACPC,YAAaA,IAAMnB,EAAWoB,eAAeqB,EAA1BzC,MAChBT,Q","sources":["webpack://root-config/./packages/legacy-workbench/src/js/angular/guides/steps/complex/select-repository/plugin.js"],"sourcesContent":["const getRepositoryName = (services, options) => {\n return services.$repositories.getRepositories().find((repo) => repo.id === options.repositoryId) ? options.repositoryId : options.repositoryIdBase;\n};\n\nconst getRepositoryElementSelector = (services, options) => {\n return services.GuideUtils.getGuideElementSelector(`repository-id-${getRepositoryName(services, options)}`);\n};\n\nconst setRepositorySelectorAutoClose = (autoClose) => {\n const component = document.querySelector('.onto-repository-selector');\n if (component) {\n // Enable auto-close when the guide step is closed.\n component.autoClose = autoClose;\n }\n}\n\nconst REPOSITORIES_DEFAULT_TITLE = 'guide.step_plugin.repositories.default-title'\n\nPluginRegistry.add('guide.step', [\n {\n guideBlockName: 'select-repository-dropdown',\n getSteps: (options, services) => {\n const GuideUtils = services.GuideUtils;\n options.mainAction = 'select-repository';\n options.getRepositoryId = () => getRepositoryName(services, options);\n\n return [{\n guideBlockName: 'clickable-element',\n options: angular.extend({}, {\n skipPoint: true,\n content: 'guide.step_plugin.choose-repository.content',\n elementSelector: '.onto-repository-selector',\n class: 'repositories-group-button',\n onNextClick: GuideUtils.clickOnElement('.onto-repository-selector .onto-dropdown-button')\n }, options)\n }, {\n guideBlockName: 'clickable-element',\n options: angular.extend({}, {\n content: 'guide.step_plugin.select-repository.content',\n elementSelector: () => {\n return getRepositoryElementSelector(services, options);\n },\n class: 'repository-select-button',\n advanceOn: undefined,\n beforeShowPromise: () => services.GuideUtils.waitFor(getRepositoryElementSelector(services, options), 1)\n .catch((error) => {\n services.toastr.error(services.$translate.instant('guide.unexpected.error.message'));\n throw (error);\n }),\n show: (guide) => () => {\n setRepositorySelectorAutoClose(false);\n // Added listener to the element.\n $(getRepositoryElementSelector(services, options))\n .on('mouseup.selectRepositoryButtonClick', function () {\n guide.next();\n });\n },\n onNextClick: (guide) => {\n $(getRepositoryElementSelector(services, options)).off('mouseup.selectRepositoryButtonClick');\n GuideUtils.clickOnElement(getRepositoryElementSelector(services, options))().then(() => guide.next());\n },\n hide: () => () => {\n setRepositorySelectorAutoClose(true);\n // Remove ths listener from element. It is important when step is hided.\n $(getRepositoryElementSelector(services, options)).off('mouseup.selectRepositoryButtonClick');\n },\n canBePaused: false\n }, options)\n }\n ];\n }\n },\n {\n guideBlockName: 'repositories-select-repository',\n getSteps: (options, services) => {\n const GuideUtils = services.GuideUtils;\n const repositoryId = options.repositoryIdToSelect ?? getRepositoryName(services, options);\n const selectRepositoryRowSelector = GuideUtils.getGuideElementSelector(`repository-${repositoryId}`);\n const selectRepositoryButtonWrapperSelector = `${selectRepositoryRowSelector} ${GuideUtils.getGuideElementSelector('select-repository-button-wrapper')}`;\n const selectRepositoryButtonSelector = `${selectRepositoryButtonWrapperSelector} ${GuideUtils.getGuideElementSelector('select-repository-button')}`;\n return [\n {\n guideBlockName: 'clickable-element',\n options: {\n content: 'guide.step_plugin.repositories.select-repository.content',\n // If mainAction is set the title will be set automatically\n ...(options.mainAction ? {} : {title: REPOSITORIES_DEFAULT_TITLE}),\n url: 'repository',\n elementSelector: selectRepositoryButtonWrapperSelector,\n class: 'repositories-select-repository',\n onNextClick: () => GuideUtils.clickOnElement(selectRepositoryButtonSelector)(),\n ...options\n }\n }\n ]\n }\n }\n]);\n"],"names":["getRepositoryName","services","options","$repositories","getRepositories","find","repo","id","repositoryId","repositoryIdBase","getRepositoryElementSelector","GuideUtils","getGuideElementSelector","setRepositorySelectorAutoClose","autoClose","component","document","querySelector","PluginRegistry","add","guideBlockName","getSteps","mainAction","getRepositoryId","angular","extend","skipPoint","content","elementSelector","class","onNextClick","clickOnElement","advanceOn","undefined","beforeShowPromise","waitFor","catch","error","toastr","$translate","instant","show","guide","$","on","next","off","then","hide","canBePaused","repositoryIdToSelect","selectRepositoryButtonWrapperSelector","selectRepositoryButtonSelector","title","url"],"sourceRoot":""}
@@ -1,2 +0,0 @@
1
- export const __webpack_id__=7928;export const __webpack_ids__=[7928,49539,71920];export const __webpack_modules__={7928:(e,t,n)=>{n.r(t);var E=n(71920),a=n(76076);function T(e,t){return{restrict:"E",templateUrl:"js/angular/ttyg/templates/no-agents-view.html",scope:{},link:n=>{n.canModifyAgent=!1,n.talkToGraphDocumentationLink=a.DocumentationUrlResolver.getDocumentationUrl(t.productShortVersion,"talk-to-graph.html"),n.onCreateAgent=()=>{e.emit(E.TTYGEventName.OPEN_AGENT_SETTINGS)};const T=[];T.push(e.onCanUpdateAgentUpdated(e=>{n.canModifyAgent=e})),n.$on("$destroy",()=>{T.forEach(e=>e())})}}}angular.module("graphdb.framework.ttyg.directives.no-agents-view",[]).directive("noAgentsView",T),T.$inject=["TTYGContextService","productInfo"]},71920:(e,t,n)=>{n.r(t),n.d(t,{TTYGEventName:()=>T});var E=n(98980);function a(e){let t,n,a,A,_,o={},C=!1;const c=()=>(0,E.cloneDeep)(t),i=()=>(0,E.cloneDeep)(n),d=e=>{n=(0,E.cloneDeep)(e),p(T.CHAT_LIST_UPDATED,i())},l=()=>(0,E.cloneDeep)(a),s=()=>(0,E.cloneDeep)(A),D=()=>(0,E.cloneDeep)(o),r=e=>!!o[e],S=()=>C,p=(t,n)=>{e.emitSync(t,(0,E.cloneDeep)(n))},g=(t,n)=>e.subscribeSync(t,e=>n(e));return{resetContext:()=>{t=void 0,n=void 0,a=void 0,A=void 0,o={},_=void 0,C=!1},emit:p,subscribe:g,getChats:i,updateChats:d,addChat:e=>{n.appendChat(e),d(n)},replaceChat:(e,t)=>{n.replaceChat(e,t),d(n)},onChatsListChanged:e=>(n&&angular.isFunction(e)&&e(i()),g(T.CHAT_LIST_UPDATED,t=>e(t))),getSelectedChat:l,selectChat:e=>{a&&a.id===e.id||(a=(0,E.cloneDeep)(e),p(T.SELECT_CHAT,l()))},deselectChat:()=>{a=void 0,p(T.SELECT_CHAT,l())},deleteChat:e=>{n.deleteChat(e),d(n)},onSelectedChatChanged:e=>(angular.isFunction(e)&&e(l()),g(T.SELECT_CHAT,t=>e(t))),updateSelectedChat:e=>{a&&a.id&&e&&a.id!==e.id||(a=(0,E.cloneDeep)(e),p(T.SELECTED_CHAT_UPDATED,l()))},onSelectedChatUpdated:e=>(a&&angular.isFunction(e)&&e(l()),g(T.SELECTED_CHAT_UPDATED,t=>e(t))),onLastMessageReceived:e=>(a&&angular.isFunction(e)&&e(l()),g(T.LAST_MESSAGE_RECEIVED,t=>e(t))),updateAgents:e=>{t=(0,E.cloneDeep)(e),p(T.AGENT_LIST_UPDATED,c())},onAgentsListChanged:e=>(t&&angular.isFunction(e)&&e(c()),g(T.AGENT_LIST_UPDATED,t=>e(t))),getAgents:c,getAgent:e=>{if(t)return(0,E.cloneDeep)(t.getAgent(e))},selectAgent:e=>{A=(0,E.cloneDeep)(e),p(T.AGENT_SELECTED,s())},getSelectedAgent:s,onSelectedAgentChanged:e=>(A&&angular.isFunction(e)&&e(s()),g(T.AGENT_SELECTED,t=>e(t))),getDefaultAgent:()=>(0,E.cloneDeep)(_),setDefaultAgent:e=>{_=e},setCanModifyAgent:e=>{C=(0,E.cloneDeep)(e),p(T.CAN_MODIFY_AGENT_UPDATED,S())},getCanModifyAgent:S,onCanUpdateAgentUpdated:e=>(angular.isFunction(e)&&e(S()),g(T.CAN_MODIFY_AGENT_UPDATED,t=>e(t))),hasExplainResponse:r,toggleExplainResponse:e=>{r(e)&&(o[e].expanded=!o[e].expanded,p(T.EXPLAIN_RESPONSE_CACHE_UPDATED,D()))},getExplainResponse:e=>(0,E.cloneDeep)(o[e]),addExplainResponseCache:e=>{o[e.answerId]=(0,E.cloneDeep)(e),p(T.EXPLAIN_RESPONSE_CACHE_UPDATED,D())},onExplainResponseCacheUpdated:e=>(angular.isFunction(e)&&e(D()),g(T.EXPLAIN_RESPONSE_CACHE_UPDATED,t=>e(t)))}}angular.module("graphdb.framework.ttyg.services.ttygcontext",[]).factory("TTYGContextService",a),a.$inject=["EventEmitterService","TTYGService"];const T={CREATE_CHAT:"createChat",CREATE_CHAT_SUCCESSFUL:"chatCreated",CREATE_CHAT_FAILURE:"chatCreationFailed",RENAME_CHAT:"renameChat",RENAME_CHAT_SUCCESSFUL:"chatRenamed",RENAME_CHAT_FAILURE:"chatRenamedFailure",SELECT_CHAT:"selectChat",SELECTED_CHAT_UPDATED:"selectChatUpdated",LAST_MESSAGE_RECEIVED:"lastMessageReceived",DELETING_CHAT:"deletingChat",DELETE_CHAT:"deleteChat",DELETE_CHAT_SUCCESSFUL:"chatDeleted",DELETE_CHAT_FAILURE:"chatDeletedFailure",CHAT_EXPORT:"chatExport",CHAT_EXPORT_SUCCESSFUL:"chatExportSuccess",CHAT_EXPORT_FAILURE:"chatExportFailure",CHAT_LIST_UPDATED:"chatListUpdated",ASK_QUESTION:"askQuestion",ASK_QUESTION_FAILURE:"askQuestionFailure",CONTINUE_CHAT_RUN:"continueChatRun",LOAD_CHATS:"loadChats",LOAD_CHAT_SUCCESSFUL:"loadChatSuccess",LOAD_CHAT_FAILURE:"loadChatFailure",AGENT_LIST_UPDATED:"agentListUpdated",OPEN_AGENT_SETTINGS:"openAgentSettings",EDIT_AGENT:"editAgent",CLONE_AGENT:"cloneAgent",DELETE_AGENT:"deleteAgent",AGENT_DELETED:"agentDeleted",DELETING_AGENT:"deletingAgent",AGENT_SELECTED:"agentSelected",GO_TO_CREATE_SIMILARITY_VIEW:"goToCreateSimilarityView",GO_TO_CONNECTORS_VIEW:"goToConnectorsView",GO_TO_AUTOCOMPLETE_INDEX_VIEW:"goToAutocompleteIndexView",EXPLAIN_RESPONSE:"explainResponse",EXPLAIN_RESPONSE_CACHE_UPDATED:"explainResponseCacheUpdated",GO_TO_SPARQL_EDITOR:"openQueryInSparqlEditor",CAN_MODIFY_AGENT_UPDATED:"canModifyAgentUpdated"}}};
2
- //# sourceMappingURL=7928.7900a3911c83495d74dd.bundle.js.map