delego 0.3.1 — MCP + CLI UX from live testing - #14
Merged
Merged
Conversation
MCP: tools return structured dicts (no more double-encoded JSON); a broker refusal comes back deny-shaped instead of raising; an uninitialised home is a structured setup_required payload naming the delego init command; new read-only delego_pending tool (approve/deny stay off the MCP surface — the agent that proposed an action must never be able to approve it). Engine: fingerprint/intent mismatch denials name what the approval was issued for (summary/instruction, already visible via pending and the ledger), so a drifted caller can self-correct. CLI: approve/deny echo the action and instruction being decided; verify gains --anchor-file, which checks against the stored head and advances it only after a clean verify. Protocol unchanged (0.3); package 0.3.1. dev extra now pulls mcp so CI exercises the MCP facade. 51 tests.
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.
What
UX patch driven by friction hit while exercising the MCP server end-to-end today. No protocol change (still 0.3); package 0.3.1.
MCP server
#fragmenton an allowed action's URL now returnsoutcome: "deny", executed: falsewith the reason, instead of a rawBrokerRefusaltool error (receipt already written since 0.3.0).setup_requiredpayload with the exactdelego initcommand, not a stack trace. Init stays deliberate — no silent key generation.delego_pendingtool (read-only). Approve/deny remain deliberately absent from the MCP surface: the agent that proposed an action must never be able to approve it. Stated in the module docstring, tool docs, README, ARCHITECTURE.Engine
pendingand the ledger, so nothing new is revealed). CTKresolvesubstring expectations still pass (text is appended after the matched prefix).CLI
delego approve/denyecho the action + instruction — the consent moment shows what was authorised, not just an id.delego verify --anchor-file PATH— checks against the stored head, advances it only after a clean verify; mutually exclusive with--expected-head.Verification
examples/demo.pygreen.devextra now includesmcp, so CI exercises the MCP facade (tests skip gracefully wheremcpis absent).server.jsonbumped to 0.3.1.