Chore: permission-set refactor#10
Merged
Merged
Conversation
…hardcoded permission sets per agent
Each harness writer now defines three explicit permission sets (rigid,
sensible-defaults, max-autonomy) instead of deriving them from abstract
capability flags. This removes the brittle capability→tool-name mapping
layer that proved difficult to maintain correctly across nine harnesses.
Key changes:
- PermissionPolicy simplified to just { profile } — capabilities field removed
- autonomy.ts facet recipes simplified to pass { profile } directly
- All harness writers updated with hardcoded permission sets per profile
- Claude Code MCP rules now forward wildcard allowedTools as mcp__<ref>__*
(previously wildcard servers were silently skipped, causing MCP tools
to always prompt for approval)
- OpenCode permission rule sets inlined from the now-removed
getHarnessPermissionRules() helper
https://claude.ai/code/session_01RgRDwsqvUZhuz2hEjkBK53
- Extract `formatYamlKey` to `util.ts`; remove duplicate copies from `copilot.ts` and `opencode.ts` - Compute `getKiroTools` once in `kiro.ts` and reuse for both `tools` and `allowedTools` instead of calling it twice with identical args - Strengthen the local `PermissionRule` type in `opencode.ts` from `string | Record<string, string>` to use the explicit decision union `"ask" | "allow" | "deny"` so the compiler catches invalid values - Hoist repeated header strings out of individual `switch` case arms in `universal.ts` and `windsurf.ts` into a local `const` https://claude.ai/code/session_01RgRDwsqvUZhuz2hEjkBK53
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.
No description provided.