Skip to content

feat: add income range mode - #455

Open
Goodness-0x wants to merge 1 commit into
ToluLabs:mainfrom
Goodness-0x:feature/income-range-band
Open

feat: add income range mode#455
Goodness-0x wants to merge 1 commit into
ToluLabs:mainfrom
Goodness-0x:feature/income-range-band

Conversation

@Goodness-0x

Copy link
Copy Markdown

Summary

Adds an inclusive income band mode to the income proof while keeping the existing threshold mode intact.

What changed

  • Added range-mode support for income proofs: min <= income <= max
  • Kept legacy threshold mode working: income >= threshold
  • Wired min/max values through the witness builder and verification URL flow
  • Validated income band inputs in the frontend and SDK
  • Documented the public input layout for the income proof circuit

Why

This enables tiered eligibility checks such as subsidy or bracket-based income gates without revealing the exact value.

Testing

  • Added focused validation for income range params
  • Verified SDK URL generation for banded income claims
  • Verified the validation suite passes

Closes #414

@drips-wave

drips-wave Bot commented Aug 31, 2026

Copy link
Copy Markdown

@Goodness-0x Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits.

You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀

Learn more about application limits

@Psalmuel01

Copy link
Copy Markdown
Collaborator

The income range mode is implemented well (threshold mode preserved, plus min/max band with income >= min and income <= max, and mode-selection tests). Two things before merge. First, changing income_proof/src/main.nr changes the circuit and therefore its verification key, but there is no fixtures/income/vk update in this PR. Once merged that would fail main's Circuit compile artifact-freshness check (the committed VK would no longer match the circuit). Please regenerate and commit the income vk/proof/public_inputs from the updated circuit. Second, CI has not run on this branch yet (no checks reported) - push so it runs and confirm everything is green, especially the circuit job. Also confirm the witness/SDK path passes min and max through end to end.

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.

Feature: income_proof range mode — prove income within a band, not just above a threshold

2 participants