Available in
Marketplaces, most starred first
Tags
Add to README
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Marketplaces, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Marketplaces, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
By danielrosehillv0.3.0MITIn 1 marketplace
Auto-/clear when a prompt starts an unrelated task: a local ONNX classifier (no API calls) scores each prompt and splits it into a fresh session.
Claude loads one when your task matches it, or you run it by name.
No risk signals detected
Nothing flagged in this plugin's hooks, MCP servers or commands. Other components are not analyzed.
Static checks of hooks, mods, MCP servers and commands. Not a security audit.
1 marketplace, most starred first
Shows its components, always-on context cost and install status, kept current. Add ?tokens=0 to hide the cost.
Status: prototype (v0.1, 2026-10-24). A Claude Code plugin that notices when the user drops an
unrelated task into a long session and moves that prompt into a fresh session (/clear, then re-send)
automatically, so each task keeps a clean context.
Each prompt is scored locally by a small int8 ONNX cross-encoder,
danielrosehill/Agent-Task-Break-Detector-ModernBERT
(ModernBERT-base, trained on the synthetic
Agent-Task-Break-Detector dataset).
It does no per-turn API calls. The input is the new prompt plus the last 4 exchanges.
claudehook (one session only)The repo can be used without installing the plugin:
git clone https://github.com/danielrosehill/New-Task-Split
New-Task-Split/scripts/ntsctl launcher # links ~/.local/bin/claudehook
claudehook # Claude Code with auto-split ON for this session only
claudehook --shadow # ON, but log only (ntsctl status shows what it would have split)
claudehook --turns 2 # this session sends only the last 2 exchanges as context
claudehook passes any other arguments through to claude. On first run it installs the model, which is left disabled. It then loads
the plugin with claude --plugin-dir and sets NEW_TASK_SPLIT=split|shadow for that process alone, so a
plain claude session never runs the hook. If the plugin is already installed, claudehook only sets the env var.
ntsctl launcher --remove removes the link. Inside Claude Code, the trial skill does the same setup.
Promote a trial to always on with ntsctl enable (or --shadow), or the install skill. Demote with ntsctl disable; claudehook still works while the hook is disabled.
/plugin marketplace add danielrosehill/Claude-Code-Plugins
/plugin install new-task-split@danielrosehill
Then ask Claude to "install new-task-split" (skill install), or run the following directly:
~/.claude/plugins/.../new-task-split/scripts/ntsctl install --enable --shadow
install creates a venv (onnxruntime, tokenizers, numpy; it uses uv if present), downloads
the int8 model (~155 MB, sha256-checked against the Hub), runs a smoke test. The hook stays disabled unless the user passes
--enable (with --shadow for log-only mode).
Requirements: Python 3.10+ and Linux or macOS.
The hook is registered as soon as the plugin is installed, but it does nothing until ntsctl install has run and the
config says enabled.
| Command | Effect |
|---|---|
ntsctl enable --shadow | On, log only: decisions go to the log, nothing is split. Start here. |
ntsctl enable --split | On, and splits for real. |
ntsctl disable | Off. The venv and model are kept. |
ntsctl status | Config, model revision, last 10 decisions. |
ntsctl threshold 0.97 / default | Raise or lower the bar for a split (higher means fewer splits). |
ntsctl turns 1|2|3|4 / default | How many trailing exchanges the model sees (default 4). |
Settings take effect on the next prompt. There is no need to restart. The toggle skill wraps these commands.
Per session, typed as a whole prompt:
split off / split on: pause or resume for this session.NEW_TASK_SPLIT=off claude: off for that process. NEW_TASK_SPLIT=split or shadow turns it on for that
process whatever the config says. This is what claudehook sets.Per prompt:
same: … keeps the prompt in this session.new: … forces a split.The model sees the new prompt plus the last N exchanges (one exchange is a prompt and the agent's reply), newest first. Each exchange is cut to the last 600 characters of the reply and the first 600 of the prompt, and the whole input is capped at 512 tokens, with the oldest exchange dropped first.
N is 1–4 and defaults to 4, which is what the model was trained on.
ntsctl turns N, or NEW_TASK_SPLIT_TURNS=N, or claudehook --turns N for one session.turns it used, so shadow logs from different settings can be compared.The hook blocks the prompt and, in a background helper, types /clear and then the prompt back into the
same terminal. The fresh session is told that it was auto-split.
Undo: run /resume, pick the previous session and re-send. A prompt re-sent within 30 minutes is never
split again.
Terminal transport:
send-keys).wl-copy, xclip or pbcopy) and the user
is asked to /clear and paste.new-task-split@danielrosehill is listed by danielrosehill/claude-code-plugins — review the source before installing
npx claudepluginhub danielrosehill/claude-code-plugins --plugin new-task-splitPlugins from other owners that cover similar ground
Built from public signals: copy clicks on this site, GitHub stars and activity, the README and the manifest. Not a security audit or an endorsement.