@markusylisiurunen/tau 0.3.80 → 0.3.82
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.
- package/dist/code_mode/command.js +4 -16
- package/dist/code_mode/command.js.map +1 -1
- package/dist/code_mode/images.js +5 -6
- package/dist/code_mode/images.js.map +1 -1
- package/dist/code_mode/index.d.ts +1 -3
- package/dist/code_mode/index.js +1 -2
- package/dist/code_mode/index.js.map +1 -1
- package/dist/code_mode/runtime.d.ts +8 -4
- package/dist/code_mode/runtime.js +52 -63
- package/dist/code_mode/runtime.js.map +1 -1
- package/dist/core/code_mode/bash.js +269 -0
- package/dist/core/code_mode/bash.js.map +1 -0
- package/dist/core/code_mode/capability.js +2 -0
- package/dist/core/code_mode/capability.js.map +1 -0
- package/dist/core/code_mode/history.js +62 -0
- package/dist/core/code_mode/history.js.map +1 -0
- package/dist/core/code_mode/mcp.js +121 -0
- package/dist/core/code_mode/mcp.js.map +1 -0
- package/dist/core/code_mode/models.js +256 -0
- package/dist/core/code_mode/models.js.map +1 -0
- package/dist/core/{tools → code_mode}/nook.js +13 -77
- package/dist/core/code_mode/nook.js.map +1 -0
- package/dist/core/code_mode/sdk.js +97 -0
- package/dist/core/code_mode/sdk.js.map +1 -0
- package/dist/core/{tools → code_mode}/web.js +31 -90
- package/dist/core/code_mode/web.js.map +1 -0
- package/dist/core/commands/registry.js +0 -22
- package/dist/core/commands/registry.js.map +1 -1
- package/dist/core/config/content_loader.js +3 -1
- package/dist/core/config/content_loader.js.map +1 -1
- package/dist/core/debug.js +1 -1
- package/dist/core/debug.js.map +1 -1
- package/dist/core/index.js +1 -1
- package/dist/core/index.js.map +1 -1
- package/dist/core/models/openrouter.js +171 -0
- package/dist/core/models/openrouter.js.map +1 -0
- package/dist/core/{tool → models}/openrouter_decisions.js +6 -7
- package/dist/core/models/openrouter_decisions.js.map +1 -0
- package/dist/core/models/openrouter_media.js +128 -0
- package/dist/core/models/openrouter_media.js.map +1 -0
- package/dist/core/personas.js +2 -1
- package/dist/core/personas.js.map +1 -1
- package/dist/core/runtime/chat_runtime.js +2 -13
- package/dist/core/runtime/chat_runtime.js.map +1 -1
- package/dist/core/session/compaction.js +5 -3
- package/dist/core/session/compaction.js.map +1 -1
- package/dist/core/static/code_mode/history/documentation.md +95 -167
- package/dist/core/static/code_mode/mcp/documentation.md +144 -67
- package/dist/core/static/code_mode/nook/documentation.md +108 -169
- package/dist/core/static/code_mode/sandbox_runner.mjs +37 -20
- package/dist/core/static/code_mode/web/documentation.md +115 -213
- package/dist/core/static/tau_docs/client-tools.md +4 -4
- package/dist/core/static/tau_docs/history.md +2 -2
- package/dist/core/static/tau_docs/index.md +1 -1
- package/dist/core/static/tau_docs/node-sdk.md +6 -7
- package/dist/core/static/tau_docs/nook.md +2 -2
- package/dist/core/static/tau_docs/personas.md +2 -2
- package/dist/core/static/tau_docs/remote-sessions.md +2 -2
- package/dist/core/static/tau_docs/security.md +4 -4
- package/dist/core/static/tau_docs/session-protocol-methods.md +1 -46
- package/dist/core/static/tau_docs/session-protocol.md +11 -11
- package/dist/core/static/tau_docs/sessions.md +6 -25
- package/dist/core/static/tau_docs/subagents.md +3 -2
- package/dist/core/static/tau_docs/telegram.md +1 -1
- package/dist/core/static/tau_docs/tools.md +40 -48
- package/dist/core/static/tau_docs/troubleshooting.md +2 -2
- package/dist/core/static/tau_docs/tui.md +8 -7
- package/dist/core/subagents/registry.js +2 -1
- package/dist/core/subagents/registry.js.map +1 -1
- package/dist/core/subagents/types.js +2 -1
- package/dist/core/subagents/types.js.map +1 -1
- package/dist/core/telegram/adapter.js +1 -6
- package/dist/core/telegram/adapter.js.map +1 -1
- package/dist/core/tool/image_generate.js +2 -1
- package/dist/core/tool/image_generate.js.map +1 -1
- package/dist/core/tool/media.js +1 -49
- package/dist/core/tool/media.js.map +1 -1
- package/dist/core/tool/openrouter.js +24 -156
- package/dist/core/tool/openrouter.js.map +1 -1
- package/dist/core/tool/openrouter_input.js +77 -0
- package/dist/core/tool/openrouter_input.js.map +1 -0
- package/dist/core/tool/speech_generate.js +2 -1
- package/dist/core/tool/speech_generate.js.map +1 -1
- package/dist/core/tools/bash.js +2 -1
- package/dist/core/tools/bash.js.map +1 -1
- package/dist/core/tools/bash_jobs.js +34 -5
- package/dist/core/tools/bash_jobs.js.map +1 -1
- package/dist/core/tools/catalog.js +18 -44
- package/dist/core/tools/catalog.js.map +1 -1
- package/dist/core/tools/code.js +100 -0
- package/dist/core/tools/code.js.map +1 -0
- package/dist/core/tools/code_mode.js +9 -30
- package/dist/core/tools/code_mode.js.map +1 -1
- package/dist/core/tools/code_mode_worker.js +2 -2
- package/dist/core/tools/presentation.js +2 -1
- package/dist/core/tools/presentation.js.map +1 -1
- package/dist/core/tools/tool_names.js +5 -7
- package/dist/core/tools/tool_names.js.map +1 -1
- package/dist/core/utils/gemini_transcription.js +81 -37
- package/dist/core/utils/gemini_transcription.js.map +1 -1
- package/dist/core/utils/media_validation.js +50 -0
- package/dist/core/utils/media_validation.js.map +1 -0
- package/dist/core/utils/user_metadata.js +0 -14
- package/dist/core/utils/user_metadata.js.map +1 -1
- package/dist/core/version.js +2 -2
- package/dist/diff_tool/app/dist/assets/{angular-html-BbLgbIhq.js → angular-html-D20byCHL.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{angular-ts-DXk17TRM.js → angular-ts-CvVQslm2.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{apl-BsvksCXR.js → apl-DNIxlYWe.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{astro-DH775E4V.js → astro-DDOw4EUG.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{blade-Ck99Rm59.js → blade-DlhB-SLW.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{c-DJpHqu5J.js → c-C1f4vhDm.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{chapel-Owff0Csy.js → chapel-Ctt8xOX1.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{cobol-Cv2gZuhO.js → cobol-BXw71PAA.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{coffee-Bji0YCf_.js → coffee-CRh_5Nmr.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{cpp-DTjA_yFF.js → cpp-IlI-zWOZ.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{crystal-Dd00NOeb.js → crystal-CXeL28i7.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{css-D44TN1V6.js → css-BfST9hFI.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{edge-CVmGSi2m.js → edge--Q22k_ty.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{elixir-B8Mq7no2.js → elixir-CIfC_rQx.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{elm-CXS0I3Z2.js → elm-OkZ29XRO.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{erb-B9oDKaUo.js → erb-B8ZXgEqv.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{git-rebase-DT-YFebH.js → git-rebase-CxkO_WGd.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{glimmer-js-s0DXlNjq.js → glimmer-js-BVadyIrr.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{glimmer-ts-QgEB5S2z.js → glimmer-ts-D5J3Qb7n.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{glsl-NA0icwbY.js → glsl-B6iy73-Y.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{graphql-0_dOlfV0.js → graphql-Dc3rUXf5.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{hack-D-mr7l1l.js → hack-q8Utf8Jp.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{haml-B0-oQmz7.js → haml-mjMIlj_2.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{handlebars-Yq9bXpWN.js → handlebars-CA-BL8Ks.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{html-B8bMmdRK.js → html-BmPxhYCX.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{html-derivative-BpxSlQb_.js → html-derivative-CvknIjuB.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{http-hS_53mxt.js → http-DNxLDRIi.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{hurl-B2ST1kwl.js → hurl-kbd3Eq2V.js} +1 -1
- package/dist/diff_tool/app/dist/assets/index-D8ZI_2RC.js +340 -0
- package/dist/diff_tool/app/dist/assets/{java-D4mj0lZJ.js → java-BuZshgf1.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{javascript-wC7rrKiV.js → javascript-DfL2oeFU.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{jinja-DbQ3o87F.js → jinja-Bu0KQihU.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{jison-CrE9FdvP.js → jison-Bqn7Mf3Q.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{json-xjicDyWN.js → json-BuX5LKaB.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{jsx-m28lXojQ.js → jsx-DdVJ-ZBp.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{julia-19xkOmop.js → julia-CQeijOoQ.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{just-Cf7OorTr.js → just-vzAktFGR.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{latex-DDb7GQOy.js → latex-Dm60cg0k.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{liquid-DHOuQ0rf.js → liquid-vxKzm2P8.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{lua-BGyIvonw.js → lua-DIoqi4dd.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{marko-DB5OqI1C.js → marko-BTHgFKby.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{mdc-DTyNMupO.js → mdc-CEfz8gZ9.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{nginx-DfF0fMYD.js → nginx-DNlFDEfJ.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{nim-BbwsXuZD.js → nim-DnvT_0lZ.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{org-BkOBBl1f.js → org-BbD-ElVf.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{perl-BTXTOl4K.js → perl-DTsbnAmK.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{php-DIMVQWiA.js → php-CwEsJe-W.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{pug-B_nrb4dJ.js → pug-BOttMVH-.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{qml-1PXi8G8Z.js → qml-C8KkSItN.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{r-CJrAkc2Z.js → r-K4ksJj_R.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{razor-DgPUftNd.js → razor-yuWRrrG6.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{regexp-C2hS8XvL.js → regexp-CV-jhnUz.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{rst-CDouhKnc.js → rst-CLA3Attc.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{ruby-CAjKW1uO.js → ruby-DiHR2-DX.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{sas-qAHkHLc1.js → sas-DxIjbYJ5.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{scss-Bfx2Ydid.js → scss-CShwEaV4.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{shellscript-Bu76R8y2.js → shellscript-CeezOnrF.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{shellsession-BU8BL0oL.js → shellsession-CjSS2r7j.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{soy-FRl8ozP-.js → soy-CI_v23nJ.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{sql-BacQgsEs.js → sql-D9GaB00A.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{stata-B9kkG-ET.js → stata-hK92TPE_.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{surrealql-qvETr7iY.js → surrealql-UO8LtPJG.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{svelte-B0z1MgHc.js → svelte-kIlaw_oh.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{templ-DTnPshKb.js → templ-DFRz1JP6.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{tex-Cosab9_H.js → tex-CfxIXk_z.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{ts-tags-DNYvLFUH.js → ts-tags-BtUHl0ff.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{tsx-Dstq6j1a.js → tsx-Cd4SAe2C.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{twig-BzqZdwaX.js → twig-CWk4q5Y3.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{typescript-YOQ_oE25.js → typescript-BqxGJiP0.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{typst-DTffwfpc.js → typst-D9nAun2p.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{vue-D4OMj_C5.js → vue-D6HYhg6_.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{vue-html-kT4WrHGK.js → vue-html-1VRlaENS.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{vue-vine-CxeapeMO.js → vue-vine-BaH0We9y.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{xml-DWVpuurg.js → xml-C4RWnUuj.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{xsl-C0ciup5a.js → xsl-D1iD38ga.js} +1 -1
- package/dist/diff_tool/app/dist/assets/{yaml-98Fvyfpc.js → yaml-yAb4W0G-.js} +1 -1
- package/dist/diff_tool/app/dist/index.html +1 -1
- package/dist/host/local_session_host.js +24 -318
- package/dist/host/local_session_host.js.map +1 -1
- package/dist/host/session_host.js.map +1 -1
- package/dist/host/session_protocol_handler.js +0 -98
- package/dist/host/session_protocol_handler.js.map +1 -1
- package/dist/nook/README.md +1 -1
- package/dist/protocol/index.d.ts +1 -1
- package/dist/protocol/index.js.map +1 -1
- package/dist/protocol/session_protocol.d.ts +3 -28
- package/dist/protocol/session_protocol.js +1 -56
- package/dist/protocol/session_protocol.js.map +1 -1
- package/dist/sdk/code_mode.js +11 -17
- package/dist/sdk/code_mode.js.map +1 -1
- package/dist/sdk/index.d.ts +2 -2
- package/dist/sdk/index.js +1 -1
- package/dist/sdk/index.js.map +1 -1
- package/dist/sdk/session.js +0 -20
- package/dist/sdk/session.js.map +1 -1
- package/dist/sdk/types.d.ts +1 -7
- package/dist/store/session_snapshot_migrations.js +72 -1
- package/dist/store/session_snapshot_migrations.js.map +1 -1
- package/dist/tui/session_chat_controller.js +95 -82
- package/dist/tui/session_chat_controller.js.map +1 -1
- package/dist/tui/ui/footer.js +2 -5
- package/dist/tui/ui/footer.js.map +1 -1
- package/package.json +7 -7
- package/dist/code_mode/files.d.ts +0 -47
- package/dist/code_mode/files.js +0 -296
- package/dist/code_mode/files.js.map +0 -1
- package/dist/core/session/goal.js +0 -54
- package/dist/core/session/goal.js.map +0 -1
- package/dist/core/tool/openrouter_decisions.js.map +0 -1
- package/dist/core/tool/openrouter_media.js +0 -180
- package/dist/core/tool/openrouter_media.js.map +0 -1
- package/dist/core/tools/goal.js +0 -167
- package/dist/core/tools/goal.js.map +0 -1
- package/dist/core/tools/history.js +0 -118
- package/dist/core/tools/history.js.map +0 -1
- package/dist/core/tools/mcp.js +0 -167
- package/dist/core/tools/mcp.js.map +0 -1
- package/dist/core/tools/nook.js.map +0 -1
- package/dist/core/tools/web.js.map +0 -1
- package/dist/diff_tool/app/dist/assets/index-CBT_sNIz.js +0 -340
|
@@ -1 +1 @@
|
|
|
1
|
-
import{t as e}from"./index-
|
|
1
|
+
import{t as e}from"./index-D8ZI_2RC.js";import{t}from"./java-BuZshgf1.js";var n=e({default:()=>i}),r=Object.freeze(JSON.parse(`{"displayName":"XML","name":"xml","patterns":[{"begin":"(<\\\\?)\\\\s*([-0-9A-Z_a-z]+)","captures":{"1":{"name":"punctuation.definition.tag.xml"},"2":{"name":"entity.name.tag.xml"}},"end":"(\\\\?>)","name":"meta.tag.preprocessor.xml","patterns":[{"match":" ([-A-Za-z]+)","name":"entity.other.attribute-name.xml"},{"include":"#doublequotedString"},{"include":"#singlequotedString"}]},{"begin":"(<!)(DOCTYPE)\\\\s+([:A-Z_a-z][-.0-:A-Z_a-z]*)","captures":{"1":{"name":"punctuation.definition.tag.xml"},"2":{"name":"keyword.other.doctype.xml"},"3":{"name":"variable.language.documentroot.xml"}},"end":"\\\\s*(>)","name":"meta.tag.sgml.doctype.xml","patterns":[{"include":"#internalSubset"}]},{"include":"#comments"},{"begin":"(<)((?:([-0-9A-Z_a-z]+)(:))?([-0-:A-Z_a-z]+))(?=(\\\\s[^>]*)?></\\\\2>)","beginCaptures":{"1":{"name":"punctuation.definition.tag.xml"},"2":{"name":"entity.name.tag.xml"},"3":{"name":"entity.name.tag.namespace.xml"},"4":{"name":"punctuation.separator.namespace.xml"},"5":{"name":"entity.name.tag.localname.xml"}},"end":"(>)(</)((?:([-0-9A-Z_a-z]+)(:))?([-0-:A-Z_a-z]+))(>)","endCaptures":{"1":{"name":"punctuation.definition.tag.xml"},"2":{"name":"punctuation.definition.tag.xml"},"3":{"name":"entity.name.tag.xml"},"4":{"name":"entity.name.tag.namespace.xml"},"5":{"name":"punctuation.separator.namespace.xml"},"6":{"name":"entity.name.tag.localname.xml"},"7":{"name":"punctuation.definition.tag.xml"}},"name":"meta.tag.no-content.xml","patterns":[{"include":"#tagStuff"}]},{"begin":"(</?)(?:([-.\\\\w]+)((:)))?([-.:\\\\w]+)","captures":{"1":{"name":"punctuation.definition.tag.xml"},"2":{"name":"entity.name.tag.namespace.xml"},"3":{"name":"entity.name.tag.xml"},"4":{"name":"punctuation.separator.namespace.xml"},"5":{"name":"entity.name.tag.localname.xml"}},"end":"(/?>)","name":"meta.tag.xml","patterns":[{"include":"#tagStuff"}]},{"include":"#entity"},{"include":"#bare-ampersand"},{"begin":"<%@","beginCaptures":{"0":{"name":"punctuation.section.embedded.begin.xml"}},"end":"%>","endCaptures":{"0":{"name":"punctuation.section.embedded.end.xml"}},"name":"source.java-props.embedded.xml","patterns":[{"match":"page|include|taglib","name":"keyword.other.page-props.xml"}]},{"begin":"<%[!=]?(?!--)","beginCaptures":{"0":{"name":"punctuation.section.embedded.begin.xml"}},"end":"(?!--)%>","endCaptures":{"0":{"name":"punctuation.section.embedded.end.xml"}},"name":"source.java.embedded.xml","patterns":[{"include":"source.java"}]},{"begin":"<!\\\\[CDATA\\\\[","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.xml"}},"end":"]]>","endCaptures":{"0":{"name":"punctuation.definition.string.end.xml"}},"name":"string.unquoted.cdata.xml"}],"repository":{"EntityDecl":{"begin":"(<!)(ENTITY)\\\\s+(%\\\\s+)?([:A-Z_a-z][-.0-:A-Z_a-z]*)(\\\\s+(?:SYSTEM|PUBLIC)\\\\s+)?","captures":{"1":{"name":"punctuation.definition.tag.xml"},"2":{"name":"keyword.other.entity.xml"},"3":{"name":"punctuation.definition.entity.xml"},"4":{"name":"variable.language.entity.xml"},"5":{"name":"keyword.other.entitytype.xml"}},"end":"(>)","patterns":[{"include":"#doublequotedString"},{"include":"#singlequotedString"}]},"bare-ampersand":{"match":"&","name":"invalid.illegal.bad-ampersand.xml"},"comments":{"patterns":[{"begin":"<%--","captures":{"0":{"name":"punctuation.definition.comment.xml"},"end":"--%>","name":"comment.block.xml"}},{"begin":"<!--","captures":{"0":{"name":"punctuation.definition.comment.xml"}},"end":"-->","name":"comment.block.xml","patterns":[{"begin":"--(?!>)","captures":{"0":{"name":"invalid.illegal.bad-comments-or-CDATA.xml"}}}]}]},"doublequotedString":{"begin":"\\"","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.xml"}},"end":"\\"","endCaptures":{"0":{"name":"punctuation.definition.string.end.xml"}},"name":"string.quoted.double.xml","patterns":[{"include":"#entity"},{"include":"#bare-ampersand"}]},"entity":{"captures":{"1":{"name":"punctuation.definition.constant.xml"},"3":{"name":"punctuation.definition.constant.xml"}},"match":"(&)([:A-Z_a-z][-.0-:A-Z_a-z]*|#[0-9]+|#x\\\\h+)(;)","name":"constant.character.entity.xml"},"internalSubset":{"begin":"(\\\\[)","captures":{"1":{"name":"punctuation.definition.constant.xml"}},"end":"(])","name":"meta.internalsubset.xml","patterns":[{"include":"#EntityDecl"},{"include":"#parameterEntity"},{"include":"#comments"}]},"parameterEntity":{"captures":{"1":{"name":"punctuation.definition.constant.xml"},"3":{"name":"punctuation.definition.constant.xml"}},"match":"(%)([:A-Z_a-z][-.0-:A-Z_a-z]*)(;)","name":"constant.character.parameter-entity.xml"},"singlequotedString":{"begin":"'","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.xml"}},"end":"'","endCaptures":{"0":{"name":"punctuation.definition.string.end.xml"}},"name":"string.quoted.single.xml","patterns":[{"include":"#entity"},{"include":"#bare-ampersand"}]},"tagStuff":{"patterns":[{"captures":{"1":{"name":"entity.other.attribute-name.namespace.xml"},"2":{"name":"entity.other.attribute-name.xml"},"3":{"name":"punctuation.separator.namespace.xml"},"4":{"name":"entity.other.attribute-name.localname.xml"}},"match":"(?:^|\\\\s+)(?:([-.\\\\w]+)((:)))?([-.:\\\\w]+)\\\\s*="},{"include":"#doublequotedString"},{"include":"#singlequotedString"}]}},"scopeName":"text.xml","embeddedLangs":["java"]}`)),i=[...t,r];export{n,i as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{t as e}from"./xml-
|
|
1
|
+
import{t as e}from"./xml-C4RWnUuj.js";var t=Object.freeze(JSON.parse(`{"displayName":"XSL","name":"xsl","patterns":[{"begin":"(<)(xsl)((:))(template)","captures":{"1":{"name":"punctuation.definition.tag.xml"},"2":{"name":"entity.name.tag.namespace.xml"},"3":{"name":"entity.name.tag.xml"},"4":{"name":"punctuation.separator.namespace.xml"},"5":{"name":"entity.name.tag.localname.xml"}},"end":"(>)","name":"meta.tag.xml.template","patterns":[{"captures":{"1":{"name":"entity.other.attribute-name.namespace.xml"},"2":{"name":"entity.other.attribute-name.xml"},"3":{"name":"punctuation.separator.namespace.xml"},"4":{"name":"entity.other.attribute-name.localname.xml"}},"match":" (?:([-0-9A-Z_a-z]+)((:)))?([-A-Za-z]+)"},{"include":"#doublequotedString"},{"include":"#singlequotedString"}]},{"include":"text.xml"}],"repository":{"doublequotedString":{"begin":"\\"","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.xml"}},"end":"\\"","endCaptures":{"0":{"name":"punctuation.definition.string.end.xml"}},"name":"string.quoted.double.xml"},"singlequotedString":{"begin":"'","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.xml"}},"end":"'","endCaptures":{"0":{"name":"punctuation.definition.string.end.xml"}},"name":"string.quoted.single.xml"}},"scopeName":"text.xml.xsl","embeddedLangs":["xml"]}`)),n=[...e,t];export{n as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{t as e}from"./index-CBT_sNIz.js";var t=e({default:()=>n}),n=[Object.freeze(JSON.parse(`{"displayName":"YAML","fileTypes":["yaml","yml","rviz","reek","clang-format","yaml-tmlanguage","syntax","sublime-syntax"],"firstLineMatch":"^%YAML( ?1.\\\\d+)?","name":"yaml","patterns":[{"include":"#comment"},{"include":"#property"},{"include":"#directive"},{"match":"^---","name":"entity.other.document.begin.yaml"},{"match":"^\\\\.{3}","name":"entity.other.document.end.yaml"},{"include":"#node"}],"repository":{"block-collection":{"patterns":[{"include":"#block-sequence"},{"include":"#block-mapping"}]},"block-mapping":{"patterns":[{"include":"#block-pair"}]},"block-node":{"patterns":[{"include":"#prototype"},{"include":"#block-scalar"},{"include":"#block-collection"},{"include":"#flow-scalar-plain-out"},{"include":"#flow-node"}]},"block-pair":{"patterns":[{"begin":"\\\\?","beginCaptures":{"1":{"name":"punctuation.definition.key-value.begin.yaml"}},"end":"(?=\\\\?)|^ *(:)|(:)","endCaptures":{"1":{"name":"punctuation.separator.key-value.mapping.yaml"},"2":{"name":"invalid.illegal.expected-newline.yaml"}},"name":"meta.block-mapping.yaml","patterns":[{"include":"#block-node"}]},{"begin":"(?=(?:[^-\\\\]!\\"#%\\\\&'*,:>?@\\\\[\`{|}\\\\s]|[-:?]\\\\S)([^:\\\\s]|:\\\\S|\\\\s+(?![#\\\\s]))*\\\\s*:(\\\\s|$))","end":"(?=\\\\s*$|\\\\s+#|\\\\s*:(\\\\s|$))","patterns":[{"include":"#flow-scalar-plain-out-implicit-type"},{"begin":"[^-\\\\]!\\"#%\\\\&'*,:>?@\\\\[\`{|}\\\\s]|[-:?]\\\\S","beginCaptures":{"0":{"name":"entity.name.tag.yaml"}},"contentName":"entity.name.tag.yaml","end":"(?=\\\\s*$|\\\\s+#|\\\\s*:(\\\\s|$))","name":"string.unquoted.plain.out.yaml"}]},{"match":":(?=\\\\s|$)","name":"punctuation.separator.key-value.mapping.yaml"}]},"block-scalar":{"begin":"(?:(\\\\|)|(>))([1-9])?([-+])?(.*\\\\n?)","beginCaptures":{"1":{"name":"keyword.control.flow.block-scalar.literal.yaml"},"2":{"name":"keyword.control.flow.block-scalar.folded.yaml"},"3":{"name":"constant.numeric.indentation-indicator.yaml"},"4":{"name":"storage.modifier.chomping-indicator.yaml"},"5":{"patterns":[{"include":"#comment"},{"match":".+","name":"invalid.illegal.expected-comment-or-newline.yaml"}]}},"end":"^(?=\\\\S)|(?!\\\\G)","patterns":[{"begin":"^( +)(?! )","end":"^(?!\\\\1|\\\\s*$)","name":"string.unquoted.block.yaml"}]},"block-sequence":{"match":"(-)(?!\\\\S)","name":"punctuation.definition.block.sequence.item.yaml"},"comment":{"begin":"(?:^([\\\\t ]*)|[\\\\t ]+)(?=#\\\\p{print}*$)","beginCaptures":{"1":{"name":"punctuation.whitespace.comment.leading.yaml"}},"end":"(?!\\\\G)","patterns":[{"begin":"#","beginCaptures":{"0":{"name":"punctuation.definition.comment.yaml"}},"end":"\\\\n","name":"comment.line.number-sign.yaml"}]},"directive":{"begin":"^%","beginCaptures":{"0":{"name":"punctuation.definition.directive.begin.yaml"}},"end":"(?=$|[\\\\t ]+($|#))","name":"meta.directive.yaml","patterns":[{"captures":{"1":{"name":"keyword.other.directive.yaml.yaml"},"2":{"name":"constant.numeric.yaml-version.yaml"}},"match":"\\\\G(YAML)[\\\\t ]+(\\\\d+\\\\.\\\\d+)"},{"captures":{"1":{"name":"keyword.other.directive.tag.yaml"},"2":{"name":"storage.type.tag-handle.yaml"},"3":{"name":"support.type.tag-prefix.yaml"}},"match":"\\\\G(TAG)(?:[\\\\t ]+(!(?:[-0-9A-Za-z]*!)?)(?:[\\\\t ]+(!(?:%\\\\h{2}|[]!#$\\\\&-;=?-\\\\[_a-z~])*|(?![]!,\\\\[{}])(?:%\\\\h{2}|[]!#$\\\\&-;=?-\\\\[_a-z~])+))?)?"},{"captures":{"1":{"name":"support.other.directive.reserved.yaml"},"2":{"name":"string.unquoted.directive-name.yaml"},"3":{"name":"string.unquoted.directive-parameter.yaml"}},"match":"\\\\G(\\\\w+)(?:[\\\\t ]+(\\\\w+)(?:[\\\\t ]+(\\\\w+))?)?"},{"match":"\\\\S+","name":"invalid.illegal.unrecognized.yaml"}]},"flow-alias":{"captures":{"1":{"name":"keyword.control.flow.alias.yaml"},"2":{"name":"punctuation.definition.alias.yaml"},"3":{"name":"variable.other.alias.yaml"},"4":{"name":"invalid.illegal.character.anchor.yaml"}},"match":"((\\\\*))([^],/\\\\[{}\\\\s]+)([^],}\\\\s]\\\\S*)?"},"flow-collection":{"patterns":[{"include":"#flow-sequence"},{"include":"#flow-mapping"}]},"flow-mapping":{"begin":"\\\\{","beginCaptures":{"0":{"name":"punctuation.definition.mapping.begin.yaml"}},"end":"}","endCaptures":{"0":{"name":"punctuation.definition.mapping.end.yaml"}},"name":"meta.flow-mapping.yaml","patterns":[{"include":"#prototype"},{"match":",","name":"punctuation.separator.mapping.yaml"},{"include":"#flow-pair"}]},"flow-node":{"patterns":[{"include":"#prototype"},{"include":"#flow-alias"},{"include":"#flow-collection"},{"include":"#flow-scalar"}]},"flow-pair":{"patterns":[{"begin":"\\\\?","beginCaptures":{"0":{"name":"punctuation.definition.key-value.begin.yaml"}},"end":"(?=[],}])","name":"meta.flow-pair.explicit.yaml","patterns":[{"include":"#prototype"},{"include":"#flow-pair"},{"include":"#flow-node"},{"begin":":(?=\\\\s|$|[],\\\\[{}])","beginCaptures":{"0":{"name":"punctuation.separator.key-value.mapping.yaml"}},"end":"(?=[],}])","patterns":[{"include":"#flow-value"}]}]},{"begin":"(?=(?:[^-\\\\]!\\"#%\\\\&'*,:>?@\\\\[\`{|}\\\\s]|[-:?][^],\\\\[{}\\\\s])([^],:\\\\[{}\\\\s]|:[^],\\\\[{}\\\\s]|\\\\s+(?![#\\\\s]))*\\\\s*:(\\\\s|$))","end":"(?=\\\\s*$|\\\\s+#|\\\\s*:(\\\\s|$)|\\\\s*:[],\\\\[{}]|\\\\s*[],\\\\[{}])","name":"meta.flow-pair.key.yaml","patterns":[{"include":"#flow-scalar-plain-in-implicit-type"},{"begin":"[^-\\\\]!\\"#%\\\\&'*,:>?@\\\\[\`{|}\\\\s]|[-:?][^],\\\\[{}\\\\s]","beginCaptures":{"0":{"name":"entity.name.tag.yaml"}},"contentName":"entity.name.tag.yaml","end":"(?=\\\\s*$|\\\\s+#|\\\\s*:(\\\\s|$)|\\\\s*:[],\\\\[{}]|\\\\s*[],\\\\[{}])","name":"string.unquoted.plain.in.yaml"}]},{"include":"#flow-node"},{"begin":":(?=\\\\s|$|[],\\\\[{}])","captures":{"0":{"name":"punctuation.separator.key-value.mapping.yaml"}},"end":"(?=[],}])","name":"meta.flow-pair.yaml","patterns":[{"include":"#flow-value"}]}]},"flow-scalar":{"patterns":[{"include":"#flow-scalar-double-quoted"},{"include":"#flow-scalar-single-quoted"},{"include":"#flow-scalar-plain-in"}]},"flow-scalar-double-quoted":{"begin":"\\"","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.yaml"}},"end":"\\"","endCaptures":{"0":{"name":"punctuation.definition.string.end.yaml"}},"name":"string.quoted.double.yaml","patterns":[{"match":"\\\\\\\\([ \\"/0LN\\\\\\\\_abefnprtv]|x\\\\d\\\\d|u\\\\d{4}|U\\\\d{8})","name":"constant.character.escape.yaml"},{"match":"\\\\\\\\\\\\n","name":"constant.character.escape.double-quoted.newline.yaml"}]},"flow-scalar-plain-in":{"patterns":[{"include":"#flow-scalar-plain-in-implicit-type"},{"begin":"[^-\\\\]!\\"#%\\\\&'*,:>?@\\\\[\`{|}\\\\s]|[-:?][^],\\\\[{}\\\\s]","end":"(?=\\\\s*$|\\\\s+#|\\\\s*:(\\\\s|$)|\\\\s*:[],\\\\[{}]|\\\\s*[],\\\\[{}])","name":"string.unquoted.plain.in.yaml"}]},"flow-scalar-plain-in-implicit-type":{"patterns":[{"captures":{"1":{"name":"constant.language.null.yaml"},"2":{"name":"constant.language.boolean.yaml"},"3":{"name":"constant.numeric.integer.yaml"},"4":{"name":"constant.numeric.float.yaml"},"5":{"name":"constant.other.timestamp.yaml"},"6":{"name":"constant.language.value.yaml"},"7":{"name":"constant.language.merge.yaml"}},"match":"(?:(null|Null|NULL|~)|([Yy]|yes|Yes|YES|[Nn]|no|No|NO|true|True|TRUE|false|False|FALSE|on|On|ON|off|Off|OFF)|([-+]?0b[01_]+|[-+]?0[0-7_]+|[-+]?(?:0|[1-9][0-9_]*)|[-+]?0x[_\\\\h]+|[-+]?[1-9][0-9_]*(?::[0-5]?[0-9])+)|([-+]?(?:[0-9][0-9_]*)?\\\\.[.0-9]*(?:[Ee][-+][0-9]+)?|[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\\\\.[0-9_]*|[-+]?\\\\.(?:inf|Inf|INF)|\\\\.(?:nan|NaN|NAN))|(\\\\d{4}-\\\\d{2}-\\\\d{2}|\\\\d{4}-\\\\d{1,2}-\\\\d{1,2}(?:[Tt]|[\\\\t ]+)\\\\d{1,2}:\\\\d{2}:\\\\d{2}(?:\\\\.\\\\d*)?(?:[\\\\t ]*Z|[-+]\\\\d{1,2}(?::\\\\d{1,2})?)?)|(=)|(<<))(?=\\\\s*$|\\\\s+#|\\\\s*:(\\\\s|$)|\\\\s*:[],\\\\[{}]|\\\\s*[],\\\\[{}])"}]},"flow-scalar-plain-out":{"patterns":[{"include":"#flow-scalar-plain-out-implicit-type"},{"begin":"[^-\\\\]!\\"#%\\\\&'*,:>?@\\\\[\`{|}\\\\s]|[-:?]\\\\S","end":"(?=\\\\s*$|\\\\s+#|\\\\s*:(\\\\s|$))","name":"string.unquoted.plain.out.yaml"}]},"flow-scalar-plain-out-implicit-type":{"patterns":[{"captures":{"1":{"name":"constant.language.null.yaml"},"2":{"name":"constant.language.boolean.yaml"},"3":{"name":"constant.numeric.integer.yaml"},"4":{"name":"constant.numeric.float.yaml"},"5":{"name":"constant.other.timestamp.yaml"},"6":{"name":"constant.language.value.yaml"},"7":{"name":"constant.language.merge.yaml"}},"match":"(?:(null|Null|NULL|~)|([Yy]|yes|Yes|YES|[Nn]|no|No|NO|true|True|TRUE|false|False|FALSE|on|On|ON|off|Off|OFF)|([-+]?0b[01_]+|[-+]?0[0-7_]+|[-+]?(?:0|[1-9][0-9_]*)|[-+]?0x[_\\\\h]+|[-+]?[1-9][0-9_]*(?::[0-5]?[0-9])+)|([-+]?(?:[0-9][0-9_]*)?\\\\.[.0-9]*(?:[Ee][-+][0-9]+)?|[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\\\\.[0-9_]*|[-+]?\\\\.(?:inf|Inf|INF)|\\\\.(?:nan|NaN|NAN))|(\\\\d{4}-\\\\d{2}-\\\\d{2}|\\\\d{4}-\\\\d{1,2}-\\\\d{1,2}(?:[Tt]|[\\\\t ]+)\\\\d{1,2}:\\\\d{2}:\\\\d{2}(?:\\\\.\\\\d*)?(?:[\\\\t ]*Z|[-+]\\\\d{1,2}(?::\\\\d{1,2})?)?)|(=)|(<<))(?=\\\\s*$|\\\\s+#|\\\\s*:(\\\\s|$))"}]},"flow-scalar-single-quoted":{"begin":"'","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.yaml"}},"end":"'(?!')","endCaptures":{"0":{"name":"punctuation.definition.string.end.yaml"}},"name":"string.quoted.single.yaml","patterns":[{"match":"''","name":"constant.character.escape.single-quoted.yaml"}]},"flow-sequence":{"begin":"\\\\[","beginCaptures":{"0":{"name":"punctuation.definition.sequence.begin.yaml"}},"end":"]","endCaptures":{"0":{"name":"punctuation.definition.sequence.end.yaml"}},"name":"meta.flow-sequence.yaml","patterns":[{"include":"#prototype"},{"match":",","name":"punctuation.separator.sequence.yaml"},{"include":"#flow-pair"},{"include":"#flow-node"}]},"flow-value":{"patterns":[{"begin":"\\\\G(?![],}])","end":"(?=[],}])","name":"meta.flow-pair.value.yaml","patterns":[{"include":"#flow-node"}]}]},"node":{"patterns":[{"include":"#block-node"}]},"property":{"begin":"(?=[!\\\\&])","end":"(?!\\\\G)","name":"meta.property.yaml","patterns":[{"captures":{"1":{"name":"keyword.control.property.anchor.yaml"},"2":{"name":"punctuation.definition.anchor.yaml"},"3":{"name":"entity.name.type.anchor.yaml"},"4":{"name":"invalid.illegal.character.anchor.yaml"}},"match":"\\\\G((&))([^],/\\\\[{}\\\\s]+)(\\\\S+)?"},{"match":"\\\\G!(?:<(?:%\\\\h{2}|[]!#$\\\\&-;=?-\\\\[_a-z~])+>|(?:[-0-9A-Za-z]*!)?(?:%\\\\h{2}|[#$\\\\&-+\\\\--;=?-Z_a-z~])+|)(?=[\\\\t ]|$)","name":"storage.type.tag-handle.yaml"},{"match":"\\\\S+","name":"invalid.illegal.tag-handle.yaml"}]},"prototype":{"patterns":[{"include":"#comment"},{"include":"#property"}]}},"scopeName":"source.yaml","aliases":["yml"]}`))];export{t as n,n as t};
|
|
1
|
+
import{t as e}from"./index-D8ZI_2RC.js";var t=e({default:()=>n}),n=[Object.freeze(JSON.parse(`{"displayName":"YAML","fileTypes":["yaml","yml","rviz","reek","clang-format","yaml-tmlanguage","syntax","sublime-syntax"],"firstLineMatch":"^%YAML( ?1.\\\\d+)?","name":"yaml","patterns":[{"include":"#comment"},{"include":"#property"},{"include":"#directive"},{"match":"^---","name":"entity.other.document.begin.yaml"},{"match":"^\\\\.{3}","name":"entity.other.document.end.yaml"},{"include":"#node"}],"repository":{"block-collection":{"patterns":[{"include":"#block-sequence"},{"include":"#block-mapping"}]},"block-mapping":{"patterns":[{"include":"#block-pair"}]},"block-node":{"patterns":[{"include":"#prototype"},{"include":"#block-scalar"},{"include":"#block-collection"},{"include":"#flow-scalar-plain-out"},{"include":"#flow-node"}]},"block-pair":{"patterns":[{"begin":"\\\\?","beginCaptures":{"1":{"name":"punctuation.definition.key-value.begin.yaml"}},"end":"(?=\\\\?)|^ *(:)|(:)","endCaptures":{"1":{"name":"punctuation.separator.key-value.mapping.yaml"},"2":{"name":"invalid.illegal.expected-newline.yaml"}},"name":"meta.block-mapping.yaml","patterns":[{"include":"#block-node"}]},{"begin":"(?=(?:[^-\\\\]!\\"#%\\\\&'*,:>?@\\\\[\`{|}\\\\s]|[-:?]\\\\S)([^:\\\\s]|:\\\\S|\\\\s+(?![#\\\\s]))*\\\\s*:(\\\\s|$))","end":"(?=\\\\s*$|\\\\s+#|\\\\s*:(\\\\s|$))","patterns":[{"include":"#flow-scalar-plain-out-implicit-type"},{"begin":"[^-\\\\]!\\"#%\\\\&'*,:>?@\\\\[\`{|}\\\\s]|[-:?]\\\\S","beginCaptures":{"0":{"name":"entity.name.tag.yaml"}},"contentName":"entity.name.tag.yaml","end":"(?=\\\\s*$|\\\\s+#|\\\\s*:(\\\\s|$))","name":"string.unquoted.plain.out.yaml"}]},{"match":":(?=\\\\s|$)","name":"punctuation.separator.key-value.mapping.yaml"}]},"block-scalar":{"begin":"(?:(\\\\|)|(>))([1-9])?([-+])?(.*\\\\n?)","beginCaptures":{"1":{"name":"keyword.control.flow.block-scalar.literal.yaml"},"2":{"name":"keyword.control.flow.block-scalar.folded.yaml"},"3":{"name":"constant.numeric.indentation-indicator.yaml"},"4":{"name":"storage.modifier.chomping-indicator.yaml"},"5":{"patterns":[{"include":"#comment"},{"match":".+","name":"invalid.illegal.expected-comment-or-newline.yaml"}]}},"end":"^(?=\\\\S)|(?!\\\\G)","patterns":[{"begin":"^( +)(?! )","end":"^(?!\\\\1|\\\\s*$)","name":"string.unquoted.block.yaml"}]},"block-sequence":{"match":"(-)(?!\\\\S)","name":"punctuation.definition.block.sequence.item.yaml"},"comment":{"begin":"(?:^([\\\\t ]*)|[\\\\t ]+)(?=#\\\\p{print}*$)","beginCaptures":{"1":{"name":"punctuation.whitespace.comment.leading.yaml"}},"end":"(?!\\\\G)","patterns":[{"begin":"#","beginCaptures":{"0":{"name":"punctuation.definition.comment.yaml"}},"end":"\\\\n","name":"comment.line.number-sign.yaml"}]},"directive":{"begin":"^%","beginCaptures":{"0":{"name":"punctuation.definition.directive.begin.yaml"}},"end":"(?=$|[\\\\t ]+($|#))","name":"meta.directive.yaml","patterns":[{"captures":{"1":{"name":"keyword.other.directive.yaml.yaml"},"2":{"name":"constant.numeric.yaml-version.yaml"}},"match":"\\\\G(YAML)[\\\\t ]+(\\\\d+\\\\.\\\\d+)"},{"captures":{"1":{"name":"keyword.other.directive.tag.yaml"},"2":{"name":"storage.type.tag-handle.yaml"},"3":{"name":"support.type.tag-prefix.yaml"}},"match":"\\\\G(TAG)(?:[\\\\t ]+(!(?:[-0-9A-Za-z]*!)?)(?:[\\\\t ]+(!(?:%\\\\h{2}|[]!#$\\\\&-;=?-\\\\[_a-z~])*|(?![]!,\\\\[{}])(?:%\\\\h{2}|[]!#$\\\\&-;=?-\\\\[_a-z~])+))?)?"},{"captures":{"1":{"name":"support.other.directive.reserved.yaml"},"2":{"name":"string.unquoted.directive-name.yaml"},"3":{"name":"string.unquoted.directive-parameter.yaml"}},"match":"\\\\G(\\\\w+)(?:[\\\\t ]+(\\\\w+)(?:[\\\\t ]+(\\\\w+))?)?"},{"match":"\\\\S+","name":"invalid.illegal.unrecognized.yaml"}]},"flow-alias":{"captures":{"1":{"name":"keyword.control.flow.alias.yaml"},"2":{"name":"punctuation.definition.alias.yaml"},"3":{"name":"variable.other.alias.yaml"},"4":{"name":"invalid.illegal.character.anchor.yaml"}},"match":"((\\\\*))([^],/\\\\[{}\\\\s]+)([^],}\\\\s]\\\\S*)?"},"flow-collection":{"patterns":[{"include":"#flow-sequence"},{"include":"#flow-mapping"}]},"flow-mapping":{"begin":"\\\\{","beginCaptures":{"0":{"name":"punctuation.definition.mapping.begin.yaml"}},"end":"}","endCaptures":{"0":{"name":"punctuation.definition.mapping.end.yaml"}},"name":"meta.flow-mapping.yaml","patterns":[{"include":"#prototype"},{"match":",","name":"punctuation.separator.mapping.yaml"},{"include":"#flow-pair"}]},"flow-node":{"patterns":[{"include":"#prototype"},{"include":"#flow-alias"},{"include":"#flow-collection"},{"include":"#flow-scalar"}]},"flow-pair":{"patterns":[{"begin":"\\\\?","beginCaptures":{"0":{"name":"punctuation.definition.key-value.begin.yaml"}},"end":"(?=[],}])","name":"meta.flow-pair.explicit.yaml","patterns":[{"include":"#prototype"},{"include":"#flow-pair"},{"include":"#flow-node"},{"begin":":(?=\\\\s|$|[],\\\\[{}])","beginCaptures":{"0":{"name":"punctuation.separator.key-value.mapping.yaml"}},"end":"(?=[],}])","patterns":[{"include":"#flow-value"}]}]},{"begin":"(?=(?:[^-\\\\]!\\"#%\\\\&'*,:>?@\\\\[\`{|}\\\\s]|[-:?][^],\\\\[{}\\\\s])([^],:\\\\[{}\\\\s]|:[^],\\\\[{}\\\\s]|\\\\s+(?![#\\\\s]))*\\\\s*:(\\\\s|$))","end":"(?=\\\\s*$|\\\\s+#|\\\\s*:(\\\\s|$)|\\\\s*:[],\\\\[{}]|\\\\s*[],\\\\[{}])","name":"meta.flow-pair.key.yaml","patterns":[{"include":"#flow-scalar-plain-in-implicit-type"},{"begin":"[^-\\\\]!\\"#%\\\\&'*,:>?@\\\\[\`{|}\\\\s]|[-:?][^],\\\\[{}\\\\s]","beginCaptures":{"0":{"name":"entity.name.tag.yaml"}},"contentName":"entity.name.tag.yaml","end":"(?=\\\\s*$|\\\\s+#|\\\\s*:(\\\\s|$)|\\\\s*:[],\\\\[{}]|\\\\s*[],\\\\[{}])","name":"string.unquoted.plain.in.yaml"}]},{"include":"#flow-node"},{"begin":":(?=\\\\s|$|[],\\\\[{}])","captures":{"0":{"name":"punctuation.separator.key-value.mapping.yaml"}},"end":"(?=[],}])","name":"meta.flow-pair.yaml","patterns":[{"include":"#flow-value"}]}]},"flow-scalar":{"patterns":[{"include":"#flow-scalar-double-quoted"},{"include":"#flow-scalar-single-quoted"},{"include":"#flow-scalar-plain-in"}]},"flow-scalar-double-quoted":{"begin":"\\"","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.yaml"}},"end":"\\"","endCaptures":{"0":{"name":"punctuation.definition.string.end.yaml"}},"name":"string.quoted.double.yaml","patterns":[{"match":"\\\\\\\\([ \\"/0LN\\\\\\\\_abefnprtv]|x\\\\d\\\\d|u\\\\d{4}|U\\\\d{8})","name":"constant.character.escape.yaml"},{"match":"\\\\\\\\\\\\n","name":"constant.character.escape.double-quoted.newline.yaml"}]},"flow-scalar-plain-in":{"patterns":[{"include":"#flow-scalar-plain-in-implicit-type"},{"begin":"[^-\\\\]!\\"#%\\\\&'*,:>?@\\\\[\`{|}\\\\s]|[-:?][^],\\\\[{}\\\\s]","end":"(?=\\\\s*$|\\\\s+#|\\\\s*:(\\\\s|$)|\\\\s*:[],\\\\[{}]|\\\\s*[],\\\\[{}])","name":"string.unquoted.plain.in.yaml"}]},"flow-scalar-plain-in-implicit-type":{"patterns":[{"captures":{"1":{"name":"constant.language.null.yaml"},"2":{"name":"constant.language.boolean.yaml"},"3":{"name":"constant.numeric.integer.yaml"},"4":{"name":"constant.numeric.float.yaml"},"5":{"name":"constant.other.timestamp.yaml"},"6":{"name":"constant.language.value.yaml"},"7":{"name":"constant.language.merge.yaml"}},"match":"(?:(null|Null|NULL|~)|([Yy]|yes|Yes|YES|[Nn]|no|No|NO|true|True|TRUE|false|False|FALSE|on|On|ON|off|Off|OFF)|([-+]?0b[01_]+|[-+]?0[0-7_]+|[-+]?(?:0|[1-9][0-9_]*)|[-+]?0x[_\\\\h]+|[-+]?[1-9][0-9_]*(?::[0-5]?[0-9])+)|([-+]?(?:[0-9][0-9_]*)?\\\\.[.0-9]*(?:[Ee][-+][0-9]+)?|[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\\\\.[0-9_]*|[-+]?\\\\.(?:inf|Inf|INF)|\\\\.(?:nan|NaN|NAN))|(\\\\d{4}-\\\\d{2}-\\\\d{2}|\\\\d{4}-\\\\d{1,2}-\\\\d{1,2}(?:[Tt]|[\\\\t ]+)\\\\d{1,2}:\\\\d{2}:\\\\d{2}(?:\\\\.\\\\d*)?(?:[\\\\t ]*Z|[-+]\\\\d{1,2}(?::\\\\d{1,2})?)?)|(=)|(<<))(?=\\\\s*$|\\\\s+#|\\\\s*:(\\\\s|$)|\\\\s*:[],\\\\[{}]|\\\\s*[],\\\\[{}])"}]},"flow-scalar-plain-out":{"patterns":[{"include":"#flow-scalar-plain-out-implicit-type"},{"begin":"[^-\\\\]!\\"#%\\\\&'*,:>?@\\\\[\`{|}\\\\s]|[-:?]\\\\S","end":"(?=\\\\s*$|\\\\s+#|\\\\s*:(\\\\s|$))","name":"string.unquoted.plain.out.yaml"}]},"flow-scalar-plain-out-implicit-type":{"patterns":[{"captures":{"1":{"name":"constant.language.null.yaml"},"2":{"name":"constant.language.boolean.yaml"},"3":{"name":"constant.numeric.integer.yaml"},"4":{"name":"constant.numeric.float.yaml"},"5":{"name":"constant.other.timestamp.yaml"},"6":{"name":"constant.language.value.yaml"},"7":{"name":"constant.language.merge.yaml"}},"match":"(?:(null|Null|NULL|~)|([Yy]|yes|Yes|YES|[Nn]|no|No|NO|true|True|TRUE|false|False|FALSE|on|On|ON|off|Off|OFF)|([-+]?0b[01_]+|[-+]?0[0-7_]+|[-+]?(?:0|[1-9][0-9_]*)|[-+]?0x[_\\\\h]+|[-+]?[1-9][0-9_]*(?::[0-5]?[0-9])+)|([-+]?(?:[0-9][0-9_]*)?\\\\.[.0-9]*(?:[Ee][-+][0-9]+)?|[-+]?[0-9][0-9_]*(?::[0-5]?[0-9])+\\\\.[0-9_]*|[-+]?\\\\.(?:inf|Inf|INF)|\\\\.(?:nan|NaN|NAN))|(\\\\d{4}-\\\\d{2}-\\\\d{2}|\\\\d{4}-\\\\d{1,2}-\\\\d{1,2}(?:[Tt]|[\\\\t ]+)\\\\d{1,2}:\\\\d{2}:\\\\d{2}(?:\\\\.\\\\d*)?(?:[\\\\t ]*Z|[-+]\\\\d{1,2}(?::\\\\d{1,2})?)?)|(=)|(<<))(?=\\\\s*$|\\\\s+#|\\\\s*:(\\\\s|$))"}]},"flow-scalar-single-quoted":{"begin":"'","beginCaptures":{"0":{"name":"punctuation.definition.string.begin.yaml"}},"end":"'(?!')","endCaptures":{"0":{"name":"punctuation.definition.string.end.yaml"}},"name":"string.quoted.single.yaml","patterns":[{"match":"''","name":"constant.character.escape.single-quoted.yaml"}]},"flow-sequence":{"begin":"\\\\[","beginCaptures":{"0":{"name":"punctuation.definition.sequence.begin.yaml"}},"end":"]","endCaptures":{"0":{"name":"punctuation.definition.sequence.end.yaml"}},"name":"meta.flow-sequence.yaml","patterns":[{"include":"#prototype"},{"match":",","name":"punctuation.separator.sequence.yaml"},{"include":"#flow-pair"},{"include":"#flow-node"}]},"flow-value":{"patterns":[{"begin":"\\\\G(?![],}])","end":"(?=[],}])","name":"meta.flow-pair.value.yaml","patterns":[{"include":"#flow-node"}]}]},"node":{"patterns":[{"include":"#block-node"}]},"property":{"begin":"(?=[!\\\\&])","end":"(?!\\\\G)","name":"meta.property.yaml","patterns":[{"captures":{"1":{"name":"keyword.control.property.anchor.yaml"},"2":{"name":"punctuation.definition.anchor.yaml"},"3":{"name":"entity.name.type.anchor.yaml"},"4":{"name":"invalid.illegal.character.anchor.yaml"}},"match":"\\\\G((&))([^],/\\\\[{}\\\\s]+)(\\\\S+)?"},{"match":"\\\\G!(?:<(?:%\\\\h{2}|[]!#$\\\\&-;=?-\\\\[_a-z~])+>|(?:[-0-9A-Za-z]*!)?(?:%\\\\h{2}|[#$\\\\&-+\\\\--;=?-Z_a-z~])+|)(?=[\\\\t ]|$)","name":"storage.type.tag-handle.yaml"},{"match":"\\\\S+","name":"invalid.illegal.tag-handle.yaml"}]},"prototype":{"patterns":[{"include":"#comment"},{"include":"#property"}]}},"scopeName":"source.yaml","aliases":["yml"]}`))];export{t as n,n as t};
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
<meta charset="utf-8" />
|
|
5
5
|
<meta name="viewport" content="width=device-width, initial-scale=1" />
|
|
6
6
|
<title>Tau diff tool</title>
|
|
7
|
-
<script type="module" crossorigin src="./assets/index-
|
|
7
|
+
<script type="module" crossorigin src="./assets/index-D8ZI_2RC.js"></script>
|
|
8
8
|
<link rel="stylesheet" crossorigin href="./assets/index-DuML4oGc.css">
|
|
9
9
|
</head>
|
|
10
10
|
<body>
|
|
@@ -4,12 +4,9 @@ import { resolvePromptTemplateWithBackend } from "../core/config/index.js";
|
|
|
4
4
|
import { assistantHistoryEntries, systemHistoryEntry, toolHistoryEntry, userHistoryEntry, } from "../core/history/transcript.js";
|
|
5
5
|
import { McpManager } from "../core/mcp/manager.js";
|
|
6
6
|
import { ChatRuntime } from "../core/runtime/chat_runtime.js";
|
|
7
|
-
import { formatSteeringUserMessage } from "../core/runtime/steering.js";
|
|
8
|
-
import { buildGoalContinuationText, prependGoalPolicy } from "../core/session/goal.js";
|
|
9
7
|
import { buildToolRunPresentation, TOOL_UI_FACET_VERSION } from "../core/tools/presentation.js";
|
|
10
8
|
import { appendUsageLogEntry, getUsageCostTotal, getUsageTotals, } from "../core/usage/logs.js";
|
|
11
9
|
import { filterProjectPathAutocompleteEntries, loadProjectPathAutocompleteEntriesWithBackend, } from "../core/utils/project_files.js";
|
|
12
|
-
import { hasGoalTurnMetadata } from "../core/utils/user_metadata.js";
|
|
13
10
|
import { applySessionProtocolDelta, createSessionProtocolDeltaMessage, createSessionProtocolEphemeralMessage, createSessionProtocolSubagentActivitiesMessage, projectSessionProtocolNoticePresentation, projectSessionProtocolSubagentActivity, SESSION_PROTOCOL_MAX_SUBAGENT_ACTIVITIES, } from "../protocol/session_protocol.js";
|
|
14
11
|
import { isIntermediateSystemMessage, } from "../protocol/system_message.js";
|
|
15
12
|
import { LEGACY_SESSION_MODEL_CONTEXT_KEY } from "../store/session_snapshot_migrations.js";
|
|
@@ -144,11 +141,6 @@ export class LocalSessionHost {
|
|
|
144
141
|
promptContext: runtimeContext.promptBootstrap.promptContext,
|
|
145
142
|
eventSink: async (event) => await hostedSession.enqueueRuntimeEvent(event),
|
|
146
143
|
subagentEventSink: async (event) => await hostedSession.recordSubagentEvent(event),
|
|
147
|
-
goalManager: {
|
|
148
|
-
getGoal: () => hostedSession.getGoal(),
|
|
149
|
-
createGoal: async (objective) => await hostedSession.createGoal(objective),
|
|
150
|
-
updateGoal: async (update) => await hostedSession.updateGoal(update),
|
|
151
|
-
},
|
|
152
144
|
history: this.history.query(this.historyRemote),
|
|
153
145
|
mcp: this.mcp,
|
|
154
146
|
initialPromptComposition: committedSnapshot
|
|
@@ -474,8 +466,6 @@ class LocalHostedSessionHandle {
|
|
|
474
466
|
disposePromise;
|
|
475
467
|
disposing = false;
|
|
476
468
|
costTotal = 0;
|
|
477
|
-
goal;
|
|
478
|
-
pendingGoalCommit;
|
|
479
469
|
forceNextSnapshotRevision;
|
|
480
470
|
projectionFailure;
|
|
481
471
|
disposed = false;
|
|
@@ -499,7 +489,6 @@ class LocalHostedSessionHandle {
|
|
|
499
489
|
this.persistedSnapshot = committedSnapshot
|
|
500
490
|
? cloneSessionProtocolSnapshot(committedSnapshot)
|
|
501
491
|
: undefined;
|
|
502
|
-
this.goal = structuredClone(committedSnapshot?.goal ?? null);
|
|
503
492
|
this.forceNextSnapshotRevision = forceNextSnapshotRevision;
|
|
504
493
|
this.restoreProtocolState(committedSnapshot);
|
|
505
494
|
this.committedSnapshot = committedSnapshot
|
|
@@ -510,8 +499,7 @@ class LocalHostedSessionHandle {
|
|
|
510
499
|
return this.runtime.isTurnRunning;
|
|
511
500
|
}
|
|
512
501
|
get canAcceptSteering() {
|
|
513
|
-
return
|
|
514
|
-
Boolean(this.activeLogicalTurn && this.goal?.status === "active"));
|
|
502
|
+
return this.runtime.isTurnRunning;
|
|
515
503
|
}
|
|
516
504
|
get sessionId() {
|
|
517
505
|
return this.session.sessionId;
|
|
@@ -546,105 +534,6 @@ class LocalHostedSessionHandle {
|
|
|
546
534
|
this.subagentActivitiesListeners.delete(handler);
|
|
547
535
|
};
|
|
548
536
|
}
|
|
549
|
-
getGoal() {
|
|
550
|
-
return structuredClone(this.goal);
|
|
551
|
-
}
|
|
552
|
-
async createGoal(objective) {
|
|
553
|
-
const goal = this.buildNewGoal(objective);
|
|
554
|
-
await this.setGoal(goal);
|
|
555
|
-
return structuredClone(goal);
|
|
556
|
-
}
|
|
557
|
-
async updateGoal(update) {
|
|
558
|
-
this.assertActive();
|
|
559
|
-
const current = this.goal;
|
|
560
|
-
if (!current) {
|
|
561
|
-
throw new Error("no goal exists");
|
|
562
|
-
}
|
|
563
|
-
if (update.objective !== undefined && update.status === "complete") {
|
|
564
|
-
throw new Error("goal objective cannot be updated while completing the goal");
|
|
565
|
-
}
|
|
566
|
-
if (update.status === "complete") {
|
|
567
|
-
await this.setGoal(null);
|
|
568
|
-
return null;
|
|
569
|
-
}
|
|
570
|
-
const objective = update.objective?.trim() ?? current.objective;
|
|
571
|
-
if (!objective) {
|
|
572
|
-
throw new Error("goal objective must not be empty");
|
|
573
|
-
}
|
|
574
|
-
const goal = {
|
|
575
|
-
objective,
|
|
576
|
-
status: update.status ?? current.status,
|
|
577
|
-
};
|
|
578
|
-
await this.setGoal(goal);
|
|
579
|
-
return structuredClone(goal);
|
|
580
|
-
}
|
|
581
|
-
async startGoal(objective) {
|
|
582
|
-
const goal = this.buildNewGoal(objective);
|
|
583
|
-
return await this.runLogicalTurn(async (logicalTurn) => {
|
|
584
|
-
await this.enqueueMutation(() => {
|
|
585
|
-
this.goal = goal;
|
|
586
|
-
this.pendingGoalCommit = goal;
|
|
587
|
-
});
|
|
588
|
-
try {
|
|
589
|
-
const { userHistoryEntryId } = await this.acceptTurn({
|
|
590
|
-
text: prependGoalPolicy(goal.objective, goal),
|
|
591
|
-
});
|
|
592
|
-
const turn = logicalTurn.cancellationRequested
|
|
593
|
-
? await this.cancelLogicalTurn()
|
|
594
|
-
: await this.runTurnNow(logicalTurn, userHistoryEntryId);
|
|
595
|
-
await this.settleTurn(userHistoryEntryId, turn);
|
|
596
|
-
return { userHistoryEntryId, turn };
|
|
597
|
-
}
|
|
598
|
-
catch (error) {
|
|
599
|
-
if (this.pendingGoalCommit === goal) {
|
|
600
|
-
await this.enqueueMutation(() => {
|
|
601
|
-
this.goal = null;
|
|
602
|
-
this.pendingGoalCommit = undefined;
|
|
603
|
-
});
|
|
604
|
-
}
|
|
605
|
-
else {
|
|
606
|
-
await this.blockActiveGoal().catch(() => undefined);
|
|
607
|
-
}
|
|
608
|
-
throw error;
|
|
609
|
-
}
|
|
610
|
-
});
|
|
611
|
-
}
|
|
612
|
-
async resumeGoal() {
|
|
613
|
-
this.assertActive();
|
|
614
|
-
if (this.goal?.status !== "blocked") {
|
|
615
|
-
throw new Error(this.goal ? "goal is already active" : "no goal exists");
|
|
616
|
-
}
|
|
617
|
-
const goal = { ...this.goal, status: "active" };
|
|
618
|
-
return await this.runLogicalTurn(async (logicalTurn) => {
|
|
619
|
-
await this.setGoal(goal);
|
|
620
|
-
try {
|
|
621
|
-
if (logicalTurn.cancellationRequested) {
|
|
622
|
-
await this.blockActiveGoal();
|
|
623
|
-
return { turn: abortedTurnOutcome() };
|
|
624
|
-
}
|
|
625
|
-
const { userHistoryEntryId } = await this.acceptTurn({
|
|
626
|
-
text: buildGoalContinuationText(goal),
|
|
627
|
-
});
|
|
628
|
-
const turn = logicalTurn.cancellationRequested
|
|
629
|
-
? await this.cancelLogicalTurn()
|
|
630
|
-
: await this.runTurnNow(logicalTurn, userHistoryEntryId);
|
|
631
|
-
await this.settleTurn(userHistoryEntryId, turn);
|
|
632
|
-
return { turn };
|
|
633
|
-
}
|
|
634
|
-
catch (error) {
|
|
635
|
-
await this.blockActiveGoal().catch(() => undefined);
|
|
636
|
-
throw error;
|
|
637
|
-
}
|
|
638
|
-
});
|
|
639
|
-
}
|
|
640
|
-
async clearGoal() {
|
|
641
|
-
this.assertActive();
|
|
642
|
-
if (!this.goal) {
|
|
643
|
-
throw new Error("no goal exists");
|
|
644
|
-
}
|
|
645
|
-
await this.setGoal(null);
|
|
646
|
-
return await this.snapshot();
|
|
647
|
-
}
|
|
648
537
|
async record(options) {
|
|
649
538
|
this.assertActive();
|
|
650
539
|
const historyEntryId = options.historyEntryId === undefined
|
|
@@ -726,9 +615,6 @@ class LocalHostedSessionHandle {
|
|
|
726
615
|
}
|
|
727
616
|
async retryTurn() {
|
|
728
617
|
const userMessage = this.session.rawHistoryEntries.findLast((entry) => entry.message.role === "user");
|
|
729
|
-
if (userMessage && hasGoalTurnMetadata(userMessage.message)) {
|
|
730
|
-
throw new SessionRetryUnavailableError("goal-controlled turns cannot be retried; resume a blocked goal or start a new goal");
|
|
731
|
-
}
|
|
732
618
|
if (!userMessage) {
|
|
733
619
|
throw new SessionRetryUnavailableError("no user turn is available to retry");
|
|
734
620
|
}
|
|
@@ -741,7 +627,6 @@ class LocalHostedSessionHandle {
|
|
|
741
627
|
}
|
|
742
628
|
const logicalTurn = {
|
|
743
629
|
cancellationRequested: false,
|
|
744
|
-
pendingSteering: [],
|
|
745
630
|
};
|
|
746
631
|
this.activeLogicalTurn = logicalTurn;
|
|
747
632
|
const run = execute(logicalTurn);
|
|
@@ -751,7 +636,6 @@ class LocalHostedSessionHandle {
|
|
|
751
636
|
}
|
|
752
637
|
finally {
|
|
753
638
|
if (this.activeTurnPromise === run) {
|
|
754
|
-
this.rejectBufferedLogicalSteering(logicalTurn, new Error("steering was not applied before the logical turn ended"));
|
|
755
639
|
this.activeTurnPromise = undefined;
|
|
756
640
|
this.activeLogicalTurn = undefined;
|
|
757
641
|
await this.enqueueSnapshotResetIfChanged("assistant-message");
|
|
@@ -765,58 +649,20 @@ class LocalHostedSessionHandle {
|
|
|
765
649
|
if (!rootUserMessage) {
|
|
766
650
|
throw new Error("cannot run a turn without a user message");
|
|
767
651
|
}
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
try {
|
|
775
|
-
while (logicalTurn.pendingSteering.length > 0) {
|
|
776
|
-
committedSteering.push(await this.commitBufferedLogicalSteering(logicalTurn));
|
|
777
|
-
}
|
|
778
|
-
if (logicalTurn.cancellationRequested) {
|
|
779
|
-
return await this.cancelLogicalTurn(committedSteering);
|
|
780
|
-
}
|
|
781
|
-
const result = await this.runtime.runTurn();
|
|
782
|
-
const terminalResult = result.terminalResult;
|
|
783
|
-
if (terminalResult.aborted && this.draftAssistantMessage) {
|
|
784
|
-
await this.interruptDraftAssistantMessage();
|
|
785
|
-
}
|
|
786
|
-
const initialOutcome = turnOutcomeFromResult(result, result.finalMessage);
|
|
787
|
-
const terminalOutcome = turnOutcomeFromResult(terminalResult, terminalResult.finalMessage);
|
|
788
|
-
await this.enqueueMutation(async () => {
|
|
789
|
-
if (this.goal?.status === "active") {
|
|
790
|
-
goalRootHistoryEntryId ??= rootUserMessage.id;
|
|
791
|
-
}
|
|
792
|
-
if (terminalOutcome.status !== "completed" && this.goal?.status === "active") {
|
|
793
|
-
this.goal = { ...this.goal, status: "blocked" };
|
|
794
|
-
}
|
|
795
|
-
await this.emitSnapshotResetIfChanged("assistant-message");
|
|
796
|
-
});
|
|
797
|
-
await this.resolveCommittedLogicalSteering(committedSteering, initialOutcome);
|
|
798
|
-
if (logicalTurn.cancellationRequested) {
|
|
799
|
-
return await this.cancelLogicalTurn();
|
|
800
|
-
}
|
|
801
|
-
if (terminalOutcome.status !== "completed" || this.goal?.status !== "active") {
|
|
802
|
-
return goalRootHistoryEntryId ? terminalOutcome : initialOutcome;
|
|
803
|
-
}
|
|
804
|
-
if (logicalTurn.pendingSteering.length > 0) {
|
|
805
|
-
continue;
|
|
806
|
-
}
|
|
807
|
-
await this.session.commitUserText(buildGoalContinuationText(this.goal));
|
|
808
|
-
}
|
|
809
|
-
catch (error) {
|
|
810
|
-
try {
|
|
811
|
-
const outcome = await this.cleanupFailedTurn(rootUserMessage.id, error);
|
|
812
|
-
await this.resolveCommittedLogicalSteering(committedSteering, outcome);
|
|
813
|
-
return outcome;
|
|
814
|
-
}
|
|
815
|
-
catch {
|
|
816
|
-
this.rejectCommittedLogicalSteering(committedSteering, error);
|
|
817
|
-
throw error;
|
|
818
|
-
}
|
|
652
|
+
if (logicalTurn.cancellationRequested)
|
|
653
|
+
return abortedTurnOutcome();
|
|
654
|
+
try {
|
|
655
|
+
const result = await this.runtime.runTurn();
|
|
656
|
+
if (result.terminalResult.aborted && this.draftAssistantMessage) {
|
|
657
|
+
await this.interruptDraftAssistantMessage();
|
|
819
658
|
}
|
|
659
|
+
await this.enqueueSnapshotResetIfChanged("assistant-message");
|
|
660
|
+
return logicalTurn.cancellationRequested
|
|
661
|
+
? abortedTurnOutcome()
|
|
662
|
+
: turnOutcomeFromResult(result, result.finalMessage);
|
|
663
|
+
}
|
|
664
|
+
catch (error) {
|
|
665
|
+
return await this.cleanupFailedTurn(rootUserMessage.id, error);
|
|
820
666
|
}
|
|
821
667
|
}
|
|
822
668
|
interruptTurn() {
|
|
@@ -869,29 +715,22 @@ class LocalHostedSessionHandle {
|
|
|
869
715
|
const turn = turnOutcomeFromResult(association.result, association.result.finalMessage);
|
|
870
716
|
await this.settleTurn(association.historyEntryId, turn);
|
|
871
717
|
return { userHistoryEntryId: association.historyEntryId, turn };
|
|
718
|
+
}, async (error) => {
|
|
719
|
+
const association = await submission.applied;
|
|
720
|
+
await this.settleTurn(association.historyEntryId, {
|
|
721
|
+
status: "failed",
|
|
722
|
+
stopReason: "error",
|
|
723
|
+
errorMessage: formatErrorDiagnostic(error),
|
|
724
|
+
});
|
|
725
|
+
throw error;
|
|
872
726
|
}),
|
|
873
727
|
};
|
|
874
728
|
}
|
|
875
|
-
|
|
876
|
-
if (!logicalTurn || this.goal?.status !== "active") {
|
|
877
|
-
throw new Error("cannot steer without an active turn");
|
|
878
|
-
}
|
|
879
|
-
return this.bufferLogicalSteering(logicalTurn, text);
|
|
729
|
+
throw new Error("cannot steer without an active turn");
|
|
880
730
|
}
|
|
881
731
|
cancelSteering() {
|
|
882
732
|
this.assertActive();
|
|
883
|
-
|
|
884
|
-
const logicalTurn = this.activeLogicalTurn;
|
|
885
|
-
if (!logicalTurn) {
|
|
886
|
-
return cancelled;
|
|
887
|
-
}
|
|
888
|
-
const buffered = logicalTurn.pendingSteering.splice(0);
|
|
889
|
-
const error = new Error("steering submission was cancelled");
|
|
890
|
-
for (const submission of buffered) {
|
|
891
|
-
submission.rejectApplied(error);
|
|
892
|
-
submission.rejectResult(error);
|
|
893
|
-
}
|
|
894
|
-
return [...cancelled, ...buffered.map(({ id, text }) => ({ id, text }))];
|
|
733
|
+
return this.runtime.cancelSteering();
|
|
895
734
|
}
|
|
896
735
|
async exec(options) {
|
|
897
736
|
return await this.runExec(options.execId, options.signal, async (signal) => {
|
|
@@ -1270,123 +1109,6 @@ class LocalHostedSessionHandle {
|
|
|
1270
1109
|
throw new AggregateError(errors, "failed to dispose hosted session");
|
|
1271
1110
|
}
|
|
1272
1111
|
}
|
|
1273
|
-
buildNewGoal(objective) {
|
|
1274
|
-
this.assertActive();
|
|
1275
|
-
if (this.goal) {
|
|
1276
|
-
throw new Error("a goal already exists; clear it before creating another");
|
|
1277
|
-
}
|
|
1278
|
-
const normalized = objective.trim();
|
|
1279
|
-
if (!normalized) {
|
|
1280
|
-
throw new Error("goal objective must not be empty");
|
|
1281
|
-
}
|
|
1282
|
-
return { objective: normalized, status: "active" };
|
|
1283
|
-
}
|
|
1284
|
-
async setGoal(goal) {
|
|
1285
|
-
await this.enqueueMutation(async () => {
|
|
1286
|
-
await this.emitPatch("goal", [{ type: "goal.set", goal: structuredClone(goal) }]);
|
|
1287
|
-
this.goal = structuredClone(goal);
|
|
1288
|
-
});
|
|
1289
|
-
}
|
|
1290
|
-
async blockActiveGoal() {
|
|
1291
|
-
if (this.goal?.status === "active") {
|
|
1292
|
-
await this.setGoal({ ...this.goal, status: "blocked" });
|
|
1293
|
-
}
|
|
1294
|
-
}
|
|
1295
|
-
bufferLogicalSteering(logicalTurn, text) {
|
|
1296
|
-
const normalized = text.trim();
|
|
1297
|
-
if (!normalized) {
|
|
1298
|
-
throw new Error("steering input must not be empty");
|
|
1299
|
-
}
|
|
1300
|
-
let resolveApplied;
|
|
1301
|
-
let rejectApplied;
|
|
1302
|
-
const applied = new Promise((resolve, reject) => {
|
|
1303
|
-
resolveApplied = resolve;
|
|
1304
|
-
rejectApplied = reject;
|
|
1305
|
-
});
|
|
1306
|
-
let resolveResult;
|
|
1307
|
-
let rejectResult;
|
|
1308
|
-
const result = new Promise((resolve, reject) => {
|
|
1309
|
-
resolveResult = resolve;
|
|
1310
|
-
rejectResult = reject;
|
|
1311
|
-
});
|
|
1312
|
-
const submission = {
|
|
1313
|
-
id: `logical-steering-${randomUUID()}`,
|
|
1314
|
-
text: normalized,
|
|
1315
|
-
applied,
|
|
1316
|
-
result,
|
|
1317
|
-
resolveApplied,
|
|
1318
|
-
resolveResult,
|
|
1319
|
-
rejectApplied,
|
|
1320
|
-
rejectResult,
|
|
1321
|
-
};
|
|
1322
|
-
logicalTurn.pendingSteering.push(submission);
|
|
1323
|
-
return { id: submission.id, applied, result };
|
|
1324
|
-
}
|
|
1325
|
-
async commitBufferedLogicalSteering(logicalTurn) {
|
|
1326
|
-
const submissions = logicalTurn.pendingSteering.splice(0);
|
|
1327
|
-
if (submissions.length === 0) {
|
|
1328
|
-
throw new Error("cannot commit empty logical steering");
|
|
1329
|
-
}
|
|
1330
|
-
try {
|
|
1331
|
-
const goal = this.goal;
|
|
1332
|
-
if (goal?.status !== "active") {
|
|
1333
|
-
throw new Error("cannot commit logical steering without an active goal");
|
|
1334
|
-
}
|
|
1335
|
-
const historyEntryId = this.createTurnHistoryEntryId();
|
|
1336
|
-
this.pendingAcceptedTurnHistoryEntryIds.add(historyEntryId);
|
|
1337
|
-
try {
|
|
1338
|
-
await this.session.commitUserText(prependGoalPolicy(formatSteeringUserMessage(submissions.map((submission) => submission.text)), goal), { historyEntryId });
|
|
1339
|
-
}
|
|
1340
|
-
finally {
|
|
1341
|
-
this.pendingAcceptedTurnHistoryEntryIds.delete(historyEntryId);
|
|
1342
|
-
}
|
|
1343
|
-
for (const submission of submissions) {
|
|
1344
|
-
submission.resolveApplied({ userHistoryEntryId: historyEntryId });
|
|
1345
|
-
}
|
|
1346
|
-
return { historyEntryId, submissions };
|
|
1347
|
-
}
|
|
1348
|
-
catch (error) {
|
|
1349
|
-
const steeringError = error instanceof Error ? error : new Error(String(error));
|
|
1350
|
-
for (const submission of submissions) {
|
|
1351
|
-
submission.rejectApplied(steeringError);
|
|
1352
|
-
submission.rejectResult(steeringError);
|
|
1353
|
-
}
|
|
1354
|
-
throw error;
|
|
1355
|
-
}
|
|
1356
|
-
}
|
|
1357
|
-
async resolveCommittedLogicalSteering(committed, turn) {
|
|
1358
|
-
for (const { historyEntryId, submissions } of committed) {
|
|
1359
|
-
await this.settleTurn(historyEntryId, turn);
|
|
1360
|
-
for (const submission of submissions) {
|
|
1361
|
-
submission.resolveResult({ userHistoryEntryId: historyEntryId, turn });
|
|
1362
|
-
}
|
|
1363
|
-
}
|
|
1364
|
-
}
|
|
1365
|
-
rejectCommittedLogicalSteering(committed, error) {
|
|
1366
|
-
const steeringError = error instanceof Error ? error : new Error(String(error));
|
|
1367
|
-
for (const { submissions } of committed) {
|
|
1368
|
-
for (const submission of submissions) {
|
|
1369
|
-
submission.rejectResult(steeringError);
|
|
1370
|
-
}
|
|
1371
|
-
}
|
|
1372
|
-
}
|
|
1373
|
-
rejectBufferedLogicalSteering(logicalTurn, error) {
|
|
1374
|
-
for (const submission of logicalTurn.pendingSteering.splice(0)) {
|
|
1375
|
-
submission.rejectApplied(error);
|
|
1376
|
-
submission.rejectResult(error);
|
|
1377
|
-
}
|
|
1378
|
-
}
|
|
1379
|
-
async cancelLogicalTurn(committedSteering = []) {
|
|
1380
|
-
const outcome = abortedTurnOutcome();
|
|
1381
|
-
await this.enqueueMutation(async () => {
|
|
1382
|
-
if (this.goal?.status === "active") {
|
|
1383
|
-
this.goal = { ...this.goal, status: "blocked" };
|
|
1384
|
-
}
|
|
1385
|
-
await this.emitSnapshotResetIfChanged("assistant-message");
|
|
1386
|
-
});
|
|
1387
|
-
await this.resolveCommittedLogicalSteering(committedSteering, outcome);
|
|
1388
|
-
return outcome;
|
|
1389
|
-
}
|
|
1390
1112
|
async commitSnapshot(options = {}) {
|
|
1391
1113
|
this.assertNotDisposed();
|
|
1392
1114
|
this.reconcileProjections(options);
|
|
@@ -1514,7 +1236,6 @@ class LocalHostedSessionHandle {
|
|
|
1514
1236
|
: {}),
|
|
1515
1237
|
},
|
|
1516
1238
|
lifecycle: this.activeTurnPromise || this.runtime.isTurnRunning ? "running" : "idle",
|
|
1517
|
-
goal: structuredClone(this.goal),
|
|
1518
1239
|
costTotal: this.costTotal,
|
|
1519
1240
|
settings: {
|
|
1520
1241
|
personaId: this.runtime.persona.id,
|
|
@@ -1695,7 +1416,6 @@ class LocalHostedSessionHandle {
|
|
|
1695
1416
|
return await mutation();
|
|
1696
1417
|
}
|
|
1697
1418
|
catch (error) {
|
|
1698
|
-
this.goal = structuredClone(this.committedSnapshot.goal);
|
|
1699
1419
|
this.restoreProtocolState(this.committedSnapshot);
|
|
1700
1420
|
throw error;
|
|
1701
1421
|
}
|
|
@@ -1934,7 +1654,6 @@ class LocalHostedSessionHandle {
|
|
|
1934
1654
|
return;
|
|
1935
1655
|
}
|
|
1936
1656
|
case "user_message": {
|
|
1937
|
-
const pendingGoal = this.pendingGoalCommit;
|
|
1938
1657
|
const acceptsTurn = this.pendingAcceptedTurnHistoryEntryIds.has(event.historyEntryId) ||
|
|
1939
1658
|
event.origin === "steering";
|
|
1940
1659
|
const turn = acceptsTurn
|
|
@@ -1949,9 +1668,6 @@ class LocalHostedSessionHandle {
|
|
|
1949
1668
|
const timelineItem = this.appendMessageTimelineItem(event.historyEntryId, event.message.timestamp);
|
|
1950
1669
|
await this.emitPatch("user-message", [
|
|
1951
1670
|
this.agentStateChange(),
|
|
1952
|
-
...(pendingGoal
|
|
1953
|
-
? [{ type: "goal.set", goal: structuredClone(pendingGoal) }]
|
|
1954
|
-
: []),
|
|
1955
1671
|
...(turn ? [{ type: "turn.set", turn }] : []),
|
|
1956
1672
|
{
|
|
1957
1673
|
type: "message.append",
|
|
@@ -1968,9 +1684,6 @@ class LocalHostedSessionHandle {
|
|
|
1968
1684
|
this.pendingAcceptedTurnHistoryEntryIds.delete(event.historyEntryId);
|
|
1969
1685
|
}
|
|
1970
1686
|
await this.recordHistoryFailure(this.history.append(this.sessionId, [userHistoryEntry(event.historyEntryId, event.message)], this.historyRemote));
|
|
1971
|
-
if (pendingGoal && this.pendingGoalCommit === pendingGoal) {
|
|
1972
|
-
this.pendingGoalCommit = undefined;
|
|
1973
|
-
}
|
|
1974
1687
|
return;
|
|
1975
1688
|
}
|
|
1976
1689
|
case "history_rewound": {
|
|
@@ -2497,9 +2210,6 @@ class LocalHostedSessionHandle {
|
|
|
2497
2210
|
reason: "runtime-error",
|
|
2498
2211
|
message: diagnostic,
|
|
2499
2212
|
});
|
|
2500
|
-
if (this.goal?.status === "active") {
|
|
2501
|
-
this.goal = { ...this.goal, status: "blocked" };
|
|
2502
|
-
}
|
|
2503
2213
|
const timestamp = Date.now();
|
|
2504
2214
|
for (const [id, tool] of this.tools) {
|
|
2505
2215
|
if (tool.status !== "queued" && tool.status !== "running") {
|
|
@@ -2639,10 +2349,6 @@ function normalizeRecoveredSnapshot(snapshot) {
|
|
|
2639
2349
|
};
|
|
2640
2350
|
}
|
|
2641
2351
|
}
|
|
2642
|
-
if (recovered.goal?.status === "active") {
|
|
2643
|
-
changed = true;
|
|
2644
|
-
recovered.goal.status = "blocked";
|
|
2645
|
-
}
|
|
2646
2352
|
if (Object.keys(recovered.agents).length > 0) {
|
|
2647
2353
|
changed = true;
|
|
2648
2354
|
recovered.agents = {};
|