Skip to content

feat(orchestration): AP-14 AgentInvocationAdapter#5

Open
madschristensen99 wants to merge 1 commit into
mainfrom
feature/ap-14-agent-invocation-adapter
Open

feat(orchestration): AP-14 AgentInvocationAdapter#5
madschristensen99 wants to merge 1 commit into
mainfrom
feature/ap-14-agent-invocation-adapter

Conversation

@madschristensen99

Copy link
Copy Markdown
Contributor

Implements the 9-step agent invocation pipeline as an orchestration core primitive:

  • IAgenticJob, IAgentInvocationAdapter, IAgentConfigRegistry interfaces
  • IQuorumAttestedResolver dual-gate condition resolver interface
  • IAgentCoverageManager abstraction for coverage attachment
  • AgentInvocationAdapter.sol:
    • Inherits TestnetCoreBase with __gap[50]
    • ERC-7201 state layout (AgentInvocationState)
    • nonReentrant + checks-effects-interactions throughout
    • Programs against IEscrow (opaque bytes), not ConfidentialEscrow directly
    • Steps 1-5: openInvocation (config, conditions, escrow, coverages, emit)
    • Steps 7-9: submitFinalVerdict (sig, conditions, quorum gates)
    • completeInvocation / failInvocation helpers
  • Mocks for isolated unit testing
  • Full test coverage: 28 tests, all pass, 174 total orchestration tests pass

Summary

Type of Change

  • Bug fix
  • New feature
  • Breaking change
  • Refactor / cleanup
  • Documentation
  • CI / tooling

Packages Affected

  • @reineira-os/shared
  • @reineira-os/escrow
  • @reineira-os/recourse
  • @reineira-os/orchestration
  • @reineira-os/sdk
  • Operators

Testing

  • Unit tests pass (pnpm test)
  • New tests added for changed behavior
  • Contracts compile (pnpm compile)

Security Considerations

Implements the 9-step agent invocation pipeline as an orchestration core primitive:

- IAgenticJob, IAgentInvocationAdapter, IAgentConfigRegistry interfaces
- IQuorumAttestedResolver dual-gate condition resolver interface
- IAgentCoverageManager abstraction for coverage attachment
- AgentInvocationAdapter.sol:
  - Inherits TestnetCoreBase with __gap[50]
  - ERC-7201 state layout (AgentInvocationState)
  - nonReentrant + checks-effects-interactions throughout
  - Programs against IEscrow (opaque bytes), not ConfidentialEscrow directly
  - Steps 1-5: openInvocation (config, conditions, escrow, coverages, emit)
  - Steps 7-9: submitFinalVerdict (sig, conditions, quorum gates)
  - completeInvocation / failInvocation helpers
- Mocks for isolated unit testing
- Full test coverage: 28 tests, all pass, 174 total orchestration tests pass
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