research-copilot 0.1.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (395) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +190 -0
  3. package/app/build/icon.icns +0 -0
  4. package/app/build/icon.ico +0 -0
  5. package/app/build/icon.png +0 -0
  6. package/app/out/main/index.mjs +6719 -0
  7. package/app/out/preload/index.js +141 -0
  8. package/app/out/renderer/assets/Inter-Variable-Latin-8kRkwJBP.woff2 +0 -0
  9. package/app/out/renderer/assets/Inter-Variable-LatinExt-B_-bZUTo.woff2 +0 -0
  10. package/app/out/renderer/assets/KaTeX_AMS-Regular-BQhdFMY1.woff2 +0 -0
  11. package/app/out/renderer/assets/KaTeX_AMS-Regular-DMm9YOAa.woff +0 -0
  12. package/app/out/renderer/assets/KaTeX_AMS-Regular-DRggAlZN.ttf +0 -0
  13. package/app/out/renderer/assets/KaTeX_Caligraphic-Bold-ATXxdsX0.ttf +0 -0
  14. package/app/out/renderer/assets/KaTeX_Caligraphic-Bold-BEiXGLvX.woff +0 -0
  15. package/app/out/renderer/assets/KaTeX_Caligraphic-Bold-Dq_IR9rO.woff2 +0 -0
  16. package/app/out/renderer/assets/KaTeX_Caligraphic-Regular-CTRA-rTL.woff +0 -0
  17. package/app/out/renderer/assets/KaTeX_Caligraphic-Regular-Di6jR-x-.woff2 +0 -0
  18. package/app/out/renderer/assets/KaTeX_Caligraphic-Regular-wX97UBjC.ttf +0 -0
  19. package/app/out/renderer/assets/KaTeX_Fraktur-Bold-BdnERNNW.ttf +0 -0
  20. package/app/out/renderer/assets/KaTeX_Fraktur-Bold-BsDP51OF.woff +0 -0
  21. package/app/out/renderer/assets/KaTeX_Fraktur-Bold-CL6g_b3V.woff2 +0 -0
  22. package/app/out/renderer/assets/KaTeX_Fraktur-Regular-CB_wures.ttf +0 -0
  23. package/app/out/renderer/assets/KaTeX_Fraktur-Regular-CTYiF6lA.woff2 +0 -0
  24. package/app/out/renderer/assets/KaTeX_Fraktur-Regular-Dxdc4cR9.woff +0 -0
  25. package/app/out/renderer/assets/KaTeX_Main-Bold-Cx986IdX.woff2 +0 -0
  26. package/app/out/renderer/assets/KaTeX_Main-Bold-Jm3AIy58.woff +0 -0
  27. package/app/out/renderer/assets/KaTeX_Main-Bold-waoOVXN0.ttf +0 -0
  28. package/app/out/renderer/assets/KaTeX_Main-BoldItalic-DxDJ3AOS.woff2 +0 -0
  29. package/app/out/renderer/assets/KaTeX_Main-BoldItalic-DzxPMmG6.ttf +0 -0
  30. package/app/out/renderer/assets/KaTeX_Main-BoldItalic-SpSLRI95.woff +0 -0
  31. package/app/out/renderer/assets/KaTeX_Main-Italic-3WenGoN9.ttf +0 -0
  32. package/app/out/renderer/assets/KaTeX_Main-Italic-BMLOBm91.woff +0 -0
  33. package/app/out/renderer/assets/KaTeX_Main-Italic-NWA7e6Wa.woff2 +0 -0
  34. package/app/out/renderer/assets/KaTeX_Main-Regular-B22Nviop.woff2 +0 -0
  35. package/app/out/renderer/assets/KaTeX_Main-Regular-Dr94JaBh.woff +0 -0
  36. package/app/out/renderer/assets/KaTeX_Main-Regular-ypZvNtVU.ttf +0 -0
  37. package/app/out/renderer/assets/KaTeX_Math-BoldItalic-B3XSjfu4.ttf +0 -0
  38. package/app/out/renderer/assets/KaTeX_Math-BoldItalic-CZnvNsCZ.woff2 +0 -0
  39. package/app/out/renderer/assets/KaTeX_Math-BoldItalic-iY-2wyZ7.woff +0 -0
  40. package/app/out/renderer/assets/KaTeX_Math-Italic-DA0__PXp.woff +0 -0
  41. package/app/out/renderer/assets/KaTeX_Math-Italic-flOr_0UB.ttf +0 -0
  42. package/app/out/renderer/assets/KaTeX_Math-Italic-t53AETM-.woff2 +0 -0
  43. package/app/out/renderer/assets/KaTeX_SansSerif-Bold-CFMepnvq.ttf +0 -0
  44. package/app/out/renderer/assets/KaTeX_SansSerif-Bold-D1sUS0GD.woff2 +0 -0
  45. package/app/out/renderer/assets/KaTeX_SansSerif-Bold-DbIhKOiC.woff +0 -0
  46. package/app/out/renderer/assets/KaTeX_SansSerif-Italic-C3H0VqGB.woff2 +0 -0
  47. package/app/out/renderer/assets/KaTeX_SansSerif-Italic-DN2j7dab.woff +0 -0
  48. package/app/out/renderer/assets/KaTeX_SansSerif-Italic-YYjJ1zSn.ttf +0 -0
  49. package/app/out/renderer/assets/KaTeX_SansSerif-Regular-BNo7hRIc.ttf +0 -0
  50. package/app/out/renderer/assets/KaTeX_SansSerif-Regular-CS6fqUqJ.woff +0 -0
  51. package/app/out/renderer/assets/KaTeX_SansSerif-Regular-DDBCnlJ7.woff2 +0 -0
  52. package/app/out/renderer/assets/KaTeX_Script-Regular-C5JkGWo-.ttf +0 -0
  53. package/app/out/renderer/assets/KaTeX_Script-Regular-D3wIWfF6.woff2 +0 -0
  54. package/app/out/renderer/assets/KaTeX_Script-Regular-D5yQViql.woff +0 -0
  55. package/app/out/renderer/assets/KaTeX_Size1-Regular-C195tn64.woff +0 -0
  56. package/app/out/renderer/assets/KaTeX_Size1-Regular-Dbsnue_I.ttf +0 -0
  57. package/app/out/renderer/assets/KaTeX_Size1-Regular-mCD8mA8B.woff2 +0 -0
  58. package/app/out/renderer/assets/KaTeX_Size2-Regular-B7gKUWhC.ttf +0 -0
  59. package/app/out/renderer/assets/KaTeX_Size2-Regular-Dy4dx90m.woff2 +0 -0
  60. package/app/out/renderer/assets/KaTeX_Size2-Regular-oD1tc_U0.woff +0 -0
  61. package/app/out/renderer/assets/KaTeX_Size3-Regular-CTq5MqoE.woff +0 -0
  62. package/app/out/renderer/assets/KaTeX_Size3-Regular-DgpXs0kz.ttf +0 -0
  63. package/app/out/renderer/assets/KaTeX_Size4-Regular-BF-4gkZK.woff +0 -0
  64. package/app/out/renderer/assets/KaTeX_Size4-Regular-DWFBv043.ttf +0 -0
  65. package/app/out/renderer/assets/KaTeX_Size4-Regular-Dl5lxZxV.woff2 +0 -0
  66. package/app/out/renderer/assets/KaTeX_Typewriter-Regular-C0xS9mPB.woff +0 -0
  67. package/app/out/renderer/assets/KaTeX_Typewriter-Regular-CO6r4hn1.woff2 +0 -0
  68. package/app/out/renderer/assets/KaTeX_Typewriter-Regular-D3Ib7_Hf.ttf +0 -0
  69. package/app/out/renderer/assets/MilkdownMarkdownEditor-bLPxrCVb.js +89821 -0
  70. package/app/out/renderer/assets/MilkdownMarkdownEditor-tTNRIB2K.css +2555 -0
  71. package/app/out/renderer/assets/Tableau10-BqnYsPR6.js +9 -0
  72. package/app/out/renderer/assets/apl-fqmucPXA.js +140 -0
  73. package/app/out/renderer/assets/arc-J47ePHZ2.js +132 -0
  74. package/app/out/renderer/assets/array-DgktLKBx.js +6 -0
  75. package/app/out/renderer/assets/asciiarmor-DucZyvP0.js +56 -0
  76. package/app/out/renderer/assets/asn1-BnOEsgAm.js +144 -0
  77. package/app/out/renderer/assets/asterisk-QAlztEwS.js +345 -0
  78. package/app/out/renderer/assets/blockDiagram-c4efeb88-5uRQXgQJ.js +1817 -0
  79. package/app/out/renderer/assets/brainfuck-DZVCuF_t.js +53 -0
  80. package/app/out/renderer/assets/c4Diagram-c83219d4-C4iCTPEL.js +2464 -0
  81. package/app/out/renderer/assets/channel-ZAmhHE3g.js +7 -0
  82. package/app/out/renderer/assets/classDiagram-beda092f-7NOZxq_W.js +357 -0
  83. package/app/out/renderer/assets/classDiagram-v2-2358418a-5fPT-cUH.js +291 -0
  84. package/app/out/renderer/assets/clike-xqXYL6ge.js +805 -0
  85. package/app/out/renderer/assets/clojure-BhXMqnxz.js +849 -0
  86. package/app/out/renderer/assets/clone-CsnzsYXQ.js +8 -0
  87. package/app/out/renderer/assets/cmake-BGaNd9E7.js +71 -0
  88. package/app/out/renderer/assets/cobol-4yqQntpt.js +120 -0
  89. package/app/out/renderer/assets/coffeescript-D2dXvhEc.js +308 -0
  90. package/app/out/renderer/assets/commonlisp-CF_VNHQR.js +130 -0
  91. package/app/out/renderer/assets/createText-1719965b-Cji7KN4K.js +4904 -0
  92. package/app/out/renderer/assets/crystal-DyuLTqLs.js +398 -0
  93. package/app/out/renderer/assets/css-c-jst79C.js +1783 -0
  94. package/app/out/renderer/assets/cypher-Dlu_3r4V.js +121 -0
  95. package/app/out/renderer/assets/d-UURgV0Ux.js +179 -0
  96. package/app/out/renderer/assets/diff-B_Bi2Crb.js +25 -0
  97. package/app/out/renderer/assets/dockerfile-Bvk733Ga.js +201 -0
  98. package/app/out/renderer/assets/dtd-Dy74G54E.js +114 -0
  99. package/app/out/renderer/assets/dylan-TSb-Nfix.js +314 -0
  100. package/app/out/renderer/assets/ebnf-DAomQUbD.js +139 -0
  101. package/app/out/renderer/assets/ecl-B59qGGVg.js +178 -0
  102. package/app/out/renderer/assets/edges-96097737-CD0EvAZQ.js +1844 -0
  103. package/app/out/renderer/assets/eiffel-Dze7nlu3.js +134 -0
  104. package/app/out/renderer/assets/elm-DG7jkhNZ.js +176 -0
  105. package/app/out/renderer/assets/erDiagram-0228fc6a-DRYXBpi7.js +1321 -0
  106. package/app/out/renderer/assets/erlang-BO6gOnGA.js +674 -0
  107. package/app/out/renderer/assets/factor-CMxFHDqz.js +65 -0
  108. package/app/out/renderer/assets/fcl-CDDUNjTj.js +141 -0
  109. package/app/out/renderer/assets/flowDb-c6c81e3f-CuoIN-Cy.js +1713 -0
  110. package/app/out/renderer/assets/flowDiagram-50d868cf-CPWPLOml.js +1272 -0
  111. package/app/out/renderer/assets/flowDiagram-v2-4f6560a1-C_R12s4S.js +33 -0
  112. package/app/out/renderer/assets/flowchart-elk-definition-6af322e1-BdKUSFpi.js +92921 -0
  113. package/app/out/renderer/assets/forth-B9D2JCeE.js +116 -0
  114. package/app/out/renderer/assets/fortran-CAG2BFbe.js +467 -0
  115. package/app/out/renderer/assets/ganttDiagram-a2739b55-ygqT5HlG.js +3399 -0
  116. package/app/out/renderer/assets/gas-d3KEcW3x.js +294 -0
  117. package/app/out/renderer/assets/gherkin-DhZlEZiy.js +115 -0
  118. package/app/out/renderer/assets/gitGraphDiagram-82fe8481-D97GT4iA.js +1791 -0
  119. package/app/out/renderer/assets/graph-DpC13d95.js +1237 -0
  120. package/app/out/renderer/assets/groovy-CpwJiBl7.js +223 -0
  121. package/app/out/renderer/assets/haskell-BlGBCCe3.js +459 -0
  122. package/app/out/renderer/assets/haxe-7MlzfeYV.js +514 -0
  123. package/app/out/renderer/assets/http-BqypyemW.js +79 -0
  124. package/app/out/renderer/assets/idl-4HIGJlDI.js +985 -0
  125. package/app/out/renderer/assets/index-4-ziknCv.js +292 -0
  126. package/app/out/renderer/assets/index-5325376f-Bbs7Fbqr.js +663 -0
  127. package/app/out/renderer/assets/index-B2jip-rk.js +2489 -0
  128. package/app/out/renderer/assets/index-BKTVfokE.js +312 -0
  129. package/app/out/renderer/assets/index-BiJbFgVG.js +118 -0
  130. package/app/out/renderer/assets/index-Bn433Fat.js +83 -0
  131. package/app/out/renderer/assets/index-BqDyyRCx.js +39679 -0
  132. package/app/out/renderer/assets/index-BzFMeMPn.js +158 -0
  133. package/app/out/renderer/assets/index-C-_uCjZJ.css +2701 -0
  134. package/app/out/renderer/assets/index-C1ithNW1.js +1765 -0
  135. package/app/out/renderer/assets/index-CAJkRYkO.js +407 -0
  136. package/app/out/renderer/assets/index-CleO0-yj.js +690 -0
  137. package/app/out/renderer/assets/index-Cq4MH3sY.js +1020 -0
  138. package/app/out/renderer/assets/index-CtA0Xj22.js +705 -0
  139. package/app/out/renderer/assets/index-CvAZkqBZ.js +83 -0
  140. package/app/out/renderer/assets/index-D3UDN-5c.js +152 -0
  141. package/app/out/renderer/assets/index-D4F9R5ao.js +179 -0
  142. package/app/out/renderer/assets/index-D6RguhZ5.js +328 -0
  143. package/app/out/renderer/assets/index-DnEowqXv.js +386 -0
  144. package/app/out/renderer/assets/index-K8c8Mqdy.js +98 -0
  145. package/app/out/renderer/assets/index-Kh14gO6K.js +62 -0
  146. package/app/out/renderer/assets/index-WFd2jRnA.js +333 -0
  147. package/app/out/renderer/assets/index-WgMfkRFp.js +313 -0
  148. package/app/out/renderer/assets/index-Y4lKyF6t.js +1042 -0
  149. package/app/out/renderer/assets/index-fx307_f1.js +643 -0
  150. package/app/out/renderer/assets/infoDiagram-8eee0895-ptaVSwzq.js +511 -0
  151. package/app/out/renderer/assets/init-ZxktEp_H.js +16 -0
  152. package/app/out/renderer/assets/javascript-C3MnDRiU.js +994 -0
  153. package/app/out/renderer/assets/journeyDiagram-c64418c1-aloEGOQp.js +1184 -0
  154. package/app/out/renderer/assets/julia-Bs6JJhYG.js +407 -0
  155. package/app/out/renderer/assets/layout-ZeuHE_aY.js +2217 -0
  156. package/app/out/renderer/assets/line-CAgaGl-S.js +45 -0
  157. package/app/out/renderer/assets/linear-DIg7lTe1.js +539 -0
  158. package/app/out/renderer/assets/livescript-DmzgM3Yt.js +296 -0
  159. package/app/out/renderer/assets/lua-8cJgIlqe.js +256 -0
  160. package/app/out/renderer/assets/mathematica-DNLOL9PQ.js +110 -0
  161. package/app/out/renderer/assets/mbox-Ga7d4MMN.js +117 -0
  162. package/app/out/renderer/assets/mindmap-definition-8da855dc-B8XVoUxz.js +36054 -0
  163. package/app/out/renderer/assets/mirc-Dma3B8rS.js +107 -0
  164. package/app/out/renderer/assets/mllike-DHn7xckP.js +334 -0
  165. package/app/out/renderer/assets/modelica-0d55jYY0.js +147 -0
  166. package/app/out/renderer/assets/mscgen-DdqZYINH.js +135 -0
  167. package/app/out/renderer/assets/mumps-Btr8VblO.js +93 -0
  168. package/app/out/renderer/assets/nginx-DTDtBDVN.js +141 -0
  169. package/app/out/renderer/assets/nsis-3zG7tgur.js +62 -0
  170. package/app/out/renderer/assets/ntriples-CvgOYMpL.js +153 -0
  171. package/app/out/renderer/assets/octave-DYBj3-tl.js +200 -0
  172. package/app/out/renderer/assets/ordinal-DSZU4PqD.js +76 -0
  173. package/app/out/renderer/assets/oz-R_e8WMIi.js +231 -0
  174. package/app/out/renderer/assets/pascal-GD8iposT.js +105 -0
  175. package/app/out/renderer/assets/path-Cp2qmpkd.js +109 -0
  176. package/app/out/renderer/assets/perl-DL9mHpoi.js +1105 -0
  177. package/app/out/renderer/assets/pieDiagram-a8764435-DlwoeBU2.js +770 -0
  178. package/app/out/renderer/assets/pig-C_4T4YIV.js +101 -0
  179. package/app/out/renderer/assets/powershell-B0suO7Vd.js +328 -0
  180. package/app/out/renderer/assets/properties-BR-vP1aU.js +58 -0
  181. package/app/out/renderer/assets/protobuf-BxgpyhoW.js +77 -0
  182. package/app/out/renderer/assets/pug-By0kVCfm.js +405 -0
  183. package/app/out/renderer/assets/puppet-Bdao66PW.js +137 -0
  184. package/app/out/renderer/assets/python-CvWbmiX4.js +427 -0
  185. package/app/out/renderer/assets/q-CrbCVq4a.js +131 -0
  186. package/app/out/renderer/assets/quadrantDiagram-1e28029f-BaSi1XB4.js +1200 -0
  187. package/app/out/renderer/assets/r-V7nswm59.js +170 -0
  188. package/app/out/renderer/assets/requirementDiagram-08caed73-D3EFyegZ.js +1092 -0
  189. package/app/out/renderer/assets/rpm-C-DLY-If.js +109 -0
  190. package/app/out/renderer/assets/ruby-JDKLJNK0.js +330 -0
  191. package/app/out/renderer/assets/sankeyDiagram-a04cb91d-Cv44AsnM.js +1174 -0
  192. package/app/out/renderer/assets/sas-D2UG-yhZ.js +207 -0
  193. package/app/out/renderer/assets/scheme-BKzrkGJD.js +222 -0
  194. package/app/out/renderer/assets/sequenceDiagram-c5b8d532-CuUBu-x4.js +3337 -0
  195. package/app/out/renderer/assets/shell-BlsXDxCn.js +222 -0
  196. package/app/out/renderer/assets/sieve-CjwBwOY5.js +135 -0
  197. package/app/out/renderer/assets/simple-mode-DMneyfDu.js +130 -0
  198. package/app/out/renderer/assets/smalltalk-BOIGQuhN.js +121 -0
  199. package/app/out/renderer/assets/solr-CwD7U71z.js +69 -0
  200. package/app/out/renderer/assets/sparql-DYskk2vE.js +249 -0
  201. package/app/out/renderer/assets/spreadsheet-Bgtt3oLP.js +87 -0
  202. package/app/out/renderer/assets/sql-BSrOzCRI.js +354 -0
  203. package/app/out/renderer/assets/stateDiagram-1ecb1508-BOU34Zp4.js +454 -0
  204. package/app/out/renderer/assets/stateDiagram-v2-c2b004d7-BgRoffou.js +326 -0
  205. package/app/out/renderer/assets/stex-B6LNC55o.js +231 -0
  206. package/app/out/renderer/assets/styles-b4e223ce-BMr9TPuj.js +1483 -0
  207. package/app/out/renderer/assets/styles-ca3715f6-DgbNw99p.js +1363 -0
  208. package/app/out/renderer/assets/styles-d45a18b0-DtRYKYKf.js +574 -0
  209. package/app/out/renderer/assets/stylus-BkS-boTH.js +565 -0
  210. package/app/out/renderer/assets/svgDrawCommon-b86b1483-Bein03PD.js +100 -0
  211. package/app/out/renderer/assets/swift-FRZi1uvB.js +291 -0
  212. package/app/out/renderer/assets/tcl-CUcaCdmq.js +114 -0
  213. package/app/out/renderer/assets/textile-BnFpjsrl.js +414 -0
  214. package/app/out/renderer/assets/tiddlywiki-CjprD-Qp.js +218 -0
  215. package/app/out/renderer/assets/tiki-B4EPSQ1G.js +265 -0
  216. package/app/out/renderer/assets/timeline-definition-faaaa080-BlWpLE_4.js +1212 -0
  217. package/app/out/renderer/assets/toml-BOuWGMcf.js +76 -0
  218. package/app/out/renderer/assets/troff-E1bJ0PPL.js +61 -0
  219. package/app/out/renderer/assets/ttcn-cfg-Dc39-fIP.js +133 -0
  220. package/app/out/renderer/assets/ttcn-tKd4HLu4.js +192 -0
  221. package/app/out/renderer/assets/turtle-Dq7-1WAf.js +124 -0
  222. package/app/out/renderer/assets/vb-Dp90gtsv.js +196 -0
  223. package/app/out/renderer/assets/vbscript-CI6_mxxU.js +479 -0
  224. package/app/out/renderer/assets/velocity-BwIZK1TH.js +149 -0
  225. package/app/out/renderer/assets/verilog-DDCYnHN8.js +430 -0
  226. package/app/out/renderer/assets/vhdl-DCkMIyT9.js +158 -0
  227. package/app/out/renderer/assets/webidl-BTLTThCm.js +204 -0
  228. package/app/out/renderer/assets/xquery-BgiOC5Ce.js +525 -0
  229. package/app/out/renderer/assets/xychartDiagram-f5964ef8-Bhga-YXm.js +1799 -0
  230. package/app/out/renderer/assets/yacas-b5lAVEIl.js +130 -0
  231. package/app/out/renderer/assets/z80-BZV19vqv.js +93 -0
  232. package/app/out/renderer/index.html +13 -0
  233. package/app/out/skills/community-builtin/README.md +29 -0
  234. package/app/out/skills/community-builtin/document-docx/SKILL.md +44 -0
  235. package/app/out/skills/community-builtin/document-docx/scripts/docx-to-markdown.sh +20 -0
  236. package/app/out/skills/community-builtin/document-docx/scripts/extract-docx-text.sh +28 -0
  237. package/app/out/skills/community-builtin/document-docx/scripts/init-docx-template.sh +32 -0
  238. package/app/out/skills/community-builtin/document-docx/scripts/setup-docx-tools.sh +10 -0
  239. package/app/out/skills/community-builtin/markitdown/SKILL.md +105 -0
  240. package/app/out/skills/community-builtin/markitdown/scripts/batch-convert.sh +40 -0
  241. package/app/out/skills/community-builtin/markitdown/scripts/convert-file.sh +24 -0
  242. package/app/out/skills/community-builtin/markitdown/scripts/setup-markitdown.sh +10 -0
  243. package/app/out/skills/community-builtin/repo-quick-audit/SKILL.md +27 -0
  244. package/app/out/skills/community-builtin/repo-quick-audit/scripts/audit-basics.sh +19 -0
  245. package/app/out/skills/research-pilot-default-project-skills/README.md +23 -0
  246. package/app/out/skills/research-pilot-default-project-skills/citation-management/SKILL.md +39 -0
  247. package/app/out/skills/research-pilot-default-project-skills/citation-management/scripts/doi-to-bibtex.sh +25 -0
  248. package/app/out/skills/research-pilot-default-project-skills/citation-management/scripts/normalize-bibtex-keys.sh +51 -0
  249. package/app/out/skills/research-pilot-default-project-skills/citation-management/scripts/setup-citation-tools.sh +10 -0
  250. package/app/out/skills/research-pilot-default-project-skills/citation-management/scripts/validate-bib.sh +31 -0
  251. package/app/out/skills/research-pilot-default-project-skills/matplotlib/SKILL.md +34 -0
  252. package/app/out/skills/research-pilot-default-project-skills/matplotlib/references/api_reference.md +412 -0
  253. package/app/out/skills/research-pilot-default-project-skills/matplotlib/references/common_issues.md +563 -0
  254. package/app/out/skills/research-pilot-default-project-skills/matplotlib/references/plot_types.md +476 -0
  255. package/app/out/skills/research-pilot-default-project-skills/matplotlib/references/styling_guide.md +589 -0
  256. package/app/out/skills/research-pilot-default-project-skills/matplotlib/references/subagent_quickstart.md +30 -0
  257. package/app/out/skills/research-pilot-default-project-skills/matplotlib/scripts/plot_template.py +401 -0
  258. package/app/out/skills/research-pilot-default-project-skills/matplotlib/scripts/style_configurator.py +409 -0
  259. package/app/out/skills/research-pilot-default-project-skills/research-grants/SKILL.md +38 -0
  260. package/app/out/skills/research-pilot-default-project-skills/research-grants/scripts/check-grant-compliance.sh +40 -0
  261. package/app/out/skills/research-pilot-default-project-skills/research-grants/scripts/grant-summary-card.sh +32 -0
  262. package/app/out/skills/research-pilot-default-project-skills/research-grants/scripts/init-grant-structure.sh +70 -0
  263. package/app/package.json +77 -0
  264. package/bin/cli.mjs +56 -0
  265. package/lib/README.md +145 -0
  266. package/lib/skills/_generated.ts +13 -0
  267. package/lib/skills/builtin/brainstorming-research-ideas/SKILL.md +280 -0
  268. package/lib/skills/builtin/coding/SKILL.md +114 -0
  269. package/lib/skills/builtin/creative-thinking-for-research/SKILL.md +273 -0
  270. package/lib/skills/builtin/matplotlib/SKILL.md +361 -0
  271. package/lib/skills/builtin/matplotlib/references/api_reference.md +412 -0
  272. package/lib/skills/builtin/matplotlib/references/common_issues.md +563 -0
  273. package/lib/skills/builtin/matplotlib/references/plot_types.md +476 -0
  274. package/lib/skills/builtin/matplotlib/references/styling_guide.md +589 -0
  275. package/lib/skills/builtin/matplotlib/scripts/plot_template.py +401 -0
  276. package/lib/skills/builtin/matplotlib/scripts/style_configurator.py +409 -0
  277. package/lib/skills/builtin/paper-writing/SKILL.md +554 -0
  278. package/lib/skills/builtin/paper-writing/references/checklists.md +524 -0
  279. package/lib/skills/builtin/paper-writing/references/citation-workflow.md +562 -0
  280. package/lib/skills/builtin/paper-writing/references/reviewer-guidelines.md +462 -0
  281. package/lib/skills/builtin/paper-writing/references/sources.md +189 -0
  282. package/lib/skills/builtin/paper-writing/references/systems-conferences.md +260 -0
  283. package/lib/skills/builtin/paper-writing/references/writing-guide.md +476 -0
  284. package/lib/skills/builtin/paper-writing/templates/README.md +408 -0
  285. package/lib/skills/builtin/paper-writing/templates/aaai2026/README.md +534 -0
  286. package/lib/skills/builtin/paper-writing/templates/aaai2026/aaai2026-unified-supp.tex +144 -0
  287. package/lib/skills/builtin/paper-writing/templates/aaai2026/aaai2026-unified-template.tex +952 -0
  288. package/lib/skills/builtin/paper-writing/templates/aaai2026/aaai2026.bib +111 -0
  289. package/lib/skills/builtin/paper-writing/templates/aaai2026/aaai2026.bst +1493 -0
  290. package/lib/skills/builtin/paper-writing/templates/aaai2026/aaai2026.sty +315 -0
  291. package/lib/skills/builtin/paper-writing/templates/acl/README.md +50 -0
  292. package/lib/skills/builtin/paper-writing/templates/acl/acl.sty +312 -0
  293. package/lib/skills/builtin/paper-writing/templates/acl/acl_latex.tex +377 -0
  294. package/lib/skills/builtin/paper-writing/templates/acl/acl_lualatex.tex +101 -0
  295. package/lib/skills/builtin/paper-writing/templates/acl/acl_natbib.bst +1940 -0
  296. package/lib/skills/builtin/paper-writing/templates/acl/anthology.bib.txt +26 -0
  297. package/lib/skills/builtin/paper-writing/templates/acl/custom.bib +70 -0
  298. package/lib/skills/builtin/paper-writing/templates/acl/formatting.md +326 -0
  299. package/lib/skills/builtin/paper-writing/templates/asplos2027/main.tex +459 -0
  300. package/lib/skills/builtin/paper-writing/templates/asplos2027/references.bib +135 -0
  301. package/lib/skills/builtin/paper-writing/templates/colm2025/README.md +3 -0
  302. package/lib/skills/builtin/paper-writing/templates/colm2025/colm2025_conference.bib +11 -0
  303. package/lib/skills/builtin/paper-writing/templates/colm2025/colm2025_conference.bst +1440 -0
  304. package/lib/skills/builtin/paper-writing/templates/colm2025/colm2025_conference.pdf +0 -0
  305. package/lib/skills/builtin/paper-writing/templates/colm2025/colm2025_conference.sty +218 -0
  306. package/lib/skills/builtin/paper-writing/templates/colm2025/colm2025_conference.tex +305 -0
  307. package/lib/skills/builtin/paper-writing/templates/colm2025/fancyhdr.sty +485 -0
  308. package/lib/skills/builtin/paper-writing/templates/colm2025/math_commands.tex +508 -0
  309. package/lib/skills/builtin/paper-writing/templates/colm2025/natbib.sty +1246 -0
  310. package/lib/skills/builtin/paper-writing/templates/iclr2026/fancyhdr.sty +485 -0
  311. package/lib/skills/builtin/paper-writing/templates/iclr2026/iclr2026_conference.bib +24 -0
  312. package/lib/skills/builtin/paper-writing/templates/iclr2026/iclr2026_conference.bst +1440 -0
  313. package/lib/skills/builtin/paper-writing/templates/iclr2026/iclr2026_conference.pdf +0 -0
  314. package/lib/skills/builtin/paper-writing/templates/iclr2026/iclr2026_conference.sty +246 -0
  315. package/lib/skills/builtin/paper-writing/templates/iclr2026/iclr2026_conference.tex +414 -0
  316. package/lib/skills/builtin/paper-writing/templates/iclr2026/math_commands.tex +508 -0
  317. package/lib/skills/builtin/paper-writing/templates/iclr2026/natbib.sty +1246 -0
  318. package/lib/skills/builtin/paper-writing/templates/icml2026/algorithm.sty +79 -0
  319. package/lib/skills/builtin/paper-writing/templates/icml2026/algorithmic.sty +201 -0
  320. package/lib/skills/builtin/paper-writing/templates/icml2026/example_paper.bib +75 -0
  321. package/lib/skills/builtin/paper-writing/templates/icml2026/example_paper.pdf +0 -0
  322. package/lib/skills/builtin/paper-writing/templates/icml2026/example_paper.tex +662 -0
  323. package/lib/skills/builtin/paper-writing/templates/icml2026/fancyhdr.sty +864 -0
  324. package/lib/skills/builtin/paper-writing/templates/icml2026/icml2026.bst +1443 -0
  325. package/lib/skills/builtin/paper-writing/templates/icml2026/icml2026.sty +767 -0
  326. package/lib/skills/builtin/paper-writing/templates/icml2026/icml_numpapers.pdf +0 -0
  327. package/lib/skills/builtin/paper-writing/templates/neurips2025/Makefile +36 -0
  328. package/lib/skills/builtin/paper-writing/templates/neurips2025/extra_pkgs.tex +53 -0
  329. package/lib/skills/builtin/paper-writing/templates/neurips2025/main.tex +38 -0
  330. package/lib/skills/builtin/paper-writing/templates/neurips2025/neurips.sty +382 -0
  331. package/lib/skills/builtin/paper-writing/templates/nsdi2027/main.tex +426 -0
  332. package/lib/skills/builtin/paper-writing/templates/nsdi2027/references.bib +151 -0
  333. package/lib/skills/builtin/paper-writing/templates/nsdi2027/usenix-2020-09.sty +83 -0
  334. package/lib/skills/builtin/paper-writing/templates/osdi2026/main.tex +429 -0
  335. package/lib/skills/builtin/paper-writing/templates/osdi2026/references.bib +150 -0
  336. package/lib/skills/builtin/paper-writing/templates/osdi2026/usenix-2020-09.sty +83 -0
  337. package/lib/skills/builtin/paper-writing/templates/sosp2026/main.tex +532 -0
  338. package/lib/skills/builtin/paper-writing/templates/sosp2026/references.bib +148 -0
  339. package/lib/skills/builtin/research-grants/SKILL.md +958 -0
  340. package/lib/skills/builtin/research-grants/assets/budget_justification_template.md +453 -0
  341. package/lib/skills/builtin/research-grants/assets/nih_specific_aims_template.md +166 -0
  342. package/lib/skills/builtin/research-grants/assets/nsf_project_summary_template.md +92 -0
  343. package/lib/skills/builtin/research-grants/references/README.md +285 -0
  344. package/lib/skills/builtin/research-grants/references/broader_impacts.md +392 -0
  345. package/lib/skills/builtin/research-grants/references/darpa_guidelines.md +636 -0
  346. package/lib/skills/builtin/research-grants/references/doe_guidelines.md +586 -0
  347. package/lib/skills/builtin/research-grants/references/nih_guidelines.md +851 -0
  348. package/lib/skills/builtin/research-grants/references/nsf_guidelines.md +570 -0
  349. package/lib/skills/builtin/research-grants/references/nstc_guidelines.md +733 -0
  350. package/lib/skills/builtin/research-grants/references/specific_aims_guide.md +458 -0
  351. package/lib/skills/builtin/rewrite-humanize/SKILL.md +116 -0
  352. package/lib/skills/builtin/rewrite-humanize/references/cs-venue-tone.md +57 -0
  353. package/lib/skills/builtin/rewrite-humanize/references/lexicon.md +50 -0
  354. package/lib/skills/builtin/scholar-evaluation/SKILL.md +300 -0
  355. package/lib/skills/builtin/scholar-evaluation/references/evaluation_framework.md +663 -0
  356. package/lib/skills/builtin/scholar-evaluation/scripts/calculate_scores.py +379 -0
  357. package/lib/skills/builtin/scientific-schematics/SKILL.md +603 -0
  358. package/lib/skills/builtin/scientific-schematics/references/QUICK_REFERENCE.md +182 -0
  359. package/lib/skills/builtin/scientific-schematics/references/README.md +292 -0
  360. package/lib/skills/builtin/scientific-schematics/references/best_practices.md +560 -0
  361. package/lib/skills/builtin/scientific-schematics/scripts/__pycache__/generate_schematic.cpython-312.pyc +0 -0
  362. package/lib/skills/builtin/scientific-schematics/scripts/__pycache__/generate_schematic_ai.cpython-312.pyc +0 -0
  363. package/lib/skills/builtin/scientific-schematics/scripts/example_usage.sh +85 -0
  364. package/lib/skills/builtin/scientific-schematics/scripts/generate_schematic.py +141 -0
  365. package/lib/skills/builtin/scientific-schematics/scripts/generate_schematic_ai.py +910 -0
  366. package/lib/skills/builtin/scientific-visualization/SKILL.md +749 -0
  367. package/lib/skills/builtin/scientific-visualization/assets/color_palettes.py +197 -0
  368. package/lib/skills/builtin/scientific-visualization/assets/nature.mplstyle +63 -0
  369. package/lib/skills/builtin/scientific-visualization/assets/presentation.mplstyle +61 -0
  370. package/lib/skills/builtin/scientific-visualization/assets/publication.mplstyle +68 -0
  371. package/lib/skills/builtin/scientific-visualization/references/color_palettes.md +348 -0
  372. package/lib/skills/builtin/scientific-visualization/references/journal_requirements.md +320 -0
  373. package/lib/skills/builtin/scientific-visualization/references/matplotlib_examples.md +620 -0
  374. package/lib/skills/builtin/scientific-visualization/references/publication_guidelines.md +205 -0
  375. package/lib/skills/builtin/scientific-visualization/scripts/figure_export.py +343 -0
  376. package/lib/skills/builtin/scientific-visualization/scripts/style_presets.py +416 -0
  377. package/lib/skills/builtin/scientific-writing/SKILL.md +745 -0
  378. package/lib/skills/builtin/scientific-writing/assets/REPORT_FORMATTING_GUIDE.md +574 -0
  379. package/lib/skills/builtin/scientific-writing/assets/scientific_report.sty +606 -0
  380. package/lib/skills/builtin/scientific-writing/assets/scientific_report_template.tex +449 -0
  381. package/lib/skills/builtin/scientific-writing/references/citation_styles.md +720 -0
  382. package/lib/skills/builtin/scientific-writing/references/figures_tables.md +806 -0
  383. package/lib/skills/builtin/scientific-writing/references/imrad_structure.md +686 -0
  384. package/lib/skills/builtin/scientific-writing/references/professional_report_formatting.md +664 -0
  385. package/lib/skills/builtin/scientific-writing/references/reporting_guidelines.md +748 -0
  386. package/lib/skills/builtin/scientific-writing/references/writing_principles.md +824 -0
  387. package/lib/skills/builtin/seaborn/SKILL.md +674 -0
  388. package/lib/skills/builtin/seaborn/references/examples.md +822 -0
  389. package/lib/skills/builtin/seaborn/references/function_reference.md +770 -0
  390. package/lib/skills/builtin/seaborn/references/objects_interface.md +964 -0
  391. package/lib/skills/data-analysis/SKILL.md +285 -0
  392. package/lib/skills/generate-skill-content.mjs +58 -0
  393. package/lib/skills/index.ts +34 -0
  394. package/lib/skills/loader.ts +452 -0
  395. package/package.json +62 -0
