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

[Design] Update data visualization #23

Open
vimwitch opened this issue Feb 9, 2023 · 0 comments
Open

[Design] Update data visualization #23

vimwitch opened this issue Feb 9, 2023 · 0 comments

Comments

@vimwitch
Copy link
Member

vimwitch commented Feb 9, 2023

Right now we show reputation as positive/negative numbers. In Unirep/Unirep#286 we'll make the data fields more generic allowing them to be used for things other than positive/negative reputation.

So for example, an application might use the first field to store a counter for user likes (64 bits), a counter for the number of post creations (64 bits), and a counter for the number of comments created (64 bits). In this example only the first data field is being used.

The empty user data field looks like this (in binary):

00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000

When a user likes something they receive the following attestation:

00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000001

When a user creates a post they receive the following attestation:

00000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000000

When these are combined (using addition) the user has a data value of

00000000000000000000000000000000000000000000000000000000000000100000000000000000000000000000000000000000000000000000000000000001

We can interpret this as two values stored in the data field, but only if we know how the application interprets the data. If we look at the above as raw numbers we see the following (respectively):

0
1
36893488147419103232
36893488147419103233

So it's important to look at this as data instead of numbers (like positive/negative reputation). I think on the home screen we can show total number of bytes that have been given in attestations?

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

No branches or pull requests

1 participant