Find your next open-source project

Search by name, purpose, or keyword — or paste a GitHub repository URL

danyuchn/claude-work-mode

Developer Tools

Claude Code plugin that switches session work modes for autonomy, delegation, and decision wrap-up.

110
6
TypeScript
MIT
new today

What it does

claude-work-mode is a Claude Code plugin, controlled by a slash command, that changes how the model behaves within a session. It offers four modes: auto lets the model proceed through internal, reversible steps (local files, commits, tests) without stopping, while the hard stops — outgoing messages, installs, secrets, unrecoverable deletes, payments, permission changes, production changes — are collected into a pending list reported at the end. out pushes verifiable batch work (extraction, classification, summaries, reviews) to a background subagent or external CLI while the main thread verifies, and nudges when a lot of raw output is read without delegation. wrap closes out the session: no new branches, finish the open work, and list only new or changed decisions with a label and a recommendation. off restores normal behavior.

Modes are per session and combinable (/work-mode auto wrap); if both out and wrap are set, wrap wins. A bare /work-mode opens a multi-select picker. The mode text reaches the model once with the next tool result or prompt and again only after compaction or resume, so it does not reload every turn, per the README.

Install and first run

Requirements: Claude Code 2.1.314 or later with function-hook plugin support. Run the plugin install command inside Claude Code:

/plugin install work-mode --marketplace danyuchn/claude-work-mode

Answer y to add the marketplace, then pick a scope. Optional gates are a separate plugin:

/plugin install work-mode-gates --marketplace danyuchn/claude-work-mode

The gates need bash, jq, git and python3. A 60-second walkthrough video shows the behavioral changes across the three modes. Afterwards, type /work-mode to choose modes, or pass them directly, e.g. /work-mode auto wrap.

Optional gates

The modes are written to ~/.claude/state/tempo/<session_id> so shell hooks can read them. The gates plugin ships three hooks: scratch-doc-guard.sh prevents creating new SUMMARY*/REPORT*/NOTES*/FINDINGS*/ANALYSIS*.md under auto, git-safe-commit-gate.sh handles path-scoped git commit and git add cases, and decision-label-guard.py blocks replies whose decisions section has unlabeled items or tradeoffs that do not state each side's gain. Under auto, gates that would ask instead deny with a reason telling the model what to do. hooks/lib/tempo-auto.sh exposes tempo_auto_on "$INPUT" and tempo_deny "<reason>" for writing your own gates; real hard stops such as secrets, force pushes and deploys should keep asking in every mode.

Configuration

No configuration is required. The locale is resolved from WORK_MODE_LOCALE, then the Claude Code language setting (anything mentioning Chinese selects Traditional Chinese), then LC_ALL/LANG, and English otherwise. To personalize, create ~/.config/work-mode/config.json or point WORK_MODE_CONFIG at a file; a full example config is provided. Fields cover pronouns and user name, extra auto rules, the out dispatch instructions and command regex, the nudge threshold and template, the wrap decision heading and labels, and an optional quota table for routing across external model pools.

Constraints

This is a Claude Code plugin, so it requires Claude Code 2.1.314+ and does not apply to other coding agents. The gates plugin adds a dependency on bash, jq, git and python3, which the base modes do not need. The mode persistence writes session state under ~/.claude/state/tempo/, and the optional config reads from ~/.config/work-mode/ or the path in WORK_MODE_CONFIG. The project is MIT-licensed. Development checks run via ./check.sh and need tsc and the Claude Code API types.

HotRepo's take

The repository appeared in HotRepo's new-project snapshot on 2026-11-08, gaining 103 stars over a roughly nine-hour window. That is a healthy initial reception for a small, focused plugin. Because it landed only through that single snapshot, there is not yet a multi-day trend to read into. Its interest is tied to Claude Code's plugin and hook ecosystem: the design of persisting mode text to files so shell hooks can react, and of converting confirmation prompts into denials under auto, is what makes the gates useful rather than decorative.

Written by AI from the project's README, updated . The project's own docs are the source of truth.