Skip to content

implement sigmoid function precision#265

Open
AbdulSnk wants to merge 2 commits into
DigiNodes:mainfrom
AbdulSnk:dev
Open

implement sigmoid function precision#265
AbdulSnk wants to merge 2 commits into
DigiNodes:mainfrom
AbdulSnk:dev

Conversation

@AbdulSnk

Copy link
Copy Markdown
Contributor

Refines the Sybil scoring module to resolve floating-point precision issues identified during the audit.

🧠 Problem Context & Fix
The Issue: Traditional floating-point math introduced precision drift and non-deterministic behavior in the sigmoid function calculation.

The Fix: Migrated the calculations to fixed-point math to guarantee precise, deterministic scoring across all environments.

🛠️ Technical Scope & Changes
Core Logic: Replaced standard division/exponential logic with a fixed-point math implementation for the sigmoid function.

Testing: Added targeted unit tests to validate precision bounds and ensure compliance with protocol invariants.

✅ Checklist
[x] Sigmoid precision fixed using fixed-point math.

[x] Unit tests executed and passed.

[x] Protocol invariants verified; zero regressions.
Closes #220

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.

Sybil sigmoid function precision

1 participant