Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

People's choice podcast awards allow multiple votes from the same person #2

Open
albaropereyra22 opened this issue Mar 18, 2024 · 9 comments
Labels
enhancement New feature or request

Comments

@albaropereyra22
Copy link

Perhaps pushing this number over to a 64 bit version will make the voting framework useful in a real world scenario like the People's choice podcast awards. I wonder what they are using.

@S-Ptr S-Ptr added the enhancement New feature or request label Mar 27, 2024
@S-Ptr
Copy link
Owner

S-Ptr commented Mar 27, 2024

For clarification, you mean to ask if I can enable multiple choice votes? If so, I can do that.

@albaropereyra22
Copy link
Author

albaropereyra22 commented Mar 27, 2024 via email

@S-Ptr
Copy link
Owner

S-Ptr commented Mar 28, 2024

Ah, I see. In short, I could, but that would make the system much less performant.

I would first have to double the polynomial modulus degree, making its value 8192. This would enable me to bring the ciphertext modulus to a higher bit length, and then also raise the value of the plaintext modulus so as to not compromise the noise budget too much.

For example, I could use a 60bit prime for the plaintext modulus and the SEAL recommended value for the ciphertext modulus.With these parameters, I could have 1.1 quintillion votes per candidate (1.152.921.504.606.830.593) and an initial noise budget of 105, which means 2104-1 homomorphic additions with the ciphertext, at worst. These are, indeed, outrageous numbers.

The bad news is that the ciphertext size per vote would go up from around 86.4 kilobytes(kB) to 422.2kB. If we use the US voting population in 2020 of 168.31 million, we would need around 66.18 terabytes (TB) to keep all the data - too big for most people to go over and verify by themselves. As for the processing speed, it also goes down from around 1500 votes/min per core on my machine, to around 300 votes/min.

With the parameters I currently use, multiple choice votes shouldn't be a problem, as the number of votes per candidate, and the worst case estimate for operations performed, don't differ much in value. That being said, the aim is to have a system where one user has the right to vote once

@albaropereyra22
Copy link
Author

albaropereyra22 commented Apr 2, 2024 via email

@S-Ptr
Copy link
Owner

S-Ptr commented Apr 10, 2024

The main reason I don't do it is because I don't need to. No poll will get over 2 billion votes. Not yet at least. Also, I'm not sure how well nginx would work in this case, considering Drogon runs on its own HTTP server. I could make some sort of partitioning to increase throughput, but there is also the issue of storage, which is a huge bottleneck in homomorphic encryption schemes, and I try to keep it down as much as I can.

By the time 1.1 quintillion voters are a reality, I expect computers to make the handling of 433kB-sized votes a trivial thing, and then we can raise the parameters to support those values without any meaningful performance loss. By that time, I also expect the world of cryptography to look vastly different as well, making this project an antediluvian relic of a bygone era.

@albaropereyra22
Copy link
Author

albaropereyra22 commented Apr 11, 2024 via email

@S-Ptr
Copy link
Owner

S-Ptr commented Apr 15, 2024

Lucky. The cheapest 1TB MicroSD cards over here are $100. The usual price is upwards of 200 bucks. Send the amazon link.

@albaropereyra22
Copy link
Author

albaropereyra22 commented Apr 19, 2024 via email

@albaropereyra22
Copy link
Author

albaropereyra22 commented Apr 19, 2024 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants