@herbertgao/pi-extensions 2026.10.6 → 2026.10.7
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/README.md +9 -13
- package/THIRD_PARTY_NOTICES.md +1 -53
- package/extensions/clef-format.mjs +113 -0
- package/extensions/clef.mjs +112 -0
- package/node_modules/@dietrichgebert/ponytail/.opencode/command/ponytail-debt.md +1 -1
- package/node_modules/@dietrichgebert/ponytail/.opencode/plugins/ponytail.mjs +30 -6
- package/node_modules/@dietrichgebert/ponytail/.qoder-plugin/plugin.json +1 -1
- package/node_modules/@dietrichgebert/ponytail/README.md +5 -1
- package/node_modules/@dietrichgebert/ponytail/hooks/claude-codex-hooks.json +3 -3
- package/node_modules/@dietrichgebert/ponytail/hooks/copilot-hooks.json +4 -4
- package/node_modules/@dietrichgebert/ponytail/hooks/ponytail-activate.js +158 -127
- package/node_modules/@dietrichgebert/ponytail/hooks/ponytail-config.js +5 -0
- package/node_modules/@dietrichgebert/ponytail/hooks/ponytail-map.js +8 -3
- package/node_modules/@dietrichgebert/ponytail/hooks/ponytail-runtime.js +14 -8
- package/node_modules/@dietrichgebert/ponytail/package.json +1 -1
- package/node_modules/@dietrichgebert/ponytail/pi-extension/index.js +16 -3
- package/node_modules/@dietrichgebert/ponytail/scripts/cursor-hooks.js +13 -3
- package/node_modules/@dietrichgebert/ponytail/scripts/uninstall.js +3 -2
- package/node_modules/@dietrichgebert/ponytail/skills/ponytail-debt/SKILL.md +3 -3
- package/node_modules/@herbertgao/pi-agency/package.json +2 -2
- package/node_modules/@herbertgao/pi-bark/package.json +2 -2
- package/node_modules/@herbertgao/pi-cc-extensions/README.en.md +1 -1
- package/node_modules/@herbertgao/pi-cc-extensions/README.md +1 -1
- package/node_modules/@herbertgao/pi-cc-extensions/extensions/feature/context.ts +283 -136
- package/node_modules/@herbertgao/pi-cc-extensions/extensions/renderer/compact-mode.ts +90 -22
- package/node_modules/@herbertgao/pi-cc-extensions/extensions/renderer/mouse/interaction.ts +66 -26
- package/node_modules/@herbertgao/pi-cc-extensions/package.json +5 -5
- package/node_modules/@herbertgao/pi-subagents/CHANGELOG.md +8 -0
- package/node_modules/@herbertgao/pi-subagents/docs/packages.md +211 -0
- package/node_modules/@herbertgao/pi-subagents/docs/rpc.md +61 -63
- package/node_modules/@herbertgao/pi-subagents/docs/workflows.md +24 -16
- package/node_modules/@herbertgao/pi-subagents/package.json +5 -5
- package/node_modules/@herbertgao/pi-subagents/src/agent-file-toggle.ts +51 -14
- package/node_modules/@herbertgao/pi-subagents/src/agent-manager.ts +123 -55
- package/node_modules/@herbertgao/pi-subagents/src/agent-runner.ts +144 -13
- package/node_modules/@herbertgao/pi-subagents/src/agent-source-badge.ts +78 -0
- package/node_modules/@herbertgao/pi-subagents/src/completion-outbox.ts +122 -0
- package/node_modules/@herbertgao/pi-subagents/src/custom-agents.ts +171 -79
- package/node_modules/@herbertgao/pi-subagents/src/index.ts +597 -296
- package/node_modules/@herbertgao/pi-subagents/src/package-resources.ts +724 -0
- package/node_modules/@herbertgao/pi-subagents/src/schedule.ts +1 -1
- package/node_modules/@herbertgao/pi-subagents/src/settings.ts +66 -0
- package/node_modules/@herbertgao/pi-subagents/src/types.ts +26 -4
- package/node_modules/@herbertgao/pi-subagents/src/ui/agent-widget.ts +2 -0
- package/node_modules/@herbertgao/pi-subagents/src/ui/conversation-viewer.ts +354 -32
- package/node_modules/@herbertgao/pi-subagents/src/ui/fleet-list.ts +33 -15
- package/node_modules/@herbertgao/pi-subagents/src/workflow/host.ts +6 -0
- package/node_modules/@herbertgao/pi-subagents/src/workflow/saved.ts +48 -2
- package/node_modules/@herbertgao/sol-pi/package.json +2 -2
- package/node_modules/@juicesharp/rpiv-ask-user-question/README.md +3 -3
- package/node_modules/@juicesharp/rpiv-ask-user-question/ask-user-question.ts +89 -39
- package/node_modules/@juicesharp/rpiv-ask-user-question/docs/configuration.md +1 -1
- package/node_modules/@juicesharp/rpiv-ask-user-question/docs/hosts.md +4 -4
- package/node_modules/@juicesharp/rpiv-ask-user-question/docs/keyboard.md +56 -23
- package/node_modules/@juicesharp/rpiv-ask-user-question/docs/tool-schema.md +6 -3
- package/node_modules/@juicesharp/rpiv-ask-user-question/locales/de.json +3 -1
- package/node_modules/@juicesharp/rpiv-ask-user-question/locales/en.json +3 -1
- package/node_modules/@juicesharp/rpiv-ask-user-question/locales/es.json +3 -1
- package/node_modules/@juicesharp/rpiv-ask-user-question/locales/fr.json +3 -1
- package/node_modules/@juicesharp/rpiv-ask-user-question/locales/pt-BR.json +3 -1
- package/node_modules/@juicesharp/rpiv-ask-user-question/locales/pt.json +3 -1
- package/node_modules/@juicesharp/rpiv-ask-user-question/locales/ru.json +3 -1
- package/node_modules/@juicesharp/rpiv-ask-user-question/locales/uk.json +3 -1
- package/node_modules/@juicesharp/rpiv-ask-user-question/locales/zh.json +3 -1
- package/node_modules/@juicesharp/rpiv-ask-user-question/package.json +5 -2
- package/node_modules/@juicesharp/rpiv-ask-user-question/presentation.ts +122 -0
- package/node_modules/@juicesharp/rpiv-ask-user-question/rpc-fallback.ts +73 -36
- package/node_modules/@juicesharp/rpiv-ask-user-question/state/build-questionnaire.ts +10 -1
- package/node_modules/@juicesharp/rpiv-ask-user-question/state/key-router.ts +15 -13
- package/node_modules/@juicesharp/rpiv-ask-user-question/state/questionnaire-session.ts +5 -1
- package/node_modules/@juicesharp/rpiv-ask-user-question/state/selectors/derivations.ts +15 -0
- package/node_modules/@juicesharp/rpiv-ask-user-question/state/selectors/projections.ts +4 -1
- package/node_modules/@juicesharp/rpiv-ask-user-question/state/state-reducer.ts +29 -18
- package/node_modules/@juicesharp/rpiv-ask-user-question/state/state.ts +1 -1
- package/node_modules/@juicesharp/rpiv-ask-user-question/tool/format-answer.ts +5 -2
- package/node_modules/@juicesharp/rpiv-ask-user-question/tool/normalize-params.ts +46 -0
- package/node_modules/@juicesharp/rpiv-ask-user-question/tool/response-envelope.ts +19 -8
- package/node_modules/@juicesharp/rpiv-ask-user-question/tool/types.ts +9 -2
- package/node_modules/@juicesharp/rpiv-ask-user-question/view/components/multi-select-view.ts +4 -2
- package/node_modules/@juicesharp/rpiv-ask-user-question/view/components/preview/preview-block-renderer.ts +56 -25
- package/node_modules/@juicesharp/rpiv-ask-user-question/view/components/preview/preview-pane.ts +131 -46
- package/node_modules/@juicesharp/rpiv-ask-user-question/view/dialog-builder.ts +94 -106
- package/node_modules/@juicesharp/rpiv-ask-user-question/view/dialog-copy.ts +51 -0
- package/node_modules/@juicesharp/rpiv-ask-user-question/view/scroll-window.ts +73 -0
- package/node_modules/@juicesharp/rpiv-ask-user-question/view/tab-content-strategy.ts +31 -10
- package/node_modules/@pi-plugins/fast-mode/dist/index.d.mts.map +1 -1
- package/node_modules/@pi-plugins/fast-mode/dist/index.mjs +474 -93
- package/node_modules/@pi-plugins/fast-mode/dist/index.mjs.map +1 -1
- package/node_modules/@pi-plugins/fast-mode/package.json +1 -1
- package/node_modules/pi-lens/CHANGELOG.md +88 -0
- package/node_modules/pi-lens/config/dependency-cruiser-eager-allowlist.json +3 -1
- package/node_modules/pi-lens/dist/{chunk-BJF25SUG.js → chunk-23WOO7TX.js} +11 -10
- package/node_modules/pi-lens/dist/{chunk-WATC3IQR.js → chunk-2B73ZPOK.js} +3 -3
- package/node_modules/pi-lens/dist/{chunk-N2IRDBZI.js → chunk-2BBLFX75.js} +101 -11
- package/node_modules/pi-lens/dist/{chunk-TA5L5KWQ.js → chunk-2CD5RS6M.js} +2 -2
- package/node_modules/pi-lens/dist/{chunk-3TTPKMEF.js → chunk-2VUQMUMT.js} +38 -37
- package/node_modules/pi-lens/dist/{chunk-5JHXUETW.js → chunk-3EFKIGZN.js} +3 -3
- package/node_modules/pi-lens/dist/chunk-3JNKMP3B.js +17 -0
- package/node_modules/pi-lens/dist/{chunk-6P54TMWL.js → chunk-3VPVG5SU.js} +6 -6
- package/node_modules/pi-lens/dist/{chunk-ZETYB3XG.js → chunk-3W7IEVVL.js} +44 -28
- package/node_modules/pi-lens/dist/chunk-3YN6V5TV.js +85 -0
- package/node_modules/pi-lens/dist/chunk-466Z26MG.js +30 -0
- package/node_modules/pi-lens/dist/{chunk-PCHDGUKT.js → chunk-4UNXBNE2.js} +12 -11
- package/node_modules/pi-lens/dist/{chunk-J7WJZ6W7.js → chunk-4W4VLAPJ.js} +12 -11
- package/node_modules/pi-lens/dist/{chunk-F5VLZHUW.js → chunk-52FUZI6K.js} +4 -2
- package/node_modules/pi-lens/dist/{chunk-H5EV3VMF.js → chunk-5NGR67U5.js} +2 -2
- package/node_modules/pi-lens/dist/{chunk-CBD2B5CP.js → chunk-5UCAH366.js} +21 -20
- package/node_modules/pi-lens/dist/{chunk-BHWHXMQ2.js → chunk-67WMNWEE.js} +9 -8
- package/node_modules/pi-lens/dist/{chunk-USHG4DLH.js → chunk-6C7JWPCP.js} +7 -7
- package/node_modules/pi-lens/dist/{chunk-VPWKF3GN.js → chunk-6GFRNVYR.js} +11 -10
- package/node_modules/pi-lens/dist/{chunk-3JL6IFD7.js → chunk-6SDEP3AJ.js} +9 -8
- package/node_modules/pi-lens/dist/{chunk-NJF2X5XF.js → chunk-6STA6Z7I.js} +19 -17
- package/node_modules/pi-lens/dist/{chunk-KJCWXUUS.js → chunk-724UL2TJ.js} +6 -4
- package/node_modules/pi-lens/dist/{chunk-MQA2YBAH.js → chunk-76MWC2K6.js} +3 -3
- package/node_modules/pi-lens/dist/{chunk-YLN4K6WD.js → chunk-77M37OKR.js} +10 -8
- package/node_modules/pi-lens/dist/{chunk-XHSCVSOL.js → chunk-7DYBLXYA.js} +3 -3
- package/node_modules/pi-lens/dist/{chunk-OC7LYAU5.js → chunk-AB3YYG6N.js} +24 -10
- package/node_modules/pi-lens/dist/{chunk-LD7WFTRX.js → chunk-ACXEQZOU.js} +16 -16
- package/node_modules/pi-lens/dist/{chunk-VSMJK3ZJ.js → chunk-AOHZU2BM.js} +1 -1
- package/node_modules/pi-lens/dist/{chunk-T4QZ6FEH.js → chunk-AW7R2GWG.js} +65 -8
- package/node_modules/pi-lens/dist/{chunk-GAYGGICG.js → chunk-BKE7E7TC.js} +10 -9
- package/node_modules/pi-lens/dist/{chunk-EUT3B22Y.js → chunk-BRGDSBJE.js} +13 -12
- package/node_modules/pi-lens/dist/{chunk-T54VJRAD.js → chunk-C34ZXZ7O.js} +55 -11
- package/node_modules/pi-lens/dist/{chunk-UGSMCQ4D.js → chunk-CHOW74WE.js} +1 -1
- package/node_modules/pi-lens/dist/{chunk-H2W2AXD3.js → chunk-CMMHNUZ2.js} +66 -58
- package/node_modules/pi-lens/dist/chunk-CSHFH5IN.js +17 -0
- package/node_modules/pi-lens/dist/chunk-EC47DWFA.js +56 -0
- package/node_modules/pi-lens/dist/{chunk-KJN4IOEJ.js → chunk-EJIUXPBX.js} +1 -1
- package/node_modules/pi-lens/dist/{chunk-IQZXOZ7S.js → chunk-EU63SDCG.js} +720 -334
- package/node_modules/pi-lens/dist/{chunk-LNOMA3MP.js → chunk-FCSOVF55.js} +107 -3
- package/node_modules/pi-lens/dist/{chunk-CFYISHUW.js → chunk-FLKWCIZH.js} +8 -5
- package/node_modules/pi-lens/dist/{chunk-OYTMZXRF.js → chunk-FMSO6RDZ.js} +16 -14
- package/node_modules/pi-lens/dist/{chunk-IUKPRZER.js → chunk-GAEGEPOC.js} +2 -2
- package/node_modules/pi-lens/dist/{chunk-6XX5HCLK.js → chunk-GBPP5P7X.js} +4 -4
- package/node_modules/pi-lens/dist/{chunk-TQFBZVCG.js → chunk-GXW6K4YJ.js} +1 -1
- package/node_modules/pi-lens/dist/{chunk-ZZUFZUQZ.js → chunk-H6MF6EVN.js} +331 -107
- package/node_modules/pi-lens/dist/{chunk-3JSEWUWI.js → chunk-IBGIOBEE.js} +3 -3
- package/node_modules/pi-lens/dist/chunk-IZSHAIJ7.js +26 -0
- package/node_modules/pi-lens/dist/{chunk-7ELY2CSM.js → chunk-JAU72XNY.js} +16 -14
- package/node_modules/pi-lens/dist/chunk-JMYYOTQG.js +77 -0
- package/node_modules/pi-lens/dist/{chunk-ELVWJYRV.js → chunk-JSQFTSC6.js} +12 -11
- package/node_modules/pi-lens/dist/{chunk-J6DFZDFA.js → chunk-KBG47GHP.js} +4 -4
- package/node_modules/pi-lens/dist/chunk-KDERNTCQ.js +28 -0
- package/node_modules/pi-lens/dist/chunk-KSX3TXSZ.js +69 -0
- package/node_modules/pi-lens/dist/{chunk-XGUL4SLQ.js → chunk-L3BLXZG7.js} +2 -2
- package/node_modules/pi-lens/dist/chunk-LOP6GRPH.js +31 -0
- package/node_modules/pi-lens/dist/{chunk-MTDRLSI7.js → chunk-M6HSLBWY.js} +1064 -986
- package/node_modules/pi-lens/dist/chunk-MQLUAEOC.js +162 -0
- package/node_modules/pi-lens/dist/{chunk-3MRXIJ6I.js → chunk-MRXKYPCS.js} +2 -2
- package/node_modules/pi-lens/dist/{chunk-D65GOCJB.js → chunk-MXGY6KPT.js} +19 -16
- package/node_modules/pi-lens/dist/{chunk-G3RLJYA2.js → chunk-N2H3ZPZY.js} +47 -1
- package/node_modules/pi-lens/dist/{chunk-HREZQCT3.js → chunk-N3X6Q4YT.js} +3 -3
- package/node_modules/pi-lens/dist/{chunk-HSIRMK2D.js → chunk-OCAGUNBC.js} +15 -15
- package/node_modules/pi-lens/dist/{chunk-ZOEYVXSV.js → chunk-OXXKQCSV.js} +6 -6
- package/node_modules/pi-lens/dist/{chunk-S6AMWKPC.js → chunk-P7266HLM.js} +2 -2
- package/node_modules/pi-lens/dist/{chunk-64LU2OVH.js → chunk-PHDMFAKM.js} +12 -2
- package/node_modules/pi-lens/dist/{chunk-IMSQR4WO.js → chunk-PNQDPDRC.js} +1 -1
- package/node_modules/pi-lens/dist/{chunk-IUR76K6A.js → chunk-Q7DUK4LX.js} +5 -5
- package/node_modules/pi-lens/dist/{chunk-CULQYFLU.js → chunk-QGQ5CCCG.js} +2 -2
- package/node_modules/pi-lens/dist/{chunk-UEAHAMEI.js → chunk-QHJ6DQ2R.js} +11 -11
- package/node_modules/pi-lens/dist/{chunk-BNKLYOOO.js → chunk-QILIYSJF.js} +1 -1
- package/node_modules/pi-lens/dist/{chunk-VYKKMYVT.js → chunk-QOBUHWHX.js} +11 -6
- package/node_modules/pi-lens/dist/{chunk-3PNFWVHT.js → chunk-QQNQ7SJW.js} +2 -75
- package/node_modules/pi-lens/dist/{chunk-7M4T5N3V.js → chunk-R3PCY3YS.js} +14 -13
- package/node_modules/pi-lens/dist/{chunk-MGIWSROG.js → chunk-RPLINGVB.js} +7 -7
- package/node_modules/pi-lens/dist/{chunk-CMU4RMJB.js → chunk-RWWYJ623.js} +10 -1
- package/node_modules/pi-lens/dist/{chunk-3FERWMCH.js → chunk-RXCOMYPY.js} +27 -26
- package/node_modules/pi-lens/dist/{chunk-7BX5DWSA.js → chunk-SAEFPSB6.js} +11 -11
- package/node_modules/pi-lens/dist/{chunk-N7YNJE5R.js → chunk-SQ4TVJBR.js} +10 -10
- package/node_modules/pi-lens/dist/{chunk-DMS52BEP.js → chunk-SS36ZX4J.js} +9 -7
- package/node_modules/pi-lens/dist/{chunk-JONGANYH.js → chunk-T6CPIZNT.js} +32 -30
- package/node_modules/pi-lens/dist/{chunk-6UYA642J.js → chunk-TYM6OUIT.js} +13 -12
- package/node_modules/pi-lens/dist/{chunk-ALQRYH6O.js → chunk-UXGETRP4.js} +13 -12
- package/node_modules/pi-lens/dist/{chunk-FGALODG3.js → chunk-UZ3TUTRV.js} +1 -1
- package/node_modules/pi-lens/dist/{chunk-J3FZR3YY.js → chunk-VCHXCQFG.js} +3 -3
- package/node_modules/pi-lens/dist/{chunk-3P4PF2BX.js → chunk-VCO24T4L.js} +34 -22
- package/node_modules/pi-lens/dist/{chunk-O7HZX7CA.js → chunk-VRZP76YM.js} +1 -1
- package/node_modules/pi-lens/dist/{chunk-VZHJS6DR.js → chunk-VSSBEUFT.js} +16 -15
- package/node_modules/pi-lens/dist/{chunk-U52SAGRM.js → chunk-VWCXW2E7.js} +1 -1
- package/node_modules/pi-lens/dist/{chunk-WW5BLB74.js → chunk-WOA4LN2R.js} +2 -2
- package/node_modules/pi-lens/dist/{chunk-ZMOMPX2Z.js → chunk-WU567RSC.js} +11 -10
- package/node_modules/pi-lens/dist/{chunk-N77WFUL7.js → chunk-XAGLWMJ4.js} +23 -22
- package/node_modules/pi-lens/dist/{chunk-WSEWKCXU.js → chunk-XCJN5IJU.js} +4 -4
- package/node_modules/pi-lens/dist/{chunk-IR6XFA5P.js → chunk-XIJZVPD5.js} +16 -14
- package/node_modules/pi-lens/dist/{chunk-OYOB3ZFG.js → chunk-XMSXXAHW.js} +2 -2
- package/node_modules/pi-lens/dist/{chunk-34OCDWOS.js → chunk-XTMJ7XDT.js} +1 -1
- package/node_modules/pi-lens/dist/{chunk-Z6BB4JLQ.js → chunk-XVF2VVXP.js} +5 -3
- package/node_modules/pi-lens/dist/{chunk-AFZYMAIV.js → chunk-YIUAVF7E.js} +37 -35
- package/node_modules/pi-lens/dist/{chunk-NFXP47RV.js → chunk-YSZNHOBY.js} +85 -31
- package/node_modules/pi-lens/dist/{chunk-V5MEBST3.js → chunk-YYOIQFRS.js} +21 -21
- package/node_modules/pi-lens/dist/chunk-Z527N6YQ.js +28 -0
- package/node_modules/pi-lens/dist/{chunk-D6YF5HKX.js → chunk-ZANLILYD.js} +22 -2
- package/node_modules/pi-lens/dist/{chunk-2UMYMRI3.js → chunk-ZGDGW2V3.js} +2 -2
- package/node_modules/pi-lens/dist/{chunk-6B5I6ICN.js → chunk-ZHFZWTZV.js} +12 -11
- package/node_modules/pi-lens/dist/{chunk-OEX24ECI.js → chunk-ZWFS3OEF.js} +51 -41
- package/node_modules/pi-lens/dist/{chunk-AXKPQ6ZI.js → chunk-ZXYDQ3TZ.js} +5 -5
- package/node_modules/pi-lens/dist/index.js +73783 -71033
- package/node_modules/pi-lens/dist/mcp/analyze-cli.js +18 -8
- package/node_modules/pi-lens/dist/mcp/cli.js +48 -37
- package/node_modules/pi-lens/dist/mcp/server.js +568 -397
- package/node_modules/pi-lens/dist/mcp/worker.js +67 -55
- package/node_modules/pi-lens/dist/probes/installer.js +20 -19
- package/node_modules/pi-lens/docs/astplayground.md +1 -1
- package/node_modules/pi-lens/docs/configuration.md +29 -0
- package/node_modules/pi-lens/docs/dependencies.md +3 -0
- package/node_modules/pi-lens/docs/features.md +2 -2
- package/node_modules/pi-lens/docs/globalconfig.md +2 -0
- package/node_modules/pi-lens/docs/language-coverage.md +2 -1
- package/node_modules/pi-lens/docs/lsp-capability-matrix.md +29 -7
- package/node_modules/pi-lens/docs/lsp-idle-eviction.md +38 -47
- package/node_modules/pi-lens/docs/pi-lens-fixer.md +4 -0
- package/node_modules/pi-lens/docs/pi-lens-merge-policy.md +17 -4
- package/node_modules/pi-lens/docs/pi-lens-retro.md +2 -1
- package/node_modules/pi-lens/docs/pi-lens-reviewer.md +18 -0
- package/node_modules/pi-lens/docs/pi-lens-subagent.md +7 -0
- package/node_modules/pi-lens/docs/real-harness.md +17 -0
- package/node_modules/pi-lens/docs/schema/pi-lens-config-v1.json +37 -2
- package/node_modules/pi-lens/docs/servercapabilities.md +15 -4
- package/node_modules/pi-lens/docs/settings.md +2 -1
- package/node_modules/pi-lens/package.json +1 -1
- package/node_modules/pi-provider-qoder/dist/index.js +30 -2
- package/node_modules/pi-provider-qoder/package.json +1 -1
- package/node_modules/pi-web-access/CHANGELOG.md +50 -0
- package/node_modules/pi-web-access/README.md +13 -7
- package/node_modules/pi-web-access/brave.ts +20 -2
- package/node_modules/pi-web-access/content-find.ts +2 -1
- package/node_modules/pi-web-access/dist/index.js +655 -406
- package/node_modules/pi-web-access/dist/mcp-cli.js +653 -416
- package/node_modules/pi-web-access/duckduckgo.ts +5 -1
- package/node_modules/pi-web-access/endpoint-pdf-extract.ts +225 -0
- package/node_modules/pi-web-access/extract.ts +51 -13
- package/node_modules/pi-web-access/fetch-params.ts +10 -0
- package/node_modules/pi-web-access/gemini-api.ts +15 -0
- package/node_modules/pi-web-access/gemini-search.ts +32 -152
- package/node_modules/pi-web-access/github-issue-pr.ts +80 -68
- package/node_modules/pi-web-access/index.ts +3 -0
- package/node_modules/pi-web-access/package.json +1 -1
- package/node_modules/pi-web-access/pdf-extract.ts +38 -4
- package/node_modules/pi-web-access/perplexity.ts +19 -2
- package/node_modules/pi-web-access/ssrf-protection.ts +24 -4
- package/node_modules/pi-web-access/summary-review.ts +10 -0
- package/node_modules/pi-web-access/tool-arguments.ts +5 -2
- package/node_modules/pi-web-access/video-extract.ts +6 -2
- package/node_modules/pi-web-access/web-tool-core.ts +53 -13
- package/package.json +19 -24
- package/node_modules/pi-jev-auto-mode/CHANGELOG.md +0 -118
- package/node_modules/pi-jev-auto-mode/LICENSE +0 -21
- package/node_modules/pi-jev-auto-mode/README.md +0 -292
- package/node_modules/pi-jev-auto-mode/SECURITY.md +0 -32
- package/node_modules/pi-jev-auto-mode/docs/calibration.md +0 -154
- package/node_modules/pi-jev-auto-mode/docs/design.md +0 -164
- package/node_modules/pi-jev-auto-mode/docs/security.md +0 -124
- package/node_modules/pi-jev-auto-mode/index.ts +0 -1
- package/node_modules/pi-jev-auto-mode/package.json +0 -72
- package/node_modules/pi-jev-auto-mode/src/call.ts +0 -180
- package/node_modules/pi-jev-auto-mode/src/decide.ts +0 -86
- package/node_modules/pi-jev-auto-mode/src/extension.ts +0 -881
- package/node_modules/pi-jev-auto-mode/src/intent.ts +0 -71
- package/node_modules/pi-jev-auto-mode/src/jev/availability.ts +0 -53
- package/node_modules/pi-jev-auto-mode/src/jev/criteria.ts +0 -19
- package/node_modules/pi-jev-auto-mode/src/jev/decide.ts +0 -187
- package/node_modules/pi-jev-auto-mode/src/jev/engine.ts +0 -165
- package/node_modules/pi-jev-auto-mode/src/jev/index.ts +0 -20
- package/node_modules/pi-jev-auto-mode/src/jev/questions.ts +0 -273
- package/node_modules/pi-jev-auto-mode/src/jev/response.ts +0 -64
- package/node_modules/pi-jev-auto-mode/src/jev/state.ts +0 -20
- package/node_modules/pi-jev-auto-mode/src/jev/transport.ts +0 -117
- package/node_modules/pi-jev-auto-mode/src/jev/types.ts +0 -46
- package/node_modules/pi-jev-auto-mode/src/policy.ts +0 -558
- package/node_modules/pi-jev-auto-mode/src/records.ts +0 -184
- package/node_modules/pi-jev-auto-mode/src/settings.ts +0 -349
- package/node_modules/pi-jev-auto-mode/src/ui.ts +0 -243
- package/node_modules/pi-lens/dist/chunk-2FQ62SPM.js +0 -83
- package/node_modules/pi-lens/dist/chunk-7AXO3ZDF.js +0 -30
- package/node_modules/pi-lens/dist/chunk-KMGPUKFD.js +0 -25
- package/node_modules/pi-lens/dist/chunk-OZJINN4O.js +0 -84
- package/node_modules/pi-lens/dist/chunk-RJFED73B.js +0 -79
- package/node_modules/pi-lens/dist/chunk-RTQNRM5X.js +0 -27
- package/node_modules/pi-lens/dist/chunk-VGEVL5EQ.js +0 -29
- package/node_modules/pi-lens/dist/chunk-WPE5FPGR.js +0 -54
- package/node_modules/pi-lens/dist/chunk-Z7QQA2KT.js +0 -27
- package/node_modules/resume-from/LICENSE +0 -21
- package/node_modules/resume-from/README.md +0 -167
- package/node_modules/resume-from/dist/adapters/claude-code/adapter.d.ts +0 -20
- package/node_modules/resume-from/dist/adapters/claude-code/adapter.js +0 -59
- package/node_modules/resume-from/dist/adapters/claude-code/contract.d.ts +0 -8
- package/node_modules/resume-from/dist/adapters/claude-code/contract.js +0 -4
- package/node_modules/resume-from/dist/adapters/claude-code/entries.d.ts +0 -30
- package/node_modules/resume-from/dist/adapters/claude-code/entries.js +0 -107
- package/node_modules/resume-from/dist/adapters/claude-code/index.d.ts +0 -3
- package/node_modules/resume-from/dist/adapters/claude-code/index.js +0 -2
- package/node_modules/resume-from/dist/adapters/claude-code/layout.d.ts +0 -29
- package/node_modules/resume-from/dist/adapters/claude-code/layout.js +0 -80
- package/node_modules/resume-from/dist/adapters/claude-code/readback.d.ts +0 -9
- package/node_modules/resume-from/dist/adapters/claude-code/readback.js +0 -39
- package/node_modules/resume-from/dist/adapters/claude-code/reader.d.ts +0 -40
- package/node_modules/resume-from/dist/adapters/claude-code/reader.js +0 -436
- package/node_modules/resume-from/dist/adapters/claude-code/redaction.d.ts +0 -26
- package/node_modules/resume-from/dist/adapters/claude-code/redaction.js +0 -145
- package/node_modules/resume-from/dist/adapters/claude-code/validation.d.ts +0 -4
- package/node_modules/resume-from/dist/adapters/claude-code/validation.js +0 -39
- package/node_modules/resume-from/dist/adapters/claude-code/writer.d.ts +0 -21
- package/node_modules/resume-from/dist/adapters/claude-code/writer.js +0 -306
- package/node_modules/resume-from/dist/adapters/codex/contract.d.ts +0 -13
- package/node_modules/resume-from/dist/adapters/codex/contract.js +0 -4
- package/node_modules/resume-from/dist/adapters/codex/index.d.ts +0 -6
- package/node_modules/resume-from/dist/adapters/codex/index.js +0 -43
- package/node_modules/resume-from/dist/adapters/codex/read.d.ts +0 -44
- package/node_modules/resume-from/dist/adapters/codex/read.js +0 -723
- package/node_modules/resume-from/dist/adapters/codex/readback.d.ts +0 -9
- package/node_modules/resume-from/dist/adapters/codex/readback.js +0 -47
- package/node_modules/resume-from/dist/adapters/codex/redaction.d.ts +0 -26
- package/node_modules/resume-from/dist/adapters/codex/redaction.js +0 -145
- package/node_modules/resume-from/dist/adapters/codex/rollout.d.ts +0 -115
- package/node_modules/resume-from/dist/adapters/codex/rollout.js +0 -269
- package/node_modules/resume-from/dist/adapters/codex/validation.d.ts +0 -7
- package/node_modules/resume-from/dist/adapters/codex/validation.js +0 -78
- package/node_modules/resume-from/dist/adapters/codex/write.d.ts +0 -17
- package/node_modules/resume-from/dist/adapters/codex/write.js +0 -141
- package/node_modules/resume-from/dist/adapters/contract.d.ts +0 -78
- package/node_modules/resume-from/dist/adapters/contract.js +0 -4
- package/node_modules/resume-from/dist/adapters/pi/adapter.d.ts +0 -15
- package/node_modules/resume-from/dist/adapters/pi/adapter.js +0 -213
- package/node_modules/resume-from/dist/adapters/pi/contract.d.ts +0 -24
- package/node_modules/resume-from/dist/adapters/pi/contract.js +0 -4
- package/node_modules/resume-from/dist/adapters/pi/format.d.ts +0 -162
- package/node_modules/resume-from/dist/adapters/pi/format.js +0 -223
- package/node_modules/resume-from/dist/adapters/pi/index.d.ts +0 -7
- package/node_modules/resume-from/dist/adapters/pi/index.js +0 -10
- package/node_modules/resume-from/dist/adapters/pi/parse.d.ts +0 -41
- package/node_modules/resume-from/dist/adapters/pi/parse.js +0 -371
- package/node_modules/resume-from/dist/adapters/pi/redaction.d.ts +0 -26
- package/node_modules/resume-from/dist/adapters/pi/redaction.js +0 -145
- package/node_modules/resume-from/dist/adapters/pi/serialize.d.ts +0 -20
- package/node_modules/resume-from/dist/adapters/pi/serialize.js +0 -87
- package/node_modules/resume-from/dist/adapters/pi/validate.d.ts +0 -14
- package/node_modules/resume-from/dist/adapters/pi/validate.js +0 -134
- package/node_modules/resume-from/dist/bin.d.ts +0 -35
- package/node_modules/resume-from/dist/bin.js +0 -135
- package/node_modules/resume-from/dist/contract.d.ts +0 -10
- package/node_modules/resume-from/dist/contract.js +0 -4
- package/node_modules/resume-from/dist/host/agents.d.ts +0 -29
- package/node_modules/resume-from/dist/host/agents.js +0 -20
- package/node_modules/resume-from/dist/host/cli/args.d.ts +0 -21
- package/node_modules/resume-from/dist/host/cli/args.js +0 -187
- package/node_modules/resume-from/dist/host/cli/contract.d.ts +0 -27
- package/node_modules/resume-from/dist/host/cli/contract.js +0 -4
- package/node_modules/resume-from/dist/host/cli/index.d.ts +0 -2
- package/node_modules/resume-from/dist/host/cli/index.js +0 -1
- package/node_modules/resume-from/dist/host/cli/presentation.d.ts +0 -2
- package/node_modules/resume-from/dist/host/cli/presentation.js +0 -11
- package/node_modules/resume-from/dist/host/cli/render.d.ts +0 -3
- package/node_modules/resume-from/dist/host/cli/render.js +0 -70
- package/node_modules/resume-from/dist/host/cli/runner.d.ts +0 -8
- package/node_modules/resume-from/dist/host/cli/runner.js +0 -125
- package/node_modules/resume-from/dist/host/contract.d.ts +0 -42
- package/node_modules/resume-from/dist/host/contract.js +0 -4
- package/node_modules/resume-from/dist/host/entry.d.ts +0 -52
- package/node_modules/resume-from/dist/host/entry.js +0 -91
- package/node_modules/resume-from/dist/host/index.d.ts +0 -11
- package/node_modules/resume-from/dist/host/index.js +0 -10
- package/node_modules/resume-from/dist/host/pi-extension/command.d.ts +0 -18
- package/node_modules/resume-from/dist/host/pi-extension/command.js +0 -126
- package/node_modules/resume-from/dist/host/pi-extension/contract.d.ts +0 -34
- package/node_modules/resume-from/dist/host/pi-extension/contract.js +0 -4
- package/node_modules/resume-from/dist/host/pi-extension/index.d.ts +0 -6
- package/node_modules/resume-from/dist/host/pi-extension/index.js +0 -4
- package/node_modules/resume-from/dist/host/pi-extension/picker.d.ts +0 -16
- package/node_modules/resume-from/dist/host/pi-extension/picker.js +0 -35
- package/node_modules/resume-from/dist/host/pi-extension/presentation.d.ts +0 -2
- package/node_modules/resume-from/dist/host/pi-extension/presentation.js +0 -11
- package/node_modules/resume-from/dist/host/pi-extension/register.d.ts +0 -25
- package/node_modules/resume-from/dist/host/pi-extension/register.js +0 -11
- package/node_modules/resume-from/dist/host/pi-extension/ui.d.ts +0 -20
- package/node_modules/resume-from/dist/host/pi-extension/ui.js +0 -1
- package/node_modules/resume-from/dist/host/profile.d.ts +0 -8
- package/node_modules/resume-from/dist/host/profile.js +0 -31
- package/node_modules/resume-from/dist/host/registry.d.ts +0 -8
- package/node_modules/resume-from/dist/host/registry.js +0 -33
- package/node_modules/resume-from/dist/host/wiring.d.ts +0 -41
- package/node_modules/resume-from/dist/host/wiring.js +0 -66
- package/node_modules/resume-from/dist/import/confirmation.d.ts +0 -9
- package/node_modules/resume-from/dist/import/confirmation.js +0 -27
- package/node_modules/resume-from/dist/import/contract.d.ts +0 -43
- package/node_modules/resume-from/dist/import/contract.js +0 -4
- package/node_modules/resume-from/dist/import/discovery/contract.d.ts +0 -63
- package/node_modules/resume-from/dist/import/discovery/contract.js +0 -4
- package/node_modules/resume-from/dist/import/discovery/errors.d.ts +0 -9
- package/node_modules/resume-from/dist/import/discovery/errors.js +0 -12
- package/node_modules/resume-from/dist/import/discovery/finder.d.ts +0 -11
- package/node_modules/resume-from/dist/import/discovery/finder.js +0 -269
- package/node_modules/resume-from/dist/import/discovery/homes.d.ts +0 -23
- package/node_modules/resume-from/dist/import/discovery/homes.js +0 -83
- package/node_modules/resume-from/dist/import/discovery/index.d.ts +0 -2
- package/node_modules/resume-from/dist/import/discovery/index.js +0 -2
- package/node_modules/resume-from/dist/import/discovery/ordering.d.ts +0 -3
- package/node_modules/resume-from/dist/import/discovery/ordering.js +0 -21
- package/node_modules/resume-from/dist/import/errors.d.ts +0 -22
- package/node_modules/resume-from/dist/import/errors.js +0 -20
- package/node_modules/resume-from/dist/import/index.d.ts +0 -3
- package/node_modules/resume-from/dist/import/index.js +0 -5
- package/node_modules/resume-from/dist/import/landing/contract.d.ts +0 -44
- package/node_modules/resume-from/dist/import/landing/contract.js +0 -4
- package/node_modules/resume-from/dist/import/landing/errors.d.ts +0 -15
- package/node_modules/resume-from/dist/import/landing/errors.js +0 -15
- package/node_modules/resume-from/dist/import/landing/handover.d.ts +0 -5
- package/node_modules/resume-from/dist/import/landing/handover.js +0 -12
- package/node_modules/resume-from/dist/import/landing/index.d.ts +0 -4
- package/node_modules/resume-from/dist/import/landing/index.js +0 -4
- package/node_modules/resume-from/dist/import/landing/lander.d.ts +0 -7
- package/node_modules/resume-from/dist/import/landing/lander.js +0 -133
- package/node_modules/resume-from/dist/import/landing/marker.d.ts +0 -9
- package/node_modules/resume-from/dist/import/landing/marker.js +0 -46
- package/node_modules/resume-from/dist/import/pipeline.d.ts +0 -28
- package/node_modules/resume-from/dist/import/pipeline.js +0 -154
- package/node_modules/resume-from/dist/import/preview/builder.d.ts +0 -6
- package/node_modules/resume-from/dist/import/preview/builder.js +0 -80
- package/node_modules/resume-from/dist/import/preview/contract.d.ts +0 -39
- package/node_modules/resume-from/dist/import/preview/contract.js +0 -4
- package/node_modules/resume-from/dist/import/preview/format.d.ts +0 -19
- package/node_modules/resume-from/dist/import/preview/format.js +0 -45
- package/node_modules/resume-from/dist/import/preview/index.d.ts +0 -2
- package/node_modules/resume-from/dist/import/preview/index.js +0 -1
- package/node_modules/resume-from/dist/import/preview/warnings.d.ts +0 -14
- package/node_modules/resume-from/dist/import/preview/warnings.js +0 -86
- package/node_modules/resume-from/dist/import/transfer/contract.d.ts +0 -48
- package/node_modules/resume-from/dist/import/transfer/contract.js +0 -4
- package/node_modules/resume-from/dist/import/transfer/index.d.ts +0 -2
- package/node_modules/resume-from/dist/import/transfer/index.js +0 -1
- package/node_modules/resume-from/dist/import/transfer/rules.d.ts +0 -3
- package/node_modules/resume-from/dist/import/transfer/rules.js +0 -228
- package/node_modules/resume-from/dist/import/wiring.d.ts +0 -24
- package/node_modules/resume-from/dist/import/wiring.js +0 -37
- package/node_modules/resume-from/dist/index.d.ts +0 -36
- package/node_modules/resume-from/dist/index.js +0 -36
- package/node_modules/resume-from/dist/platform/config/contract.d.ts +0 -35
- package/node_modules/resume-from/dist/platform/config/contract.js +0 -4
- package/node_modules/resume-from/dist/platform/config/defaults.d.ts +0 -16
- package/node_modules/resume-from/dist/platform/config/defaults.js +0 -22
- package/node_modules/resume-from/dist/platform/config/errors.d.ts +0 -9
- package/node_modules/resume-from/dist/platform/config/errors.js +0 -12
- package/node_modules/resume-from/dist/platform/config/index.d.ts +0 -5
- package/node_modules/resume-from/dist/platform/config/index.js +0 -6
- package/node_modules/resume-from/dist/platform/config/loader.d.ts +0 -10
- package/node_modules/resume-from/dist/platform/config/loader.js +0 -47
- package/node_modules/resume-from/dist/platform/config/paths.d.ts +0 -13
- package/node_modules/resume-from/dist/platform/config/paths.js +0 -37
- package/node_modules/resume-from/dist/platform/config/validate.d.ts +0 -9
- package/node_modules/resume-from/dist/platform/config/validate.js +0 -117
- package/node_modules/resume-from/dist/platform/repo/contract.d.ts +0 -36
- package/node_modules/resume-from/dist/platform/repo/contract.js +0 -4
- package/node_modules/resume-from/dist/platform/repo/git.d.ts +0 -21
- package/node_modules/resume-from/dist/platform/repo/git.js +0 -77
- package/node_modules/resume-from/dist/platform/repo/index.d.ts +0 -2
- package/node_modules/resume-from/dist/platform/repo/index.js +0 -1
- package/node_modules/resume-from/dist/platform/repo/reader.d.ts +0 -3
- package/node_modules/resume-from/dist/platform/repo/reader.js +0 -170
- package/node_modules/resume-from/dist/platform/store/contract.d.ts +0 -31
- package/node_modules/resume-from/dist/platform/store/contract.js +0 -4
- package/node_modules/resume-from/dist/platform/store/file-committer.d.ts +0 -3
- package/node_modules/resume-from/dist/platform/store/file-committer.js +0 -391
- package/node_modules/resume-from/dist/platform/store/index.d.ts +0 -2
- package/node_modules/resume-from/dist/platform/store/index.js +0 -2
- package/node_modules/resume-from/dist/platform/tokens/contract.d.ts +0 -12
- package/node_modules/resume-from/dist/platform/tokens/contract.js +0 -4
- package/node_modules/resume-from/dist/platform/tokens/estimator.d.ts +0 -12
- package/node_modules/resume-from/dist/platform/tokens/estimator.js +0 -111
- package/node_modules/resume-from/dist/platform/tokens/index.d.ts +0 -2
- package/node_modules/resume-from/dist/platform/tokens/index.js +0 -1
- package/node_modules/resume-from/dist/session/contract.d.ts +0 -116
- package/node_modules/resume-from/dist/session/contract.js +0 -4
- package/node_modules/resume-from/package.json +0 -83
- package/node_modules/resume-from/shims/pi/extensions/resume-from.js +0 -118
|
@@ -41,18 +41,36 @@ import { existsSync, readdirSync, readFileSync, statSync } from "node:fs"
|
|
|
41
41
|
import { isAbsolute, join } from "node:path"
|
|
42
42
|
import { getAgentDir } from "@earendil-works/pi-coding-agent"
|
|
43
43
|
import { isSymlink, isUnsafeName, safeReadFile } from "../memory.js"
|
|
44
|
+
import {
|
|
45
|
+
isPackageResourceExcluded,
|
|
46
|
+
packageWorkflowDirs,
|
|
47
|
+
packageWorkflowFiles,
|
|
48
|
+
} from "../package-resources.js"
|
|
44
49
|
import { hasMetaDeclaration } from "./meta.js"
|
|
45
50
|
import { MAX_SCRIPT_LENGTH } from "./runtime.js"
|
|
46
51
|
|
|
47
52
|
/** Extension a saved workflow file carries. */
|
|
48
53
|
const WORKFLOW_EXTENSION = ".js"
|
|
49
54
|
|
|
50
|
-
/**
|
|
55
|
+
/**
|
|
56
|
+
* The roots a `name` is looked up in, highest priority first.
|
|
57
|
+
*
|
|
58
|
+
* Directories declared by installed pi packages come last, so a project, shared
|
|
59
|
+
* workspace or personal script always wins the name. That is the same tier
|
|
60
|
+
* package-provided agents get, and the same tier pi gives package-provided
|
|
61
|
+
* skills — a package offers a workflow, it never takes a name away from you.
|
|
62
|
+
*
|
|
63
|
+
* The `packageWorkflows` gate and pi's project-trust answer are session state in
|
|
64
|
+
* package-resources.ts rather than parameters here, so a gate set in `/agents`
|
|
65
|
+
* reaches this without an options bag travelling through `resolveWorkflowScript`,
|
|
66
|
+
* `resolveWorkflowSource` and `readSavedWorkflow` purely to be consulted once.
|
|
67
|
+
*/
|
|
51
68
|
export function savedWorkflowRoots(cwd: string): string[] {
|
|
52
69
|
return [
|
|
53
70
|
join(cwd, ".pi", "workflows"),
|
|
54
71
|
join(cwd, ".agents", "workflows"),
|
|
55
72
|
join(getAgentDir(), "workflows"),
|
|
73
|
+
...packageWorkflowDirs(cwd),
|
|
56
74
|
]
|
|
57
75
|
}
|
|
58
76
|
|
|
@@ -82,6 +100,9 @@ export function readSavedWorkflow(name: string, cwd: string): SavedWorkflow {
|
|
|
82
100
|
for (const root of roots) {
|
|
83
101
|
if (isSymlink(root)) continue // reject a symlinked root entirely, as skill-loader does
|
|
84
102
|
const path = join(root, `${trimmed}${WORKFLOW_EXTENSION}`)
|
|
103
|
+
// A `!` entry in the declaring package's manifest. Only ever true for a path
|
|
104
|
+
// under a package root, so the local roots pay one set lookup for it.
|
|
105
|
+
if (isPackageResourceExcluded(path, cwd, "workflows")) continue
|
|
85
106
|
const script = safeReadFile(path)
|
|
86
107
|
if (script === undefined) continue
|
|
87
108
|
// Found the file, so stop looking — a shadowing name that turns out not to
|
|
@@ -97,6 +118,25 @@ export function readSavedWorkflow(name: string, cwd: string): SavedWorkflow {
|
|
|
97
118
|
return { ok: true, script, path }
|
|
98
119
|
}
|
|
99
120
|
|
|
121
|
+
// Last: a package that declared an individual file rather than a directory.
|
|
122
|
+
// It carries no root to look a name up in, so it is matched by name here
|
|
123
|
+
// instead — after every root, which keeps package scripts lowest-precedence.
|
|
124
|
+
const declared = packageWorkflowFiles(cwd).get(trimmed)
|
|
125
|
+
if (declared !== undefined) {
|
|
126
|
+
const script = safeReadFile(declared)
|
|
127
|
+
if (script !== undefined) {
|
|
128
|
+
if (!hasMetaDeclaration(script)) {
|
|
129
|
+
return {
|
|
130
|
+
ok: false,
|
|
131
|
+
message:
|
|
132
|
+
`"${declared}" is not a workflow script — it has no \`export const meta = { name, description }\` ` +
|
|
133
|
+
"declaration. Nothing was run.",
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
return { ok: true, script, path: declared }
|
|
137
|
+
}
|
|
138
|
+
}
|
|
139
|
+
|
|
100
140
|
const known = listSavedWorkflows(cwd)
|
|
101
141
|
return {
|
|
102
142
|
ok: false,
|
|
@@ -158,9 +198,15 @@ export function listSavedWorkflows(cwd: string): string[] {
|
|
|
158
198
|
if (!entry.endsWith(WORKFLOW_EXTENSION)) continue
|
|
159
199
|
const name = entry.slice(0, -WORKFLOW_EXTENSION.length)
|
|
160
200
|
if (isUnsafeName(name)) continue
|
|
161
|
-
|
|
201
|
+
const path = join(root, entry)
|
|
202
|
+
if (isPackageResourceExcluded(path, cwd, "workflows")) continue
|
|
203
|
+
if (isWorkflowFile(path)) names.add(name)
|
|
162
204
|
}
|
|
163
205
|
}
|
|
206
|
+
for (const [name, path] of packageWorkflowFiles(cwd)) {
|
|
207
|
+
if (isUnsafeName(name)) continue
|
|
208
|
+
if (isWorkflowFile(path)) names.add(name)
|
|
209
|
+
}
|
|
164
210
|
return [...names].sort()
|
|
165
211
|
}
|
|
166
212
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@herbertgao/sol-pi",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.1",
|
|
4
4
|
"description": "Token-efficient context and tool extensions for Pi, maintained from NVlabs/SoL-Pi.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"pi-package",
|
|
@@ -61,7 +61,7 @@
|
|
|
61
61
|
"vitest": "^4.0.18"
|
|
62
62
|
},
|
|
63
63
|
"engines": {
|
|
64
|
-
"node": ">=
|
|
64
|
+
"node": ">=22.19.0"
|
|
65
65
|
},
|
|
66
66
|
"pi": {
|
|
67
67
|
"extensions": [
|
|
@@ -25,7 +25,7 @@ Nothing to set up — the tool is live as soon as Pi restarts. Hand the model a
|
|
|
25
25
|
|
|
26
26
|
> Add caching to the API client.
|
|
27
27
|
|
|
28
|
-
Rather than picking a strategy on your behalf, the model calls `ask_user_question` and a dialog takes over the bottom of your terminal. Move with `↑`/`↓`, choose with `Enter`, press `n` to attach a note to a question
|
|
28
|
+
Rather than picking a strategy on your behalf, the model calls `ask_user_question` and a dialog takes over the bottom of your terminal. Move with `↑`/`↓`, choose with `Enter`, press `n` to attach a note to a question or a global note from the Submit tab, or land on `Type something.` to answer in your own words. In a multi-select question, typed custom text is selected automatically and submitted together with checked options. While typing, `Shift+Enter` adds a line, `Ctrl+G` opens Pi's configured external editor, and `Ctrl+U` clears the draft; browsing another option and returning keeps what you wrote. `Esc` abandons the questionnaire entirely.
|
|
29
29
|
|
|
30
30
|
When the questionnaire begins waiting in an interactive TTY, it emits one standard terminal BEL (`\x07`). Your terminal configuration determines whether that appears as an audible alert, a visual alert, or nothing; redirected and non-TTY output is untouched.
|
|
31
31
|
|
|
@@ -38,11 +38,11 @@ When the model asks several things at once, `Tab` moves between them and a Submi
|
|
|
38
38
|
## What you get
|
|
39
39
|
|
|
40
40
|
- **Typed options instead of a wall of prose** — each question carries 2-4 authored choices, and every choice comes with a description of what it means or what it costs you.
|
|
41
|
-
- **You can always answer in your own words
|
|
41
|
+
- **You can always answer in your own words**. A `Type something.` row is appended to every question. On multi-select questions, it keeps checked options and custom text in the same answer. The row widens to the full pane while you type, keeps its multiline draft visible while you browse, and supports Pi's `Shift+Enter` newline and `Ctrl+G` external-editor flows.
|
|
42
42
|
- **Compare real artifacts, not just labels** — an option can carry a markdown `preview` (ASCII mockup, code, diagram, config) that renders in a bordered box beside the option list.
|
|
43
43
|
- **One interruption, not five** — up to four questions arrive in a single tabbed dialog, and the Submit tab lists your answers and names anything still blank before you commit.
|
|
44
44
|
- **Notes on any answer — or on all of them** — `n` opens a multiline note editor on any question tab, and on the Submit tab it opens one global note for the whole questionnaire. Per-question notes reach the model as `user notes: <text>`, the global note as `global note: <text>`; neither marks a question answered.
|
|
45
|
-
- **
|
|
45
|
+
- **Keep reading while you answer** — the question opens below the transcript, and `PageUp`/`PageDown` or the mouse wheel keep scrolling the conversation; `Ctrl+]` shrinks the dialog to one line when you want more room, then brings it back with your answers intact.
|
|
46
46
|
- **Works outside the terminal too** — in RPC and ACP hosts such as the VS Code pendant or Zed the questionnaire walks through the host's native dialogs (notes are terminal-only and do not carry over), and in non-interactive runs the tool is removed from the model's tool list instead of failing every call.
|
|
47
47
|
|
|
48
48
|
## Configuration
|
|
@@ -15,10 +15,18 @@ import {
|
|
|
15
15
|
} from "./events.js";
|
|
16
16
|
// Static import is fine — rpc-fallback pulls only types + the i18n bridge,
|
|
17
17
|
// none of the ~560ms TUI render graph that QuestionnaireSession lazy-loads.
|
|
18
|
+
import {
|
|
19
|
+
mustYieldInlineSlot,
|
|
20
|
+
type Presentation,
|
|
21
|
+
resolvePresentation,
|
|
22
|
+
rowBudgetForHost,
|
|
23
|
+
STACKED_OVERLAY_PRESENTATION,
|
|
24
|
+
YIELD_TO_OVERLAY,
|
|
25
|
+
} from "./presentation.js";
|
|
18
26
|
import { type DialogUI, hasDialogUI, runRpcQuestionnaire } from "./rpc-fallback.js";
|
|
19
27
|
import { displayLabel, t } from "./state/i18n-bridge.js";
|
|
20
28
|
import { sentinelsToAppend } from "./state/row-intent.js";
|
|
21
|
-
import { normalizeQuestionParams } from "./tool/normalize-params.js";
|
|
29
|
+
import { normalizeQuestionParams, prepareQuestionArguments } from "./tool/normalize-params.js";
|
|
22
30
|
import { buildQuestionnaireResponse, buildToolResult } from "./tool/response-envelope.js";
|
|
23
31
|
import {
|
|
24
32
|
MAX_OPTIONS,
|
|
@@ -190,16 +198,23 @@ function makeSessionFactory(config: {
|
|
|
190
198
|
itemsByTab: WrappingSelectItem[][];
|
|
191
199
|
collapseKey: string;
|
|
192
200
|
canReopenWhileHidden: boolean;
|
|
201
|
+
presentation: Presentation;
|
|
193
202
|
sessionRef: SessionRef;
|
|
194
203
|
Session: SessionModule["QuestionnaireSession"];
|
|
195
204
|
}) {
|
|
196
|
-
const { ctx, typed, itemsByTab, collapseKey, canReopenWhileHidden, sessionRef, Session } = config;
|
|
205
|
+
const { ctx, typed, itemsByTab, collapseKey, canReopenWhileHidden, presentation, sessionRef, Session } = config;
|
|
197
206
|
return (
|
|
198
207
|
tui: TUI,
|
|
199
208
|
theme: Theme,
|
|
200
209
|
keybindings: import("./state/questionnaire-session.js").QuestionnaireSessionConfig["keybindings"],
|
|
201
210
|
done: (result: QuestionnaireResult) => void,
|
|
202
211
|
): import("./state/questionnaire-session.js").QuestionnaireSessionComponent => {
|
|
212
|
+
// The factory runs at mount time — the first point the TUI is reachable — so this is
|
|
213
|
+
// where an inline mount notices an overlay already on screen and gives the slot up.
|
|
214
|
+
if (!presentation.overlay && mustYieldInlineSlot(tui)) {
|
|
215
|
+
done(YIELD_TO_OVERLAY);
|
|
216
|
+
return INERT_COMPONENT;
|
|
217
|
+
}
|
|
203
218
|
const session = new Session({
|
|
204
219
|
tui,
|
|
205
220
|
theme,
|
|
@@ -226,12 +241,69 @@ function makeSessionFactory(config: {
|
|
|
226
241
|
},
|
|
227
242
|
collapseKey,
|
|
228
243
|
canReopenWhileHidden,
|
|
244
|
+
rowBudget: rowBudgetForHost(tui.terminal, presentation.rowBudget),
|
|
229
245
|
});
|
|
230
246
|
sessionRef.current = session;
|
|
231
247
|
return session.component;
|
|
232
248
|
};
|
|
233
249
|
}
|
|
234
250
|
|
|
251
|
+
/** Stand-in returned by a mount that resolved before mounting (Pi discards it unmounted). */
|
|
252
|
+
const INERT_COMPONENT: import("./state/questionnaire-session.js").QuestionnaireSessionComponent = {
|
|
253
|
+
render: () => [],
|
|
254
|
+
invalidate: () => {},
|
|
255
|
+
handleInput: () => {},
|
|
256
|
+
};
|
|
257
|
+
|
|
258
|
+
/**
|
|
259
|
+
* One `ctx.ui.custom` mount under `presentation`. The overlay additionally gets its handle
|
|
260
|
+
* captured (so collapse can `setHidden()`) and a raw terminal listener for the collapse key,
|
|
261
|
+
* which stays reachable while the overlay is hidden (pi-tui routes no input to a hidden
|
|
262
|
+
* overlay's `component.handleInput`). Inline has no handle to hide and keeps focus while
|
|
263
|
+
* collapsed, so it needs no listener.
|
|
264
|
+
*/
|
|
265
|
+
async function mountQuestionnaire(config: {
|
|
266
|
+
ctx: ExtensionContext;
|
|
267
|
+
typed: QuestionParams;
|
|
268
|
+
itemsByTab: WrappingSelectItem[][];
|
|
269
|
+
collapseKey: string;
|
|
270
|
+
presentation: Presentation;
|
|
271
|
+
Session: SessionModule["QuestionnaireSession"];
|
|
272
|
+
}): Promise<QuestionnaireResult | undefined> {
|
|
273
|
+
const { ctx, collapseKey, presentation } = config;
|
|
274
|
+
const sessionRef: SessionRef = { current: null };
|
|
275
|
+
const overlayHandleRef: OverlayHandleRef = { current: undefined };
|
|
276
|
+
const removeOverlayInputListener = presentation.hideOnCollapse
|
|
277
|
+
? registerCollapseKeyListener(ctx, collapseKey, sessionRef, overlayHandleRef)
|
|
278
|
+
: undefined;
|
|
279
|
+
// Hiding the overlay is only reversible through the raw listener above, so the session
|
|
280
|
+
// may emit `setHidden` only when it was actually registered; otherwise collapse falls
|
|
281
|
+
// back to the visible one-line row.
|
|
282
|
+
const canReopenWhileHidden = removeOverlayInputListener !== undefined;
|
|
283
|
+
try {
|
|
284
|
+
return await ctx.ui.custom<QuestionnaireResult>(
|
|
285
|
+
makeSessionFactory({ ...config, canReopenWhileHidden, sessionRef }),
|
|
286
|
+
presentation.overlay
|
|
287
|
+
? {
|
|
288
|
+
overlay: true,
|
|
289
|
+
overlayOptions: {
|
|
290
|
+
anchor: "bottom-center",
|
|
291
|
+
width: "100%",
|
|
292
|
+
maxHeight: "100%",
|
|
293
|
+
margin: { left: 0, right: 0, bottom: 0 },
|
|
294
|
+
},
|
|
295
|
+
onHandle: (handle) => {
|
|
296
|
+
overlayHandleRef.current = handle;
|
|
297
|
+
sessionRef.current?.setOverlayHandle(handle);
|
|
298
|
+
},
|
|
299
|
+
}
|
|
300
|
+
: { overlay: false },
|
|
301
|
+
);
|
|
302
|
+
} finally {
|
|
303
|
+
removeOverlayInputListener?.();
|
|
304
|
+
}
|
|
305
|
+
}
|
|
306
|
+
|
|
235
307
|
/**
|
|
236
308
|
* A TUI questionnaire ALWAYS resolves a QuestionnaireResult (cancel included), so
|
|
237
309
|
* `undefined` uniquely means "host cannot render", never "user declined". RPC builds
|
|
@@ -309,6 +381,8 @@ export function registerAskUserQuestionTool(pi: ExtensionAPI): void {
|
|
|
309
381
|
promptSnippet: guidance.promptSnippet ?? DEFAULT_PROMPT_SNIPPET,
|
|
310
382
|
promptGuidelines: guidance.promptGuidelines ?? DEFAULT_PROMPT_GUIDELINES,
|
|
311
383
|
parameters: QuestionParamsSchema,
|
|
384
|
+
// Undo double-encoded nested arguments before Pi validates them (#244).
|
|
385
|
+
prepareArguments: prepareQuestionArguments,
|
|
312
386
|
|
|
313
387
|
async execute(_toolCallId, params, _signal, _onUpdate, ctx) {
|
|
314
388
|
// Line-terminator normalization runs once here, ahead of validation, so
|
|
@@ -353,46 +427,22 @@ export function registerAskUserQuestionTool(pi: ExtensionAPI): void {
|
|
|
353
427
|
// via the `collapseKey` config field. `resolveCollapseKey` also accepts the
|
|
354
428
|
// sentinel value `"off"` to disable the shortcut entirely.
|
|
355
429
|
const collapseKey = resolveCollapseKey(loadConfig());
|
|
356
|
-
|
|
357
|
-
//
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
const sessionRef: SessionRef = { current: null };
|
|
362
|
-
const overlayHandleRef: OverlayHandleRef = { current: undefined };
|
|
363
|
-
const removeOverlayInputListener = registerCollapseKeyListener(ctx, collapseKey, sessionRef, overlayHandleRef);
|
|
364
|
-
// Hiding the overlay is only reversible through the raw listener above, so
|
|
365
|
-
// the session may emit `setHidden` only when it was actually registered;
|
|
366
|
-
// otherwise collapse falls back to the visible one-line row.
|
|
367
|
-
const canReopenWhileHidden = removeOverlayInputListener !== undefined;
|
|
430
|
+
// Pi's editor slot (#253); the overlay only while another questionnaire holds the slot,
|
|
431
|
+
// or stacked when another overlay is already on screen (see below).
|
|
432
|
+
let presentation = resolvePresentation();
|
|
433
|
+
const mount = (p: Presentation) =>
|
|
434
|
+
mountQuestionnaire({ ctx, typed, itemsByTab, collapseKey, presentation: p, Session: QuestionnaireSession });
|
|
368
435
|
|
|
369
436
|
emitAskUserBlockedEvent(pi, true);
|
|
370
437
|
try {
|
|
371
438
|
emitTerminalAttention();
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
sessionRef,
|
|
380
|
-
Session: QuestionnaireSession,
|
|
381
|
-
}),
|
|
382
|
-
{
|
|
383
|
-
overlay: true,
|
|
384
|
-
overlayOptions: {
|
|
385
|
-
anchor: "bottom-center",
|
|
386
|
-
width: "100%",
|
|
387
|
-
maxHeight: "100%",
|
|
388
|
-
margin: { left: 0, right: 0, bottom: 0 },
|
|
389
|
-
},
|
|
390
|
-
onHandle: (handle) => {
|
|
391
|
-
overlayHandleRef.current = handle;
|
|
392
|
-
sessionRef.current?.setOverlayHandle(handle);
|
|
393
|
-
},
|
|
394
|
-
},
|
|
395
|
-
);
|
|
439
|
+
let result = await mount(presentation);
|
|
440
|
+
if (result === YIELD_TO_OVERLAY) {
|
|
441
|
+
// Another overlay was on screen: stack on top of it instead (see mustYieldInlineSlot).
|
|
442
|
+
presentation.release?.();
|
|
443
|
+
presentation = STACKED_OVERLAY_PRESENTATION;
|
|
444
|
+
result = await mount(presentation);
|
|
445
|
+
}
|
|
396
446
|
|
|
397
447
|
if (result === undefined) {
|
|
398
448
|
return resolveUndefinedResult(ctx, typed);
|
|
@@ -400,7 +450,7 @@ export function registerAskUserQuestionTool(pi: ExtensionAPI): void {
|
|
|
400
450
|
|
|
401
451
|
return buildQuestionnaireResponse(result, typed);
|
|
402
452
|
} finally {
|
|
403
|
-
|
|
453
|
+
presentation.release?.();
|
|
404
454
|
emitAskUserBlockedEvent(pi, false);
|
|
405
455
|
}
|
|
406
456
|
},
|
|
@@ -58,7 +58,7 @@ type are likewise dropped back to their default without a warning.
|
|
|
58
58
|
|
|
59
59
|
| Setting | What it does | Default |
|
|
60
60
|
| --- | --- | --- |
|
|
61
|
-
| `collapseKey` | Key that collapses and expands the dialog
|
|
61
|
+
| `collapseKey` | Key that collapses and expands the dialog. | `"ctrl+]"` |
|
|
62
62
|
| `guidance.description` | Full text of the tool description the model sees. Replaces the built-in default entirely — no merging. | built-in description |
|
|
63
63
|
| `guidance.promptSnippet` | One-line snippet describing the tool in the system prompt. | built-in snippet |
|
|
64
64
|
| `guidance.promptGuidelines` | List of usage guidelines given to the model. | 4 built-in guidelines |
|
|
@@ -46,10 +46,10 @@ TUI produces. Trade-offs inherent to the native primitives:
|
|
|
46
46
|
- No notes. Both note kinds — per-question `n` on a question tab and global `n` on the
|
|
47
47
|
Submit tab — are terminal-only; the host's native `select` and `input` primitives carry
|
|
48
48
|
no note field.
|
|
49
|
-
- Multi-select is a free-text input
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
49
|
+
- Multi-select is a free-text input. Type option numbers separated by commas (`1,3`).
|
|
50
|
+
Add a semicolon and custom text to return both (`1,3; another color`). Plain text still
|
|
51
|
+
returns a custom-only multi-select answer. An empty input commits an empty selection,
|
|
52
|
+
matching `Next` with nothing selected.
|
|
53
53
|
- Dismissing any dialog cancels the whole questionnaire, mirroring `Esc` in the TUI.
|
|
54
54
|
|
|
55
55
|
If the host can render neither custom UI nor dialogs, the call returns
|
|
@@ -12,7 +12,7 @@ adapts to the size of your terminal.
|
|
|
12
12
|
| `Shift+Enter` | Insert a newline. | `Type something.` input, notes editor |
|
|
13
13
|
| `Esc` | Cancel the whole questionnaire. | Everywhere except the notes editor, where it closes notes |
|
|
14
14
|
| `Tab` / `Shift+Tab` | Next / previous tab, wrapping. `→` / `←` do the same. | Multi-question dialogs only |
|
|
15
|
-
| `Space` | Toggle the focused
|
|
15
|
+
| `Space` | Toggle the focused authored option. In `Type something.`, Space inserts text. | Multi-select questions |
|
|
16
16
|
| `n` | Open the notes editor for the focused question — or, on the Submit tab, the global note for the whole questionnaire. | Every question tab; the Submit tab in multi-question dialogs |
|
|
17
17
|
| `Ctrl+G` | Open Pi's configured external editor with the current custom-answer draft. | `Type something.` input |
|
|
18
18
|
| `Ctrl+U` | Clear the current custom-answer draft. | `Type something.` input |
|
|
@@ -26,13 +26,13 @@ Slack-style configuration — `enter` folded into `tui.input.newLine`, submit mo
|
|
|
26
26
|
everywhere `Enter` does.
|
|
27
27
|
|
|
28
28
|
In a multi-select question, `Enter` on a regular row toggles its checkbox exactly like
|
|
29
|
-
`Space
|
|
30
|
-
|
|
31
|
-
|
|
29
|
+
`Space`. It does not submit. Focus `Next` and press `Enter` to commit the question. That
|
|
30
|
+
is deliberate: it makes `Enter` a zero-cost way to flip boxes without leaving the home row.
|
|
31
|
+
`Space` does nothing on `Next` (it is a command, not a choice).
|
|
32
32
|
|
|
33
|
-
`
|
|
34
|
-
`
|
|
35
|
-
|
|
33
|
+
`Type something.` is an inline input, so Space inserts a space. Its checkbox changes to
|
|
34
|
+
`[✔]` when the input contains text. Press `Enter` in the input or use `Next` to submit
|
|
35
|
+
both the checked options and the custom text.
|
|
36
36
|
|
|
37
37
|
## The rows the dialog adds
|
|
38
38
|
|
|
@@ -43,12 +43,15 @@ answer).
|
|
|
43
43
|
|
|
44
44
|
Focusing `Type something.` switches the row into an inline multiline editor. In preview
|
|
45
45
|
mode it expands to the full pane width while you type, so a long custom answer is not
|
|
46
|
-
squeezed into the narrow options column. `Shift+Enter` inserts a line break
|
|
46
|
+
squeezed into the narrow options column. `Shift+Enter` inserts a line break. Vertical
|
|
47
47
|
arrows move between lines and return to row navigation at the draft's top and bottom.
|
|
48
48
|
The draft replaces the static row label while you browse other options and is isolated
|
|
49
|
-
per question. `Ctrl+G`
|
|
50
|
-
|
|
51
|
-
|
|
49
|
+
per question. `Ctrl+G` sends it through Pi's configured external editor. `Ctrl+U` clears
|
|
50
|
+
it, while `Esc` cancels the questionnaire.
|
|
51
|
+
|
|
52
|
+
On a single-select question, confirming the input produces `kind: "custom"`. On a
|
|
53
|
+
multi-select question, the result uses `kind: "multi"`: `selected` contains checked
|
|
54
|
+
labels, and `answer` contains the custom text.
|
|
52
55
|
|
|
53
56
|
Both labels are reserved — the model cannot author an option that collides with them.
|
|
54
57
|
Both localize with the rest of the UI chrome; the reserved-label check always compares
|
|
@@ -60,7 +63,10 @@ against the canonical English strings.
|
|
|
60
63
|
multi-select and whether or not its options carry previews. Notes are stored in a
|
|
61
64
|
side-band keyed by tab index, not inside the answer, so writing a note does not mark a
|
|
62
65
|
question as answered — the Submit tab still lists it as outstanding. The note merges into
|
|
63
|
-
the answer when you confirm it, and reaches the model as `user notes: <text>`.
|
|
66
|
+
the answer when you confirm it, and reaches the model as `user notes: <text>`. Once the
|
|
67
|
+
editor closes, the question shows the saved note as `Note for this answer: …` (its first
|
|
68
|
+
line), and a preview pane's hint changes to "Note saved: press n to edit"; the Submit tab's
|
|
69
|
+
review uses the same label.
|
|
64
70
|
|
|
65
71
|
On the Submit tab, `n` opens the global note editor instead — one note covering the whole
|
|
66
72
|
questionnaire. It lives outside every answer, so it survives tab switches and never marks
|
|
@@ -70,20 +76,47 @@ nothing but a global note still returns an answered result rather than a decline
|
|
|
70
76
|
Inside the editor, `Shift+Enter` inserts a newline, while `Esc` and `Enter` close it; other
|
|
71
77
|
keystrokes edit the buffer, so `n` types an `n`. Pasted line breaks are preserved.
|
|
72
78
|
|
|
73
|
-
##
|
|
79
|
+
## Where the dialog appears
|
|
80
|
+
|
|
81
|
+
The questionnaire opens in Pi's editor area, below the transcript — where Pi's own select
|
|
82
|
+
and input prompts appear. The transcript keeps scrolling with `PageUp`/`PageDown` and the
|
|
83
|
+
wheel while the dialog keeps its own keys. The dialog takes at most 70% of the terminal
|
|
84
|
+
height (at least 12 rows); a taller questionnaire scrolls its options inside that space,
|
|
85
|
+
keeping the header, the question, the focused option and the key hints visible.
|
|
74
86
|
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
press — that message names your configured key.
|
|
87
|
+
Wheel and trackpad scrolling reach the transcript only when the terminal reports them as
|
|
88
|
+
mouse events. A terminal with mouse reporting turned off (Warp, for one) converts them
|
|
89
|
+
into ↑/↓ key presses instead, which move between the dialog's options. `PageUp`/`PageDown`
|
|
90
|
+
(`Fn+↑`/`Fn+↓` on a Mac keyboard) scroll the transcript either way.
|
|
80
91
|
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
92
|
+
Two cases open the questionnaire as an overlay instead:
|
|
93
|
+
|
|
94
|
+
- **A second question while one is open.** Only one questionnaire fits in the editor area,
|
|
95
|
+
so the second covers the bottom of the transcript as an overlay.
|
|
96
|
+
- **A question arriving while another overlay, such as `/btw`, is open.** The question
|
|
97
|
+
stacks on top, so the question you see is the one your keys reach. `Ctrl+]` shrinks it to
|
|
98
|
+
its one-line row so `/btw` is readable behind it; the question keeps the keys, so `Esc`
|
|
99
|
+
cancels the question, and `/btw` closes after the question is answered or cancelled.
|
|
100
|
+
|
|
101
|
+
## Collapse mode
|
|
84
102
|
|
|
85
|
-
|
|
86
|
-
|
|
103
|
+
`Ctrl+]` gets the dialog out of the way. In the editor area it shrinks the questionnaire
|
|
104
|
+
to a single dim hint row for more room. The row keeps focus, so the same key brings the
|
|
105
|
+
questionnaire back with your answers intact.
|
|
106
|
+
|
|
107
|
+
When the questionnaire opened as an overlay for a second question, collapse marks the
|
|
108
|
+
overlay hidden in Pi's overlay stack, so the transcript it was covering
|
|
109
|
+
becomes readable and chat scrolling resumes. The first time you collapse, Pi notifies you
|
|
110
|
+
with the key to press — that message names your configured key. Because Pi routes no
|
|
111
|
+
input to a hidden overlay, the collapse key is additionally captured at the raw terminal
|
|
112
|
+
level. It only acts when the questionnaire is hidden or focused, so a different overlay
|
|
113
|
+
on top of it (for example `/btw`) keeps its keystrokes. A question that opened on top of
|
|
114
|
+
an overlay that was already showing (for example `/btw`) is never hidden this way: collapse
|
|
115
|
+
shrinks it to the one-line row and it keeps focus, because Pi closes overlays from the top
|
|
116
|
+
of the stack and would otherwise remove the hidden question when `/btw` closes.
|
|
117
|
+
|
|
118
|
+
While collapsed, every keystroke other than cancel or expand is ignored, so you cannot
|
|
119
|
+
mutate answers you cannot see.
|
|
87
120
|
|
|
88
121
|
The default `ctrl+]` is free in Terminal.app, iTerm2, Warp, tmux, zellij and screen. On
|
|
89
122
|
keyboard layouts where `]` sits on the shifted layer — Latin American `es-AR` / `es-MX`,
|
|
@@ -77,13 +77,14 @@ code. The `content[0].text` string is written for the model, not for a log.
|
|
|
77
77
|
questionIndex: number,
|
|
78
78
|
question: string,
|
|
79
79
|
kind: "option" | "custom" | "multi",
|
|
80
|
-
answer: string | null, // option label,
|
|
81
|
-
selected?: string[], // chosen labels, multi-select only
|
|
80
|
+
answer: string | null, // option label, custom text, or null
|
|
81
|
+
selected?: string[], // chosen labels, multi-select only; can accompany answer
|
|
82
82
|
notes?: string, // free-text note, when you wrote one
|
|
83
83
|
preview?: string, // echoed back when the chosen option carried a preview
|
|
84
84
|
}>,
|
|
85
85
|
cancelled: boolean,
|
|
86
86
|
globalNote?: string, // Submit-tab note; present even when cancelled is true
|
|
87
|
+
unanswered?: number[], // indexes of questions left blank on a partial submit
|
|
87
88
|
error?: QuestionnaireError, // one of the codes above
|
|
88
89
|
}
|
|
89
90
|
}
|
|
@@ -100,7 +101,9 @@ question is blank.
|
|
|
100
101
|
|
|
101
102
|
Cancelling, and any result with neither answer segments nor a global note, both collapse
|
|
102
103
|
to the single string `User declined to answer questions` so the model sees one canonical
|
|
103
|
-
signal. Partial submission is allowed:
|
|
104
|
+
signal. Partial submission is allowed: the questions left blank are named in an
|
|
105
|
+
`unanswered: "<question>", …` segment after the answers (before any global note), and their
|
|
106
|
+
indexes are in `details.unanswered`. Both are absent when every question is answered.
|
|
104
107
|
A cancelled result always reads as the decline in text; its note, if any, survives only
|
|
105
108
|
in `details.globalNote`.
|
|
106
109
|
|
|
@@ -22,10 +22,12 @@
|
|
|
22
22
|
|
|
23
23
|
"preview.no_preview": "Keine Vorschau verfügbar",
|
|
24
24
|
"preview.notes_affordance": "Notizen: drücke n, um Notizen hinzuzufügen",
|
|
25
|
+
"preview.notes_edit_affordance": "Notiz gespeichert: drücke n zum Bearbeiten",
|
|
25
26
|
"notes.header": "Notizen:",
|
|
27
|
+
"notes.saved_label": "Notiz zu dieser Antwort:",
|
|
26
28
|
|
|
27
29
|
"editor.failed": "Externer Editor fehlgeschlagen",
|
|
28
30
|
|
|
29
|
-
"rpc.multi_instructions": "Gib die Nummern aller zutreffenden Optionen durch
|
|
31
|
+
"rpc.multi_instructions": "Gib die Nummern aller zutreffenden Optionen durch Kommas getrennt ein (z. B. \"1,3\"). Füge \"; eigene Antwort\" hinzu, um eigenen Text einzuschließen, oder gib nur eigenen Text ein.",
|
|
30
32
|
"rpc.custom_answer_title": "Gib deine Antwort ein:"
|
|
31
33
|
}
|
|
@@ -24,11 +24,13 @@
|
|
|
24
24
|
|
|
25
25
|
"preview.no_preview": "No preview available",
|
|
26
26
|
"preview.notes_affordance": "Notes: press n to add notes",
|
|
27
|
+
"preview.notes_edit_affordance": "Note saved: press n to edit",
|
|
27
28
|
"notes.header": "Notes:",
|
|
29
|
+
"notes.saved_label": "Note for this answer:",
|
|
28
30
|
"notes.global_header": "Global note:",
|
|
29
31
|
|
|
30
32
|
"editor.failed": "External editor failed",
|
|
31
33
|
|
|
32
|
-
"rpc.multi_instructions": "Enter the numbers of all that apply, comma-separated (e.g. \"1,3\")
|
|
34
|
+
"rpc.multi_instructions": "Enter the numbers of all that apply, comma-separated (e.g. \"1,3\"). Add \"; custom answer\" to include your own text, or type only custom text.",
|
|
33
35
|
"rpc.custom_answer_title": "Type your answer:"
|
|
34
36
|
}
|
|
@@ -22,10 +22,12 @@
|
|
|
22
22
|
|
|
23
23
|
"preview.no_preview": "Vista previa no disponible",
|
|
24
24
|
"preview.notes_affordance": "Notas: pulsa n para añadir notas",
|
|
25
|
+
"preview.notes_edit_affordance": "Nota guardada: pulsa n para editarla",
|
|
25
26
|
"notes.header": "Notas:",
|
|
27
|
+
"notes.saved_label": "Nota para esta respuesta:",
|
|
26
28
|
|
|
27
29
|
"editor.failed": "Error del editor externo",
|
|
28
30
|
|
|
29
|
-
"rpc.multi_instructions": "Introduce los números de todas las opciones que
|
|
31
|
+
"rpc.multi_instructions": "Introduce los números de todas las opciones que correspondan, separados por comas (p. ej. \"1,3\"). Añade \"; respuesta propia\" para incluir texto propio, o escribe solo texto propio.",
|
|
30
32
|
"rpc.custom_answer_title": "Escribe tu respuesta:"
|
|
31
33
|
}
|
|
@@ -22,10 +22,12 @@
|
|
|
22
22
|
|
|
23
23
|
"preview.no_preview": "Aucun aperçu disponible",
|
|
24
24
|
"preview.notes_affordance": "Notes : appuyez sur n pour ajouter des notes",
|
|
25
|
+
"preview.notes_edit_affordance": "Note enregistrée : appuyez sur n pour la modifier",
|
|
25
26
|
"notes.header": "Notes :",
|
|
27
|
+
"notes.saved_label": "Note pour cette réponse :",
|
|
26
28
|
|
|
27
29
|
"editor.failed": "Échec de l’éditeur externe",
|
|
28
30
|
|
|
29
|
-
"rpc.multi_instructions": "Saisissez les numéros de toutes les options applicables, séparés par des virgules (p. ex. « 1,3 »)
|
|
31
|
+
"rpc.multi_instructions": "Saisissez les numéros de toutes les options applicables, séparés par des virgules (p. ex. « 1,3 »). Ajoutez « ; réponse libre » pour inclure votre propre texte, ou saisissez uniquement ce texte.",
|
|
30
32
|
"rpc.custom_answer_title": "Tapez votre réponse :"
|
|
31
33
|
}
|
|
@@ -22,10 +22,12 @@
|
|
|
22
22
|
|
|
23
23
|
"preview.no_preview": "Pré-visualização indisponível",
|
|
24
24
|
"preview.notes_affordance": "Notas: pressione n para adicionar notas",
|
|
25
|
+
"preview.notes_edit_affordance": "Nota salva: pressione n para editar",
|
|
25
26
|
"notes.header": "Notas:",
|
|
27
|
+
"notes.saved_label": "Nota para esta resposta:",
|
|
26
28
|
|
|
27
29
|
"editor.failed": "Falha no editor externo",
|
|
28
30
|
|
|
29
|
-
"rpc.multi_instructions": "Digite os números de todas as opções aplicáveis, separados por
|
|
31
|
+
"rpc.multi_instructions": "Digite os números de todas as opções aplicáveis, separados por vírgulas (ex.: \"1,3\"). Adicione \"; resposta própria\" para incluir texto próprio, ou digite apenas esse texto.",
|
|
30
32
|
"rpc.custom_answer_title": "Digite sua resposta:"
|
|
31
33
|
}
|
|
@@ -22,10 +22,12 @@
|
|
|
22
22
|
|
|
23
23
|
"preview.no_preview": "Pré-visualização indisponível",
|
|
24
24
|
"preview.notes_affordance": "Notas: prima n para adicionar notas",
|
|
25
|
+
"preview.notes_edit_affordance": "Nota guardada: prima n para editar",
|
|
25
26
|
"notes.header": "Notas:",
|
|
27
|
+
"notes.saved_label": "Nota para esta resposta:",
|
|
26
28
|
|
|
27
29
|
"editor.failed": "Falha no editor externo",
|
|
28
30
|
|
|
29
|
-
"rpc.multi_instructions": "Introduza os números de todas as opções aplicáveis, separados por vírgulas (ex.: \"1,3\")
|
|
31
|
+
"rpc.multi_instructions": "Introduza os números de todas as opções aplicáveis, separados por vírgulas (ex.: \"1,3\"). Adicione \"; resposta própria\" para incluir texto próprio, ou escreva apenas esse texto.",
|
|
30
32
|
"rpc.custom_answer_title": "Escreva a sua resposta:"
|
|
31
33
|
}
|
|
@@ -22,10 +22,12 @@
|
|
|
22
22
|
|
|
23
23
|
"preview.no_preview": "Предпросмотр недоступен",
|
|
24
24
|
"preview.notes_affordance": "Заметки: нажмите n, чтобы добавить заметки",
|
|
25
|
+
"preview.notes_edit_affordance": "Заметка сохранена: нажмите n, чтобы изменить",
|
|
25
26
|
"notes.header": "Заметки:",
|
|
27
|
+
"notes.saved_label": "Заметка к этому ответу:",
|
|
26
28
|
|
|
27
29
|
"editor.failed": "Ошибка внешнего редактора",
|
|
28
30
|
|
|
29
|
-
"rpc.multi_instructions": "Введите номера всех подходящих вариантов через запятую (например, \"1,3\") или введите
|
|
31
|
+
"rpc.multi_instructions": "Введите номера всех подходящих вариантов через запятую (например, \"1,3\"). Добавьте \"; свой ответ\", чтобы включить собственный текст, или введите только этот текст.",
|
|
30
32
|
"rpc.custom_answer_title": "Введите свой ответ:"
|
|
31
33
|
}
|
|
@@ -22,10 +22,12 @@
|
|
|
22
22
|
|
|
23
23
|
"preview.no_preview": "Попередній перегляд недоступний",
|
|
24
24
|
"preview.notes_affordance": "Нотатки: натисніть n, щоб додати нотатки",
|
|
25
|
+
"preview.notes_edit_affordance": "Нотатку збережено: натисніть n, щоб змінити",
|
|
25
26
|
"notes.header": "Нотатки:",
|
|
27
|
+
"notes.saved_label": "Нотатка до цієї відповіді:",
|
|
26
28
|
|
|
27
29
|
"editor.failed": "Помилка зовнішнього редактора",
|
|
28
30
|
|
|
29
|
-
"rpc.multi_instructions": "Введіть номери всіх відповідних варіантів через кому (наприклад, \"1,3\") або введіть
|
|
31
|
+
"rpc.multi_instructions": "Введіть номери всіх відповідних варіантів через кому (наприклад, \"1,3\"). Додайте \"; власна відповідь\", щоб включити власний текст, або введіть лише цей текст.",
|
|
30
32
|
"rpc.custom_answer_title": "Введіть свою відповідь:"
|
|
31
33
|
}
|