Skip to main content

Using Hourglass to Implement Your AVS

What Hourglass Provides

The Hourglass template provides a basic structure for building an AVS with the Hourglass framework. It includes:

  • A stub of Go code for your Performer.
  • Default TaskAVSRegistrar and AVSTaskHook AVS contracts that work out of the box. These contracts can be extended to add additional onchain logic.
  • All dependent contracts required by the framework and the scripts to deploy them. The scripts are managed by the Devkit CLI.
  • A docker-compose stack to run an Aggregator and Executor locally to test your AVS.
  • Integration with the DevKit CLI. DevKit provides a streamlined, modular experience for scaffolding your projects, compiling, running local networks, and testing.

What You Need to Implement

ComponentPurposeDeveloper to ImplementRequired or Optional
main.goTask logicWrite AVS-specific task processingRequired
Smart Contracts (TaskAVSRegistrar, AVSTaskHook)On-chain AVS logicModify if you need custom onchain behaviorOptional
Config files (.hourglass, .devkit)Runtime and CLI setupCustomize paths, images, and networkOptional
Task InputTask testingCreate representative input dataOptional
docker-compose.ymlLocal setupEdit to match your environmentOptional

For detailed information on the Hourglass framework, refer to the Readme in the Hourglass repo.