Skip to content

feat(initflow): MCP fallback, external-API token prompt, and verification gate tweak - #8

Merged
lorem-dev merged 6 commits into
developfrom
feat/tune-skills
May 24, 2026
Merged

feat(initflow): MCP fallback, external-API token prompt, and verification gate tweak#8
lorem-dev merged 6 commits into
developfrom
feat/tune-skills

Conversation

@lorem-dev

Copy link
Copy Markdown
Owner

Summary

Three additions to agent instruction templates plus one verification-gate tweak:

  • MCP wrapper fallback — when a locksmith-wrapped MCP server fails, the agent parses --header/--env templates from its own MCP config, resolves them via locksmith get, and runs the server directly. Templates also whitelist session ensure, serve, and get as the only runtime locksmith commands; all other subcommands are forbidden.
  • External-API auth-failure prompt — on the first 401/403 (or body containing "invalid token"/"unauthorized") for a hostname, the agent asks the user once: (1) Skip, (2) Locksmith key or vault+path, or (3) paste the token directly. Resolved tokens are cached per hostname for the session; Skip suppresses further prompts for that hostname.
  • Tightened wording — both sections are ~45% shorter than first draft. The MCP fallback now opens with an explicit "execute these steps; do not ask clarifying questions" directive so smaller models (Haiku) commit to the recovery path instead of pausing. Validated across multiple parallel sub-agent runs on Sonnet and Haiku.
  • GPG gate tweakverification.sh and the verification skill now ignore GitHub-generated "Merge pull request" commits whose web-flow signature is often expired locally and cannot be re-signed without diverging from the remote.

Two new cross-template Go tests (TestTemplates_AllHaveMCPFallback, TestTemplates_AllHaveAuthFailurePrompt) block regressions by asserting that every shipped template carries the required needles.

Test plan

  • All initflow tests pass (go test ./internal/initflow/...)
  • All 7 verification gates pass (.scripts/verification.sh): build, lint, test-race, coverage >= 90%, GPG signatures, CHANGES.md, docs completeness
  • Sub-agent dry-runs (Sonnet + Haiku) across MCP, external-API, edge-case, and non-locksmith scenarios

lorem-dev added 6 commits May 23, 2026 10:00
GitHub's "Merge pull request" commits are signed by the web-flow key,
which is often expired (E) or untrusted locally. Re-signing them is
impossible without diverging from the remote, so filter them out of
the unsigned-commits report and document the rule in the skill.
Shorten the runtime-whitelist, MCP-fallback, and external-API
auth-failure sections by ~45% with the same semantics. Add an
explicit "execute these steps; do not ask clarifying questions"
directive to the MCP fallback so smaller models commit to the
recovery path instead of pausing for confirmation.
@lorem-dev
lorem-dev merged commit 00a0b22 into develop May 24, 2026
3 checks passed
@lorem-dev
lorem-dev deleted the feat/tune-skills branch May 24, 2026 17:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant