Inspiration

What if a company matched 100% of its annual electricity use with wind power, yet still relied on a grid that was not equally clean every hour?

Using Energinet's 2025 data, Denmark's IT and telecom sector, when matched against Danish wind generation equal to its annual electricity consumption, achieves only 69.7% hourly matching. Wind generated at night cannot cover electricity demand at noon, even if annual accounting makes the totals look equal.

This gap inspired HourProof. Hourly clean-energy matching is more meaningful, but it introduces three challenges: preventing the same energy from being claimed twice, protecting commercially sensitive electricity-use data, and ensuring emissions calculations use the correct grid-intensity data. We built HourProof to address all three.

What it does

HourProof makes clean-energy claims verifiable hour by hour.

  • One certificate, one claim: A shared on-chain ledger prevents the same MWh-hour from being claimed twice across registries. Issuance is capped by metered production, and daily batches are authenticated using ML-DSA-44, a post-quantum signature scheme.
  • Private verification: Zero-knowledge proofs verify that a buyer meets a minimum hourly clean-energy coverage threshold and stays within a residual-emissions cap, without revealing its hourly electricity consumption.
  • AI-powered energy decisions: An agent shifts flexible demand toward windier hours and purchases additional hourly certificates. A carbon-aware mode uses a learned CO₂-intensity forecast to move 10% of each hour's load into cleaner hours of the same day.
  • Accountability through finance: A sustainability-linked note adjusts its coupon automatically according to the proven emissions result.

Smart contracts reconstruct public proof inputs from on-chain data, preventing a valid proof from being reused against different certificates or a cleaner intensity series.

How we built it

We built HourProof using Solidity and Foundry for smart contracts, Noir and Barretenberg's UltraHonk for zero-knowledge proofs, Python with pandas, scikit-learn and SciPy for the AI agent, and React, TypeScript, Vite, Tailwind and Recharts for the dashboard.

The system uses Energinet's open data from Energi Data Service, covering 8,759 hours of 2025. The contracts include certificate registries, a shared ledger, claims, write-once oracles, an agent commit log, a sustainability-linked note, an ML-DSA-44 verifier and two UltraHonk verifiers.

Challenges we ran into

  • Blockchain timing: Reading a nonce before the relevant block was sealed caused a signature failure. We changed the workflow to wait for the sealed block. After a Wi-Fi interruption, retries were updated to resend identical signed bytes.
  • Certificate granularity: The on-chain run uses whole-MWh certificates, while the backtest heatmap uses fractional MWh. We report these results separately rather than treating them as interchangeable.
  • Commitment timing: The public-testnet run could not establish commitments before the relevant days because it replayed a past week. Commitments remained unchanged between commit and reveal in all 7 of 7 cases, but genuine advance commitments require live operation.
  • Forecast quality: Our load forecast performed worse than repeating the previous week's load: 2.33 versus 2.09 MWh/h. We report this limitation rather than hiding it.
  • Dashboard interaction: Prerendering improved initial page delivery, but clicks before hydration caused a flaky browser test. We updated the test to wait for interactivity.

Accomplishments that we're proud of

We completed an end-to-end run on Base Sepolia with real cryptographic proofs and signatures, and an evidence bundle that anyone can inspect without a key.

The verified run recorded:

  • 80 transactions across 15 contracts, using 114,132,609 gas over 14 minutes and 53 seconds.
  • 168 hourly certificates representing 34,702 MWh, authenticated by 7 ML-DSA-44 signatures verified on-chain.
  • Private coverage verification: At least 75.00% coverage proven on-chain, with the true value of 77.47% kept private.
  • Private emissions verification: Residual emissions proven to be at most 546.1 t CO₂, with 339 public inputs reconstructed by the contract.
  • 8 of 8 deliberate cheating attempts rejected. Six were rejected by contracts before broadcast; two were rejected by the prover because the false statements could not be proven.
  • 15 independent verification checks passed, including re-reading receipts and contract state and re-verifying both proofs on-chain.

Our financial mechanism also demonstrated accountability when the target was missed. The proven residual-emissions result was at most 546.1 t against a pre-established target of 428.5 t. The note's coupon therefore increased from 5.00% to 6.00%, corresponding to 60 tUSD on 1,000 notes.

In the July–December 2025 test period, our learned CO₂-intensity forecast achieved 47% lower error than using the previous week's intensity values: 20.3 versus 38.4 g/kWh. Carbon-aware load shifting reduced location-based emissions by 2.47%, compared with 0.60% using persistence. The agent also achieved 75.7% hourly coverage, 3.97 percentage points above the comparison portfolio with the same additional MWh.

What we learned

  • Better forecasts can change the outcome: Persistence-based carbon-aware shifting reduced emissions by 0.60%, while the learned forecast achieved 2.47%. Persistence also performed worse than MWh-matching-based shifting, which achieved 1.95%.
  • Proofs must bind to the right data: A valid zero-knowledge proof is not enough unless the contract reconstructs and checks its public inputs.
  • Public-chain behavior matters: Timing, transaction failures and network interruptions must be handled explicitly, and failed attempts are part of the engineering evidence.
  • Honest evaluation builds trust: Our load forecast underperformed its baseline, and our financing KPI was missed. HourProof records these outcomes instead of presenting every experiment as a success.

What's next for HourProof

  • Run the agent in live mode on a public chain, committing plans before the day they apply to.
  • Introduce independent oracle sources and quorum-based verification, such as cross-checking a TSO-signed feed against ENTSO-E.
  • Explore a STARK-based prover for an end-to-end post-quantum approach and obtain an independent security audit.

What this does not claim

HourProof is a Base Sepolia testnet demonstration, not an accredited certification system. Issuers and registries replay published Energinet data; production data enters through an oracle role, and the declaration and settlement series are not independent sources.

The flexible-load share and additional certificate budget are scenario parameters. Although the underlying MWh values are real, the experiment does not establish real-world deployment or physically avoided emissions. The ML-DSA verifier is unaudited research code, and UltraHonk is not post-quantum.

Carbon results cover July–December 2025 and use Energinet's average location-based grid-intensity factors, not marginal emissions or a residual-mix factor. Nothing in this demonstration has been independently audited. Hourly matching remains voluntary today, while the GHG Protocol's Scope 2 revision is still in progress.

Links

Built With

Share this project:

Updates

Submission history