Help wanted: build a visual QF allocation tool

Check out this visual of how the QF matching amount is calculated from Vitaliks blog.

Can anyone build a similar tool to help me visualize the matching distribution calculations of the new Gitcoin Grants? Eg for any round created with round manager I want to be able to visualize the way the matching amount was calculated in the above visualization format ^^

I have budget for this build out.

Related info:

3 Likes

@owocki So a set of figures like this, but with better styling and interactivity as part of dashboard/similarity finding tool? I was just working on finding similarities between donors in Beta round data so I could likely get prototype up and running without excessive effort if python+streamlit is acceptable stack here.

Bonus is that I could extract and re-package figure drawing module for other analysts to re-use (once I get labels to display nicely).

Here is how I would imagine end result, one streamlit dashboard page per round:

  • Searchbar to select grants/donors
  • Pyvis network graph, where each dot radius is sum of donations to a grant
  • Grid of figures, like one attached that display matching power each contributor added to grant.

Interactions:

  1. typing in searchbar would let you search with autocompletion for grant/donor address(+maybe ENS search for all grants/interesting donors).
  2. Clicking enter would add item to highlighted. Highlighted items would display with color on the graph and on the matching power figures.
  3. At the very bottom there could be a table displaying aggregated contributions for a subset of highlighted donors/grants.

Should be doable, as long as you don’t YOLO it trying to open all figures for OSS round at once.

2 Likes

yeah basically.

yeah, itll be interesting to see how performance is managed here. maybe we start by making charts for a grant => n grants => all grants in a round (eg start small and scale up). open to recommendations of performance management schemes.

2 Likes

Gotcha, if you are interested I can hack on weekend to make a demo dashboard that shows grants and small groups grants side by side, will illuminate performance bottlnecks. But so far only problematic thing is building mega-large graph.

Just one random observation, after drawing a few of those “square” graphs, I reach conclusion I could save a lot of space and make it more presentable by stuffing squares together - which would result in something like a treemap as shown. This holds exactly the same information as Vitalik style diagonal graph, or at least I think it does, only packed more nicely.

For a single grant, treemap can show how much voting power each voter contributed to final outcome, and for all grants it could show matching outcomes in hierarchical manner comparing not only grants, but also sizes of dispersed matching pools for different rounds.

2 Likes

happy to see a demo!

i probably prefer the vitalik style diagonal graph for now. just so that i can go back to him and present the info to him in the way he perceives it already

1 Like

image

Taking a form where folks could find those diagrams interesting, plan is to chuck them onto dashboard tomorrow. On left figure edge of square represents contributions to grant (actual money donated), on the right figure edge is isqrt(contributions) like Gitcoin algorithm.

For most grants, this shows what some folks love to say re:QF in that voting power distribution becomes a bit more “democratic” by dampening power of whales. This is my main motivation to build here, trying to figure out and verify how much influence on end result a typical QF donor actually has. I cannot say this confidently yet, but I feel like whales still stand out a lot, thus dominating how matching money is assigned.

Performance is very reasonable so far, pairs of pyplot figures for all pre-existing grants can be built without a problem. Worst case grant takes ~7s, typical about ~1s, most grants are way closer to 1-2s. Worst offenders can be pre-built and pulled into streamlit cache so dashboard doesn’t need to built figures, only load, but this is worry for later.

1 Like

https://distributeddoge-streamdash-dash-88rk4u.streamlit.app/ WIP, no zoom yet, but at least it is clickable. QF in action.

2 Likes

really strong result! glad to see it in action.

is there any way for me to hover/click on a square and see whom the contribution is from/to, how much it is, and how much proportionally of the matching pool it allocated?

1 Like

This app has gone to sleep due to inactivity. Would you like to wake it back up?

Just rewoke up the app.

I may write a blog post on this soon+ send to Glen/Vitalik

1 Like

This is really cool! I feel like I didn’t know I wanted this visualization until I saw it and now I’m so glad to have it for all future rounds. Thanks for building

I really want to be able to view grants by title and round instead of id. I also wonder if I could have a leaderboard list of who the donors are next to the graph.

I also really like the lines you have present in the first version of the graph which clearly shows the matching areas and find myself missing them in the future versions. If this is a personal preference so be it lol

Also, for the future, it’s really interesting to think about how this image extends for other QF implementations. When we implement pairwise QF (or collusion-resistant) or bring back some sort of ‘trust score’ multiplier then the matching amount/ weight could somehow be additionally represented by making this a 3d graph and having the z-axis represent the passport/trust score times some collusion factor. This is a bit of spitballing and I’m not sure if my understandings of the right way to visually represent QF are entirely correct here.

Anyway, I really hope work on this project continues. Great work! Would love to chat about doing more data stuff for gitcoin with you @DistributedDoge

1 Like

Thanks for thoughtful feedback, it is really helpful and motivating to push project forward. I must have missed earlier messages from Kevin, but anyways if anyone really wants me to see something, it feels safer to mention or reply to one of my posts than just write in thread.

  • The app should be live again. I can poke it from time to time to make sure it stays that way, but please don’t get too attached: https://distributeddoge-streamdash-dash-88rk4u.streamlit.app/

  • I really like the leaderboard idea, can sit down and try to incorporate this and your other feedback by end of week, time permitting.

  • Speaking of styling of a figure, I can add option to do so, but it would be easier for me to just share figure drawing code so that you can get it drawn exactly according to your wishes and try different algos than sqrt. Also end of week.

  • One word of warning (should add to dashboard), those figures are computed from all votes while actual matching in round is only calculated using votes that are eligible. So yeah at the moment you can look who voted and how but keep in mind that not all of those votes you see are valid for matching.

  • I hope that once results of the round are ratified Gitcoin would release a dataset or a listing of all votes that counted towards matching. While getting “all votes” is easy, “eligible” votes are impossible to reproduce without Gitcoin help because I have no way of knowing which votes were squelched as part of Sybil-defence or maybe some eligiblity check could be missaplied.

2 Likes

Hey @DistributedDoge just wanted to make sure you saw this, since I didnt ping you last time.

After this is done, I think I can share it more widely.

maybe worth poking around in the gitcoin discord (try the allo-builders channel) and or [Discussion & Proposal] Ratify the Results of Gitcoin’s Beta Round and Formally Request the Community Multisig Holders to Payout Matching Allocations - đŸŒ± Grants - Gitcoin Governance to get that? hopefully one day the info will be available via the API.

2 Likes

I likely won’t get full vote data but Gitcoin shares next best thing which is “matching power” for each grant. ATM even Gitcoin doesn’t know what final sybil-purged round results are so I will just work with what I have.

On my side, need one extra evening to deal with QF math so that I can plop annotations on dashboard. “How much of matching pool is attributed to one vote” is suprisingly tricky but I can already match most of test cases for Gitcoin-style QF.

Two interesting scenarios are - “excess” votes cast after project hits matching cap. No matter how much extra money I pour in I won’t increase match so maybe winning move is not to play wait for next round?

Worthless votes. Quirk of QF as implemented by Gitcoin/Vitalik (which differs from WTFisQF site) is that if a project attracts only single contribution it will get 0 matching no matter the contribution size. BUT once a project gets 2 contributions or more, suddenly the first contribution is counted in full.

For simplicity, I’d say lets treat these as corner cases (for now). Unless there is a very simple workaround.

Excited for this.!

@DistributedDoge wanna shill ur project there https://twitter.com/owocki/status/1674820183406567424

would be cool to get the GG18 data visualized through this tool :slight_smile:

id definitely tweet it if we had that

similar to https://twitter.com/lensterxyz/status/1692963337330729288