@@ -0,0 +1,7 @@
1
+ import { U as Utils, Q as Color } from "./MilkdownMarkdownEditor-bLPxrCVb.js";
2
+ const channel = (color, channel2) => {
3
+ return Utils.lang.round(Color.parse(color)[channel2]);
4
+ };
5
+ export {
6
+ channel as c
7
+ };
@@ -0,0 +1,357 @@
1
+ import { s as styles, d as db, p as parser$1 } from "./styles-b4e223ce-BMr9TPuj.js";
2
+ import { r as getConfig, v as log$1, u as select, w as configureSvgSize, R as curveBasis, O as utils, aj as parseGenericTypes } from "./MilkdownMarkdownEditor-bLPxrCVb.js";
3
+ import { G as Graph } from "./graph-DpC13d95.js";
4
+ import { l as layout } from "./layout-ZeuHE_aY.js";
5
+ import { l as line } from "./line-CAgaGl-S.js";
6
+ import "./index-BqDyyRCx.js";
7
+ import "./array-DgktLKBx.js";
8
+ import "./path-Cp2qmpkd.js";
9
+ let edgeCount = 0;
10
+ const drawEdge = function(elem, path, relation, conf, diagObj) {
11
+ const getRelationType = function(type) {
12
+ switch (type) {
13
+ case diagObj.db.relationType.AGGREGATION:
14
+ return "aggregation";
15
+ case diagObj.db.relationType.EXTENSION:
16
+ return "extension";
17
+ case diagObj.db.relationType.COMPOSITION:
18
+ return "composition";
19
+ case diagObj.db.relationType.DEPENDENCY:
20
+ return "dependency";
21
+ case diagObj.db.relationType.LOLLIPOP:
22
+ return "lollipop";
23
+ }
24
+ };
25
+ path.points = path.points.filter((p) => !Number.isNaN(p.y));
26
+ const lineData = path.points;
27
+ const lineFunction = line().x(function(d) {
28
+ return d.x;
29
+ }).y(function(d) {
30
+ return d.y;
31
+ }).curve(curveBasis);
32
+ const svgPath = elem.append("path").attr("d", lineFunction(lineData)).attr("id", "edge" + edgeCount).attr("class", "relation");
33
+ let url = "";
34
+ if (conf.arrowMarkerAbsolute) {
35
+ url = window.location.protocol + "//" + window.location.host + window.location.pathname + window.location.search;
36
+ url = url.replace(/\(/g, "\\(");
37
+ url = url.replace(/\)/g, "\\)");
38
+ }
39
+ if (relation.relation.lineType == 1) {
40
+ svgPath.attr("class", "relation dashed-line");
41
+ }
42
+ if (relation.relation.lineType == 10) {
43
+ svgPath.attr("class", "relation dotted-line");
44
+ }
45
+ if (relation.relation.type1 !== "none") {
46
+ svgPath.attr(
47
+ "marker-start",
48
+ "url(" + url + "#" + getRelationType(relation.relation.type1) + "Start)"
49
+ );
50
+ }
51
+ if (relation.relation.type2 !== "none") {
52
+ svgPath.attr(
53
+ "marker-end",
54
+ "url(" + url + "#" + getRelationType(relation.relation.type2) + "End)"
55
+ );
56
+ }
57
+ let x, y;
58
+ const l = path.points.length;
59
+ let labelPosition = utils.calcLabelPosition(path.points);
60
+ x = labelPosition.x;
61
+ y = labelPosition.y;
62
+ let p1_card_x, p1_card_y;
63
+ let p2_card_x, p2_card_y;
64
+ if (l % 2 !== 0 && l > 1) {
65
+ let cardinality_1_point = utils.calcCardinalityPosition(
66
+ relation.relation.type1 !== "none",
67
+ path.points,
68
+ path.points[0]
69
+ );
70
+ let cardinality_2_point = utils.calcCardinalityPosition(
71
+ relation.relation.type2 !== "none",
72
+ path.points,
73
+ path.points[l - 1]
74
+ );
75
+ log$1.debug("cardinality_1_point " + JSON.stringify(cardinality_1_point));
76
+ log$1.debug("cardinality_2_point " + JSON.stringify(cardinality_2_point));
77
+ p1_card_x = cardinality_1_point.x;
78
+ p1_card_y = cardinality_1_point.y;
79
+ p2_card_x = cardinality_2_point.x;
80
+ p2_card_y = cardinality_2_point.y;
81
+ }
82
+ if (relation.title !== void 0) {
83
+ const g = elem.append("g").attr("class", "classLabel");
84
+ const label = g.append("text").attr("class", "label").attr("x", x).attr("y", y).attr("fill", "red").attr("text-anchor", "middle").text(relation.title);
85
+ window.label = label;
86
+ const bounds = label.node().getBBox();
87
+ g.insert("rect", ":first-child").attr("class", "box").attr("x", bounds.x - conf.padding / 2).attr("y", bounds.y - conf.padding / 2).attr("width", bounds.width + conf.padding).attr("height", bounds.height + conf.padding);
88
+ }
89
+ log$1.info("Rendering relation " + JSON.stringify(relation));
90
+ if (relation.relationTitle1 !== void 0 && relation.relationTitle1 !== "none") {
91
+ const g = elem.append("g").attr("class", "cardinality");
92
+ g.append("text").attr("class", "type1").attr("x", p1_card_x).attr("y", p1_card_y).attr("fill", "black").attr("font-size", "6").text(relation.relationTitle1);
93
+ }
94
+ if (relation.relationTitle2 !== void 0 && relation.relationTitle2 !== "none") {
95
+ const g = elem.append("g").attr("class", "cardinality");
96
+ g.append("text").attr("class", "type2").attr("x", p2_card_x).attr("y", p2_card_y).attr("fill", "black").attr("font-size", "6").text(relation.relationTitle2);
97
+ }
98
+ edgeCount++;
99
+ };
100
+ const drawClass = function(elem, classDef, conf, diagObj) {
101
+ log$1.debug("Rendering class ", classDef, conf);
102
+ const id = classDef.id;
103
+ const classInfo = {
104
+ id,
105
+ label: classDef.id,
106
+ width: 0,
107
+ height: 0
108
+ };
109
+ const g = elem.append("g").attr("id", diagObj.db.lookUpDomId(id)).attr("class", "classGroup");
110
+ let title;
111
+ if (classDef.link) {
112
+ title = g.append("svg:a").attr("xlink:href", classDef.link).attr("target", classDef.linkTarget).append("text").attr("y", conf.textHeight + conf.padding).attr("x", 0);
113
+ } else {
114
+ title = g.append("text").attr("y", conf.textHeight + conf.padding).attr("x", 0);
115
+ }
116
+ let isFirst = true;
117
+ classDef.annotations.forEach(function(member) {
118
+ const titleText2 = title.append("tspan").text("«" + member + "»");
119
+ if (!isFirst) {
120
+ titleText2.attr("dy", conf.textHeight);
121
+ }
122
+ isFirst = false;
123
+ });
124
+ let classTitleString = getClassTitleString(classDef);
125
+ const classTitle = title.append("tspan").text(classTitleString).attr("class", "title");
126
+ if (!isFirst) {
127
+ classTitle.attr("dy", conf.textHeight);
128
+ }
129
+ const titleHeight = title.node().getBBox().height;
130
+ let membersLine;
131
+ let membersBox;
132
+ let methodsLine;
133
+ if (classDef.members.length > 0) {
134
+ membersLine = g.append("line").attr("x1", 0).attr("y1", conf.padding + titleHeight + conf.dividerMargin / 2).attr("y2", conf.padding + titleHeight + conf.dividerMargin / 2);
135
+ const members = g.append("text").attr("x", conf.padding).attr("y", titleHeight + conf.dividerMargin + conf.textHeight).attr("fill", "white").attr("class", "classText");
136
+ isFirst = true;
137
+ classDef.members.forEach(function(member) {
138
+ addTspan(members, member, isFirst, conf);
139
+ isFirst = false;
140
+ });
141
+ membersBox = members.node().getBBox();
142
+ }
143
+ if (classDef.methods.length > 0) {
144
+ methodsLine = g.append("line").attr("x1", 0).attr("y1", conf.padding + titleHeight + conf.dividerMargin + membersBox.height).attr("y2", conf.padding + titleHeight + conf.dividerMargin + membersBox.height);
145
+ const methods = g.append("text").attr("x", conf.padding).attr("y", titleHeight + 2 * conf.dividerMargin + membersBox.height + conf.textHeight).attr("fill", "white").attr("class", "classText");
146
+ isFirst = true;
147
+ classDef.methods.forEach(function(method) {
148
+ addTspan(methods, method, isFirst, conf);
149
+ isFirst = false;
150
+ });
151
+ }
152
+ const classBox = g.node().getBBox();
153
+ var cssClassStr = " ";
154
+ if (classDef.cssClasses.length > 0) {
155
+ cssClassStr = cssClassStr + classDef.cssClasses.join(" ");
156
+ }
157
+ const rect = g.insert("rect", ":first-child").attr("x", 0).attr("y", 0).attr("width", classBox.width + 2 * conf.padding).attr("height", classBox.height + conf.padding + 0.5 * conf.dividerMargin).attr("class", cssClassStr);
158
+ const rectWidth = rect.node().getBBox().width;
159
+ title.node().childNodes.forEach(function(x) {
160
+ x.setAttribute("x", (rectWidth - x.getBBox().width) / 2);
161
+ });
162
+ if (classDef.tooltip) {
163
+ title.insert("title").text(classDef.tooltip);
164
+ }
165
+ if (membersLine) {
166
+ membersLine.attr("x2", rectWidth);
167
+ }
168
+ if (methodsLine) {
169
+ methodsLine.attr("x2", rectWidth);
170
+ }
171
+ classInfo.width = rectWidth;
172
+ classInfo.height = classBox.height + conf.padding + 0.5 * conf.dividerMargin;
173
+ return classInfo;
174
+ };
175
+ const getClassTitleString = function(classDef) {
176
+ let classTitleString = classDef.id;
177
+ if (classDef.type) {
178
+ classTitleString += "<" + parseGenericTypes(classDef.type) + ">";
179
+ }
180
+ return classTitleString;
181
+ };
182
+ const drawNote = function(elem, note, conf, diagObj) {
183
+ log$1.debug("Rendering note ", note, conf);
184
+ const id = note.id;
185
+ const noteInfo = {
186
+ id,
187
+ text: note.text,
188
+ width: 0,
189
+ height: 0
190
+ };
191
+ const g = elem.append("g").attr("id", id).attr("class", "classGroup");
192
+ let text = g.append("text").attr("y", conf.textHeight + conf.padding).attr("x", 0);
193
+ const lines = JSON.parse(`"${note.text}"`).split("\n");
194
+ lines.forEach(function(line2) {
195
+ log$1.debug(`Adding line: ${line2}`);
196
+ text.append("tspan").text(line2).attr("class", "title").attr("dy", conf.textHeight);
197
+ });
198
+ const noteBox = g.node().getBBox();
199
+ const rect = g.insert("rect", ":first-child").attr("x", 0).attr("y", 0).attr("width", noteBox.width + 2 * conf.padding).attr(
200
+ "height",
201
+ noteBox.height + lines.length * conf.textHeight + conf.padding + 0.5 * conf.dividerMargin
202
+ );
203
+ const rectWidth = rect.node().getBBox().width;
204
+ text.node().childNodes.forEach(function(x) {
205
+ x.setAttribute("x", (rectWidth - x.getBBox().width) / 2);
206
+ });
207
+ noteInfo.width = rectWidth;
208
+ noteInfo.height = noteBox.height + lines.length * conf.textHeight + conf.padding + 0.5 * conf.dividerMargin;
209
+ return noteInfo;
210
+ };
211
+ const addTspan = function(textEl, member, isFirst, conf) {
212
+ const { displayText, cssStyle } = member.getDisplayDetails();
213
+ const tSpan = textEl.append("tspan").attr("x", conf.padding).text(displayText);
214
+ if (cssStyle !== "") {
215
+ tSpan.attr("style", member.cssStyle);
216
+ }
217
+ if (!isFirst) {
218
+ tSpan.attr("dy", conf.textHeight);
219
+ }
220
+ };
221
+ const svgDraw = {
222
+ getClassTitleString,
223
+ drawClass,
224
+ drawEdge,
225
+ drawNote
226
+ };
227
+ let idCache = {};
228
+ const padding = 20;
229
+ const getGraphId = function(label) {
230
+ const foundEntry = Object.entries(idCache).find((entry) => entry[1].label === label);
231
+ if (foundEntry) {
232
+ return foundEntry[0];
233
+ }
234
+ };
235
+ const insertMarkers = function(elem) {
236
+ elem.append("defs").append("marker").attr("id", "extensionStart").attr("class", "extension").attr("refX", 0).attr("refY", 7).attr("markerWidth", 190).attr("markerHeight", 240).attr("orient", "auto").append("path").attr("d", "M 1,7 L18,13 V 1 Z");
237
+ elem.append("defs").append("marker").attr("id", "extensionEnd").attr("refX", 19).attr("refY", 7).attr("markerWidth", 20).attr("markerHeight", 28).attr("orient", "auto").append("path").attr("d", "M 1,1 V 13 L18,7 Z");
238
+ elem.append("defs").append("marker").attr("id", "compositionStart").attr("class", "extension").attr("refX", 0).attr("refY", 7).attr("markerWidth", 190).attr("markerHeight", 240).attr("orient", "auto").append("path").attr("d", "M 18,7 L9,13 L1,7 L9,1 Z");
239
+ elem.append("defs").append("marker").attr("id", "compositionEnd").attr("refX", 19).attr("refY", 7).attr("markerWidth", 20).attr("markerHeight", 28).attr("orient", "auto").append("path").attr("d", "M 18,7 L9,13 L1,7 L9,1 Z");
240
+ elem.append("defs").append("marker").attr("id", "aggregationStart").attr("class", "extension").attr("refX", 0).attr("refY", 7).attr("markerWidth", 190).attr("markerHeight", 240).attr("orient", "auto").append("path").attr("d", "M 18,7 L9,13 L1,7 L9,1 Z");
241
+ elem.append("defs").append("marker").attr("id", "aggregationEnd").attr("refX", 19).attr("refY", 7).attr("markerWidth", 20).attr("markerHeight", 28).attr("orient", "auto").append("path").attr("d", "M 18,7 L9,13 L1,7 L9,1 Z");
242
+ elem.append("defs").append("marker").attr("id", "dependencyStart").attr("class", "extension").attr("refX", 0).attr("refY", 7).attr("markerWidth", 190).attr("markerHeight", 240).attr("orient", "auto").append("path").attr("d", "M 5,7 L9,13 L1,7 L9,1 Z");
243
+ elem.append("defs").append("marker").attr("id", "dependencyEnd").attr("refX", 19).attr("refY", 7).attr("markerWidth", 20).attr("markerHeight", 28).attr("orient", "auto").append("path").attr("d", "M 18,7 L9,13 L14,7 L9,1 Z");
244
+ };
245
+ const draw = function(text, id, _version, diagObj) {
246
+ const conf = getConfig().class;
247
+ idCache = {};
248
+ log$1.info("Rendering diagram " + text);
249
+ const securityLevel = getConfig().securityLevel;
250
+ let sandboxElement;
251
+ if (securityLevel === "sandbox") {
252
+ sandboxElement = select("#i" + id);
253
+ }
254
+ const root = securityLevel === "sandbox" ? select(sandboxElement.nodes()[0].contentDocument.body) : select("body");
255
+ const diagram2 = root.select(`[id='${id}']`);
256
+ insertMarkers(diagram2);
257
+ const g = new Graph({
258
+ multigraph: true
259
+ });
260
+ g.setGraph({
261
+ isMultiGraph: true
262
+ });
263
+ g.setDefaultEdgeLabel(function() {
264
+ return {};
265
+ });
266
+ const classes = diagObj.db.getClasses();
267
+ const keys = Object.keys(classes);
268
+ for (const key of keys) {
269
+ const classDef = classes[key];
270
+ const node = svgDraw.drawClass(diagram2, classDef, conf, diagObj);
271
+ idCache[node.id] = node;
272
+ g.setNode(node.id, node);
273
+ log$1.info("Org height: " + node.height);
274
+ }
275
+ const relations = diagObj.db.getRelations();
276
+ relations.forEach(function(relation) {
277
+ log$1.info(
278
+ // cspell:ignore tjoho
279
+ "tjoho" + getGraphId(relation.id1) + getGraphId(relation.id2) + JSON.stringify(relation)
280
+ );
281
+ g.setEdge(
282
+ getGraphId(relation.id1),
283
+ getGraphId(relation.id2),
284
+ {
285
+ relation
286
+ },
287
+ relation.title || "DEFAULT"
288
+ );
289
+ });
290
+ const notes = diagObj.db.getNotes();
291
+ notes.forEach(function(note) {
292
+ log$1.debug(`Adding note: ${JSON.stringify(note)}`);
293
+ const node = svgDraw.drawNote(diagram2, note, conf, diagObj);
294
+ idCache[node.id] = node;
295
+ g.setNode(node.id, node);
296
+ if (note.class && note.class in classes) {
297
+ g.setEdge(
298
+ note.id,
299
+ getGraphId(note.class),
300
+ {
301
+ relation: {
302
+ id1: note.id,
303
+ id2: note.class,
304
+ relation: {
305
+ type1: "none",
306
+ type2: "none",
307
+ lineType: 10
308
+ }
309
+ }
310
+ },
311
+ "DEFAULT"
312
+ );
313
+ }
314
+ });
315
+ layout(g);
316
+ g.nodes().forEach(function(v) {
317
+ if (v !== void 0 && g.node(v) !== void 0) {
318
+ log$1.debug("Node " + v + ": " + JSON.stringify(g.node(v)));
319
+ root.select("#" + (diagObj.db.lookUpDomId(v) || v)).attr(
320
+ "transform",
321
+ "translate(" + (g.node(v).x - g.node(v).width / 2) + "," + (g.node(v).y - g.node(v).height / 2) + " )"
322
+ );
323
+ }
324
+ });
325
+ g.edges().forEach(function(e) {
326
+ if (e !== void 0 && g.edge(e) !== void 0) {
327
+ log$1.debug("Edge " + e.v + " -> " + e.w + ": " + JSON.stringify(g.edge(e)));
328
+ svgDraw.drawEdge(diagram2, g.edge(e), g.edge(e).relation, conf, diagObj);
329
+ }
330
+ });
331
+ const svgBounds = diagram2.node().getBBox();
332
+ const width = svgBounds.width + padding * 2;
333
+ const height = svgBounds.height + padding * 2;
334
+ configureSvgSize(diagram2, height, width, conf.useMaxWidth);
335
+ const vBox = `${svgBounds.x - padding} ${svgBounds.y - padding} ${width} ${height}`;
336
+ log$1.debug(`viewBox ${vBox}`);
337
+ diagram2.attr("viewBox", vBox);
338
+ };
339
+ const renderer = {
340
+ draw
341
+ };
342
+ const diagram = {
343
+ parser: parser$1,
344
+ db,
345
+ renderer,
346
+ styles,
347
+ init: (cnf) => {
348
+ if (!cnf.class) {
349
+ cnf.class = {};
350
+ }
351
+ cnf.class.arrowMarkerAbsolute = cnf.arrowMarkerAbsolute;
352
+ db.clear();
353
+ }
354
+ };
355
+ export {
356
+ diagram
357
+ };
@@ -0,0 +1,291 @@
1
+ import { s as styles, d as db, p as parser$1 } from "./styles-b4e223ce-BMr9TPuj.js";
2
+ import { v as log$1, r as getConfig, u as select, O as utils, ak as setupGraphViewbox$1, al as getStylesFromArray, am as interpolateToCurve, an as curveLinear, C as common$1 } from "./MilkdownMarkdownEditor-bLPxrCVb.js";
3
+ import { G as Graph } from "./graph-DpC13d95.js";
4
+ import { r as render } from "./index-5325376f-Bbs7Fbqr.js";
5
+ import "./layout-ZeuHE_aY.js";
6
+ import "./index-BqDyyRCx.js";
7
+ import "./clone-CsnzsYXQ.js";
8
+ import "./edges-96097737-CD0EvAZQ.js";
9
+ import "./createText-1719965b-Cji7KN4K.js";
10
+ import "./line-CAgaGl-S.js";
11
+ import "./array-DgktLKBx.js";
12
+ import "./path-Cp2qmpkd.js";
13
+ const sanitizeText = (txt) => common$1.sanitizeText(txt, getConfig());
14
+ let conf = {
15
+ dividerMargin: 10,
16
+ padding: 5,
17
+ textHeight: 10,
18
+ curve: void 0
19
+ };
20
+ const addNamespaces = function(namespaces, g, _id, diagObj) {
21
+ const keys = Object.keys(namespaces);
22
+ log$1.info("keys:", keys);
23
+ log$1.info(namespaces);
24
+ keys.forEach(function(id) {
25
+ var _a, _b;
26
+ const vertex = namespaces[id];
27
+ const shape = "rect";
28
+ const node = {
29
+ shape,
30
+ id: vertex.id,
31
+ domId: vertex.domId,
32
+ labelText: sanitizeText(vertex.id),
33
+ labelStyle: "",
34
+ style: "fill: none; stroke: black",
35
+ // TODO V10: Flowchart ? Keeping flowchart for backwards compatibility. Remove in next major release
36
+ padding: ((_a = getConfig().flowchart) == null ? void 0 : _a.padding) ?? ((_b = getConfig().class) == null ? void 0 : _b.padding)
37
+ };
38
+ g.setNode(vertex.id, node);
39
+ addClasses(vertex.classes, g, _id, diagObj, vertex.id);
40
+ log$1.info("setNode", node);
41
+ });
42
+ };
43
+ const addClasses = function(classes, g, _id, diagObj, parent) {
44
+ const keys = Object.keys(classes);
45
+ log$1.info("keys:", keys);
46
+ log$1.info(classes);
47
+ keys.filter((id) => classes[id].parent == parent).forEach(function(id) {
48
+ var _a, _b;
49
+ const vertex = classes[id];
50
+ const cssClassStr = vertex.cssClasses.join(" ");
51
+ const styles2 = getStylesFromArray(vertex.styles);
52
+ const vertexText = vertex.label ?? vertex.id;
53
+ const radius = 0;
54
+ const shape = "class_box";
55
+ const node = {
56
+ labelStyle: styles2.labelStyle,
57
+ shape,
58
+ labelText: sanitizeText(vertexText),
59
+ classData: vertex,
60
+ rx: radius,
61
+ ry: radius,
62
+ class: cssClassStr,
63
+ style: styles2.style,
64
+ id: vertex.id,
65
+ domId: vertex.domId,
66
+ tooltip: diagObj.db.getTooltip(vertex.id, parent) || "",
67
+ haveCallback: vertex.haveCallback,
68
+ link: vertex.link,
69
+ width: vertex.type === "group" ? 500 : void 0,
70
+ type: vertex.type,
71
+ // TODO V10: Flowchart ? Keeping flowchart for backwards compatibility. Remove in next major release
72
+ padding: ((_a = getConfig().flowchart) == null ? void 0 : _a.padding) ?? ((_b = getConfig().class) == null ? void 0 : _b.padding)
73
+ };
74
+ g.setNode(vertex.id, node);
75
+ if (parent) {
76
+ g.setParent(vertex.id, parent);
77
+ }
78
+ log$1.info("setNode", node);
79
+ });
80
+ };
81
+ const addNotes = function(notes, g, startEdgeId, classes) {
82
+ log$1.info(notes);
83
+ notes.forEach(function(note, i) {
84
+ var _a, _b;
85
+ const vertex = note;
86
+ const cssNoteStr = "";
87
+ const styles2 = { labelStyle: "", style: "" };
88
+ const vertexText = vertex.text;
89
+ const radius = 0;
90
+ const shape = "note";
91
+ const node = {
92
+ labelStyle: styles2.labelStyle,
93
+ shape,
94
+ labelText: sanitizeText(vertexText),
95
+ noteData: vertex,
96
+ rx: radius,
97
+ ry: radius,
98
+ class: cssNoteStr,
99
+ style: styles2.style,
100
+ id: vertex.id,
101
+ domId: vertex.id,
102
+ tooltip: "",
103
+ type: "note",
104
+ // TODO V10: Flowchart ? Keeping flowchart for backwards compatibility. Remove in next major release
105
+ padding: ((_a = getConfig().flowchart) == null ? void 0 : _a.padding) ?? ((_b = getConfig().class) == null ? void 0 : _b.padding)
106
+ };
107
+ g.setNode(vertex.id, node);
108
+ log$1.info("setNode", node);
109
+ if (!vertex.class || !(vertex.class in classes)) {
110
+ return;
111
+ }
112
+ const edgeId = startEdgeId + i;
113
+ const edgeData = {
114
+ id: `edgeNote${edgeId}`,
115
+ //Set relationship style and line type
116
+ classes: "relation",
117
+ pattern: "dotted",
118
+ // Set link type for rendering
119
+ arrowhead: "none",
120
+ //Set edge extra labels
121
+ startLabelRight: "",
122
+ endLabelLeft: "",
123
+ //Set relation arrow types
124
+ arrowTypeStart: "none",
125
+ arrowTypeEnd: "none",
126
+ style: "fill:none",
127
+ labelStyle: "",
128
+ curve: interpolateToCurve(conf.curve, curveLinear)
129
+ };
130
+ g.setEdge(vertex.id, vertex.class, edgeData, edgeId);
131
+ });
132
+ };
133
+ const addRelations = function(relations, g) {
134
+ const conf2 = getConfig().flowchart;
135
+ let cnt = 0;
136
+ relations.forEach(function(edge) {
137
+ var _a;
138
+ cnt++;
139
+ const edgeData = {
140
+ //Set relationship style and line type
141
+ classes: "relation",
142
+ pattern: edge.relation.lineType == 1 ? "dashed" : "solid",
143
+ id: `id_${edge.id1}_${edge.id2}_${cnt}`,
144
+ // Set link type for rendering
145
+ arrowhead: edge.type === "arrow_open" ? "none" : "normal",
146
+ //Set edge extra labels
147
+ startLabelRight: edge.relationTitle1 === "none" ? "" : edge.relationTitle1,
148
+ endLabelLeft: edge.relationTitle2 === "none" ? "" : edge.relationTitle2,
149
+ //Set relation arrow types
150
+ arrowTypeStart: getArrowMarker(edge.relation.type1),
151
+ arrowTypeEnd: getArrowMarker(edge.relation.type2),
152
+ style: "fill:none",
153
+ labelStyle: "",
154
+ curve: interpolateToCurve(conf2 == null ? void 0 : conf2.curve, curveLinear)
155
+ };
156
+ log$1.info(edgeData, edge);
157
+ if (edge.style !== void 0) {
158
+ const styles2 = getStylesFromArray(edge.style);
159
+ edgeData.style = styles2.style;
160
+ edgeData.labelStyle = styles2.labelStyle;
161
+ }
162
+ edge.text = edge.title;
163
+ if (edge.text === void 0) {
164
+ if (edge.style !== void 0) {
165
+ edgeData.arrowheadStyle = "fill: #333";
166
+ }
167
+ } else {
168
+ edgeData.arrowheadStyle = "fill: #333";
169
+ edgeData.labelpos = "c";
170
+ if (((_a = getConfig().flowchart) == null ? void 0 : _a.htmlLabels) ?? getConfig().htmlLabels) {
171
+ edgeData.labelType = "html";
172
+ edgeData.label = '<span class="edgeLabel">' + edge.text + "</span>";
173
+ } else {
174
+ edgeData.labelType = "text";
175
+ edgeData.label = edge.text.replace(common$1.lineBreakRegex, "\n");
176
+ if (edge.style === void 0) {
177
+ edgeData.style = edgeData.style || "stroke: #333; stroke-width: 1.5px;fill:none";
178
+ }
179
+ edgeData.labelStyle = edgeData.labelStyle.replace("color:", "fill:");
180
+ }
181
+ }
182
+ g.setEdge(edge.id1, edge.id2, edgeData, cnt);
183
+ });
184
+ };
185
+ const setConf = function(cnf) {
186
+ conf = {
187
+ ...conf,
188
+ ...cnf
189
+ };
190
+ };
191
+ const draw = async function(text, id, _version, diagObj) {
192
+ log$1.info("Drawing class - ", id);
193
+ const conf2 = getConfig().flowchart ?? getConfig().class;
194
+ const securityLevel = getConfig().securityLevel;
195
+ log$1.info("config:", conf2);
196
+ const nodeSpacing = (conf2 == null ? void 0 : conf2.nodeSpacing) ?? 50;
197
+ const rankSpacing = (conf2 == null ? void 0 : conf2.rankSpacing) ?? 50;
198
+ const g = new Graph({
199
+ multigraph: true,
200
+ compound: true
201
+ }).setGraph({
202
+ rankdir: diagObj.db.getDirection(),
203
+ nodesep: nodeSpacing,
204
+ ranksep: rankSpacing,
205
+ marginx: 8,
206
+ marginy: 8
207
+ }).setDefaultEdgeLabel(function() {
208
+ return {};
209
+ });
210
+ const namespaces = diagObj.db.getNamespaces();
211
+ const classes = diagObj.db.getClasses();
212
+ const relations = diagObj.db.getRelations();
213
+ const notes = diagObj.db.getNotes();
214
+ log$1.info(relations);
215
+ addNamespaces(namespaces, g, id, diagObj);
216
+ addClasses(classes, g, id, diagObj);
217
+ addRelations(relations, g);
218
+ addNotes(notes, g, relations.length + 1, classes);
219
+ let sandboxElement;
220
+ if (securityLevel === "sandbox") {
221
+ sandboxElement = select("#i" + id);
222
+ }
223
+ const root = securityLevel === "sandbox" ? select(sandboxElement.nodes()[0].contentDocument.body) : select("body");
224
+ const svg = root.select(`[id="${id}"]`);
225
+ const element = root.select("#" + id + " g");
226
+ await render(
227
+ element,
228
+ g,
229
+ ["aggregation", "extension", "composition", "dependency", "lollipop"],
230
+ "classDiagram",
231
+ id
232
+ );
233
+ utils.insertTitle(svg, "classTitleText", (conf2 == null ? void 0 : conf2.titleTopMargin) ?? 5, diagObj.db.getDiagramTitle());
234
+ setupGraphViewbox$1(g, svg, conf2 == null ? void 0 : conf2.diagramPadding, conf2 == null ? void 0 : conf2.useMaxWidth);
235
+ if (!(conf2 == null ? void 0 : conf2.htmlLabels)) {
236
+ const doc = securityLevel === "sandbox" ? sandboxElement.nodes()[0].contentDocument : document;
237
+ const labels = doc.querySelectorAll('[id="' + id + '"] .edgeLabel .label');
238
+ for (const label of labels) {
239
+ const dim = label.getBBox();
240
+ const rect = doc.createElementNS("http://www.w3.org/2000/svg", "rect");
241
+ rect.setAttribute("rx", 0);
242
+ rect.setAttribute("ry", 0);
243
+ rect.setAttribute("width", dim.width);
244
+ rect.setAttribute("height", dim.height);
245
+ label.insertBefore(rect, label.firstChild);
246
+ }
247
+ }
248
+ };
249
+ function getArrowMarker(type) {
250
+ let marker;
251
+ switch (type) {
252
+ case 0:
253
+ marker = "aggregation";
254
+ break;
255
+ case 1:
256
+ marker = "extension";
257
+ break;
258
+ case 2:
259
+ marker = "composition";
260
+ break;
261
+ case 3:
262
+ marker = "dependency";
263
+ break;
264
+ case 4:
265
+ marker = "lollipop";
266
+ break;
267
+ default:
268
+ marker = "none";
269
+ }
270
+ return marker;
271
+ }
272
+ const renderer = {
273
+ setConf,
274
+ draw
275
+ };
276
+ const diagram = {
277
+ parser: parser$1,
278
+ db,
279
+ renderer,
280
+ styles,
281
+ init: (cnf) => {
282
+ if (!cnf.class) {
283
+ cnf.class = {};
284
+ }
285
+ cnf.class.arrowMarkerAbsolute = cnf.arrowMarkerAbsolute;
286
+ db.clear();
287
+ }
288
+ };
289
+ export {
290
+ diagram
291
+ };