Skip to content

feat(middleware): Vibes-Coded trust guard — pre-settlement screening + signed action-receipts#21

Open
doteyeso-ops wants to merge 4 commits into
AetherCore-Dev:mainfrom
doteyeso-ops:feat/vibes-coded-middleware
Open

feat(middleware): Vibes-Coded trust guard — pre-settlement screening + signed action-receipts#21
doteyeso-ops wants to merge 4 commits into
AetherCore-Dev:mainfrom
doteyeso-ops:feat/vibes-coded-middleware

Conversation

@doteyeso-ops

Copy link
Copy Markdown

What

A drop-in middleware for core/ag402_core/middleware (per @LeoBchuk's direction on #9) that turns Vibes-Coded's hosted pay-per-call trust layer into a first-class ag402 guard.

VibesCodedGuard.screen(intent, payload):

  • Maps the action intent to the right guard (idempotency-guard, agent-state-guard, contract-pin-guard, etc.) — see GUARD_ROUTES.
  • Calls the guard endpoint. ag402's own x402 middleware transparently pays the 402, so this is a pure trust layer.
  • Fails closed on any guard rejection or network/parse error.
  • On allow, mints a signed, offline-verifiable action-receipt bound to the frozen action tuple — recomputable by anyone running neither service (we publish Apache-2.0 conformance vectors that cross-verify against giskard09's action-ref suite).

Why

The community framing on #4/#9 was: ag402 handles settlement, Observer (did:web identity) handles trust, Vibes-Coded provides the reliability/replay/receipt checks. This middleware is the seam where those compose — a single screen() call gates an irreversible action on reliability + consent before money moves, then leaves an auditable receipt behind.

Commercials

Pay-per-call x402 (Agent Economy > Vibes-Coded on vibes-coded.com): agents pay a tiny per-call USDC fee only when an action is actually screened — no seats, no minimums. Built so it composes with Observer Protocol's did:web identity check in the same screen() pass.

Test plan

  • module compiles; route mapping + fail-closed paths unit-checked
  • wire against the sandbox key and run a live payment_or_transfer screen
  • confirm receipt mint + offline verify on the published conformance vectors

Want this gated-by-default (screen every irreversible action) or opt-in on the first cut? Happy to adjust the default route map.

… nonexistent fields); verified mints receipt
…+ signed action-receipts

Drop-in ag402 middleware that screens irreversible actions through Vibes-Coded's
hosted pay-per-call guards (idempotency/spend/contract-pin/agent-state) before
settlement, and mints a signed, offline-verifiable action-receipt on allow.

Per LeoBchuk's direction (AetherCore-Dev#9): lands in core/ag402_core/middleware alongside
budget_guard.py. Guard calls are x402 402s paid transparently by ag402's own
payment middleware; commercial model is pay-per-call USDC, no seats/minimums.
@doteyeso-ops

Copy link
Copy Markdown
Author

Friendly bump — this adds a pre-settlement Vibes-Coded trust guard (screening + signed action-receipts) that fits the ag402 middleware path.

Happy to adjust naming/shape if you want it to match Observer/#20 conventions. Live endpoints + OpenAPI: https://vibes-coded.com/openapi.json · https://vibes-coded.com/llms.txt

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