39 39 The bash tool widget is the command indicator.
40 40 When RTK applies, Pi shows the rewritten `rtk ...` command.
41 -After session start, Pi checks RTK in the background and warns whether `find` rewrites are disabled or the compatibility guard can be removed.
41 +After session start, Pi checks RTK in the background and warns if it is unavailable or too old.
42 42 The first `bash` call waits for that shared check when it is still running.
48 48 1. registers the `bash` hook without blocking extension load
49 49 2. probes `rtk --version` after session start, or on the first `bash` call
50 50 3. warns once and leaves commands unchanged if `rtk` is missing or too old
51 -4. probes `rtk find -path` against a temporary nested marker and warns with the result
52 -5. ignores non-bash tools
53 -6. ignores empty, already-`rtk`, and disabled commands
54 -7. calls `rtk rewrite <command>` with a 2s timeout
55 -8. applies exit `0` and `3` rewrites
56 -9. rejects every `rtk find` rewrite while the path probe fails
57 -10. locally maps missing `journalctl`, `systemctl status`, `hyprctl clients`, and `ps` filters to `rtk summary`
58 -11. leaves other exit `1`, exit `2`, timeouts, errors, and empty output untouched
51 +4. ignores non-bash tools
52 +5. ignores empty, already-`rtk`, and disabled commands
53 +6. calls `rtk rewrite <command>` with a 2s timeout
54 +7. applies exit `0` and `3` rewrites
55 +8. caches exact successful rewrites for the current session
56 +9. locally maps missing `journalctl`, `systemctl status`, `hyprctl clients`, and `ps` filters to `rtk summary`
57 +10. leaves other exit `1`, exit `2`, timeouts, errors, and empty output untouched
61 +`rtk rewrite` starts an external process, so repeated exact commands reuse deterministic successful results within one session.
62 +Session transitions clear the cache, and no-match or transient failures remain retryable.
63 +`mise run //extensions/rtk:bench` compares repeated commands against unique-command controls through Pi's test harness and installed RTK executable.
64 +`mise run //extensions/rtk:profile` records a Node CPU profile under `.research/rtk`.
65 +`mise run //extensions/rtk:benchstat <baseline> <candidate>` performs statistical comparison.
60 67 No prompt injection.