Repository navigation
Releases
Releases · gaussialabs/gaussia-match
gaussia-match v0.9.2
- Fixed: a result file with a duplicate object key was hashed using whichever value
JSON.parsekept (the last). Other parsers keep the first, so two nodes could hash the same file differently. NewparseJsonStrictrefuses duplicate keys at any depth, including escaped spellings like"\u0061"for"a", and names the path. Every CLI command that reads JSON uses it (exit 2). - Fixed: CLI JSON files saved with a UTF-8 byte order mark were refused as invalid JSON; the BOM is now skipped.
- SPEC.md canonical JSON rule 2: duplicate keys are an error.
- README: the job outcome example now shows
outliers, the spec links are fixed, and the limits say plainly that Gaussia is at concept stage and that the coordinator service is not part of this repo.
gaussia-match v0.9.1
- Security: closes the tiebreak copy gap left to the operator in v0.3.0. New
MatchJob.publicSnapshot()returns the state and event log with every revealed result hash set tonullwhile the job is open, so a coordinator serving it can't leak the pair's hashes to the third node before it commits. Commitments stay visible. After the job closes nothing is hidden. TypesPublicJobSnapshot,PublicSlot,PublicJobEvent.
gaussia-match v0.9.0
- Solidity reference library
contracts/src/GaussiaMatch.sol:commitHash,verifyReveal,nodeScore,voteCommitHash(reverts on a choice outside 1..3) andcandidateHash(reverts unless finders are sorted, unique and non-empty). Not deployed; shipped in the package for a future contract to import. scripts/gen-sol-vectors.mjsgeneratescontracts/test/Vectors.t.sol, one Foundry test per JSON vector (15), plus hand-written fuzz tests.pnpm test:solruns them; a new CI job checks the generated file is current and runsforge test.- SPEC.md: "Solidity reference".
gaussia-match v0.8.0
- JSON test vectors in
vectors/for canonical JSON, result commitments (with ABI encoding), node assignment (full rankings), sealed votes and sealed candidates. Shipped in the package.scripts/gen-vectors.mjsregenerates them; CI fails if the committed files drift. scripts/check-canonical.py: an independent Python implementation of canonical JSON v0; all 12 canonical vectors match. Runs in CI.- Property tests (fast-check): a result commitment changes when any field changes, a vote commitment changes with the choice, a candidate hash changes when any quantity moves by one fixed-point unit, canonical JSON is idempotent and key-order independent.
- SPEC.md: "Test vectors".
gaussia-match v0.7.0
- Advisory tolerance compare:
compareSignalchecks tic, period, epoch folded by whole periods, and relative depth against tolerances the caller passes (no defaults).compareSignalspairs two signal lists and reports leftovers.extractSignalsreads three result shapes. - CLI
gaussia-match compare <a.json> <b.json> --period-tol --epoch-tol --depth-tol, which also prints whether the result hashes are equal. Exit 1 when a signal has no partner. examples/result.node-c.json: the same signal with slightly different numbers.- SPEC.md: "Tolerance compare (advisory)". Equal result hashes stay the only match rule.
gaussia-match v0.6.0
- Sealed candidates:
candidateHash=keccak256(abi.encode(uint64 tic, uint256 period, uint256 epoch, uint256 depth, address[] finders)). Period and epoch in days (epoch in BTJD), depth in ppm, all fixed point × 10^9, rounded half to even. Finders sorted by address, duplicates refused. Checked against a hand-built ABI encoding in the tests and against Foundrycastby hand. verifyCandidate,encodeCandidate,toFixed9/fromFixed9,normalizeFinders.- CLI
gaussia-match candidate, with--sealto check a reveal. - Fixed the package description.
- SPEC.md: "Sealed candidates".
gaussia-match v0.5.0
- Sealed review votes:
voteCommitHash=keccak256(abi.encode(VOTE_DOMAIN, signalId, uint8 choice, voter, salt))with choicestransit(1),not_transit(2),unsure(3) and a domain tagkeccak256("gaussia.vote.v0").makeVoteCommit,verifyVoteReveal. VoteRound: commit phase, then reveals only after commits close (early_reveal), one commitment per voter, optional allow-list, reveals checked against the commitment (bad_reveal), tally only after reveals close.tally({ threshold }):passed,rejectedorundecided. The threshold has no default because Gaussia has not fixed it.- CLI
gaussia-match vote: make a vote commitment, or check a reveal with--commit. - SPEC.md: "Sealed votes".
gaussia-match v0.4.0
- Deterministic node assignment
assignNodes: per-wallet scorekeccak256(abi.encode(bytes32 seed, bytes32 jobId, address wallet)), lowest scores selected. Independent of list order and address case. Duplicate wallets count once and are reported;excludepicks a tiebreak or replacement node from the rest of the ranking.nodeScorefor a single wallet. - CLI
gaussia-match assign --seed --job --nodes <file> [--count] [--exclude].... The nodes file is a JSON array of wallets or of objects with awalletfield. examples/nodes.json.- SPEC.md: "Node assignment", including what a seed must and can't guarantee.
gaussia-match v0.3.0
- Third-node tiebreak. A mismatch no longer closes the job: it moves to
needs_tiebreak,assignTiebreak(wallet, now)opens round 2 for a wallet that has not held a slot, and the third node's hash decides by 2-of-3 majority. The pair node in the minority is listed inoutliers. - New terminal status
no_majoritywhen all three hashes differ (nobody paid, nobody flagged). Themismatchstatus is gone; amismatchevent records the two hashes instead. - Round 2 has the same deadlines, no-show replacement and expiry as round 1.
- SPEC.md: "Third-node tiebreak", including why the pair's hashes must be withheld from the third node.
gaussia-match v0.2.0
- Job state machine
MatchJobfor one job and two assigned wallets: both commit before either can reveal (early_revealrefused), one commitment per wallet (already_committed), copied commitments refused (duplicate_commit), reveals checked against the commitment (bad_reveal). - Deadlines from a caller-supplied clock: a commit no-show opens the slot for a blind replacement (
needs_replacement,replace); a reveal no-show expires the job. No-shows are flagged in the outcome. - Outcomes
verified(with the agreed hash and the wallets to pay) andmismatch. Event log for audit and replay. - SPEC.md: "Job state machine".