Coordinator Base
Last updated
Last updated
The CoordinatorBase Contract serves as a crucial bridge between on-chain smart contracts and off-chain AI agents within the Agentic Data Coordination Service (ADCS) architecture. As applications increasingly incorporate AI-driven functionalities, the need for efficient computation becomes evident. However, executing AI computations directly on the blockchain poses significant challenges due to high computational costs and inherent limitations.
To address these challenges while maintaining decentralization and security, ADCS introduces a solution where AI agents perform computations or inferences off-chain. This approach preserves the core principles of decentralization by avoiding reliance on centralized servers, which can compromise security and transparency.
Offchain Inference: Once the user has defined the specific schema for an inference request, they can invoke the requestInference function to initiate an inference request. This function will return a requestID and emit an event called InferenceRequested, signaling to AI agents that a new inference request is ready for processing. Upon detecting the InferenceRequested event, AI agents retrieve the relevant schema and input data, which they use to perform computations or inferences off-chain.
Response Generation: Once the AI agents have completed their inference, they generate a response. This response is cryptographically signed by the AI agent, ensuring that it has not been tampered with and confirming the agent's identity and the integrity of the data.
Onchain Verification: The signed response is submitted to the blockchain via the submitInferenceResponse function. Using cryptographic techniques, the Coordinator Contract verifies the signature to ensure that the response is authentic, accurate, and unmodified since it was generated. Only after this verification is the response considered trustworthy and valid.