feat: make the secretary opt-in instead of on by default - #107
Merged
Conversation
Consulting the secretary costs tokens on every question a session would otherwise put to the owner, and a fresh install should not pay that unasked. The app default flips to off; a value already stored in config.json is left alone, since serde's default only fills a missing key. The hooks had to move with it. Both readers tested `!== false`, which treats a missing key as enabled — with the app defaulting to off, that would run the secretary behind a Settings toggle reading "off". They now require `=== true`, on the Claude Code side (hooks/lib.mjs) and in the OpenCode plugin alike. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
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
models.rs; a value already stored in~/.workhub/config.jsonis left untouched, since serde's default only fills a missing key.plugins/workhub/hooks/lib.mjsand the OpenCodesecretary-plugin.ts) moved from!== falseto=== true, so the feature can no longer run behind a Settings toggle that reads "off".help-view.tsx,.claude/rules/secretary-agent.md,CHANGELOG.md) updated to match. App bumped to 0.74.1,workhubplugin to 0.20.0.Test plan
cargo test --release— 217 passed / 0 failedcargo clippy -- -D warnings— cleancargo fmt --check— cleannpm run build— passesnpm run check:opencode— passessecretary_enabledkey) shows the Settings checkbox unchecked, and no secretary hooks fire🤖 Generated with Claude Code