lazycodex-ai 5.1.62 → 5.1.63
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cli/index.js +1598 -284
- package/dist/cli/service-auth/closed-device-login.fixture.d.ts +1 -0
- package/dist/cli/service-auth/credential-lock.d.ts +8 -2
- package/dist/cli/service-auth/keychain-helper/access.d.ts +27 -0
- package/dist/cli/service-auth/keychain-helper/approval-cache.d.ts +51 -0
- package/dist/cli/service-auth/keychain-helper/client.d.ts +68 -0
- package/dist/cli/service-auth/keychain-helper/creator-handoff.d.ts +31 -0
- package/dist/cli/service-auth/keychain-helper/darwin-backend.d.ts +75 -0
- package/dist/cli/service-auth/keychain-helper/darwin-read.d.ts +46 -0
- package/dist/cli/service-auth/keychain-helper/darwin-store.d.ts +28 -0
- package/dist/cli/service-auth/keychain-helper/fake-keychain.test-support.d.ts +85 -0
- package/dist/cli/service-auth/keychain-helper/location.d.ts +28 -0
- package/dist/cli/service-auth/keychain-helper/migration.d.ts +20 -0
- package/dist/cli/service-auth/keychain-helper/owner-marker.d.ts +7 -0
- package/dist/cli/service-auth/keychain-helper/pin.d.ts +20 -0
- package/dist/cli/service-auth/keychain-helper/process-copy.test-support.d.ts +3 -0
- package/dist/cli/service-auth/keychain-helper/process-state.d.ts +19 -0
- package/dist/cli/service-auth/keychain-helper/prompt-lock.d.ts +14 -0
- package/dist/cli/service-auth/keychain-helper/recovery.d.ts +34 -0
- package/dist/cli/service-auth/keychain-helper/runtime-capabilities.d.ts +13 -0
- package/dist/cli/service-auth/keychain-helper/secrets-gate.d.ts +4 -0
- package/dist/cli/service-auth/keychain-helper/signature.d.ts +17 -0
- package/dist/cli/service-auth/keychain-helper/store-binding.d.ts +46 -0
- package/dist/cli/service-auth/keystore.d.ts +18 -3
- package/dist/cli/service-auth/session.d.ts +2 -2
- package/dist/cli-node/index.js +1598 -284
- package/package.json +1 -1
- package/packages/omo-codex/plugin/.codex-plugin/plugin.json +1 -1
- package/packages/omo-codex/plugin/components/bootstrap/hooks/hooks.json +1 -1
- package/packages/omo-codex/plugin/components/bootstrap/package.json +1 -1
- package/packages/omo-codex/plugin/components/comment-checker/hooks/hooks.json +1 -1
- package/packages/omo-codex/plugin/components/comment-checker/package.json +1 -1
- package/packages/omo-codex/plugin/components/git-bash/hooks/hooks.json +2 -2
- package/packages/omo-codex/plugin/components/git-bash/package.json +1 -1
- package/packages/omo-codex/plugin/components/lazycodex-executor-verify/hooks/hooks.json +1 -1
- package/packages/omo-codex/plugin/components/lazycodex-executor-verify/package.json +1 -1
- package/packages/omo-codex/plugin/components/lsp/dist/.omo-runtime-manifest.json +2 -2
- package/packages/omo-codex/plugin/components/lsp/hooks/hooks.json +2 -2
- package/packages/omo-codex/plugin/components/lsp/package.json +1 -1
- package/packages/omo-codex/plugin/components/rules/hooks/hooks.json +4 -4
- package/packages/omo-codex/plugin/components/rules/package.json +1 -1
- package/packages/omo-codex/plugin/components/teammode/hooks/hooks.json +1 -1
- package/packages/omo-codex/plugin/components/teammode/package.json +1 -1
- package/packages/omo-codex/plugin/components/telemetry/hooks/hooks.json +1 -1
- package/packages/omo-codex/plugin/components/telemetry/package.json +1 -1
- package/packages/omo-codex/plugin/components/ultrawork/dist/cli.js +2 -0
- package/packages/omo-codex/plugin/components/ultrawork/hooks/hooks.json +1 -1
- package/packages/omo-codex/plugin/components/ultrawork/package.json +1 -1
- package/packages/omo-codex/plugin/components/ultrawork/skills/ulw-plan/references/full-workflow.md +1 -1
- package/packages/omo-codex/plugin/components/ultrawork/skills/ulw-plan/references/intent-unclear.md +2 -2
- package/packages/omo-codex/plugin/components/ultrawork/src/directive-content.ts +1 -1
- package/packages/omo-codex/plugin/components/ulw-execute-continuation/directive.md +1 -1
- package/packages/omo-codex/plugin/components/ulw-execute-continuation/hooks/hooks.json +1 -1
- package/packages/omo-codex/plugin/components/ulw-execute-continuation/package.json +1 -1
- package/packages/omo-codex/plugin/components/ulw-loop/directive.md +2 -0
- package/packages/omo-codex/plugin/components/ulw-loop/hooks/hooks.json +5 -5
- package/packages/omo-codex/plugin/components/ulw-loop/package.json +1 -1
- package/packages/omo-codex/plugin/components/ulw-loop/skills/ulw-loop/SKILL.md +1 -1
- package/packages/omo-codex/plugin/components/ulw-loop/skills/ulw-loop/references/define-goal.md +1 -1
- package/packages/omo-codex/plugin/components/ulw-loop/skills/ulw-loop/references/full-workflow.md +10 -10
- package/packages/omo-codex/plugin/hooks/post-compact-resetting-git-bash-mcp-reminder.json +1 -1
- package/packages/omo-codex/plugin/hooks/post-compact-resetting-lsp-diagnostics-cache.json +1 -1
- package/packages/omo-codex/plugin/hooks/post-compact-resetting-project-rule-cache.json +1 -1
- package/packages/omo-codex/plugin/hooks/post-tool-use-checking-comments.json +1 -1
- package/packages/omo-codex/plugin/hooks/post-tool-use-checking-lsp-diagnostics.json +1 -1
- package/packages/omo-codex/plugin/hooks/post-tool-use-checking-thread-title-hygiene.json +1 -1
- package/packages/omo-codex/plugin/hooks/post-tool-use-matching-project-rules.json +1 -1
- package/packages/omo-codex/plugin/hooks/post-tool-use-recording-spawn-admission.json +1 -1
- package/packages/omo-codex/plugin/hooks/pre-tool-use-enforcing-unlimited-goal-budget.json +1 -1
- package/packages/omo-codex/plugin/hooks/pre-tool-use-guarding-ulw-loop-spawns.json +1 -1
- package/packages/omo-codex/plugin/hooks/pre-tool-use-recommending-git-bash-mcp.json +1 -1
- package/packages/omo-codex/plugin/hooks/session-start-checking-auto-update.json +1 -1
- package/packages/omo-codex/plugin/hooks/session-start-checking-bootstrap-provisioning.json +1 -1
- package/packages/omo-codex/plugin/hooks/session-start-loading-project-rules.json +1 -1
- package/packages/omo-codex/plugin/hooks/session-start-recording-session-telemetry.json +1 -1
- package/packages/omo-codex/plugin/hooks/stop-checking-ulw-execute-continuation.json +1 -1
- package/packages/omo-codex/plugin/hooks/stop-checking-ulw-loop-resume.json +1 -1
- package/packages/omo-codex/plugin/hooks/subagent-stop-verifying-lazycodex-executor-evidence.json +1 -1
- package/packages/omo-codex/plugin/hooks/user-prompt-submit-checking-ultrawork-trigger.json +1 -1
- package/packages/omo-codex/plugin/hooks/user-prompt-submit-checking-ulw-loop-steering.json +1 -1
- package/packages/omo-codex/plugin/hooks/user-prompt-submit-loading-project-rules.json +1 -1
- package/packages/omo-codex/plugin/package-lock.json +12 -12
- package/packages/omo-codex/plugin/package.json +1 -1
- package/packages/omo-codex/plugin/scripts/sync-skills.mjs +6 -3
- package/packages/omo-codex/plugin/skills/ast-grep/AGENTS.md +2 -2
- package/packages/omo-codex/plugin/skills/ast-grep/README.md +4 -4
- package/packages/omo-codex/plugin/skills/ast-grep/SKILL.md +10 -8
- package/packages/omo-codex/plugin/skills/ast-grep/references/cli.md +4 -3
- package/packages/omo-codex/plugin/skills/ast-grep/references/patterns.md +5 -5
- package/packages/omo-codex/plugin/skills/ast-grep/references/pitfalls.md +3 -3
- package/packages/omo-codex/plugin/skills/ast-grep/references/recipes.md +6 -4
- package/packages/omo-codex/plugin/skills/ast-grep/references/yaml-rules.md +3 -3
- package/packages/omo-codex/plugin/skills/ast-grep/scripts/ast_grep_helper.py +3 -3
- package/packages/omo-codex/plugin/skills/browser/SKILL.md +2 -3
- package/packages/omo-codex/plugin/skills/browser/runtime/omowright/manifest.json +1 -1
- package/packages/omo-codex/plugin/skills/coding-agent-sessions/AGENTS.md +1 -1
- package/packages/omo-codex/plugin/skills/coding-agent-sessions/SKILL.md +2 -1
- package/packages/omo-codex/plugin/skills/data-scientist/SKILL.md +8 -6
- package/packages/omo-codex/plugin/skills/data-scientist/references/placement.md +9 -5
- package/packages/omo-codex/plugin/skills/data-scientist/references/uv-setup.md +3 -3
- package/packages/omo-codex/plugin/skills/data-scientist/references/visualization.md +19 -4
- package/packages/omo-codex/plugin/skills/debugging/SKILL.md +5 -5
- package/packages/omo-codex/plugin/skills/debugging/references/methodology/02-investigate.md +2 -2
- package/packages/omo-codex/plugin/skills/debugging/references/methodology/06-fix.md +2 -0
- package/packages/omo-codex/plugin/skills/debugging/references/methodology/09-cleanup.md +2 -2
- package/packages/omo-codex/plugin/skills/debugging/references/methodology/partial-runtime-evidence.md +1 -1
- package/packages/omo-codex/plugin/skills/debugging/references/runtimes/bundled-js-binary.md +1 -1
- package/packages/omo-codex/plugin/skills/debugging/references/runtimes/native-binary.md +1 -1
- package/packages/omo-codex/plugin/skills/debugging/references/tools/browser-qa.md +1 -2
- package/packages/omo-codex/plugin/skills/frontend/SKILL.md +2 -2
- package/packages/omo-codex/plugin/skills/frontend/references/design/design-system-architecture.md +1 -1
- package/packages/omo-codex/plugin/skills/frontend/references/design/print-paged-media.md +1 -1
- package/packages/omo-codex/plugin/skills/frontend/references/perfection/README.md +0 -1
- package/packages/omo-codex/plugin/skills/frontend/references/perfection/react-perf-tooling.md +27 -8
- package/packages/omo-codex/plugin/skills/frontend/scripts/perfection/lighthouse-audit.py +0 -1
- package/packages/omo-codex/plugin/skills/git-master/SKILL.md +12 -2
- package/packages/omo-codex/plugin/skills/init-deep/SKILL.md +1 -1
- package/packages/omo-codex/plugin/skills/lsp-setup/SKILL.md +24 -15
- package/packages/omo-codex/plugin/skills/lsp-setup/references/bash/README.md +3 -3
- package/packages/omo-codex/plugin/skills/lsp-setup/references/c-cpp/README.md +2 -2
- package/packages/omo-codex/plugin/skills/lsp-setup/references/csharp/README.md +2 -2
- package/packages/omo-codex/plugin/skills/lsp-setup/references/dart/README.md +2 -2
- package/packages/omo-codex/plugin/skills/lsp-setup/references/elixir/README.md +2 -2
- package/packages/omo-codex/plugin/skills/lsp-setup/references/go/README.md +2 -2
- package/packages/omo-codex/plugin/skills/lsp-setup/references/haskell/README.md +2 -2
- package/packages/omo-codex/plugin/skills/lsp-setup/references/java/README.md +3 -3
- package/packages/omo-codex/plugin/skills/lsp-setup/references/julia/README.md +3 -3
- package/packages/omo-codex/plugin/skills/lsp-setup/references/kotlin/README.md +4 -4
- package/packages/omo-codex/plugin/skills/lsp-setup/references/lua/README.md +2 -2
- package/packages/omo-codex/plugin/skills/lsp-setup/references/php/README.md +3 -3
- package/packages/omo-codex/plugin/skills/lsp-setup/references/python/README.md +13 -12
- package/packages/omo-codex/plugin/skills/lsp-setup/references/ruby/README.md +2 -2
- package/packages/omo-codex/plugin/skills/lsp-setup/references/rust/README.md +2 -2
- package/packages/omo-codex/plugin/skills/lsp-setup/references/swift/README.md +4 -4
- package/packages/omo-codex/plugin/skills/lsp-setup/references/terraform/README.md +2 -2
- package/packages/omo-codex/plugin/skills/lsp-setup/references/typescript/README.md +3 -3
- package/packages/omo-codex/plugin/skills/lsp-setup/references/yaml/README.md +2 -2
- package/packages/omo-codex/plugin/skills/lsp-setup/references/zig/README.md +2 -2
- package/packages/omo-codex/plugin/skills/lsp-setup/scripts/detect-lsp.ts +1 -1
- package/packages/omo-codex/plugin/skills/lsp-setup/scripts/lsp-server-table.ts +3 -2
- package/packages/omo-codex/plugin/skills/programming/SKILL.md +5 -5
- package/packages/omo-codex/plugin/skills/programming/references/code-smells.md +2 -2
- package/packages/omo-codex/plugin/skills/programming/references/go/README.md +3 -3
- package/packages/omo-codex/plugin/skills/programming/references/python/README.md +8 -8
- package/packages/omo-codex/plugin/skills/programming/references/python/data-processing.md +9 -9
- package/packages/omo-codex/plugin/skills/programming/references/rust-ub/README.md +3 -3
- package/packages/omo-codex/plugin/skills/programming/references/typescript/README.md +5 -5
- package/packages/omo-codex/plugin/skills/programming/scripts/typescript/new-project.ts +1 -1
- package/packages/omo-codex/plugin/skills/refactor/SKILL.md +35 -35
- package/packages/omo-codex/plugin/skills/remove-ai-slops/SKILL.md +6 -6
- package/packages/omo-codex/plugin/skills/review-work/SKILL.md +2 -2
- package/packages/omo-codex/plugin/skills/ultimate-browsing/SKILL.md +10 -7
- package/packages/omo-codex/plugin/skills/ultimate-browsing/engine/AGENTS.md +4 -4
- package/packages/omo-codex/plugin/skills/ultimate-browsing/references/agent-reach/README.md +2 -2
- package/packages/omo-codex/plugin/skills/ultimate-browsing/references/agent-reach/career.md +1 -1
- package/packages/omo-codex/plugin/skills/ultimate-browsing/references/agent-reach/social.md +1 -1
- package/packages/omo-codex/plugin/skills/ultimate-browsing/references/agent-reach/web.md +4 -4
- package/packages/omo-codex/plugin/skills/ultimate-browsing/references/chrome-stealth.md +2 -1
- package/packages/omo-codex/plugin/skills/ultimate-browsing/references/insane-search/README.md +16 -17
- package/packages/omo-codex/plugin/skills/ultimate-browsing/references/insane-search/fallback.md +10 -6
- package/packages/omo-codex/plugin/skills/ultimate-browsing/references/insane-search/jina.md +12 -12
- package/packages/omo-codex/plugin/skills/ultimate-browsing/references/insane-search/naver.md +3 -3
- package/packages/omo-codex/plugin/skills/ultimate-browsing/references/insane-search/playwright.md +1 -1
- package/packages/omo-codex/plugin/skills/ultimate-browsing/references/insane-search/rss.md +1 -1
- package/packages/omo-codex/plugin/skills/ultimate-browsing/references/insane-search/tls-impersonate.md +12 -7
- package/packages/omo-codex/plugin/skills/ultrawork/SKILL.md +2 -0
- package/packages/omo-codex/plugin/skills/ulw-execute/SKILL.md +9 -6
- package/packages/omo-codex/plugin/skills/ulw-loop/SKILL.md +1 -1
- package/packages/omo-codex/plugin/skills/ulw-loop/references/define-goal.md +1 -1
- package/packages/omo-codex/plugin/skills/ulw-loop/references/full-workflow.md +10 -10
- package/packages/omo-codex/plugin/skills/ulw-plan/references/full-workflow.md +1 -1
- package/packages/omo-codex/plugin/skills/ulw-plan/references/intent-unclear.md +2 -2
- package/packages/omo-codex/plugin/skills/ulw-research/SKILL.md +2 -2
- package/packages/omo-codex/plugin/skills/ulw-research/references/deliverable-phase.md +5 -5
- package/packages/omo-codex/plugin/skills/ulw-research/references/report-visualization.md +2 -2
- package/packages/omo-codex/plugin/skills/ulw-research/references/research-collection.md +2 -2
- package/packages/omo-codex/plugin/skills/ulw-research/references/unit-rules.md +2 -2
- package/packages/omo-codex/plugin/skills/visual-qa/AGENTS.md +1 -1
- package/packages/omo-codex/plugin/skills/visual-qa/SKILL.md +5 -5
- package/packages/omo-codex/plugin/skills/visual-qa/references/browser-setup.md +4 -2
- package/packages/omo-codex/plugin/test/sync-skills-codex-compatibility.test.mjs +2 -0
- package/packages/omo-codex/plugin/test/sync-skills-test-support.mjs +7 -3
- package/packages/omo-codex/scripts/install-dist/install-local.mjs +2 -2
- package/packages/prompts-core/prompts/ultrawork/codex.md +2 -0
- package/packages/shared-skills/skills/ast-grep/AGENTS.md +2 -2
- package/packages/shared-skills/skills/ast-grep/README.md +4 -4
- package/packages/shared-skills/skills/ast-grep/SKILL.md +10 -8
- package/packages/shared-skills/skills/ast-grep/references/cli.md +4 -3
- package/packages/shared-skills/skills/ast-grep/references/patterns.md +5 -5
- package/packages/shared-skills/skills/ast-grep/references/pitfalls.md +3 -3
- package/packages/shared-skills/skills/ast-grep/references/recipes.md +6 -4
- package/packages/shared-skills/skills/ast-grep/references/yaml-rules.md +3 -3
- package/packages/shared-skills/skills/ast-grep/scripts/ast_grep_helper.py +3 -3
- package/packages/shared-skills/skills/browser/SKILL.md +2 -3
- package/packages/shared-skills/skills/browser/runtime/omowright/manifest.json +1 -1
- package/packages/shared-skills/skills/coding-agent-sessions/AGENTS.md +1 -1
- package/packages/shared-skills/skills/coding-agent-sessions/SKILL.md +2 -1
- package/packages/shared-skills/skills/data-scientist/SKILL.md +8 -6
- package/packages/shared-skills/skills/data-scientist/references/placement.md +9 -5
- package/packages/shared-skills/skills/data-scientist/references/uv-setup.md +3 -3
- package/packages/shared-skills/skills/data-scientist/references/visualization.md +19 -4
- package/packages/shared-skills/skills/debugging/SKILL.md +5 -5
- package/packages/shared-skills/skills/debugging/references/methodology/02-investigate.md +2 -2
- package/packages/shared-skills/skills/debugging/references/methodology/06-fix.md +2 -0
- package/packages/shared-skills/skills/debugging/references/methodology/09-cleanup.md +2 -2
- package/packages/shared-skills/skills/debugging/references/methodology/partial-runtime-evidence.md +1 -1
- package/packages/shared-skills/skills/debugging/references/runtimes/bundled-js-binary.md +1 -1
- package/packages/shared-skills/skills/debugging/references/runtimes/native-binary.md +1 -1
- package/packages/shared-skills/skills/debugging/references/tools/browser-qa.md +1 -2
- package/packages/shared-skills/skills/frontend/SKILL.md +2 -2
- package/packages/shared-skills/skills/frontend/references/design/design-system-architecture.md +1 -1
- package/packages/shared-skills/skills/frontend/references/design/print-paged-media.md +1 -1
- package/packages/shared-skills/skills/frontend/references/perfection/README.md +0 -1
- package/packages/shared-skills/skills/frontend/references/perfection/react-perf-tooling.md +27 -8
- package/packages/shared-skills/skills/frontend/scripts/perfection/lighthouse-audit.py +0 -1
- package/packages/shared-skills/skills/git-master/SKILL.md +12 -2
- package/packages/shared-skills/skills/init-deep/SKILL.md +1 -1
- package/packages/shared-skills/skills/lsp-setup/SKILL.md +24 -15
- package/packages/shared-skills/skills/lsp-setup/references/bash/README.md +3 -3
- package/packages/shared-skills/skills/lsp-setup/references/c-cpp/README.md +2 -2
- package/packages/shared-skills/skills/lsp-setup/references/csharp/README.md +2 -2
- package/packages/shared-skills/skills/lsp-setup/references/dart/README.md +2 -2
- package/packages/shared-skills/skills/lsp-setup/references/elixir/README.md +2 -2
- package/packages/shared-skills/skills/lsp-setup/references/go/README.md +2 -2
- package/packages/shared-skills/skills/lsp-setup/references/haskell/README.md +2 -2
- package/packages/shared-skills/skills/lsp-setup/references/java/README.md +3 -3
- package/packages/shared-skills/skills/lsp-setup/references/julia/README.md +3 -3
- package/packages/shared-skills/skills/lsp-setup/references/kotlin/README.md +4 -4
- package/packages/shared-skills/skills/lsp-setup/references/lua/README.md +2 -2
- package/packages/shared-skills/skills/lsp-setup/references/php/README.md +3 -3
- package/packages/shared-skills/skills/lsp-setup/references/python/README.md +13 -12
- package/packages/shared-skills/skills/lsp-setup/references/ruby/README.md +2 -2
- package/packages/shared-skills/skills/lsp-setup/references/rust/README.md +2 -2
- package/packages/shared-skills/skills/lsp-setup/references/swift/README.md +4 -4
- package/packages/shared-skills/skills/lsp-setup/references/terraform/README.md +2 -2
- package/packages/shared-skills/skills/lsp-setup/references/typescript/README.md +3 -3
- package/packages/shared-skills/skills/lsp-setup/references/yaml/README.md +2 -2
- package/packages/shared-skills/skills/lsp-setup/references/zig/README.md +2 -2
- package/packages/shared-skills/skills/lsp-setup/scripts/detect-lsp.ts +1 -1
- package/packages/shared-skills/skills/lsp-setup/scripts/lsp-server-table.ts +3 -2
- package/packages/shared-skills/skills/programming/SKILL.md +5 -5
- package/packages/shared-skills/skills/programming/references/code-smells.md +2 -2
- package/packages/shared-skills/skills/programming/references/go/README.md +3 -3
- package/packages/shared-skills/skills/programming/references/python/README.md +8 -8
- package/packages/shared-skills/skills/programming/references/python/data-processing.md +9 -9
- package/packages/shared-skills/skills/programming/references/rust-ub/README.md +3 -3
- package/packages/shared-skills/skills/programming/references/typescript/README.md +5 -5
- package/packages/shared-skills/skills/programming/scripts/typescript/new-project.ts +1 -1
- package/packages/shared-skills/skills/refactor/SKILL.md +35 -35
- package/packages/shared-skills/skills/remove-ai-slops/SKILL.md +6 -6
- package/packages/shared-skills/skills/review-work/SKILL.md +2 -2
- package/packages/shared-skills/skills/ultimate-browsing/SKILL.md +10 -7
- package/packages/shared-skills/skills/ultimate-browsing/engine/AGENTS.md +4 -4
- package/packages/shared-skills/skills/ultimate-browsing/references/agent-reach/README.md +2 -2
- package/packages/shared-skills/skills/ultimate-browsing/references/agent-reach/career.md +1 -1
- package/packages/shared-skills/skills/ultimate-browsing/references/agent-reach/social.md +1 -1
- package/packages/shared-skills/skills/ultimate-browsing/references/agent-reach/web.md +4 -4
- package/packages/shared-skills/skills/ultimate-browsing/references/chrome-stealth.md +2 -1
- package/packages/shared-skills/skills/ultimate-browsing/references/insane-search/README.md +16 -17
- package/packages/shared-skills/skills/ultimate-browsing/references/insane-search/fallback.md +10 -6
- package/packages/shared-skills/skills/ultimate-browsing/references/insane-search/jina.md +12 -12
- package/packages/shared-skills/skills/ultimate-browsing/references/insane-search/naver.md +3 -3
- package/packages/shared-skills/skills/ultimate-browsing/references/insane-search/playwright.md +1 -1
- package/packages/shared-skills/skills/ultimate-browsing/references/insane-search/rss.md +1 -1
- package/packages/shared-skills/skills/ultimate-browsing/references/insane-search/tls-impersonate.md +12 -7
- package/packages/shared-skills/skills/ulw-execute/SKILL.md +9 -6
- package/packages/shared-skills/skills/ulw-plan/references/full-workflow.md +1 -1
- package/packages/shared-skills/skills/ulw-plan/references/intent-unclear.md +2 -2
- package/packages/shared-skills/skills/ulw-research/SKILL.md +3 -3
- package/packages/shared-skills/skills/ulw-research/references/deliverable-phase.md +5 -5
- package/packages/shared-skills/skills/ulw-research/references/report-visualization.md +2 -2
- package/packages/shared-skills/skills/ulw-research/references/research-collection.md +2 -2
- package/packages/shared-skills/skills/ulw-research/references/unit-rules.md +2 -2
- package/packages/shared-skills/skills/visual-qa/AGENTS.md +1 -1
- package/packages/shared-skills/skills/visual-qa/SKILL.md +5 -5
- package/packages/shared-skills/skills/visual-qa/references/browser-setup.md +4 -2
|
@@ -80,7 +80,7 @@ format description: none
|
|
|
80
80
|
|
|
81
81
|
The values below are read by `scripts/fidelity-policy.mjs`, the single registry: `SOURCE_FLOOR_RULES` and `parseSourceFloor()` for the `source floor` forms (`pointedFlag` in source registration reads the same grammar), and `FIDELITY_VALUE_RULES` for `derived numbers`, `languages`, `fallback`, and `meaning check`. `derived numbers` and `fallback` accept only the values in their row below (`FIDELITY_VALUE_RULES.tables`, any case); any other value, a free-text answer included, is a usage error (exit `2`) naming the field and the value, as an unknown `source floor` form is. Map a free-text answer onto a table value before writing it: a partial allowance ("growth rates yes, estimates no") records `derived numbers: none`.
|
|
82
82
|
|
|
83
|
-
Beside `## Deliverable`, the brief records what the report must stay faithful to, under `## Fidelity`. The fields are inferred first; only `as of`, `meaning check`, `source floor`, and `derived numbers` may be asked, each on its own trigger, in the same question call as Q1-Q3 (at most four questions in that call). The inference rules, the triggers, and the question texts are in
|
|
83
|
+
Beside `## Deliverable`, the brief records what the report must stay faithful to, under `## Fidelity`. The fields are inferred first; only `as of`, `meaning check`, `source floor`, and `derived numbers` may be asked, each on its own trigger, in the same question call as Q1-Q3 (at most four questions in that call). The inference rules, the triggers, and the question texts are in [research-collection.md](research-collection.md), under "The fidelity questions".
|
|
84
84
|
|
|
85
85
|
| Field | Values | Default | Read by |
|
|
86
86
|
| --- | --- | --- | --- |
|
|
@@ -175,14 +175,14 @@ Nothing reaches the requester until the gates for its QA tier pass, in this orde
|
|
|
175
175
|
node "$SKILL_DIR/scripts/report-tools.mjs" layout-probe --json # .source is one async expression
|
|
176
176
|
```
|
|
177
177
|
4. **Visual QA.** Render the artifact to images (PDF pages to PNG, the HTML in the browser skill's engine at desktop and phone widths) and look at the pixels for what a machine cannot see: composition, hierarchy, page breaks, figure legibility.
|
|
178
|
-
5. **Proofread.** A dedicated writing lane proofreads the final text only (grammar, spelling, punctuation, terminology, native register); it never composes or rewrites content and never edits the file. Edits change text only; an edit whose before/after would alter any tag, attribute, comment, or script/style content is rejected, and markup changes go through the full fidelity gates instead. It returns `polish-edits.json` (`[{before, after, reason}]`), which the orchestrator applies edit by edit; a rejected or unlocated edit goes back to the lane with its reason, within the repair budget. The backstop diff, `fact verify` on the polished file, and the meaning readers on the pairs whose sentences polish changed run before the fidelity gate is recorded again. Edits must not span entities (such as & or <) or markup; narrow the edit to the surrounding words instead, and a rejected edit comes back with the reason to act on.
|
|
178
|
+
5. **Proofread.** A dedicated writing lane proofreads the final text only (grammar, spelling, punctuation, terminology, native register); it never composes or rewrites content and never edits the file. Edits change text only; an edit whose before/after would alter any tag, attribute, comment, or script/style content is rejected, and markup changes go through the full fidelity gates instead. It returns `polish-edits.json` (`[{before, after, reason}]`), which the orchestrator applies edit by edit; a rejected or unlocated edit goes back to the lane with its reason, within the repair budget. The backstop diff, `fact verify` on the polished file, and the meaning readers on the pairs whose sentences polish changed run before the fidelity gate is recorded again; the layout gates and visual QA then run again on the polished file, which is the one delivered. Edits must not span entities (such as & or <) or markup; narrow the edit to the surrounding words instead, and a rejected edit comes back with the reason to act on.
|
|
179
179
|
```bash
|
|
180
180
|
node "$SKILL_DIR/scripts/report-tools.mjs" fact polish-apply "$SESSION_DIR/report.html" --edits "$SESSION_DIR/polish-edits.json" --out "$SESSION_DIR/report.polished.html" --session-dir "$SESSION_DIR"
|
|
181
181
|
node "$SKILL_DIR/scripts/report-tools.mjs" fact polish-diff --before "$SESSION_DIR/report.html" --after "$SESSION_DIR/report.polished.html" --session-dir "$SESSION_DIR" # writes polish-defects.json
|
|
182
182
|
node "$SKILL_DIR/scripts/report-tools.mjs" fact pairs "$SESSION_DIR/report.polished.html" --changed-since "$SESSION_DIR/report.html.fill-map.json" --session-dir "$SESSION_DIR"
|
|
183
183
|
```
|
|
184
184
|
|
|
185
|
-
**Every reader-facing edition is verified.** The main report, the inline edition (section 9), LaTeX per-section sources, and slide sources are filled by `fact fill` from one placeholder source and each is verified by `fact verify` into its own record; PDF and DOCX are renders of a verified source. A delivered row is recorded with `outcome set <format> delivered --path <file> --verified-by <record>`, where the record's `artifact_sha256` equals the sha256 of the delivered source; a PDF or DOCX adds `--rendered-from <source>` and is matched against that source. Each delivered edition also carries its own meaning record: run `fact pairs` on that edition's source and `fact meaning-check --edition <format>`, which writes `fidelity-meaning-defects.<format>.json` bound to those bytes (section 7). The barrier binds each edition to a record for its current bytes: every record whose `artifact_sha256` equals those bytes is a candidate (its own record, another edition's record for a byte-identical copy or the html edition a PDF renders, and the legacy single file `fidelity-meaning-defects.json`), and the one with the newest `written_at` wins; on equal times the more severe verdict wins (`meaning_drift_confirmed`, then `meaning_unverified`, then clean). In a session with a fact ledger, `outcome verify` refuses a delivered row without a matching record (`edition_unverified`, blocker, integrity).
|
|
185
|
+
**Every reader-facing edition is verified.** The main report, the inline edition (section 9), LaTeX per-section sources, and slide sources are filled by `fact fill` from one placeholder source and each is verified by `fact verify` into its own record; PDF and DOCX are renders of a verified source. A delivered row is recorded with `outcome set <format> delivered --path <file> --verified-by <record>`, where the record's `artifact_sha256` equals the sha256 of the delivered source; a PDF or DOCX adds `--rendered-from <source>` and is matched against that source. Each delivered edition also carries its own meaning record: run `fact pairs` on that edition's source and `fact meaning-check --edition <format>`, which writes `fidelity-meaning-defects.<format>.json` bound to those bytes (section 7). The barrier binds each edition to a record for its current bytes: every record whose `artifact_sha256` equals those bytes is a candidate (its own record, another edition's record for a byte-identical copy or the html edition a PDF renders, and the legacy single file `fidelity-meaning-defects.json`), and the one with the newest `written_at` wins; on equal times the more severe verdict wins (`meaning_drift_confirmed`, then `meaning_unverified`, then clean). In a session with a fact ledger, `outcome verify` refuses a delivered row without a matching record (`edition_unverified`, blocker, integrity). A LaTeX edition is verified through its Markdown source; `fact verify --format tex` exits `2`.
|
|
186
186
|
|
|
187
187
|
The light tier runs gate 1 and one render (recorded as `visual`) and records `fidelity`, `layout`, and `proofread` as `not_run` (`fidelity not_run` needs `--reason "<why>"`); the light tier never runs the fidelity verifier, although `fact verify` checks HTML and Markdown editions. The full tier runs all five.
|
|
188
188
|
|
|
@@ -269,7 +269,7 @@ Invoke every command as `node "$SKILL_DIR/scripts/report-tools.mjs" <command>`.
|
|
|
269
269
|
| `fact polish-apply <report.html>` | `--edits <polish-edits.json>` and `--out <report.polished.html>` (both required; a missing flag or a Markdown edition exits `2`), `--fill-map <file>` (default: the edition's fill map, chosen as `fact verify` chooses it; one that does not record the input's bytes exits `2` and nothing is written), `--format html`, `--ledger <fact-ledger.json>`, `--brief <brief.md>`, `--session-dir <dir>` | `fidelity_interview_incomplete` (nothing written); otherwise never: it exits `0` whenever it wrote the output. With a fill map it also writes `<out>.polished.fill-map.json` (the brief binding, the polished file's hash, and `polishedFrom` naming the fill map) and never rewrites the fill map, even when `--out` is the input. Each rejected (`polish_edit_rejected`) or unlocated (`polish_edit_unlocated`) edit leaves its text unchanged and is printed verbatim, one line per rejection, in the summary and in `data.rejected_reasons`; `data` also carries `applied`, `rejected`, `unlocated`, `applied_indexes`, `input_sha256`, `edits_sha256`, and `out_sha256` |
|
|
270
270
|
| `fact polish-diff` | `--before <pre-polish.html>` and `--after <polished.html>` (both required; a missing flag exits `2`), `--ledger <fact-ledger.json>`, `--out <record>` (default `$SESSION_DIR/polish-defects.json`), `--brief <brief.md>`, `--session-dir <dir>` | `fidelity_interview_incomplete` (nothing written), or a registry blocker in the diff (majors and minors are reported and exit `0`; a defect code the registry does not know refuses with `unknown defect code <code>`). The record is `{command, status, exitCode, before, artifact, artifact_sha256, defects[], counts}`, with `counts` in contract buckets |
|
|
271
271
|
| `fact meaning-check` | `--pairs <pairs.json>` and `--verdicts <file>` (required; repeatable, one per reader tier), `--dispute P<n> --reason <text>`, `--run-id <id>`, `--calibration <file>` (default `fidelity-calibration.jsonl`), `--brief <brief.md>`, `--edition <format>` (writes `fidelity-meaning-defects.<format>.json`, the delivered edition's meaning record), `--out <record>` (default `fidelity-meaning-defects.json`), `--session-dir <dir>` | `fidelity_interview_incomplete`, or `meaning_drift_confirmed` (stderr carries one JSON line with the defect and dropped-verdict counts) |
|
|
272
|
-
| `fact derive` | `--op <op>` and `--now <ISO>` (both required; `--now` is the row's `observed_at`, the script never reads the clock, and without it the command exits `2` with `missing_now` and writes no row) with the operation's operands (section 11), `--unit`, `--to`, `--rationale`, `--disjoint`, `--label`, `--json`, `--session-dir <dir>` | `incompatible_operands` (no row written) |
|
|
272
|
+
| `fact derive` | `--op <op>` and `--now <ISO>` (both required; `--now` is the row's `observed_at`, the script never reads the clock, and without it the command exits `2` with `missing_now` and writes no row) with the operation's operands (section 11), `--unit`, `--to`, `--rationale`, `--disjoint`, `--reference`, `--label`, `--json`, `--session-dir <dir>` | `incompatible_operands` (no row written) |
|
|
273
273
|
| `claims index <claim-graph.md>` | `--out <claims.json>` (required) | never (a malformed claim table exits `2`) |
|
|
274
274
|
|
|
275
275
|
## 11. Fidelity gate
|
|
@@ -298,7 +298,7 @@ Derivations are computed in exact rationals from the operands' stored values and
|
|
|
298
298
|
|
|
299
299
|
| Operation | Operands | Checks |
|
|
300
300
|
| --- | --- | --- |
|
|
301
|
-
| `sum` | two or more ids, `--unit` | one unit; summing `%` needs `--disjoint
|
|
301
|
+
| `sum` | two or more ids, `--unit` | one unit; summing `%` needs `--disjoint`, `--reference <denominator>`, and `--rationale` |
|
|
302
302
|
| `diff` | two ids (minuend, subtrahend) | one unit; a difference of `%` is in `pp` |
|
|
303
303
|
| `growth` | `--from <id> --to <id>` | one declared entity, two different `valid_at` periods, a positive start; result in `%` |
|
|
304
304
|
| `ratio` | `--num <id> --den <id>`, `--unit` | a non-zero denominator |
|
|
@@ -35,7 +35,7 @@ Save every asset under `$SESSION_DIR/assets/` and confirm the file exists and is
|
|
|
35
35
|
|
|
36
36
|
### Charts from data
|
|
37
37
|
|
|
38
|
-
Put the numbers in a table first (`$SESSION_DIR/data/<name>.csv`), then plot from the table, never from prose. Follow the data-scientist doctrine
|
|
38
|
+
Put the numbers in a table first (`$SESSION_DIR/data/<name>.csv`), then plot from the table, never from prose. Follow the data-scientist tool doctrine: numpy for numeric work beyond SQL/DataFrame aggregation, Polars for filtering, sorting, and transforms, DuckDB for joins, aggregations, and window functions, never pandas.
|
|
39
39
|
|
|
40
40
|
```bash
|
|
41
41
|
uv run --with numpy --with polars --with matplotlib python plot_<name>.py
|
|
@@ -125,7 +125,7 @@ A post by Andrej Karpathy on 2026-10-02 ranks the formats that make model output
|
|
|
125
125
|
|
|
126
126
|
## 5. Quality bar
|
|
127
127
|
|
|
128
|
-
- Every figure follows the figure standard in
|
|
128
|
+
- Every figure follows the binding figure standard in [deliverable-phase.md](deliverable-phase.md), section 6: fixed container, contain-fit, aspect ratio preserved, spec fonts and palette.
|
|
129
129
|
- The caption alone tells the reader what the visual shows and what to conclude: "Median build time fell from 9.4 to 3.1 minutes after the cache change [S4]" beats "Build times".
|
|
130
130
|
- Alt text states the content, not the file: the key values or the shape of the trend for a chart, the main nodes and flow for a diagram. A purely decorative image takes `alt=""` plus `role="presentation"` and does not count as a visual; an empty alt without that marker is reported as missing.
|
|
131
131
|
- Every number in a visual comes from the data table and carries its source or lineage tag in the caption.
|
|
@@ -102,7 +102,7 @@ asked: derived numbers
|
|
|
102
102
|
|
|
103
103
|
Values carry no parentheses; `pending` goes only with `answered_by: pending`. When an answer lands, rewrite that one line with `answered_by: user` and leave `asked:` as history; a late answer after `fact fill` is a re-render: fill again, then verify.
|
|
104
104
|
|
|
105
|
-
**Re-entry.** An `edit-existing` session, or any session created before this block existed, has no `## Fidelity`. Before any `fact` command, run the inference step above and write the block with `answered_by: default` on every field. `claims index` on a free-form `claim-graph.md` (no claim table) returns `{claims: [], errors: [...]}`, exits 2, and writes no `claims.json`; run `fact verify` without it, and the gate reports each unbound sentence as `unbound_sentence` (major)
|
|
105
|
+
**Re-entry.** An `edit-existing` session, or any session created before this block existed, has no `## Fidelity`. Before any `fact` command, run the inference step above and write the block with `answered_by: default` on every field. `claims index` on a free-form `claim-graph.md` (no claim table) returns `{claims: [], errors: [...]}`, exits 2, and writes no `claims.json`; run `fact verify` without it, and the gate reports each unbound sentence as `unbound_sentence` (major), which blocks delivery until the sentence is bound.
|
|
106
106
|
|
|
107
107
|
**Calibration.** `fact meaning-check` appends one line per flagged pair to `--calibration` (default `$SESSION_DIR/fidelity-calibration.jsonl`). After each run, also append that run's new lines to the workspace-level `.omo/ulw-research/fidelity-calibration.jsonl`; promotion of `meaning_drift_confirmed` is decided from that log.
|
|
108
108
|
|
|
@@ -129,7 +129,7 @@ Scaling floor — more angles always justify more workers:
|
|
|
129
129
|
Role protocols — embed the relevant one in each spawn message; every worker gets a unique angle:
|
|
130
130
|
|
|
131
131
|
- **Codebase (explore), 2-4 workers.** Grep with 3+ keyword variations; structural/AST search; LSP definitions and references; file-name globs; `git log --all -S '<keyword>'` and `--grep` for history including deleted code. Cross-validate hits across tools. Report absolute file paths, patterns with `file:line`, and how findings connect.
|
|
132
|
-
- **Web, 3-9 workers, every one loaded with the `browser` skill.** Search with 10+ websearch queries per worker, each with a different operator or angle (see Search craft); a result is a candidate, not a source. Read every candidate in the user's browser through the `browser` skill's attached engine: one named session per worker, one tab per source, several tabs open side by side while sources are compared — `session.tabCreate` / `tabSelect` / `tabClose` where the harness has a JS eval kernel, `bsk tab create --url <url>` / `tab select <id>` / `tab close <id>` / `tab list
|
|
132
|
+
- **Web, 3-9 workers, every one loaded with the `browser` skill.** Search with 10+ websearch queries per worker, each with a different operator or angle (see Search craft); a result is a candidate, not a source. Read every candidate in the user's browser through the `browser` skill's attached engine: one named session per worker, one tab per source, several tabs open side by side while sources are compared — `session.tabCreate` / `tabSelect` / `tabClose` where the harness has a JS eval kernel, `bsk tab create --session <session> --url <url>` / `tab select --session <session> <id>` / `tab close --session <session> <id>` / `tab list --session <session>` on the CLI — the page scrolled to its end, a full-page screenshot of each top source saved as provenance, the tab closed once reported. A browser on another machine is reached through the `browser` skill's remote reference or a user-level skill that bridges to it, never replaced by a local headless one. `webfetch` is for raw files only: PDF, JSON, feeds, sitemaps. A host the browser cannot open (WAF, bot score, 403) goes to `ultimate-browsing`, whose provenance travels with the claim: a `snapshot` result cites its `snapshot_timestamp` and is never stated as the live page; a `proxy` result is `untrusted` until a second independent route agrees. Context7 with 3+ queries per known library; grep.app and `gh search code|repos|issues` for real-world usage; official docs via sitemap discovery (`<base>/sitemap.xml`), then targeted pages. A worker whose sources are all fetched text has searched, not read.
|
|
133
133
|
- **Repo deep-dive (librarian), 0-2 workers.** Shallow-clone the most relevant repos to `${TMPDIR:-/tmp}`, pin the HEAD SHA, read core modules, follow call chains, return SHA-pinned permalinks.
|
|
134
134
|
|
|
135
135
|
Example spawn (codebase axis; web and repo-dive follow the same contract with their own protocol):
|
|
@@ -31,7 +31,7 @@ numeric guards may read `exact` values, unit selection may not. The property tes
|
|
|
31
31
|
|
|
32
32
|
| op | arity | operand guards | context fields (persisted on the row) | result unit | malformed -> recompute ok:false |
|
|
33
33
|
|---|---|---|---|---|---|
|
|
34
|
-
| sum | n>=2 | non-affine units, all equal after canonicalization; if `%`: `disjoint: true` AND `reference` (one denominator id/text) equal on every operand AND rationale | disjoint, reference
|
|
34
|
+
| sum | n>=2 | non-affine units, all equal after canonicalization; if `%`: `disjoint: true` AND `reference` (one denominator id/text) equal on every operand AND rationale | disjoint, reference (the `%` rationale goes in the row's `rationale` field, not in context) | the common unit (`%` stays `%`) | <2 operands; missing id; no context; unequal/affine units; `%` without disjoint, reference, or rationale |
|
|
35
35
|
| diff | 2 | non-affine units; typed pairs only: U-U -> U (same non-% unit); %-% -> `%p`; %-%p -> `%`; %p-%p -> `%p`; %p-% REFUSED | none | per the pair rule | arity; invalid pair (`%p - %`, `m - person`); affine units; stray context |
|
|
36
36
|
| growth | 2 (from,to) | equal non-affine units; same entity; two different valid_at; from.exact > 0 | none | `%` (= 100(to-from)/from) | arity; unequal/affine units; entity/valid_at; from<=0; stray context |
|
|
37
37
|
| share | 2 (part,whole) | equal non-affine units; whole.exact > 0; 0 <= part <= whole | none | `%` (= 100 part/whole) | arity; units; whole<=0; part outside [0,whole]; stray context |
|
|
@@ -123,7 +123,7 @@ converted rows that carry this version's columns, and to every row this version
|
|
|
123
123
|
still breaks a strict rule (a scale word as unit, empty metadata, an operation or derivation fields) is flagged when it
|
|
124
124
|
is used: `derive` and `recompute` refuse it with shape `dimension 6`, `dimension 18`, or `dimension 1`, and `addRow`
|
|
125
125
|
refuses to write a new one. Normalization never strips user data: an `exact` carrying keys beyond `num` and `den` is left exactly as written and flagged `dimension 7` on use, never silently reduced to `{ num, den }`. Reading a normalized file again changes nothing. The legacy test fixture is generated by
|
|
126
|
-
dev's own `addRow` (`scripts/tests/fixtures/fidelity/gen-legacy-dev.mjs
|
|
126
|
+
dev's own `addRow` (`scripts/tests/fixtures/fidelity/gen-legacy-dev.mjs` in the source repository, which pins the dev commit; the tests and fixtures do not ship with the skill).
|
|
127
127
|
|
|
128
128
|
## Trust boundary
|
|
129
129
|
|
|
@@ -154,7 +154,7 @@ This is the platform baseline, distilled from Apple's Human Interface Guidelines
|
|
|
154
154
|
- A10 Content that continues out of view shows a cue (partial item, fade, chevron).
|
|
155
155
|
- A11 (mac) Nothing important lives only at the window's bottom edge; the minimum window size keeps toolbar and content legible; the sidebar collapses when the window narrows.
|
|
156
156
|
- A12 (web and app screens; N/A for a TUI, a printed page, or a figure) Layout contract: every changed screen or region has a `Layout:` line (in `DESIGN.md`, or in the change description when the project has none; the `frontend` skill's Brief step); the capture shows that pattern's structure; the logged owner is the region's main scroller in the probe output, every other scroller listed is nested inside it for its own content (a code block, a dropdown, a composer) or is named in the line too; none of the line's anti-patterns appear. A missing line, a different main scroller, an unexplained sibling scroller, or a present anti-pattern is a FAIL; a logged skip still owes the scroll-owner check.
|
|
157
|
-
- A13 Spacing rhythm, read from computed values: the space above a section heading is at least 1.5x the space below it, and the gap between groups is at least 2x the gap inside a group (the `frontend` skill's `references/perfection/craft-floor.md`).
|
|
157
|
+
- A13 Spacing rhythm, read from computed values: the space above a section heading is at least 1.5x the space below it, and the gap between groups is at least 2x the gap inside a group, unless the brief's chosen style route sets its own spacing rhythm and the deviation is recorded in the brief or DESIGN.md, in which case that value is the check (the `frontend` skill's `references/perfection/craft-floor.md`).
|
|
158
158
|
|
|
159
159
|
**B. Hierarchy**
|
|
160
160
|
- B1 One primary action per view, in the prominent style (accent on its background, not its glyph); peers differ by style, never by size.
|
|
@@ -205,7 +205,7 @@ This is the platform baseline, distilled from Apple's Human Interface Guidelines
|
|
|
205
205
|
A13, B8, E7, F8 and F9 are adapted from the craft floor of [pbakaus/impeccable](https://github.com/pbakaus/impeccable) (Apache-2.0, Copyright 2025 Paul Bakaus); the license and the list of changes are in the `frontend` skill's `ATTRIBUTION.md` section 6.
|
|
206
206
|
|
|
207
207
|
**G. Motion and feedback**
|
|
208
|
-
- G1 Every animation has a cause - an interaction, a state change, an arrival; no motion on non-interactive elements, no hover that changes nothing, no permanent loop.
|
|
208
|
+
- G1 Every animation has a cause - an interaction, a state change, an arrival; no motion on non-interactive elements, no hover that changes nothing, no permanent loop. A background the brief's ambience route asked for may loop on its decorative layer only while in view: it starts from an IntersectionObserver, stops off-screen and on visibilitychange, and paints one static frame under reduced motion (the `frontend` skill's `references/design/ambience-skill.md`).
|
|
209
209
|
- G2 Transitions keep identity: a surface that resizes or moves animates from its old geometry to the new; exit mirrors entry; nothing reflows under the pointer.
|
|
210
210
|
- G3 Motion is interruptible and never gates input: mid-animation input retargets smoothly and never snaps; nobody waits for an animation to act.
|
|
211
211
|
- G4 Under `prefers-reduced-motion`, positional, scale and depth motion becomes a cross-fade; fades, progress and gesture tracking stay; blur never animates.
|
|
@@ -273,7 +273,7 @@ SOURCE CODE:
|
|
|
273
273
|
{Full source of the UI: components, styles/tokens, layout, render code. Include neighboring files that show existing patterns.}
|
|
274
274
|
|
|
275
275
|
CAPTURES:
|
|
276
|
-
{Web: actual screenshot path(s) plus your described observations. TUI: paste
|
|
276
|
+
{Web: actual screenshot path(s) plus your described observations. TUI: paste terminal.txt and terminal-ansi.txt inline.}
|
|
277
277
|
|
|
278
278
|
SHARED SCRIPT EVIDENCE (reference, not verdict):
|
|
279
279
|
{Paste the image-diff or tui-check JSON. Use alphaChannelIntact for the transparency check.}
|
|
@@ -330,7 +330,7 @@ BEFORE/AFTER PAIRS:
|
|
|
330
330
|
SURFACE: {web | tui | both}
|
|
331
331
|
|
|
332
332
|
CAPTURES:
|
|
333
|
-
{Web: actual and reference screenshot paths plus your described observations. TUI: paste
|
|
333
|
+
{Web: actual and reference screenshot paths plus your described observations. TUI: paste terminal.txt and terminal-ansi.txt inline.}
|
|
334
334
|
|
|
335
335
|
SOURCE CODE:
|
|
336
336
|
{For web: include the rendered text/content, components, typography, layout, and style code. For TUI: include render code that controls wrapping, width, and wide-character handling.}
|
|
@@ -346,7 +346,7 @@ USE THE EVIDENCE:
|
|
|
346
346
|
- TUI (tui-check): inspect maxWidth vs expectedColumns, every overflowLines[] entry, borderMisaligned, and wideCharColumns[].
|
|
347
347
|
|
|
348
348
|
CHECK:
|
|
349
|
-
1. Checklist sections A-F, item by item, on the 390
|
|
349
|
+
1. Checklist sections A-F, item by item, on the 390, 1440 and (for page layouts) 1920 captures in BOTH themes and on the scrolled-to-end shots: PASS, FAIL or N/A with the capture that proves it. Every FAIL is BLOCKING.
|
|
350
350
|
2. When a reference packet exists, compare ACTUAL against REFERENCE pixel-perfectly, region by region: page bounds, header/nav, hero, cards, grids, charts, media, typography, copy, color tokens, radius, shadow, border, icon size, spacing, alignment, scroll position, and state. Anything off beyond unavoidable rasterization/rounding is a finding. The overview text is part of the target: missing or rearranged reference content is a finding even if the screenshot looks plausible.
|
|
351
351
|
3. When before/after pairs exist, judge each pair side by side: the after must show the brief's primary action and priorities more legibly than the before, carry fewer elements without a job, and lose nothing from the required-content list. A pair with no change a reader can point to, or a required input, datum, or copy present in before and missing or merged in after, is a BLOCKING [defect].
|
|
352
352
|
4. CJK precision:
|
|
@@ -89,8 +89,10 @@ not fall back to the owned engine for an authenticated criterion.
|
|
|
89
89
|
|
|
90
90
|
## Capture at a fixed viewport
|
|
91
91
|
|
|
92
|
-
Match CSS viewport AND PNG dimensions: pin `deviceScaleFactor` through `emulate` (owned)
|
|
93
|
-
`resize
|
|
92
|
+
Match CSS viewport AND PNG dimensions: pin `deviceScaleFactor` through `emulate` (owned engine).
|
|
93
|
+
Attached `resize(width, height)` sets the window size only and leaves the device pixel ratio at the
|
|
94
|
+
user's display, so on the attached engine record the capture's DPR (PNG width / CSS viewport width)
|
|
95
|
+
and compare against a reference taken at that DPR. Never resize the PNG to force a pass; a 390-wide capture at desktop
|
|
94
96
|
DPR with classic scrollbars is not a phone capture. Wait for the specific page state (a locator,
|
|
95
97
|
a `waitForURL`, a `createNetworkSnoop(page).waitFor(...)`), not a sleep, then compare:
|
|
96
98
|
|
|
@@ -15,6 +15,7 @@ import {
|
|
|
15
15
|
reviewWorkAnchor,
|
|
16
16
|
ulwExecuteOriginalCompletion,
|
|
17
17
|
ulwExecuteOriginalHardRule,
|
|
18
|
+
ulwExecuteOriginalRootScope,
|
|
18
19
|
} from "../scripts/sync-skills.mjs";
|
|
19
20
|
import { removeCodexSkillOverlays } from "./sync-skills-test-support.mjs";
|
|
20
21
|
|
|
@@ -40,6 +41,7 @@ test("#given shared skill source anchors #when Codex overlays are applied #then
|
|
|
40
41
|
|
|
41
42
|
assert.ok(ulwExecuteSource.includes(ulwExecuteOriginalCompletion), "ulw-execute completion anchor drifted from shared source");
|
|
42
43
|
assert.ok(ulwExecuteSource.includes(ulwExecuteOriginalHardRule), "ulw-execute hard-rule anchor drifted from shared source");
|
|
44
|
+
assert.ok(ulwExecuteSource.includes(ulwExecuteOriginalRootScope), "ulw-execute root-scope anchor drifted from shared source");
|
|
43
45
|
assert.ok(reviewWorkSource.includes(reviewWorkAnchor), "review-work anchor drifted from shared source");
|
|
44
46
|
|
|
45
47
|
for (const [skillName, source] of [["ulw-execute", ulwExecuteSource], ["review-work", reviewWorkSource]]) {
|
|
@@ -86,7 +86,7 @@ export function removeCodexCompatibilityGuidance(content) {
|
|
|
86
86
|
const ulwExecuteOriginalCompletion = `When all top-level checkboxes in \`## TODOs\` and \`## Final Verification Wave\` are complete:
|
|
87
87
|
|
|
88
88
|
1. Run the plan's final verification commands.
|
|
89
|
-
2.
|
|
89
|
+
2. Under \`--make-pr\` or \`--ship\`, finish the lifecycle from the last phase's worktree: sync \`.omo/\` state back to the main repo, create or update the PR, and wait for review/verification gates. Then follow the delivery mode: \`--ship\` merges per the repository's merge policy; \`--make-pr\` hands off with the PR URL and merges only if the user asks. Remove the worktree only after a successful merge or that explicit handoff. Finish directory teardown per Task resources and record its receipts.
|
|
90
90
|
3. Remove or mark the Boulder work as completed.
|
|
91
91
|
4. Print an \`ORCHESTRATION COMPLETE\` block with the plan path, verification commands, artifacts, and cleanup receipts.`;
|
|
92
92
|
|
|
@@ -95,10 +95,13 @@ const ulwExecuteCodexCompletion = `When all top-level checkboxes in \`## TODOs\`
|
|
|
95
95
|
1. Run the plan's final verification commands.
|
|
96
96
|
2. Record a self-review in the notepad: re-read the diff, run diagnostics, and capture evidence for every acceptance criterion. Run your own manual QA on the real surface.
|
|
97
97
|
3. Only when the user demanded strict, rigorous, or high-accuracy review, spawn ONE \`lazycodex-gate-reviewer\`; otherwise your self-review is the final verification.
|
|
98
|
-
4. Finish the PR/branch lifecycle from its task-owned worktree: sync \`.omo/\` state back to the main repo, create or update the PR, wait for review/verification gates
|
|
98
|
+
4. Finish the PR/branch lifecycle from its task-owned worktree: sync \`.omo/\` state back to the main repo, create or update the PR, wait for review/verification gates; \`--ship\` merges per the repository's merge policy, \`--make-pr\` hands off with the PR URL and merges only if the user asks; remove the worktree only after a successful merge or that explicit handoff. Finish directory teardown per Task resources and record its receipts.
|
|
99
99
|
5. Remove or mark the Boulder work as completed.
|
|
100
100
|
6. Print an \`ORCHESTRATION COMPLETE\` block with the plan path, verification commands, artifacts, and cleanup receipts.`;
|
|
101
101
|
|
|
102
|
+
const ulwExecuteOriginalRootScope = `This rule binds the root of a ulw-execute run, including its Final Verification Wave and any \`review-work\` pass run inside it: a worker runs every QA scenario, and you judge the artifacts it captured. Outside a ulw-execute run (a bare ultrawork run, a ulw-loop final gate, a standalone \`review-work\`), the session that owns the run runs the final real-surface QA itself.`;
|
|
103
|
+
const ulwExecuteCodexRootScope = `This rule binds the root of a ulw-execute run: a worker runs every implementation and per-task QA scenario, and you judge the artifacts it captured. The Codex edition's one exception is the final verification in the Completion section below, where the root runs its own manual QA on the real surface and records a self-review. Outside a ulw-execute run (a bare ultrawork run, a ulw-loop final gate, a standalone \`review-work\`), the session that owns the run runs the final real-surface QA itself.`;
|
|
104
|
+
|
|
102
105
|
const ulwExecuteOriginalHardRule = `- No production change before the tests covering that behavior were read and a bug's reproduction captured; existing tests are green on the unchanged code first, and one that contradicts the intent is a FINDING, never edited green.
|
|
103
106
|
- No \`--dry-run\` as completion evidence.
|
|
104
107
|
- No tests-only completion claim. A Manual-QA artifact is required.
|
|
@@ -159,7 +162,7 @@ prefixes when identity is needed.
|
|
|
159
162
|
`;
|
|
160
163
|
const reviewWorkCodexGatePattern = new RegExp(reviewWorkCodexGate.replace(/[.*+?^${}()|[\]\\]/g, "\\$&"));
|
|
161
164
|
|
|
162
|
-
const ulwResearchProofreadGate = "**Proofread gate: `task(category=\"writing\", ...)`.** Hand the final text to a dedicated `writing` worker whose only job is language: grammar, spelling, punctuation, terminology consistency, and whether the prose reads NATIVELY in the report's own language. It proofreads only and never composes, and it never edits the file: it returns `$SESSION_DIR/polish-edits.json`, an array of `{\"before\": ..., \"after\": ..., \"reason\": ...}` where `before` is the exact current text of one or more adjacent sentences. Edits change text only; an edit whose before/after would alter any tag, attribute, comment, or script/style content is rejected, and markup changes go through the full fidelity gates instead. Apply it with `node \"$SKILL_DIR/scripts/report-tools.mjs\" fact polish-apply \"$SESSION_DIR/report.html\" --edits \"$SESSION_DIR/polish-edits.json\" --out \"$SESSION_DIR/report.polished.html\" --session-dir \"$SESSION_DIR\"`: each edit is applied alone, and an edit that changes a fact span, a numeral, a link, or a claim id, or drops a hedge or qualifier the source carries, is `polish_edit_rejected` (a `before` not found exactly once is `polish_edit_unlocated`) and leaves its text unchanged. Send the rejected and unlocated edits back to the same worker with their reasons, plus `$SESSION_DIR/polish-defects.json` and the pre-polish `report.html` the backstop compared against, so the worker sees why each edit was refused; it returns either a rewritten sentence or a new edit list, and the repair round re-runs `fact polish-apply` with `\"$SESSION_DIR/report.polished.html\"` as both input and output, within the repair budget. Then run the backstop `fact polish-diff --before \"$SESSION_DIR/report.html\" --after \"$SESSION_DIR/report.polished.html\" --session-dir \"$SESSION_DIR\"` (exit `1` on `polish_diff_fail`), `fact verify` on `report.polished.html`, and `fact pairs \"$SESSION_DIR/report.polished.html\" --changed-since \"$SESSION_DIR/report.html.fill-map.json\" --session-dir \"$SESSION_DIR\"`, which keeps only the quote and claim pairs whose sentence text changed during polish; run the meaning readers above (cheap, then strong on the flagged pairs) on exactly those pairs and `fact meaning-check` before recording `outcome gate fidelity`. A rewording that keeps every number, hedge, qualifier, and link but swaps who did what to whom therefore still reaches a meaning reader on the delivered text. `report.polished.html` is the report that is delivered. Deliver only on a clean pass. This gate runs BEFORE the first delivery, not after the user finds the typo. Edits must not span entities (such as & or <) or markup; narrow the edit to the surrounding words instead, and a rejected edit comes back with the reason to act on.";
|
|
165
|
+
const ulwResearchProofreadGate = "**Proofread gate: `task(category=\"writing\", ...)`.** Hand the final text to a dedicated `writing` worker whose only job is language: grammar, spelling, punctuation, terminology consistency, and whether the prose reads NATIVELY in the report's own language. It proofreads only and never composes, and it never edits the file: it returns `$SESSION_DIR/polish-edits.json`, an array of `{\"before\": ..., \"after\": ..., \"reason\": ...}` where `before` is the exact current text of one or more adjacent sentences. Edits change text only; an edit whose before/after would alter any tag, attribute, comment, or script/style content is rejected, and markup changes go through the full fidelity gates instead. Apply it with `node \"$SKILL_DIR/scripts/report-tools.mjs\" fact polish-apply \"$SESSION_DIR/report.html\" --edits \"$SESSION_DIR/polish-edits.json\" --out \"$SESSION_DIR/report.polished.html\" --session-dir \"$SESSION_DIR\"`: each edit is applied alone, and an edit that changes a fact span, a numeral, a link, or a claim id, or drops a hedge or qualifier the source carries, is `polish_edit_rejected` (a `before` not found exactly once is `polish_edit_unlocated`) and leaves its text unchanged. Send the rejected and unlocated edits back to the same worker with their reasons, plus `$SESSION_DIR/polish-defects.json` and the pre-polish `report.html` the backstop compared against, so the worker sees why each edit was refused; it returns either a rewritten sentence or a new edit list, and the repair round re-runs `fact polish-apply` with `\"$SESSION_DIR/report.polished.html\"` as both input and output, within the repair budget. Then run the backstop `fact polish-diff --before \"$SESSION_DIR/report.html\" --after \"$SESSION_DIR/report.polished.html\" --session-dir \"$SESSION_DIR\"` (exit `1` on `polish_diff_fail`), `fact verify` on `report.polished.html`, and `fact pairs \"$SESSION_DIR/report.polished.html\" --changed-since \"$SESSION_DIR/report.html.fill-map.json\" --session-dir \"$SESSION_DIR\"`, which keeps only the quote and claim pairs whose sentence text changed during polish; run the meaning readers above (cheap, then strong on the flagged pairs) on exactly those pairs and `fact meaning-check` before recording `outcome gate fidelity`. A rewording that keeps every number, hedge, qualifier, and link but swaps who did what to whom therefore still reaches a meaning reader on the delivered text. `report.polished.html` is the report that is delivered; polish can change line wrapping, so re-run the layout gates and visual QA on `report.polished.html` and record `layout` and `visual` again. Deliver only on a clean pass. This gate runs BEFORE the first delivery, not after the user finds the typo. Edits must not span entities (such as & or <) or markup; narrow the edit to the surrounding words instead, and a rejected edit comes back with the reason to act on.";
|
|
163
166
|
// The shared skill numbers the proofread gate right after the Visual QA item the Codex edition ends on.
|
|
164
167
|
const ulwResearchVisualQaItemPattern = /^(\d+)\. \*\*Visual QA\.\*\*[^\n]*inspect the pixels\.$/m;
|
|
165
168
|
|
|
@@ -172,6 +175,7 @@ export function removeCodexSkillOverlays(skillName, content) {
|
|
|
172
175
|
}
|
|
173
176
|
if (skillName === "ulw-execute") {
|
|
174
177
|
return content
|
|
178
|
+
.replace(ulwExecuteCodexRootScope, ulwExecuteOriginalRootScope)
|
|
175
179
|
.replace(ulwExecuteCodexCompletion, ulwExecuteOriginalCompletion)
|
|
176
180
|
.replace(ulwExecuteCodexHardRule, ulwExecuteOriginalHardRule);
|
|
177
181
|
}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
// omo-codex-install:
|
|
2
|
+
// omo-codex-install:ebe09a4bde119ce98f2acce7f1f2bcec3085e797964a5e3cf176873e4c1a81d7:c88063ed768fc19cb863c26d6e6592a599b331f0e45cd3c27fcc278e4c9bc51a
|
|
3
3
|
var __esm = (fn, res, err) => () => {
|
|
4
4
|
if (fn)
|
|
5
5
|
try {
|
|
@@ -10205,7 +10205,7 @@ var package_default;
|
|
|
10205
10205
|
var init_package = __esm(() => {
|
|
10206
10206
|
package_default = {
|
|
10207
10207
|
name: "@oh-my-opencode/omo-codex",
|
|
10208
|
-
version: "5.1.
|
|
10208
|
+
version: "5.1.63",
|
|
10209
10209
|
type: "module",
|
|
10210
10210
|
private: true,
|
|
10211
10211
|
description: "Codex harness adapter for oh-my-openagent. Vendored Codex plugin namespace (omo) + TypeScript installer + telemetry.",
|
|
@@ -112,6 +112,8 @@ Before the first task command, create one `RUN_TMP=$(mktemp -d)` per task, track
|
|
|
112
112
|
At task end, after owned processes exit, remove only owned directories, including runtime caches. Never wipe shared caches; retain worktrees still needed by open PRs and any parent directory containing them.
|
|
113
113
|
|
|
114
114
|
## 0. Survey the skills, gather context, then size the work
|
|
115
|
+
This section records into the notepad, so run section 2's `NOTE=`
|
|
116
|
+
command first; section 2 then initialises that same file.
|
|
115
117
|
First, survey the loaded skill list and read the description of each
|
|
116
118
|
loosely relevant skill. Decide explicitly which skills this task will
|
|
117
119
|
use and prefer using every genuinely applicable one — name them in the
|
|
@@ -41,11 +41,11 @@ Subcommands: `search`, `replace` (dry-run; `--apply` to write), `scan`, `test`,
|
|
|
41
41
|
|
|
42
42
|
```bash
|
|
43
43
|
# from packages/shared-skills/skills/ast-grep/
|
|
44
|
-
python3 scripts/ast_grep_helper.py search '<PATTERN>' --lang
|
|
44
|
+
python3 scripts/ast_grep_helper.py search '<PATTERN>' [path] --lang <LANG>
|
|
45
45
|
python3 scripts/ast_grep_helper.py replace '<PATTERN>' '<REWRITE>' --lang ts # dry-run; add --apply
|
|
46
46
|
python3 scripts/ast_grep_helper.py doctor
|
|
47
47
|
bash tests/smoke.sh # or: pwsh tests/smoke.ps1
|
|
48
48
|
# direct: sg run -p '<PATTERN>' --lang ts path
|
|
49
49
|
```
|
|
50
50
|
|
|
51
|
-
- Parent:
|
|
51
|
+
- Parent (source checkout only, not shipped with the installed skill): `packages/shared-skills/AGENTS.md`.
|
|
@@ -29,13 +29,13 @@ ln -s /path/to/your/clone ~/.agents/skills/ast-grep
|
|
|
29
29
|
|
|
30
30
|
```bash
|
|
31
31
|
# Search by AST pattern (the helper validates patterns offline first)
|
|
32
|
-
python3 scripts/ast_grep_helper.py search 'console.log($MSG)' --lang ts
|
|
32
|
+
python3 scripts/ast_grep_helper.py search 'console.log($MSG)' src/ --lang ts
|
|
33
33
|
|
|
34
34
|
# Rewrite (dry-run preview by default)
|
|
35
|
-
python3 scripts/ast_grep_helper.py replace 'console.log($MSG)' 'logger.info($MSG)' --lang ts
|
|
35
|
+
python3 scripts/ast_grep_helper.py replace 'console.log($MSG)' 'logger.info($MSG)' src/ --lang ts
|
|
36
36
|
|
|
37
37
|
# Apply the rewrite (two-pass: preview JSON + then --update-all)
|
|
38
|
-
python3 scripts/ast_grep_helper.py replace 'console.log($MSG)' 'logger.info($MSG)' --lang ts
|
|
38
|
+
python3 scripts/ast_grep_helper.py replace 'console.log($MSG)' 'logger.info($MSG)' src/ --lang ts --apply
|
|
39
39
|
|
|
40
40
|
# Run YAML lint rules from sgconfig.yml
|
|
41
41
|
python3 scripts/ast_grep_helper.py scan src/
|
|
@@ -85,7 +85,7 @@ ast-grep-skill/
|
|
|
85
85
|
|
|
86
86
|
1. **Wraps `sg`** with a single Python 3 stdlib script that works the same on macOS, Linux, Windows, WSL, Git Bash.
|
|
87
87
|
2. **Validates patterns offline** before calling `sg` — catches the regex-misuse class of mistakes (`\w`, `.*`, `|`, `[a-z]`) plus language-specific traps (Python trailing colons, JS/Go/Rust missing function bodies).
|
|
88
|
-
3. **Resolves the binary** through
|
|
88
|
+
3. **Resolves the binary** through 5 candidates: `OMO_AST_GREP_SG_PATH` override → OMO runtime dirs → cached → PATH (with Linux `setgroups` collision detection) → Homebrew. Falls through to a clear install hint with copy-paste commands.
|
|
89
89
|
4. **Runs the two-pass write trick** when applying rewrites — `sg run` silently ignores `--update-all` when `--json` is set, so `replace --apply` runs two invocations: pass 1 collects JSON matches, pass 2 mutates files.
|
|
90
90
|
5. **Ships per-OS installers** that try every reasonable package manager and fall back to a GitHub release tarball.
|
|
91
91
|
6. **Documents the failure modes** the model will hit (regex misuse, incomplete patterns, `--update-all` + `--json` trap, scope/type questions ast-grep can't answer) in `references/pitfalls.md`.
|
|
@@ -17,9 +17,9 @@ OmO native also registers a bundled ast-grep MCP server. Its three tools are **d
|
|
|
17
17
|
|
|
18
18
|
- `mcp__ast_grep_search({ pattern, language, paths })` — AST-shape search, the MCP equivalent of `sg run -p`. Prefer this over shelling out to `sg` for one-off lookups: no install, no PATH issues.
|
|
19
19
|
- `mcp__ast_grep_rewrite({ pattern, rewrite, language, paths, apply })` — preview matches (`apply: false`, the default) or apply the rewrite (`apply: true`). Same two-pass discipline as `sg run -r`: preview first, then apply.
|
|
20
|
-
- `mcp__ast_grep_scan({ paths })` — run
|
|
20
|
+
- `mcp__ast_grep_scan({ ruleFile | inlineRules, paths, apply })` — run exactly one explicit YAML rule source (a rule file or inline rules), the MCP equivalent of `sg scan --rule` / `--inline-rules`. It never discovers `sgconfig.yml`; to run a project's whole rule set, use `sg scan` (or the helper's `scan`) from the shell.
|
|
21
21
|
|
|
22
|
-
Same pattern language as the CLI: `$VAR` matches one AST node, `$$$VAR` matches zero or more, and the pattern is code, not regex. `paths` accepts a file or directory list; `language` is required
|
|
22
|
+
Same pattern language as the CLI: `$VAR` matches one AST node, `$$$VAR` matches zero or more, and the pattern is code, not regex. `paths` accepts a file or directory list; `language` is always required by `mcp__ast_grep_search` and `mcp__ast_grep_rewrite`.
|
|
23
23
|
|
|
24
24
|
---
|
|
25
25
|
|
|
@@ -79,7 +79,7 @@ A single-file Python 3 stdlib wrapper. Same on every OS. The agent's default ent
|
|
|
79
79
|
### `search` — find all matches of a pattern
|
|
80
80
|
|
|
81
81
|
```bash
|
|
82
|
-
python3 scripts/ast_grep_helper.py search 'console.log($MSG)' --lang ts
|
|
82
|
+
python3 scripts/ast_grep_helper.py search 'console.log($MSG)' src/ --lang ts
|
|
83
83
|
```
|
|
84
84
|
|
|
85
85
|
Validates the pattern offline first. If the pattern looks like regex (`\w`, `.*`, `|`, etc.) the helper exits with a hint and never calls `sg` — saves a round-trip. Pass `--force` to skip validation.
|
|
@@ -94,10 +94,10 @@ Flags:
|
|
|
94
94
|
|
|
95
95
|
```bash
|
|
96
96
|
# Dry-run preview (default — no files mutated)
|
|
97
|
-
python3 scripts/ast_grep_helper.py replace 'console.log($MSG)' 'logger.info($MSG)' --lang ts
|
|
97
|
+
python3 scripts/ast_grep_helper.py replace 'console.log($MSG)' 'logger.info($MSG)' src/ --lang ts
|
|
98
98
|
|
|
99
99
|
# Actually apply
|
|
100
|
-
python3 scripts/ast_grep_helper.py replace 'console.log($MSG)' 'logger.info($MSG)' --lang ts
|
|
100
|
+
python3 scripts/ast_grep_helper.py replace 'console.log($MSG)' 'logger.info($MSG)' src/ --lang ts --apply
|
|
101
101
|
```
|
|
102
102
|
|
|
103
103
|
The helper:
|
|
@@ -117,10 +117,12 @@ python3 scripts/ast_grep_helper.py scan -r rules/no-console.yml src/
|
|
|
117
117
|
# Apply auto-fixes
|
|
118
118
|
python3 scripts/ast_grep_helper.py scan -U src/
|
|
119
119
|
|
|
120
|
-
#
|
|
120
|
+
# Compact one-line-per-finding report
|
|
121
121
|
python3 scripts/ast_grep_helper.py scan --report-style short src/
|
|
122
122
|
```
|
|
123
123
|
|
|
124
|
+
The helper has no `--format` flag; for CI-friendly GitHub annotations call `sg scan --format github src/` directly (see `references/cli.md`).
|
|
125
|
+
|
|
124
126
|
### `validate` — offline pattern check (no `sg` call)
|
|
125
127
|
|
|
126
128
|
Useful for CI lints, pre-commit hooks, and quick sanity checks:
|
|
@@ -226,7 +228,7 @@ In priority order:
|
|
|
226
228
|
1. **Run `helper validate '<pattern>' --lang <lang>`** — catches regex misuse, missing function bodies, Python trailing colons.
|
|
227
229
|
2. **Check `--lang`** — `sg` infers from extension; if you pass a `.tsx` file with `--lang ts` (not `tsx`), JSX won't parse.
|
|
228
230
|
3. **Inspect the parsed pattern**: `sg run -p '<pattern>' --lang <lang> --debug-query=ast --stdin <<< '<sample>'`. If it shows `ERROR` nodes, the pattern is malformed.
|
|
229
|
-
4. **Check the AST of the target
|
|
231
|
+
4. **Check the AST of the target code**: paste a snippet of the target file as the pattern, `sg run -p '<snippet>' --lang <lang> --debug-query=cst path/to/file 2>&1 >/dev/null | head -40` — the dump goes to stderr and shows the pattern's tree; find the `kind` you're trying to match.
|
|
230
232
|
5. **Try the playground**: <https://ast-grep.github.io/playground.html> — paste code + pattern, see what's happening.
|
|
231
233
|
|
|
232
234
|
Do not blindly retry with variations. Each failure has a reason; surface it.
|
|
@@ -255,7 +257,7 @@ The full YAML rule schema is in `references/yaml-rules.md`. Project setup (`sgco
|
|
|
255
257
|
- `sg run --json=compact` produces an array of match objects: `{ file, range: {start, end}, text, replacement?, lines, language, ... }`. Pipe through `jq` for further processing.
|
|
256
258
|
- Without `--json`, `sg` produces human-readable colored output suitable for terminals.
|
|
257
259
|
- The helper's default output is human-readable (file:line:column + match preview). Pass `--json-out` for raw JSON.
|
|
258
|
-
- The helper's `replace`
|
|
260
|
+
- The helper's `replace` dry-run prints the number of matches, the number of files, and a per-location preview; `--apply` prints only the totals (`APPLIED: rewrote N match(es) across M file(s).`).
|
|
259
261
|
|
|
260
262
|
When summarizing for the user, **always include the count of files affected**, not just the count of matches. Users care about blast radius.
|
|
261
263
|
|
|
@@ -208,9 +208,10 @@ sg completions powershell >> $PROFILE
|
|
|
208
208
|
sg run -p 'console.log($_)' --lang ts --json=compact . \
|
|
209
209
|
| jq -r '.[].file' | sort | uniq -c | sort -rn
|
|
210
210
|
|
|
211
|
-
# Find all unique kinds in a file (great for figuring out kind names)
|
|
212
|
-
|
|
213
|
-
|
|
211
|
+
# Find all unique kinds in a file (great for figuring out kind names).
|
|
212
|
+
# --debug-query dumps the PATTERN's tree to stderr, so pass the file's code as the pattern.
|
|
213
|
+
sg run -p "$(cat src/foo.ts)" --lang ts --debug-query=ast src/foo.ts 2>&1 >/dev/null \
|
|
214
|
+
| grep -oE '[a-z_]+ \(' | tr -d ' (' | sort -u
|
|
214
215
|
|
|
215
216
|
# Rewrite only in a subset of files
|
|
216
217
|
sg run -p 'foo()' -r 'bar()' --update-all --globs 'src/**/*.ts' --globs '!src/legacy/**' .
|
|
@@ -43,9 +43,9 @@ foo === foo.bar
|
|
|
43
43
|
|
|
44
44
|
Useful for finding redundant comparisons, double assignments, etc.
|
|
45
45
|
|
|
46
|
-
### `$$$` is
|
|
46
|
+
### `$$$` is lazy
|
|
47
47
|
|
|
48
|
-
When you write `foo($$$A, b, $$$C)`, the matcher does **not** backtrack or try every possible split. It
|
|
48
|
+
When you write `foo($$$A, b, $$$C)`, the matcher does **not** backtrack or try every possible split. It fills `$$$A` only until the rest of the pattern can match — the first `b` here — then everything left goes into `$$$C`. On `foo(a, c, b, b, c)` that is `A=[a, c]` and `C=[b, c]`, never the longer `A=[a, c, b]`.
|
|
49
49
|
|
|
50
50
|
```ts
|
|
51
51
|
// Pattern
|
|
@@ -116,11 +116,11 @@ Two tools help you confirm a pattern parses the way you expect:
|
|
|
116
116
|
# Print the AST of the pattern itself
|
|
117
117
|
sg run -p 'console.log($MSG)' --lang ts --debug-query=ast
|
|
118
118
|
|
|
119
|
-
# Print the
|
|
120
|
-
sg run -p '
|
|
119
|
+
# Print the CST of code copied from a file (great for figuring out kind names)
|
|
120
|
+
sg run -p 'function f(x: number) { return x + 1 }' --lang ts --debug-query=cst src/example.ts 2>&1 >/dev/null | head -40
|
|
121
121
|
```
|
|
122
122
|
|
|
123
|
-
`--debug-query=ast` shows the named AST nodes only (cleaner). `--debug-query=cst` shows everything including punctuation. Both
|
|
123
|
+
`--debug-query=ast` shows the named AST nodes only (cleaner). `--debug-query=cst` shows everything including punctuation. Both dump the tree of the **pattern** (not of the searched files) to stderr, so they don't interfere with stdout JSON; redirect `2>&1 >/dev/null` to pipe the dump. To learn a file's node kinds, paste that file's code as the pattern.
|
|
124
124
|
|
|
125
125
|
The web playground is also fast: <https://ast-grep.github.io/playground.html>.
|
|
126
126
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
# Pitfalls — what breaks patterns and how to fix them
|
|
2
2
|
|
|
3
|
-
This is the failure-mode field guide. The `scripts/ast_grep_helper.py validate` subcommand mechanically checks
|
|
3
|
+
This is the failure-mode field guide. The `scripts/ast_grep_helper.py validate` subcommand mechanically checks the §1 items for backslash escapes, `.*`/`.+`, character classes, and `|` alternation before calling `sg` (it does not detect `^`/`$` anchors), plus the missing-body and trailing-colon cases from §2; the rest are lower-frequency but still common.
|
|
4
4
|
|
|
5
5
|
---
|
|
6
6
|
|
|
@@ -126,9 +126,9 @@ If you actually want two independent captures, name them differently: `$X = $Y`.
|
|
|
126
126
|
|
|
127
127
|
---
|
|
128
128
|
|
|
129
|
-
## 6. `$$$` is
|
|
129
|
+
## 6. `$$$` is lazy and never backtracks
|
|
130
130
|
|
|
131
|
-
`$$$` does **not** backtrack. It
|
|
131
|
+
`$$$` does **not** backtrack. It stops at the first node that lets the rest of the pattern match, then commits — on `foo($$$A, b, $$$C)` against `foo(a, c, b, b, c)`, `$$$A` is `[a, c]`, not `[a, c, b]`. If your pattern needs more to land in `$$$A`, structure it differently:
|
|
132
132
|
|
|
133
133
|
```ts
|
|
134
134
|
// You want "match foo($X), where $X is any single arg"
|
|
@@ -5,11 +5,13 @@ Every pattern in this file has been verified against the canonical syntax. They
|
|
|
5
5
|
Use them with the helper:
|
|
6
6
|
|
|
7
7
|
```bash
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
8
|
+
python3 scripts/ast_grep_helper.py search '<PATTERN>' [path] --lang <LANG>
|
|
9
|
+
python3 scripts/ast_grep_helper.py replace '<PATTERN>' '<REWRITE>' [path] --lang <LANG> # dry-run
|
|
10
|
+
python3 scripts/ast_grep_helper.py replace '<PATTERN>' '<REWRITE>' [path] --lang <LANG> --apply
|
|
11
11
|
```
|
|
12
12
|
|
|
13
|
+
Put any `[path]` BEFORE `--lang`: the helper's `paths` argument is `nargs='*'`, and on Python 3.9 (the stock macOS `python3`, which the helper supports) a positional after `--lang` is rejected with `unrecognized arguments`. A pattern or rewrite containing a literal `|` (e.g. `$T | None`) is refused by the helper's alternation check — run two calls, or pass `--force` to reach `sg` anyway.
|
|
14
|
+
|
|
13
15
|
Or directly:
|
|
14
16
|
|
|
15
17
|
```bash
|
|
@@ -132,7 +134,7 @@ sg run -p 'print($$$A)' -r 'logger.info($$$A)' --lang py --update-all .
|
|
|
132
134
|
# Optional[X] -> X | None
|
|
133
135
|
sg run -p 'Optional[$T]' -r '$T | None' --lang py --update-all .
|
|
134
136
|
|
|
135
|
-
# from typing import List ->
|
|
137
|
+
# from typing import List -> annotate for manual removal (built-in list works in 3.9+)
|
|
136
138
|
sg run -p 'from typing import List' -r 'from typing import List # TODO: remove, use list' --lang py --update-all .
|
|
137
139
|
```
|
|
138
140
|
|
|
@@ -488,14 +488,14 @@ ignores:
|
|
|
488
488
|
- '**/__generated__/**'
|
|
489
489
|
```
|
|
490
490
|
|
|
491
|
-
If omitted, the rule runs on every file matching its `language`.
|
|
491
|
+
If omitted, the rule runs on every file matching its `language`. `sgconfig.yml` has no project-wide `files`/`ignores` to override; its `languageGlobs` only changes which language a file parses as. To narrow a whole scan, pass `--globs` to `sg scan`.
|
|
492
492
|
|
|
493
493
|
Object form (rare):
|
|
494
494
|
|
|
495
495
|
```yaml
|
|
496
496
|
files:
|
|
497
|
-
-
|
|
498
|
-
|
|
497
|
+
- glob: 'src/**/*.ts'
|
|
498
|
+
caseInsensitive: true
|
|
499
499
|
```
|
|
500
500
|
|
|
501
501
|
---
|
|
@@ -27,13 +27,13 @@ USAGE
|
|
|
27
27
|
|
|
28
28
|
EXAMPLES
|
|
29
29
|
# Find all console.log calls in TypeScript
|
|
30
|
-
ast_grep_helper.py search 'console.log($MSG)' --lang ts
|
|
30
|
+
ast_grep_helper.py search 'console.log($MSG)' src/ --lang ts
|
|
31
31
|
|
|
32
32
|
# Migrate console.log -> logger.info (dry-run preview)
|
|
33
|
-
ast_grep_helper.py replace 'console.log($MSG)' 'logger.info($MSG)' --lang ts
|
|
33
|
+
ast_grep_helper.py replace 'console.log($MSG)' 'logger.info($MSG)' src/ --lang ts
|
|
34
34
|
|
|
35
35
|
# Apply the same replacement
|
|
36
|
-
ast_grep_helper.py replace 'console.log($MSG)' 'logger.info($MSG)' --lang ts
|
|
36
|
+
ast_grep_helper.py replace 'console.log($MSG)' 'logger.info($MSG)' src/ --lang ts --apply
|
|
37
37
|
|
|
38
38
|
# Validate a pattern offline (no sg call, no filesystem access)
|
|
39
39
|
ast_grep_helper.py validate '\\w+' --lang ts
|
|
@@ -117,9 +117,8 @@ changing the extension's automation settings.
|
|
|
117
117
|
out everywhere. No flow here needs it.
|
|
118
118
|
- **`focused: false` by default.** The browser belongs to someone who is probably using it.
|
|
119
119
|
- **One short, named session per task,** always stopped.
|
|
120
|
-
- **Bot-scored or WAF targets go
|
|
121
|
-
capture on every tab it drives, which is a known automation signal
|
|
122
|
-
`connectCloakProfile()` is the stealth path.
|
|
120
|
+
- **Bot-scored or WAF targets never go through the attached engine** — route them to the `ultimate-browsing` skill, whose browser tier is the owned engine (`connectCloakProfile()`). The attached engine's daemon enables console
|
|
121
|
+
capture on every tab it drives, which is a known automation signal.
|
|
123
122
|
|
|
124
123
|
## Where the rest lives
|
|
125
124
|
|
|
@@ -60,4 +60,4 @@ python3 -B scripts/find-agent-sessions.py read <session-id>
|
|
|
60
60
|
pytest scripts/tests
|
|
61
61
|
```
|
|
62
62
|
|
|
63
|
-
- Parent:
|
|
63
|
+
- Parent (source checkout only, not shipped with the installed skill): `packages/shared-skills/AGENTS.md`.
|
|
@@ -80,10 +80,11 @@ Each `match_reasons` entry includes `query`, `platform`, `field`, and `snippet`,
|
|
|
80
80
|
| `--cwd` | Working-directory substring |
|
|
81
81
|
| `--model` | Model substring |
|
|
82
82
|
| `--limit` | Maximum results |
|
|
83
|
-
| `--query` | Repeatable search query; multiple queries return per-query groups plus a de-duplicated merged result list |
|
|
84
83
|
| `--workers` | Parallel worker count for platform scans, transcript parsing, OpenCode message joins, and multi-query matching |
|
|
85
84
|
| `--include-subagents` | Include subagent/child sessions as standalone `list`/`search` results (hidden by default) |
|
|
86
85
|
|
|
86
|
+
`search` (alias `find`) also takes `--query`: a repeatable search query; multiple queries return per-query groups plus a de-duplicated merged result list. `list` ignores `--query` and positional text.
|
|
87
|
+
|
|
87
88
|
When `--platform` is omitted, the finder searches every registered platform in parallel. Each optional platform first probes fixed, known transcript roots and returns immediately when the product has no local store, so broad default searches stay cheap. Use repeatable flags such as `--platform openclaw --platform droid` only when narrowing. Comma-separated platform values are intentionally unsupported.
|
|
88
89
|
|
|
89
90
|
For OpenCode, the finder uses `opencode db path` plus direct SQLite queries first, then `opencode session list --format json` as a fallback. It avoids heavy `messages/` or `parts/` scans during normal list/search, and only falls back to file joins when the OpenCode DB/CLI is unavailable or explicit `--root` values request a nonstandard store.
|