Proof of Work

Proof of Work — Envio Growth Engineer Package

One-page scoreboard. Built for someone landing cold who wants to know: what was made, what was proven, where to verify.


🟢 Live on Envio hosted service

The money-market template (Aave V3, Polygon) is deployed and queryable right now on Envio's hosted indexing service:

GraphQL endpoint: https://indexer.dev.hyperindex.xyz/8fc0607/v1/graphql (opens in a new tab)

curl -sX POST https://indexer.dev.hyperindex.xyz/8fc0607/v1/graphql \
  -H 'Content-Type: application/json' \
  -d '{"query":"{ ReserveAggregator(order_by:{totalSupplied:desc}, limit:5){ asset totalSupplied uniqueBorrowers totalLiquidations } }"}'

Deployed from branch envio-deploy-money-market (opens in a new tab) — pushes to that branch trigger redeploys. See DEPLOY.md (opens in a new tab) on that branch for sample queries.


What was built

Three forkable Envio HyperIndex templates, each anchored to a different real DeFi vertical and a real production protocol — not synthesised toys.

TemplateVerticalAnchored protocolChain
pow/envio-defi-template-v1/DEX (AMM swaps + liquidity)Velodrome V2 PoolFactoryOptimism
pow/envio-money-market-template-v1/Money market (lending + liquidations)Aave V3 PoolPolygon
pow/envio-perp-template-v1/Perpetuals (positions + funding)GMX v2 EventEmitterArbitrum

Plus 23 strategy memos at the repo root (ENVIO_*.md) — vertical playbook, pain-map matrix, money-market diagnostics, revenue math, video script, etc.


What was proven

LayerCountWhere
Vitest unit tests passing19 / 19pow/*/test/*.test.ts (10 DEX + 5 money-market + 4 perp/v1)
Cross-entity invariants written21scripts/demo-capture/assertions{,-defi,-perp}.mjs
Live-data checks passing48,014 / 48,014All 21 invariants, against real on-chain state on 3 chains
JSON GraphQL captures18docs/screenshots/queries{,-defi,-perp}/*.json
Harness output transcripts3docs/screenshots/queries*/HARNESS_OUTPUT.txt

Per-template scoreboard

TemplateVitestInvariantsLive checksSample size
DEX (Velodrome V2 / Optimism)10 ✓8 (D1–D8)31,091 / 31,091265 pools, 10k snapshots
Money market (Aave V3 / Polygon)5 ✓9 (L1–L9)14,401 / 14,40116 reserves, 1,089 liquidations, 5k user-reserves
Perp (GMX v2 / Arbitrum)2 ✓ + 3 skip→v24 (P1–P4)2,522 / 2,5229 markets, 1,252 positions

The harnesses catch a different class of bug from the unit tests: unit tests use MockDb with ~5–10 synthetic events, while the harness queries real chain state and asserts cross-entity invariants would have failed if any handler bug produced inconsistent state across thousands of events. Two real harness bugs were caught during DEX-harness development (unstable Hasura pagination; bad heuristic D8) — see the 2026-04-30 CHANGELOG entry in Growth_Engineer_at_ENVIO/CHANGELOG.md (opens in a new tab).


Where to verify it

  1. Read the saved harness output (no setup required):
  2. Read the JSON GraphQL response captures (real live-indexer output):
  3. Read the harness scripts (the predicates being checked):
  4. Reproduce the runs yourself — see each template's RUN.md:

Chain provenance

TemplateChainContractDeploy block
DEXOptimism (10)0xF1046053…5FF5a (opens in a new tab) (Velodrome V2 PoolFactory)105,896,852
Money marketPolygon (137)0x794a6135…814aD (opens in a new tab) (Aave V3 Pool)25,826,028
PerpArbitrum (42161)0xC8ee91A5…22Fb (opens in a new tab) (GMX v2 EventEmitter)107,737,756

All harness runs recorded in this package were against these mainnet deployments on 2026-04-30.


4-line replay

git clone https://github.com/kaustubh76/Growth_Engineer_at_ENVIO.git && cd Growth_Engineer_at_ENVIO
pnpm -C pow/envio-money-market-template-v1 install && pnpm -C pow/envio-money-market-template-v1 test     # 5 ✓
pnpm -C pow/envio-defi-template-v1 install         && pnpm -C pow/envio-defi-template-v1 test             # 10 ✓
pnpm -C pow/envio-perp-template-v1 install         && pnpm -C pow/envio-perp-template-v1 test             # 2 ✓ + 3 skip→v2

For the live runs (with RPC URL): cd pow/envio-XXX-template-v1 && cat RUN.md.


Strategy artifacts (the "growth engineer" half)

Strategy and positioning memos at the repo root. Highlights: