Repository navigation
feat(pi-permission-system): carry operation purpose and complete file evidence - #1106
Draft
ElainaRoxy wants to merge 2 commits into
Draft
ElainaRoxy wants to merge 2 commits into
ElainaRoxy wants to merge 2 commits into
Conversation
通过现有审批载荷传递模型用途说明和完整读写编辑参数,保持既有权限顺序与自定义系统提示行为。 Refs gotgenes#1105
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.
Approval asks can show only a command or tool name, without explaining the operation, and file-tool previews may omit replacements. This proposal carries a per-call display explanation and complete file-operation evidence through separate existing payload channels.
Refs #1105. Draft for discussion of the sender contract; no release or merge is requested.
Behavior and contract
_permissionPurposeis consumed at the tool-call boundary and carried only as anoperation-purposeannotation for human presentation. It remains an agent-authored claim, never a policy fact or permission grant.file operationJSON evidence entry carriestoolandpath, read ranges, every edit replacement, or complete write content. The public API document specifies the exact shapes. Extra input metadata is not copied into this entry.The latest commit clarifies these independent channels and adds a contract regression demonstrating that structured payload forwarding preserves file evidence without copying purpose or extra fields into it.
Validation
pnpm run check: all workspace packages passed.pnpm run lint: passed.pnpm run test: all workspace package suites and root tests passed; pi-permission-system ran 6,446 tests, and the root suite ran 286 tests.Prepared with AI assistance. An independent subagent review was unavailable in this environment. Both changes remain proposals pending maintainer agreement on this contract.