@oh-my-pi/pi-coding-agent 6.9.69 → 8.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +219 -51
- package/README.md +1 -1
- package/docs/hooks.md +2 -2
- package/docs/sdk.md +1 -1
- package/examples/sdk/04-skills.ts +1 -1
- package/package.json +10 -10
- package/scripts/format-prompts.ts +143 -0
- package/scripts/generate-template.ts +1 -1
- package/src/cli/args.ts +3 -3
- package/src/cli/config-cli.ts +4 -4
- package/src/cli/file-processor.ts +3 -3
- package/src/cli/list-models.ts +2 -2
- package/src/cli/plugin-cli.ts +3 -3
- package/src/cli/session-picker.ts +2 -2
- package/src/cli/setup-cli.ts +2 -2
- package/src/cli/stats-cli.ts +1 -1
- package/src/cli/update-cli.ts +2 -2
- package/src/{core → config}/keybindings.ts +1 -1
- package/src/{core → config}/model-registry.ts +8 -1
- package/src/{core → config}/model-resolver.ts +3 -3
- package/src/{core → config}/prompt-templates.ts +2 -2
- package/src/{core → config}/settings-manager.ts +6 -6
- package/src/{core/cursor/exec-bridge.ts → cursor.ts} +4 -4
- package/src/discovery/agents-md.ts +4 -4
- package/src/discovery/builtin.ts +17 -17
- package/src/discovery/claude.ts +12 -12
- package/src/discovery/cline.ts +6 -6
- package/src/discovery/codex.ts +21 -21
- package/src/discovery/cursor.ts +9 -9
- package/src/discovery/gemini.ts +9 -9
- package/src/discovery/github.ts +6 -6
- package/src/discovery/helpers.ts +4 -4
- package/src/discovery/index.ts +16 -16
- package/src/discovery/mcp-json.ts +4 -4
- package/src/discovery/ssh.ts +4 -4
- package/src/discovery/vscode.ts +4 -4
- package/src/discovery/windsurf.ts +6 -6
- package/src/{core/tools/exa → exa}/company.ts +2 -3
- package/src/{core/tools/exa → exa}/index.ts +2 -2
- package/src/{core/tools/exa → exa}/linkedin.ts +2 -3
- package/src/{core/tools/exa → exa}/mcp-client.ts +2 -2
- package/src/{core/tools/exa → exa}/render.ts +3 -3
- package/src/{core/tools/exa → exa}/researcher.ts +1 -1
- package/src/{core/tools/exa → exa}/search.ts +2 -10
- package/src/{core/tools/exa → exa}/websets.ts +1 -1
- package/src/{core → exec}/bash-executor.ts +23 -7
- package/src/{core → export}/custom-share.ts +1 -1
- package/src/{core/export-html → export/html}/index.ts +3 -3
- package/src/{core → export}/ttsr.ts +2 -2
- package/src/{core → extensibility}/custom-commands/bundled/review/index.ts +4 -4
- package/src/{core → extensibility}/custom-commands/loader.ts +3 -3
- package/src/{core → extensibility}/custom-commands/types.ts +1 -1
- package/src/{core → extensibility}/custom-tools/loader.ts +9 -9
- package/src/{core → extensibility}/custom-tools/types.ts +6 -6
- package/src/{core → extensibility}/custom-tools/wrapper.ts +1 -1
- package/src/{core → extensibility}/extensions/loader.ts +8 -8
- package/src/{core → extensibility}/extensions/runner.ts +3 -3
- package/src/{core → extensibility}/extensions/types.ts +15 -15
- package/src/{core → extensibility}/extensions/wrapper.ts +1 -1
- package/src/{core → extensibility}/hooks/index.ts +1 -1
- package/src/{core → extensibility}/hooks/loader.ts +7 -7
- package/src/{core → extensibility}/hooks/runner.ts +4 -4
- package/src/{core → extensibility}/hooks/types.ts +9 -9
- package/src/{core → extensibility}/plugins/doctor.ts +1 -1
- package/src/{core → extensibility}/plugins/installer.ts +2 -3
- package/src/{core → extensibility}/plugins/paths.ts +1 -1
- package/src/{core → extensibility}/skills.ts +8 -48
- package/src/{core → extensibility}/slash-commands.ts +6 -6
- package/src/index.ts +127 -128
- package/src/internal-urls/agent-protocol.ts +126 -0
- package/src/internal-urls/artifact-protocol.ts +93 -0
- package/src/internal-urls/index.ts +28 -0
- package/src/internal-urls/json-query.ts +126 -0
- package/src/internal-urls/router.ts +69 -0
- package/src/internal-urls/rule-protocol.ts +56 -0
- package/src/internal-urls/skill-protocol.ts +112 -0
- package/src/internal-urls/types.ts +48 -0
- package/src/{core/python-executor.ts → ipy/executor.ts} +74 -13
- package/src/{core/python-gateway-coordinator.ts → ipy/gateway-coordinator.ts} +40 -270
- package/src/{core/python-kernel.ts → ipy/kernel.ts} +38 -10
- package/src/{core/python-prelude.py → ipy/prelude.py} +201 -8
- package/src/ipy/prelude.ts +3 -0
- package/src/{core/tools/lsp → lsp}/client.ts +7 -6
- package/src/{core/tools/lsp → lsp}/clients/biome-client.ts +1 -1
- package/src/{core/tools/lsp → lsp}/clients/index.ts +1 -1
- package/src/{core/tools/lsp → lsp}/clients/lsp-linter-client.ts +4 -4
- package/src/{core/tools/lsp → lsp}/config.ts +1 -1
- package/src/{core/tools/lsp → lsp}/index.ts +29 -17
- package/src/{core/tools/lsp → lsp}/render.ts +2 -2
- package/src/{core/tools/lsp → lsp}/types.ts +14 -16
- package/src/{core/tools/lsp → lsp}/utils.ts +1 -1
- package/src/main.ts +12 -12
- package/src/{core/mcp → mcp}/config.ts +8 -8
- package/src/{core/mcp → mcp}/loader.ts +5 -6
- package/src/{core/mcp → mcp}/manager.ts +2 -2
- package/src/{core/mcp → mcp}/tool-bridge.ts +35 -6
- package/src/{core/mcp → mcp}/tool-cache.ts +1 -1
- package/src/{core/mcp → mcp}/transports/http.ts +7 -1
- package/src/{core/mcp → mcp}/transports/stdio.ts +1 -1
- package/src/{core/mcp → mcp}/types.ts +1 -1
- package/src/migrations.ts +2 -2
- package/src/modes/{interactive/components → components}/armin.ts +1 -1
- package/src/modes/{interactive/components → components}/assistant-message.ts +1 -1
- package/src/modes/{interactive/components → components}/bash-execution.ts +37 -29
- package/src/modes/{interactive/components → components}/bordered-loader.ts +1 -1
- package/src/modes/{interactive/components → components}/branch-summary-message.ts +2 -2
- package/src/modes/{interactive/components → components}/compaction-summary-message.ts +2 -2
- package/src/modes/{interactive/components → components}/custom-message.ts +3 -3
- package/src/modes/{interactive/components → components}/diff.ts +1 -1
- package/src/modes/{interactive/components → components}/dynamic-border.ts +1 -1
- package/src/modes/{interactive/components → components}/extensions/extension-dashboard.ts +3 -3
- package/src/modes/{interactive/components → components}/extensions/extension-list.ts +2 -2
- package/src/modes/{interactive/components → components}/extensions/inspector-panel.ts +1 -1
- package/src/modes/{interactive/components → components}/extensions/state-manager.ts +11 -17
- package/src/modes/{interactive/components → components}/extensions/types.ts +1 -1
- package/src/modes/{interactive/components → components}/footer.ts +3 -3
- package/src/modes/{interactive/components → components}/history-search.ts +2 -2
- package/src/modes/{interactive/components → components}/hook-editor.ts +1 -1
- package/src/modes/{interactive/components → components}/hook-input.ts +1 -1
- package/src/modes/{interactive/components → components}/hook-message.ts +3 -3
- package/src/modes/{interactive/components → components}/hook-selector.ts +1 -1
- package/src/modes/{interactive/components → components}/keybinding-hints.ts +2 -2
- package/src/modes/{interactive/components → components}/login-dialog.ts +1 -1
- package/src/modes/{interactive/components → components}/model-selector.ts +5 -5
- package/src/modes/{interactive/components → components}/oauth-selector.ts +2 -2
- package/src/modes/{interactive/components → components}/plugin-settings.ts +3 -3
- package/src/modes/{interactive/components → components}/python-execution.ts +35 -24
- package/src/modes/{interactive/components → components}/queue-mode-selector.ts +1 -1
- package/src/modes/{interactive/components → components}/read-tool-group.ts +2 -2
- package/src/modes/{interactive/components → components}/session-selector.ts +3 -3
- package/src/modes/{interactive/components → components}/settings-defs.ts +2 -2
- package/src/modes/{interactive/components → components}/settings-selector.ts +2 -2
- package/src/modes/{interactive/components → components}/show-images-selector.ts +1 -1
- package/src/modes/{interactive/components → components}/status-line/segments.ts +2 -2
- package/src/modes/{interactive/components → components}/status-line/separators.ts +1 -1
- package/src/modes/{interactive/components → components}/status-line/types.ts +2 -2
- package/src/modes/{interactive/components → components}/status-line-segment-editor.ts +2 -2
- package/src/modes/{interactive/components → components}/status-line.ts +3 -3
- package/src/modes/{interactive/components → components}/theme-selector.ts +1 -1
- package/src/modes/{interactive/components → components}/thinking-selector.ts +1 -1
- package/src/modes/{interactive/components → components}/todo-display.ts +3 -4
- package/src/modes/{interactive/components → components}/todo-reminder.ts +2 -2
- package/src/modes/{interactive/components → components}/tool-execution.ts +8 -8
- package/src/modes/{interactive/components → components}/tree-selector.ts +3 -3
- package/src/modes/{interactive/components → components}/ttsr-notification.ts +2 -2
- package/src/modes/{interactive/components → components}/user-message-selector.ts +1 -1
- package/src/modes/{interactive/components → components}/user-message.ts +1 -1
- package/src/modes/{interactive/components → components}/welcome.ts +2 -2
- package/src/modes/{interactive/controllers → controllers}/command-controller.ts +381 -30
- package/src/modes/{interactive/controllers → controllers}/event-controller.ts +9 -9
- package/src/modes/{interactive/controllers → controllers}/extension-ui-controller.ts +8 -8
- package/src/modes/{interactive/controllers → controllers}/input-controller.ts +61 -13
- package/src/modes/{interactive/controllers → controllers}/selector-controller.ts +16 -16
- package/src/modes/index.ts +1 -1
- package/src/modes/{interactive/interactive-mode.ts → interactive-mode.ts} +20 -15
- package/src/modes/print-mode.ts +1 -1
- package/src/modes/rpc/rpc-client.ts +3 -3
- package/src/modes/rpc/rpc-mode.ts +3 -3
- package/src/modes/rpc/rpc-types.ts +3 -3
- package/src/modes/{interactive/theme → theme}/theme.ts +1 -1
- package/src/modes/{interactive/types.ts → types.ts} +10 -10
- package/src/modes/{interactive/utils → utils}/ui-helpers.ts +20 -27
- package/src/{core/tools/patch → patch}/applicator.ts +1 -1
- package/src/{core/tools/patch → patch}/diff.ts +1 -1
- package/src/{core/tools/patch → patch}/index.ts +31 -36
- package/src/{core/tools/patch → patch}/shared.ts +9 -6
- package/src/prompts/agents/explore.md +83 -46
- package/src/prompts/agents/init.md +9 -4
- package/src/prompts/agents/plan.md +8 -7
- package/src/prompts/agents/reviewer.md +36 -18
- package/src/prompts/agents/task.md +4 -4
- package/src/prompts/compaction/branch-summary-preamble.md +0 -1
- package/src/prompts/review-request.md +0 -1
- package/src/prompts/system/custom-system-prompt.md +2 -14
- package/src/prompts/system/file-operations.md +0 -2
- package/src/prompts/system/system-prompt.md +182 -171
- package/src/prompts/system/web-search.md +26 -0
- package/src/prompts/tools/ask.md +31 -24
- package/src/prompts/tools/bash.md +20 -17
- package/src/prompts/tools/calculator.md +9 -5
- package/src/prompts/tools/fetch.md +16 -0
- package/src/prompts/tools/find.md +15 -5
- package/src/prompts/tools/gemini-image.md +21 -6
- package/src/prompts/tools/grep.md +28 -12
- package/src/prompts/tools/lsp.md +35 -14
- package/src/prompts/tools/patch.md +39 -41
- package/src/prompts/tools/python.md +59 -77
- package/src/prompts/tools/read.md +23 -22
- package/src/prompts/tools/replace.md +19 -12
- package/src/prompts/tools/ssh.md +21 -28
- package/src/prompts/tools/task.md +54 -44
- package/src/prompts/tools/todo-write.md +52 -163
- package/src/prompts/tools/web-search.md +16 -9
- package/src/prompts/tools/write.md +13 -2
- package/src/{core/sdk.ts → sdk.ts} +65 -34
- package/src/{core → session}/agent-session.ts +157 -41
- package/src/{core → session}/agent-storage.ts +2 -2
- package/src/session/artifacts.ts +110 -0
- package/src/{core → session}/auth-storage.ts +525 -203
- package/src/{core → session}/compaction/branch-summarization.ts +5 -5
- package/src/{core → session}/compaction/compaction.ts +6 -6
- package/src/{core → session}/compaction/utils.ts +3 -3
- package/src/{core → session}/history-storage.ts +1 -1
- package/src/{core → session}/messages.ts +6 -8
- package/src/{core → session}/session-manager.ts +2 -2
- package/src/{core → session}/storage-migration.ts +2 -2
- package/src/session/streaming-output.ts +177 -0
- package/src/{core/ssh → ssh}/connection-manager.ts +1 -1
- package/src/{core/ssh → ssh}/ssh-executor.ts +19 -4
- package/src/{core/ssh → ssh}/sshfs-mount.ts +1 -1
- package/src/{core/system-prompt.ts → system-prompt.ts} +8 -37
- package/src/{core/tools/task → task}/agents.ts +8 -8
- package/src/{core/tools/task → task}/commands.ts +5 -6
- package/src/{core/tools/task → task}/discovery.ts +3 -3
- package/src/{core/tools/task → task}/executor.ts +34 -44
- package/src/{core/tools/task → task}/index.ts +206 -50
- package/src/{core/tools/task → task}/render.ts +80 -23
- package/src/{core/tools/task → task}/subprocess-tool-registry.ts +1 -1
- package/src/task/template.ts +47 -0
- package/src/{core/tools/task → task}/types.ts +19 -27
- package/src/{core/tools/task → task}/worker-protocol.ts +8 -4
- package/src/{core/tools/task → task}/worker.ts +34 -29
- package/src/task/worktree.ts +166 -0
- package/src/{core/tools → tools}/ask.ts +13 -21
- package/src/{core/tools → tools}/bash-interceptor.ts +1 -1
- package/src/{core/tools → tools}/bash.ts +61 -63
- package/src/{core/tools → tools}/calculator.ts +4 -4
- package/src/{core/tools → tools}/complete.ts +1 -1
- package/src/{core/tools → tools}/context.ts +2 -2
- package/src/{core/tools/web-fetch.ts → tools/fetch.ts} +97 -76
- package/src/{core/tools → tools}/find.ts +96 -107
- package/src/{core/tools → tools}/gemini-image.ts +420 -29
- package/src/{core/tools → tools}/grep.ts +155 -164
- package/src/{core/tools → tools}/index.ts +63 -56
- package/src/tools/list-limit.ts +40 -0
- package/src/{core/tools → tools}/ls.ts +44 -35
- package/src/{core/tools → tools}/notebook.ts +3 -3
- package/src/tools/output-meta.ts +443 -0
- package/src/tools/output-utils.ts +63 -0
- package/src/{core/tools → tools}/python.ts +106 -89
- package/src/tools/read.ts +882 -0
- package/src/{core/tools → tools}/render-utils.ts +1 -1
- package/src/{core/tools → tools}/renderers.ts +8 -10
- package/src/{core/tools → tools}/review.ts +2 -2
- package/src/{core/tools → tools}/ssh.ts +56 -59
- package/src/{core/tools → tools}/todo-write.ts +12 -23
- package/src/tools/tool-errors.ts +95 -0
- package/src/tools/tool-result.ts +92 -0
- package/src/{core/tools → tools}/truncate.ts +2 -2
- package/src/{core/tools → tools}/write.ts +15 -13
- package/src/utils/changelog.ts +1 -1
- package/src/{core → utils}/file-mentions.ts +4 -4
- package/src/utils/image-convert.ts +1 -1
- package/src/utils/image-resize.ts +1 -1
- package/src/utils/shell.ts +1 -1
- package/src/{core → utils}/title-generator.ts +4 -4
- package/src/utils/tools-manager.ts +1 -1
- package/src/{core/tools/web-scrapers → web/scrapers}/choosealicense.ts +1 -1
- package/src/{core/tools/web-scrapers → web/scrapers}/twitter.ts +3 -2
- package/src/{core/tools/web-scrapers → web/scrapers}/types.ts +4 -2
- package/src/{core/tools/web-scrapers → web/scrapers}/utils.ts +1 -1
- package/src/{core/tools/web-scrapers → web/scrapers}/youtube.ts +14 -13
- package/src/{core/tools/web-search → web/search}/auth.ts +4 -4
- package/src/{core/tools/web-search → web/search}/index.ts +22 -71
- package/src/{core/tools/web-search → web/search}/providers/anthropic.ts +7 -10
- package/src/{core/tools/web-search → web/search}/providers/exa.ts +2 -2
- package/src/{core/tools/web-search → web/search}/providers/perplexity.ts +4 -16
- package/src/{core/tools/web-search → web/search}/render.ts +3 -3
- package/scripts/migrate-sessions.sh +0 -93
- package/src/core/index.ts +0 -56
- package/src/core/python-prelude.ts +0 -3
- package/src/core/ssh-executor.ts +0 -5
- package/src/core/streaming-output.ts +0 -115
- package/src/core/tools/output.ts +0 -519
- package/src/core/tools/read.ts +0 -717
- package/src/core/tools/task/template.ts +0 -37
- package/src/prompts/tools/output.md +0 -47
- package/src/prompts/tools/web-fetch.md +0 -9
- /package/src/{core/tools/exa → exa}/types.ts +0 -0
- /package/src/{core → exec}/exec.ts +0 -0
- /package/src/{core/export-html → export/html}/template.css +0 -0
- /package/src/{core/export-html → export/html}/template.generated.ts +0 -0
- /package/src/{core/export-html → export/html}/template.html +0 -0
- /package/src/{core/export-html → export/html}/template.js +0 -0
- /package/src/{core/export-html → export/html}/template.macro.ts +0 -0
- /package/src/{core/export-html → export/html}/vendor/highlight.min.js +0 -0
- /package/src/{core/export-html → export/html}/vendor/marked.min.js +0 -0
- /package/src/{core → extensibility}/custom-commands/index.ts +0 -0
- /package/src/{core → extensibility}/custom-tools/index.ts +0 -0
- /package/src/{core → extensibility}/extensions/index.ts +0 -0
- /package/src/{core → extensibility}/hooks/tool-wrapper.ts +0 -0
- /package/src/{core → extensibility}/plugins/index.ts +0 -0
- /package/src/{core → extensibility}/plugins/loader.ts +0 -0
- /package/src/{core → extensibility}/plugins/manager.ts +0 -0
- /package/src/{core → extensibility}/plugins/parser.ts +0 -0
- /package/src/{core → extensibility}/plugins/types.ts +0 -0
- /package/src/{core/python-modules.ts → ipy/modules.ts} +0 -0
- /package/src/{core/tools/lsp → lsp}/defaults.json +0 -0
- /package/src/{core/tools/lsp → lsp}/edits.ts +0 -0
- /package/src/{core/tools/lsp → lsp}/lspmux.ts +0 -0
- /package/src/{core/tools/lsp → lsp}/rust-analyzer.ts +0 -0
- /package/src/{core/mcp → mcp}/client.ts +0 -0
- /package/src/{core/mcp → mcp}/index.ts +0 -0
- /package/src/{core/mcp → mcp}/json-rpc.ts +0 -0
- /package/src/{core/mcp → mcp}/transports/index.ts +0 -0
- /package/src/modes/{interactive/components → components}/countdown-timer.ts +0 -0
- /package/src/modes/{interactive/components → components}/custom-editor.ts +0 -0
- /package/src/modes/{interactive/components → components}/extensions/index.ts +0 -0
- /package/src/modes/{interactive/components → components}/index.ts +0 -0
- /package/src/modes/{interactive/components → components}/status-line/index.ts +0 -0
- /package/src/modes/{interactive/components → components}/status-line/presets.ts +0 -0
- /package/src/modes/{interactive/components → components}/visual-truncate.ts +0 -0
- /package/src/modes/{interactive/theme → theme}/dark.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/alabaster.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/amethyst.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/anthracite.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/basalt.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/birch.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-abyss.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-arctic.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-aurora.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-catppuccin.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-cavern.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-copper.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-cosmos.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-cyberpunk.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-dracula.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-eclipse.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-ember.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-equinox.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-forest.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-github.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-gruvbox.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-lavender.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-lunar.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-midnight.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-monochrome.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-monokai.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-nebula.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-nord.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-ocean.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-one.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-rainforest.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-reef.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-retro.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-rose-pine.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-sakura.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-slate.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-solarized.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-solstice.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-starfall.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-sunset.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-swamp.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-synthwave.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-taiga.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-terminal.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-tokyo-night.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-tundra.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-twilight.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/dark-volcanic.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/graphite.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/index.ts +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-arctic.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-aurora-day.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-canyon.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-catppuccin.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-cirrus.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-coral.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-cyberpunk.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-dawn.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-dunes.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-eucalyptus.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-forest.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-frost.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-github.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-glacier.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-gruvbox.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-haze.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-honeycomb.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-lagoon.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-lavender.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-meadow.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-mint.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-monochrome.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-ocean.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-one.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-opal.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-orchard.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-paper.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-prism.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-retro.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-sand.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-savanna.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-solarized.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-soleil.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-sunset.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-synthwave.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-tokyo-night.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-wetland.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/light-zenith.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/limestone.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/mahogany.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/marble.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/obsidian.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/onyx.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/pearl.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/porcelain.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/quartz.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/sandstone.json +0 -0
- /package/src/modes/{interactive/theme → theme}/defaults/titanium.json +0 -0
- /package/src/modes/{interactive/theme → theme}/light.json +0 -0
- /package/src/modes/{interactive/theme → theme}/theme-schema.json +0 -0
- /package/src/{core/tools/patch → patch}/fuzzy.ts +0 -0
- /package/src/{core/tools/patch → patch}/normalize.ts +0 -0
- /package/src/{core/tools/patch → patch}/normative.ts +0 -0
- /package/src/{core/tools/patch → patch}/parser.ts +0 -0
- /package/src/{core/tools/patch → patch}/types.ts +0 -0
- /package/src/{core → session}/compaction/index.ts +0 -0
- /package/src/{core → session}/session-storage.ts +0 -0
- /package/src/{core/tools/task → task}/name-generator.ts +0 -0
- /package/src/{core/tools/task → task}/omp-command.ts +0 -0
- /package/src/{core/tools/task → task}/parallel.ts +0 -0
- /package/src/{core/tools → tools}/jtd-to-json-schema.ts +0 -0
- /package/src/{core/tools → tools}/path-utils.ts +0 -0
- /package/src/{core → utils}/event-bus.ts +0 -0
- /package/src/{core → utils}/frontmatter.ts +0 -0
- /package/src/{core → utils}/terminal-notify.ts +0 -0
- /package/src/{core → utils}/timings.ts +0 -0
- /package/src/{core → utils}/utils.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/artifacthub.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/arxiv.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/aur.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/biorxiv.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/bluesky.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/brew.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/cheatsh.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/chocolatey.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/cisa-kev.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/clojars.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/coingecko.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/crates-io.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/crossref.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/devto.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/discogs.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/discourse.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/dockerhub.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/fdroid.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/firefox-addons.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/flathub.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/github-gist.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/github.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/gitlab.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/go-pkg.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/hackage.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/hackernews.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/hex.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/huggingface.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/iacr.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/index.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/jetbrains-marketplace.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/lemmy.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/lobsters.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/mastodon.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/maven.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/mdn.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/metacpan.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/musicbrainz.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/npm.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/nuget.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/nvd.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/ollama.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/open-vsx.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/opencorporates.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/openlibrary.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/orcid.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/osv.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/packagist.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/pub-dev.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/pubmed.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/pypi.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/rawg.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/readthedocs.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/reddit.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/repology.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/rfc.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/rubygems.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/searchcode.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/sec-edgar.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/semantic-scholar.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/snapcraft.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/sourcegraph.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/spdx.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/spotify.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/stackoverflow.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/terraform.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/tldr.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/vimeo.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/vscode-marketplace.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/w3c.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/wikidata.ts +0 -0
- /package/src/{core/tools/web-scrapers → web/scrapers}/wikipedia.ts +0 -0
- /package/src/{core/tools/web-search → web/search}/types.ts +0 -0
|
@@ -3,29 +3,96 @@ name: explore
|
|
|
3
3
|
description: Fast read-only codebase scout that returns compressed context for handoff
|
|
4
4
|
tools: read, grep, find, ls, bash
|
|
5
5
|
model: pi/smol, haiku, flash, mini
|
|
6
|
+
output:
|
|
7
|
+
properties:
|
|
8
|
+
query:
|
|
9
|
+
metadata:
|
|
10
|
+
description: One-line summary of what was searched
|
|
11
|
+
type: string
|
|
12
|
+
files:
|
|
13
|
+
metadata:
|
|
14
|
+
description: Files examined with exact line ranges
|
|
15
|
+
elements:
|
|
16
|
+
properties:
|
|
17
|
+
path:
|
|
18
|
+
metadata:
|
|
19
|
+
description: Absolute path to the file
|
|
20
|
+
type: string
|
|
21
|
+
line_start:
|
|
22
|
+
metadata:
|
|
23
|
+
description: First line read (1-indexed)
|
|
24
|
+
type: number
|
|
25
|
+
line_end:
|
|
26
|
+
metadata:
|
|
27
|
+
description: Last line read (1-indexed)
|
|
28
|
+
type: number
|
|
29
|
+
description:
|
|
30
|
+
metadata:
|
|
31
|
+
description: What this section contains
|
|
32
|
+
type: string
|
|
33
|
+
code:
|
|
34
|
+
metadata:
|
|
35
|
+
description: Critical types, interfaces, or functions extracted verbatim
|
|
36
|
+
elements:
|
|
37
|
+
properties:
|
|
38
|
+
path:
|
|
39
|
+
metadata:
|
|
40
|
+
description: Absolute path to the source file
|
|
41
|
+
type: string
|
|
42
|
+
line_start:
|
|
43
|
+
metadata:
|
|
44
|
+
description: First line of excerpt (1-indexed)
|
|
45
|
+
type: number
|
|
46
|
+
line_end:
|
|
47
|
+
metadata:
|
|
48
|
+
description: Last line of excerpt (1-indexed)
|
|
49
|
+
type: number
|
|
50
|
+
language:
|
|
51
|
+
metadata:
|
|
52
|
+
description: Language identifier for syntax highlighting
|
|
53
|
+
type: string
|
|
54
|
+
content:
|
|
55
|
+
metadata:
|
|
56
|
+
description: Verbatim code excerpt
|
|
57
|
+
type: string
|
|
58
|
+
architecture:
|
|
59
|
+
metadata:
|
|
60
|
+
description: Brief explanation of how the pieces connect
|
|
61
|
+
type: string
|
|
62
|
+
start_here:
|
|
63
|
+
metadata:
|
|
64
|
+
description: Recommended entry point for the receiving agent
|
|
65
|
+
properties:
|
|
66
|
+
path:
|
|
67
|
+
metadata:
|
|
68
|
+
description: Absolute path to start reading
|
|
69
|
+
type: string
|
|
70
|
+
reason:
|
|
71
|
+
metadata:
|
|
72
|
+
description: Why this file is the best starting point
|
|
73
|
+
type: string
|
|
6
74
|
---
|
|
7
75
|
|
|
8
|
-
|
|
76
|
+
<role>File search specialist and codebase scout. Quickly investigate a codebase and return structured findings that another agent can use without re-reading everything.</role>
|
|
9
77
|
|
|
10
|
-
|
|
78
|
+
<critical>
|
|
11
79
|
This is a READ-ONLY exploration task. You are STRICTLY PROHIBITED from:
|
|
12
|
-
|
|
13
80
|
- Creating or modifying files (no Write, Edit, touch, rm, mv, cp)
|
|
14
81
|
- Creating temporary files anywhere, including /tmp
|
|
15
82
|
- Using redirect operators (>, >>, |) or heredocs to write files
|
|
16
83
|
- Running commands that change system state (git add, git commit, npm install, pip install)
|
|
17
84
|
|
|
18
85
|
Your role is EXCLUSIVELY to search and analyze existing code.
|
|
86
|
+
</critical>
|
|
19
87
|
|
|
20
|
-
|
|
21
|
-
|
|
88
|
+
<strengths>
|
|
22
89
|
- Rapidly finding files using find (glob) patterns
|
|
23
90
|
- Searching code with powerful regex patterns
|
|
24
91
|
- Reading and analyzing file contents
|
|
25
92
|
- Tracing imports and dependencies
|
|
93
|
+
</strengths>
|
|
26
94
|
|
|
27
|
-
|
|
28
|
-
|
|
95
|
+
<directives>
|
|
29
96
|
- Use find for broad file pattern matching
|
|
30
97
|
- Use grep for searching file contents with regex
|
|
31
98
|
- Use read when you know the specific file path
|
|
@@ -33,52 +100,22 @@ Guidelines:
|
|
|
33
100
|
- Spawn multiple parallel tool calls wherever possible—you are meant to be fast
|
|
34
101
|
- Return file paths as absolute paths in your final response
|
|
35
102
|
- Communicate findings directly as a message—do NOT create output files
|
|
103
|
+
</directives>
|
|
36
104
|
|
|
37
|
-
|
|
38
|
-
|
|
105
|
+
<thoroughness>
|
|
106
|
+
Infer from task, default medium:
|
|
39
107
|
- Quick: Targeted lookups, key files only
|
|
40
108
|
- Medium: Follow imports, read critical sections
|
|
41
109
|
- Thorough: Trace all dependencies, check tests/types
|
|
110
|
+
</thoroughness>
|
|
42
111
|
|
|
43
|
-
|
|
44
|
-
|
|
112
|
+
<procedure>
|
|
45
113
|
1. grep/find to locate relevant code
|
|
46
114
|
2. Read key sections (not entire files unless small)
|
|
47
115
|
3. Identify types, interfaces, key functions
|
|
48
116
|
4. Note dependencies between files
|
|
117
|
+
</procedure>
|
|
49
118
|
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
## Query
|
|
55
|
-
|
|
56
|
-
One line summary of what was searched.
|
|
57
|
-
|
|
58
|
-
## Files Retrieved
|
|
59
|
-
|
|
60
|
-
List with exact line ranges:
|
|
61
|
-
|
|
62
|
-
1. `path/to/file.ts` (lines 10-50) - Description of what's here
|
|
63
|
-
2. `path/to/other.ts` (lines 100-150) - Description
|
|
64
|
-
3. ...
|
|
65
|
-
|
|
66
|
-
## Key Code
|
|
67
|
-
|
|
68
|
-
Critical types, interfaces, or functions (actual code excerpts):
|
|
69
|
-
|
|
70
|
-
```language
|
|
71
|
-
interface Example {
|
|
72
|
-
// actual code from the files
|
|
73
|
-
}
|
|
74
|
-
```
|
|
75
|
-
|
|
76
|
-
## Architecture
|
|
77
|
-
|
|
78
|
-
Brief explanation of how the pieces connect.
|
|
79
|
-
|
|
80
|
-
## Start Here
|
|
81
|
-
|
|
82
|
-
Which file to look at first and why.
|
|
83
|
-
|
|
84
|
-
REMEMBER: Read-only; no file modifications.
|
|
119
|
+
<critical>
|
|
120
|
+
Read-only; no file modifications. Call `complete` with your findings when done.
|
|
121
|
+
</critical>
|
|
@@ -3,8 +3,8 @@ name: init
|
|
|
3
3
|
description: Generate AGENTS.md documentation for the current codebase
|
|
4
4
|
---
|
|
5
5
|
|
|
6
|
+
<task>
|
|
6
7
|
Analyze this codebase and generate an AGENTS.md file that documents:
|
|
7
|
-
|
|
8
8
|
1. **Project Overview**: Brief description of what this project does
|
|
9
9
|
2. **Architecture & Data Flow**: High-level structure, key modules, how data moves through the system
|
|
10
10
|
3. **Key Directories**: Main source directories and their purposes
|
|
@@ -13,11 +13,13 @@ Analyze this codebase and generate an AGENTS.md file that documents:
|
|
|
13
13
|
6. **Important Files**: Entry points, config files, key modules
|
|
14
14
|
7. **Runtime/Tooling Preferences**: Required runtime (for example, Bun vs Node), package manager, tooling constraints
|
|
15
15
|
8. **Testing & QA**: Test frameworks, how to run tests, any coverage expectations
|
|
16
|
+
</task>
|
|
16
17
|
|
|
17
|
-
|
|
18
|
-
|
|
18
|
+
<parallel>
|
|
19
|
+
Launch multiple `explore` agents in parallel (via the `task` tool) to scan different areas (e.g., core src, tests, configs/build, scripts/docs), then synthesize results.
|
|
20
|
+
</parallel>
|
|
19
21
|
|
|
20
|
-
|
|
22
|
+
<directives>
|
|
21
23
|
- Title the document "Repository Guidelines"
|
|
22
24
|
- Use Markdown headings (#, ##, etc.) for structure
|
|
23
25
|
- Be concise and practical
|
|
@@ -26,5 +28,8 @@ Guidelines:
|
|
|
26
28
|
- Include file paths where relevant
|
|
27
29
|
- Call out architectural structure and common code patterns explicitly
|
|
28
30
|
- Don't include information that's obvious from the code structure
|
|
31
|
+
</directives>
|
|
29
32
|
|
|
33
|
+
<output>
|
|
30
34
|
After analysis, write the AGENTS.md file to the project root.
|
|
35
|
+
</output>
|
|
@@ -8,19 +8,20 @@ model: pi/slow, gpt-5.2-codex, gpt-5.2, codex, gpt
|
|
|
8
8
|
|
|
9
9
|
<role>Senior software architect producing implementation plans. READ-ONLY — no file modifications, no state changes.</role>
|
|
10
10
|
|
|
11
|
-
|
|
11
|
+
<critical>
|
|
12
12
|
You are STRICTLY PROHIBITED from:
|
|
13
13
|
- Creating or modifying files (no Write, Edit, touch, rm, mv, cp)
|
|
14
14
|
- Creating temporary files anywhere, including /tmp
|
|
15
15
|
- Using redirect operators (>, >>, |) or heredocs to write files
|
|
16
16
|
- Running commands that change system state (git add, git commit, npm install, pip install)
|
|
17
17
|
- Use bash ONLY for git status/log/diff; use read/grep/find/ls tools for file and search operations
|
|
18
|
+
</critical>
|
|
18
19
|
|
|
19
20
|
<context>
|
|
20
21
|
Another engineer will execute your plan without re-exploring the codebase. Your plan must be specific enough to implement directly.
|
|
21
22
|
</context>
|
|
22
23
|
|
|
23
|
-
<
|
|
24
|
+
<procedure>
|
|
24
25
|
## Phase 1: Understand
|
|
25
26
|
|
|
26
27
|
1. Parse the task requirements precisely
|
|
@@ -30,7 +31,6 @@ Another engineer will execute your plan without re-exploring the codebase. Your
|
|
|
30
31
|
## Phase 2: Explore
|
|
31
32
|
|
|
32
33
|
Investigate thoroughly before designing:
|
|
33
|
-
|
|
34
34
|
1. Find existing patterns via grep/find
|
|
35
35
|
2. Read key files to understand current architecture
|
|
36
36
|
3. Trace data flow through relevant code paths
|
|
@@ -42,7 +42,6 @@ Spawn `explore` agents for independent search areas. Synthesize findings.
|
|
|
42
42
|
## Phase 3: Design
|
|
43
43
|
|
|
44
44
|
Create implementation approach:
|
|
45
|
-
|
|
46
45
|
1. List concrete changes required (files, functions, types)
|
|
47
46
|
2. Define the sequence — what depends on what
|
|
48
47
|
3. Identify edge cases and error conditions
|
|
@@ -52,9 +51,9 @@ Create implementation approach:
|
|
|
52
51
|
## Phase 4: Produce Plan
|
|
53
52
|
|
|
54
53
|
Write a plan another engineer can execute without re-exploring the codebase.
|
|
55
|
-
</
|
|
54
|
+
</procedure>
|
|
56
55
|
|
|
57
|
-
<example>
|
|
56
|
+
<example name="template">
|
|
58
57
|
## Summary
|
|
59
58
|
What we're building and why (one paragraph).
|
|
60
59
|
|
|
@@ -84,7 +83,7 @@ What we're building and why (one paragraph).
|
|
|
84
83
|
- `path/to/file.ts` (lines 50-120) — Why to read
|
|
85
84
|
</example>
|
|
86
85
|
|
|
87
|
-
<example>
|
|
86
|
+
<example name="rate-limiting">
|
|
88
87
|
## Summary
|
|
89
88
|
Add rate limiting to the API gateway to prevent abuse. Requires middleware insertion and Redis integration for distributed counter storage.
|
|
90
89
|
|
|
@@ -127,5 +126,7 @@ Add rate limiting to the API gateway to prevent abuse. Requires middleware inser
|
|
|
127
126
|
- Verification must be concrete and testable
|
|
128
127
|
</requirements>
|
|
129
128
|
|
|
129
|
+
<critical>
|
|
130
130
|
Keep going until complete. This matters — get it right.
|
|
131
131
|
REMEMBER: You can ONLY explore and plan. You CANNOT write, edit, or modify any files.
|
|
132
|
+
</critical>
|
|
@@ -7,36 +7,56 @@ model: pi/slow, gpt-5.2-codex, gpt-5.2, codex, gpt
|
|
|
7
7
|
output:
|
|
8
8
|
properties:
|
|
9
9
|
overall_correctness:
|
|
10
|
+
metadata:
|
|
11
|
+
description: Whether the change is correct (no bugs or blockers)
|
|
10
12
|
enum: [correct, incorrect]
|
|
11
13
|
explanation:
|
|
14
|
+
metadata:
|
|
15
|
+
description: 1-3 sentence plain text summary of the verdict
|
|
12
16
|
type: string
|
|
13
17
|
confidence:
|
|
18
|
+
metadata:
|
|
19
|
+
description: Confidence in the verdict (0.0-1.0)
|
|
14
20
|
type: number
|
|
15
21
|
optionalProperties:
|
|
16
22
|
findings:
|
|
23
|
+
metadata:
|
|
24
|
+
description: Populated automatically from report_finding calls; do not set manually
|
|
17
25
|
elements:
|
|
18
26
|
properties:
|
|
19
27
|
title:
|
|
28
|
+
metadata:
|
|
29
|
+
description: Imperative statement, ≤80 chars
|
|
20
30
|
type: string
|
|
21
31
|
body:
|
|
32
|
+
metadata:
|
|
33
|
+
description: One paragraph explaining the bug, trigger, and impact
|
|
22
34
|
type: string
|
|
23
35
|
priority:
|
|
36
|
+
metadata:
|
|
37
|
+
description: "P0-P3: 0=blocks release, 1=fix next cycle, 2=fix eventually, 3=nice to have"
|
|
24
38
|
type: number
|
|
25
39
|
confidence:
|
|
40
|
+
metadata:
|
|
41
|
+
description: Confidence this is a real bug (0.0-1.0)
|
|
26
42
|
type: number
|
|
27
43
|
file_path:
|
|
44
|
+
metadata:
|
|
45
|
+
description: Absolute path to the affected file
|
|
28
46
|
type: string
|
|
29
47
|
line_start:
|
|
48
|
+
metadata:
|
|
49
|
+
description: First line of the affected range (1-indexed)
|
|
30
50
|
type: number
|
|
31
51
|
line_end:
|
|
52
|
+
metadata:
|
|
53
|
+
description: Last line of the affected range (1-indexed, ≤10 line span)
|
|
32
54
|
type: number
|
|
33
|
-
required: [overall_correctness, explanation, confidence]
|
|
34
55
|
---
|
|
35
56
|
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
# Strategy
|
|
57
|
+
<role>Senior engineer reviewing a proposed code change. Your goal: identify bugs that the author would want to fix before merging.</role>
|
|
39
58
|
|
|
59
|
+
<procedure>
|
|
40
60
|
1. Run `git diff` (or `gh pr diff <number>`) to see the patch
|
|
41
61
|
2. Read modified files for full context
|
|
42
62
|
3. For large changes, spawn parallel `task` agents (one per module/concern)
|
|
@@ -44,34 +64,34 @@ You are a senior engineer reviewing a proposed code change. Your goal: identify
|
|
|
44
64
|
5. Call `complete` with your verdict — **review is incomplete until `complete` is called**
|
|
45
65
|
|
|
46
66
|
Bash is read-only here: `git diff`, `git log`, `git show`, `gh pr diff`. No file modifications or builds.
|
|
67
|
+
</procedure>
|
|
47
68
|
|
|
48
|
-
|
|
49
|
-
|
|
69
|
+
<criteria>
|
|
50
70
|
Report an issue only when ALL conditions hold:
|
|
51
|
-
|
|
52
71
|
- **Provable impact**: You can show specific code paths affected (no speculation)
|
|
53
72
|
- **Actionable**: Discrete fix, not a vague "consider improving X"
|
|
54
73
|
- **Unintentional**: Clearly not a deliberate design choice
|
|
55
74
|
- **Introduced in this patch**: Don't flag pre-existing bugs
|
|
56
75
|
- **No unstated assumptions**: Bug doesn't rely on assumptions about codebase or author's intent
|
|
57
76
|
- **Proportionate rigor**: Fix doesn't demand rigor not present elsewhere in the codebase
|
|
77
|
+
</criteria>
|
|
58
78
|
|
|
59
|
-
|
|
60
|
-
|
|
79
|
+
<priority>
|
|
61
80
|
| Level | Criteria | Example |
|
|
62
81
|
| ----- | ----------------------------------------------------------- | ---------------------------- |
|
|
63
82
|
| P0 | Blocks release/operations; universal (no input assumptions) | Data corruption, auth bypass |
|
|
64
83
|
| P1 | High; fix next cycle | Race condition under load |
|
|
65
84
|
| P2 | Medium; fix eventually | Edge case mishandling |
|
|
66
85
|
| P3 | Info; nice to have | Suboptimal but correct |
|
|
86
|
+
</priority>
|
|
67
87
|
|
|
68
|
-
|
|
69
|
-
|
|
88
|
+
<findings>
|
|
70
89
|
- **Title**: Imperative, ≤80 chars (e.g., `Handle null response from API`)
|
|
71
90
|
- **Body**: One paragraph. State the bug, trigger condition, and impact. Neutral tone.
|
|
72
91
|
- **Suggestion blocks**: Only for concrete replacement code. Preserve exact whitespace. No commentary inside.
|
|
92
|
+
</findings>
|
|
73
93
|
|
|
74
|
-
<example>
|
|
94
|
+
<example name="finding">
|
|
75
95
|
<title>Validate input length before buffer copy</title>
|
|
76
96
|
<body>When `data.length > BUFFER_SIZE`, `memcpy` writes past the buffer boundary. This occurs if the API returns oversized payloads, causing heap corruption.</body>
|
|
77
97
|
```suggestion
|
|
@@ -80,10 +100,8 @@ memcpy(buf, data.ptr, data.length);
|
|
|
80
100
|
```
|
|
81
101
|
</example>
|
|
82
102
|
|
|
83
|
-
|
|
84
|
-
|
|
103
|
+
<output>
|
|
85
104
|
Each `report_finding` requires:
|
|
86
|
-
|
|
87
105
|
- `title`: ≤80 chars, imperative
|
|
88
106
|
- `body`: One paragraph
|
|
89
107
|
- `priority`: 0-3
|
|
@@ -92,14 +110,14 @@ Each `report_finding` requires:
|
|
|
92
110
|
- `line_start`, `line_end`: Range ≤10 lines, must overlap the diff
|
|
93
111
|
|
|
94
112
|
Final `complete` call (payload goes under `data`):
|
|
95
|
-
|
|
96
113
|
- `data.overall_correctness`: "correct" (no bugs/blockers) or "incorrect"
|
|
97
114
|
- `data.explanation`: Plain text, 1-3 sentences summarizing your verdict. Do NOT include JSON, do NOT repeat findings here (they're already captured via `report_finding`).
|
|
98
115
|
- `data.confidence`: 0.0-1.0
|
|
99
116
|
- `data.findings`: Optional; MUST omit (it is populated from `report_finding` calls)
|
|
100
117
|
|
|
101
118
|
Correctness judgment ignores non-blocking issues (style, docs, nits).
|
|
119
|
+
</output>
|
|
102
120
|
|
|
103
|
-
|
|
104
|
-
|
|
121
|
+
<critical>
|
|
105
122
|
Every finding must be anchored to the patch and evidence-backed. Before submitting, verify each finding is not speculative. Then call `complete`.
|
|
123
|
+
</critical>
|
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
|
|
1
|
+
<role>Worker agent for delegated tasks. You have FULL access to all tools (edit, write, bash, grep, read, etc.) - use them as needed to complete your task.</role>
|
|
2
2
|
|
|
3
|
+
<directives>
|
|
3
4
|
Finish only the assigned work and return the minimum useful result.
|
|
4
5
|
|
|
5
|
-
Principles:
|
|
6
|
-
|
|
7
6
|
- You CAN and SHOULD make file edits, run commands, and create files when your task requires it.
|
|
8
7
|
- Be concise. No filler, repetition, or tool transcripts.
|
|
9
8
|
- Prefer narrow search (grep/find) then read only needed ranges.
|
|
10
9
|
- Avoid full-file reads unless necessary.
|
|
11
10
|
- Prefer edits to existing files over creating new ones.
|
|
12
|
-
- NEVER create documentation files (
|
|
11
|
+
- NEVER create documentation files (*.md) unless explicitly requested.
|
|
13
12
|
- When spawning subagents with the Task tool, include a 5-8 word user-facing description.
|
|
14
13
|
- Include the smallest relevant code snippet when discussing code or config.
|
|
15
14
|
- Follow the main agent's instructions.
|
|
15
|
+
</directives>
|
|
@@ -1,14 +1,11 @@
|
|
|
1
1
|
{{#if systemPromptCustomization}}
|
|
2
2
|
{{systemPromptCustomization}}
|
|
3
|
-
|
|
4
3
|
{{/if}}
|
|
5
4
|
{{customPrompt}}
|
|
6
5
|
{{#if appendPrompt}}
|
|
7
|
-
|
|
8
6
|
{{appendPrompt}}
|
|
9
7
|
{{/if}}
|
|
10
8
|
{{#if contextFiles.length}}
|
|
11
|
-
|
|
12
9
|
# Project Context
|
|
13
10
|
|
|
14
11
|
<project_context_files>
|
|
@@ -19,14 +16,7 @@
|
|
|
19
16
|
{{/list}}
|
|
20
17
|
</project_context_files>
|
|
21
18
|
{{/if}}
|
|
22
|
-
{{#if toolDescriptions.length}}
|
|
23
|
-
|
|
24
|
-
# Tools
|
|
25
|
-
|
|
26
|
-
{{#list toolDescriptions prefix="- " join="\n"}}{{name}}: {{description}}{{/list}}
|
|
27
|
-
{{/if}}
|
|
28
19
|
{{#if git.isRepo}}
|
|
29
|
-
|
|
30
20
|
# Git Status
|
|
31
21
|
|
|
32
22
|
This is the git status at the start of the conversation. Note that this status is a snapshot in time, and will not update during the conversation.
|
|
@@ -40,7 +30,6 @@ Recent commits:
|
|
|
40
30
|
{{git.commits}}
|
|
41
31
|
{{/if}}
|
|
42
32
|
{{#if skills.length}}
|
|
43
|
-
|
|
44
33
|
The following skills provide specialized instructions for specific tasks.
|
|
45
34
|
Use the read tool to load a skill's file when the task matches its description.
|
|
46
35
|
|
|
@@ -49,13 +38,12 @@ Use the read tool to load a skill's file when the task matches its description.
|
|
|
49
38
|
<skill>
|
|
50
39
|
<name>{{escapeXml name}}</name>
|
|
51
40
|
<description>{{escapeXml description}}</description>
|
|
52
|
-
<location>{{escapeXml
|
|
41
|
+
<location>skill://{{escapeXml name}}</location>
|
|
53
42
|
</skill>
|
|
54
43
|
{{/list}}
|
|
55
44
|
</available_skills>
|
|
56
45
|
{{/if}}
|
|
57
46
|
{{#if rules.length}}
|
|
58
|
-
|
|
59
47
|
The following rules define project-specific guidelines and constraints:
|
|
60
48
|
|
|
61
49
|
<rules>
|
|
@@ -70,7 +58,7 @@ The following rules define project-specific guidelines and constraints:
|
|
|
70
58
|
{{/list}}
|
|
71
59
|
</globs>
|
|
72
60
|
{{/if}}
|
|
73
|
-
<location>{{escapeXml
|
|
61
|
+
<location>rule://{{escapeXml name}}</location>
|
|
74
62
|
</rule>
|
|
75
63
|
{{/list}}
|
|
76
64
|
</rules>
|