Repository navigation
docs: use "tmux" as the registration slug throughout - #40
Merged
Merged
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #40 +/- ##
=======================================
Coverage 84.91% 84.91%
=======================================
Files 40 40
Lines 2294 2294
Branches 294 294
=======================================
Hits 1948 1948
Misses 261 261
Partials 85 85 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
tony
force-pushed
the
feature/docs-slug-consistency-tmux
branch
from
May 9, 2026 10:35
3f738ff to
27caa70
Compare
Member
Author
Code reviewNo issues found. Re-checked the latest delta for bugs and AGENTS.md compliance. |
tony
force-pushed
the
feature/docs-slug-consistency-tmux
branch
from
May 9, 2026 12:02
27caa70 to
b112e5c
Compare
Member
Author
Code reviewNo issues found. Re-checked the latest delta for bugs and AGENTS.md compliance. |
tony
added a commit
that referenced
this pull request
May 9, 2026
why: PR #40 renames the recommended registration slug from `libtmux` to `tmux` (matching `serverInfo.name`). Existing user installations keep working, but users who want the new `mcp__tmux__*` tool prefix need clear before/after instructions. Following the libtmux pattern (~/work/python/libtmux/MIGRATION): a root MIGRATION file (no extension) is the source of truth, included into the docs build via docs/migration.md (added in the next commit). what: - New `MIGRATION` file at the repo root, no extension. Plain Markdown with MyST extensions so the future {include} from docs/migration.md renders cleanly under Sphinx. - Welcome admonition with tracker link, mirroring libtmux's intro. - Single section under "## libtmux-mcp 0.1.0a6 (unreleased)" for the slug rename. Before / After / What's unchanged subsections with 4-space-indented shell examples (matches libtmux MIGRATION style). - Confirms `claude mcp remove <name>` auto-detects scope (verified against `claude --version 2.1.138`), so migration commands work regardless of original registration scope.
Member
Author
Code reviewFound 2 issues in the new `MIGRATION` file:
Lines 37 to 48 in dfe6507
Lines 43 to 48 in dfe6507 If this code review was useful, please react with thumbs-up. Otherwise, react with thumbs-down. |
tony
added a commit
that referenced
this pull request
May 9, 2026
why: PR #40 renames the recommended registration slug from `libtmux` to `tmux` (matching `serverInfo.name`). Existing user installations keep working, but users who want the new `mcp__tmux__*` tool prefix need clear before/after instructions. Following the libtmux pattern (~/work/python/libtmux/MIGRATION): a root MIGRATION file (no extension) is the source of truth, included into the docs build via docs/migration.md (added in the next commit). what: - New `MIGRATION` file at the repo root, no extension. Plain Markdown with MyST extensions so the future {include} from docs/migration.md renders cleanly under Sphinx. - Welcome admonition with tracker link, mirroring libtmux's intro. - Single section under "## libtmux-mcp 0.1.0a6 (unreleased)" for the slug rename. Before / After / What's unchanged subsections with 4-space-indented shell examples (matches libtmux MIGRATION style). - Confirms `claude mcp remove <name>` auto-detects scope (verified against `claude --version 2.1.138`), so migration commands work regardless of original registration scope.
tony
force-pushed
the
feature/docs-slug-consistency-tmux
branch
from
May 9, 2026 13:42
dfe6507 to
ec304da
Compare
tony
added a commit
that referenced
this pull request
May 9, 2026
why: PR #40 renames the recommended registration slug from `libtmux` to `tmux` (matching `serverInfo.name`). Existing user installations keep working, but users who want the new `mcp__tmux__*` tool prefix need clear before/after instructions. Following the libtmux pattern (~/work/python/libtmux/MIGRATION): a root MIGRATION file (no extension) is the source of truth, included into the docs build via docs/migration.md (added in the next commit). what: - New `MIGRATION` file at the repo root, no extension. Plain Markdown with MyST extensions so the future {include} from docs/migration.md renders cleanly under Sphinx. - Welcome admonition with tracker link, mirroring libtmux's intro. - Single section under "## libtmux-mcp 0.1.0a6 (unreleased)" for the slug rename. Before / After / What's unchanged subsections with 4-space-indented shell examples (matches libtmux MIGRATION style). - Confirms `claude mcp remove <name>` auto-detects scope (verified against `claude --version 2.1.138`), so migration commands work regardless of original registration scope.
tony
force-pushed
the
feature/docs-slug-consistency-tmux
branch
from
May 9, 2026 14:03
ec304da to
bb1c635
Compare
tony
added a commit
that referenced
this pull request
May 9, 2026
Bare *"pane"* / *"window"* / *"session"* prompts now reliably activate libtmux-mcp without the user having to say "tmux". This ships three orthogonal activation levers: a `_INSTR_SCOPE` instruction segment that names positive triggers and explicit anti-triggers, a buried-synonym pass on six discovery-anchor docstrings so the BM25 corpus indexes terminal-vocabulary, and per-tool `anthropic/alwaysLoad: true` meta hints on the three high-traffic read-only anchors. **Activation rule** — `_INSTR_SCOPE` names positive triggers (`pane`, `split`, `scrollback`, `%`/`@`/`$` IDs) and explicit anti-triggers (browser windows/tabs, editor panes, GUI workspaces, Jupyter cells, login/HTTP sessions). The full transmitted `instructions=` re-fits Claude Code's 2KB ceiling across all safety tiers and both `$TMUX_PANE` configurations. **BM25 corpus widening** — six discovery-anchor docstrings (`list_panes`, `list_windows`, `list_sessions`, `snapshot_pane`, `search_panes`, `capture_pane`) gain tmux-vocabulary synonyms (terminal, shell, scrollback, multiplexer, workspace) plus inline anti-triggers. Both sentences land in the indexed corpus via FastMCP's griffe parser. **Per-tool alwaysLoad** — `list_panes`, `list_windows`, and `snapshot_pane` carry `anthropic/alwaysLoad: true` per-tool hints (Claude Code v2.1.121+). Best-effort, opaque pass-through in FastMCP; safe no-op for clients that don't honor the field. **Server identity** — `serverInfo.name` is now `tmux` (was `libtmux`), aligning with the recommended registration slug from PR #40. **HOOKS_GAP rationale** — `_INSTR_HOOKS_GAP` restores the "survive process death" causal phrase so the read-only-hooks rule reads as a correctness boundary rather than a soft preference. **Tests** — transmitted `instructions=` length is gated across all (tier × tmux_pane) combinations including a variable-length stress case (longer socket name + multi-digit pane id); SCOPE, HOOKS, and discovery-anchor substrings pinned to their respective `_INSTR_*` segments to catch refactor drift.
tony
added a commit
that referenced
this pull request
May 9, 2026
why: PR #40 renames the recommended registration slug from `libtmux` to `tmux` (matching `serverInfo.name`). Existing user installations keep working, but users who want the new `mcp__tmux__*` tool prefix need clear before/after instructions. Following the libtmux pattern (~/work/python/libtmux/MIGRATION): a root MIGRATION file (no extension) is the source of truth, included into the docs build via docs/migration.md (added in the next commit). what: - New `MIGRATION` file at the repo root, no extension. Plain Markdown with MyST extensions so the future {include} from docs/migration.md renders cleanly under Sphinx. - Welcome admonition with tracker link, mirroring libtmux's intro. - Single section under "## libtmux-mcp 0.1.0a6 (unreleased)" for the slug rename. Before / After / What's unchanged subsections with 4-space-indented shell examples (matches libtmux MIGRATION style). - Confirms `claude mcp remove <name>` auto-detects scope (verified against `claude --version 2.1.138`), so migration commands work regardless of original registration scope.
tony
force-pushed
the
feature/docs-slug-consistency-tmux
branch
from
May 9, 2026 14:25
bb1c635 to
d6099d6
Compare
why: README's recommended registration slug is `tmux` (matches what users actually think — "the tmux MCP"), but `docs/clients.md` and the install-widget were using `libtmux`. Followers of either doc would end up with `mcp__tmux__*` or `mcp__libtmux__*` tool prefixes depending on which page they read. Aligning every doc to `tmux` removes the papercut. what: - docs/clients.md: 18 registration-slug `libtmux` -> `tmux` (in `claude mcp add ...`, `codex mcp add ...`, `gemini mcp add ...`, JSON `mcpServers.libtmux` keys, TOML `[mcp_servers.libtmux]` key). Package name `libtmux-mcp`, module `libtmux_mcp`, and GitHub link unchanged. - docs/_ext/widgets/mcp_install.py: 9 registration-slug occurrences in INSTALL_CMDS dict updated to `tmux`. `pip install libtmux-mcp` lines unchanged. - tests/docs/test_widgets.py + snapshots: assertions and stored snapshots updated to expect the new `tmux` slug. note: existing user registrations as `libtmux` keep working — the slug is a per-install user choice, not a property of the package. This change recommends `tmux` for new installs.
why: PR #40 renames the recommended registration slug from `libtmux` to `tmux` (matching `serverInfo.name`). Existing user installations keep working, but users who want the new `mcp__tmux__*` tool prefix need clear before/after instructions. Following the libtmux pattern (~/work/python/libtmux/MIGRATION): a root MIGRATION file (no extension) is the source of truth, included into the docs build via docs/migration.md (added in the next commit). what: - New `MIGRATION` file at the repo root, no extension. Plain Markdown with MyST extensions so the future {include} from docs/migration.md renders cleanly under Sphinx. - Welcome admonition with tracker link, mirroring libtmux's intro. - Single section under "## libtmux-mcp 0.1.0a6 (unreleased)" for the slug rename. Before / After / What's unchanged subsections with 4-space-indented shell examples (matches libtmux MIGRATION style). - Confirms `claude mcp remove <name>` auto-detects scope (verified against `claude --version 2.1.138`), so migration commands work regardless of original registration scope.
why: the root MIGRATION file is the source of truth, but it needs a
docs entry point so users can navigate to it from the docs sidebar.
Mirrors libtmux's two-file pattern (~/work/python/libtmux/docs/migration.md):
a thin MyST wrapper that {include}s the root file. The (migration)=
anchor is what other docs pages cross-reference to.
what:
- New `docs/migration.md` (5 lines): MyST anchor + ``{include}``
directive pulling in `../MIGRATION`. No content of its own; the
authoritative source is the root MIGRATION file.
- Sphinx warns "document isn't included in any toctree" until the
next commit wires it in. Build still succeeds.
why: Commit 2's docs/migration.md page is unreachable until it lives
in the docs sidebar nav. And the migration {note} I added earlier in
docs/clients.md duplicates content that now lives on the dedicated
migration page. Replace the inline admonition with a one-line
cross-reference so docs/clients.md stays focused on setup
instructions and migration content lives in one place.
what:
- docs/index.md: add `migration` to the "Project" caption toctree
between `history` and the GitHub link, mirroring libtmux's
placement (~/work/python/libtmux/docs/index.md). The Sphinx
toc.not_included warning from Commit 2 clears.
- docs/clients.md: replace the 9-line {note} admonition with a
one-line ``{ref}``-style cross-reference: "See {ref}`migration`
for the recommended `tmux` registration slug (existing `libtmux`
registrations keep working)." The migration anchor was added in
Commit 2.
Adds an unreleased "What's new" bullet covering the libtmux→tmux registration slug recommendation across docs and the new MIGRATION root file + docs/migration.md wrapper.
tony
force-pushed
the
feature/docs-slug-consistency-tmux
branch
from
May 9, 2026 15:08
d6099d6 to
43a2832
Compare
tony
added a commit
that referenced
this pull request
May 9, 2026
User-facing companion documentation for the activation work shipped by #37 and the slug rename shipped by #40. The mechanism (`alwaysLoad` meta on three discovery anchors, BM25 description tuning, `serverInfo.name="tmux"`, the `libtmux` → `tmux` slug recommendation) already lives on main; this PR adds the prose that explains how to leverage it. - **Activation and discovery section** in {ref}`prompting`: positive triggers (*"split this pane"*, *"current window"*, *"this session"*) vs. anti-triggers (browser, editor split, i3/Hyprland, Jupyter), with the agent asking when phrasing is ambiguous. - **Always-on tool listing (Claude Code only)**: the `alwaysLoad: true` JSON snippet at server-entry level for users who want every schema preloaded (Claude Code v2.1.121+). ~3-5K token permanent context cost noted — recommended only if libtmux-mcp is among your top-3 most-used MCPs. - **Project-bias template** under the existing "System prompt fragments" section. `AGENTS.md` / `CLAUDE.md` / equivalent project files compose into the system prompt above the server's `instructions=` block, making this the highest-leverage user-side lever for *"current window"* / *"this session"* anaphora. The inside-tmux \`\$TMUX_PANE\` auto-detection note is not duplicated — {ref}\`concepts\` "Agent self-awareness" already covers it and is cross-referenced. See also: #37 (activation mechanism), #40 (slug rename to \`tmux\`).
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
docs/clients.mdand the install widget were usinglibtmuxas the registration slug whileREADME.mdrecommendstmux. Followers of either doc would end up withmcp__tmux__*ormcp__libtmux__*tool prefixes depending on which page they read.This PR aligns every doc to
tmux:docs/clients.md— 18 registration-sluglibtmux→tmux(inclaude mcp add,codex mcp add,gemini mcp add, JSONmcpServers.libtmuxkeys, TOML[mcp_servers.libtmux]key)docs/_ext/widgets/mcp_install.py— 9 registration-slug occurrences inINSTALL_CMDStests/docs/test_widgets.py+ snapshots — assertions and stored snapshots updated to expect the newtmuxslugThe package name
libtmux-mcp, the importlibtmux_mcp, and the GitHub link are unchanged. Existing user registrations aslibtmuxkeep working — the slug is a per-install user choice, not a property of the package. This change just recommendstmuxfor new installs.Test plan
uv run ruff check . && uv run mypy && uv run py.test -q(428 passed; widget snapshot tests updated)just build-docs