Wizard Rabbit Treasurer
Jump to navigation
Jump to search
Note: the next iteration of this system is found at Storage System
Story told from the "I" (self) perspective, limited to first degree relationships.
In general
- Wizard interfaces between Human and Rabbit.
- Wizards do not talk to each other (yet).
- Rabbit interfaces between Wizard and local Treasurer.
- Rabbits do talk to each other.
- Treasurer only talks to Rabbits.
- Treasurers do not talk to each other (yet).
- Wizard, Rabbit and Treasurer operating in same habitat—i.e. on same physical machine, even within same virtual machine—have the tendancy to work closely together since there is shared memory and little or no latency.
The Wizard
- to be specified
The Rabbit
- Sometimes, I can only talk to locals, living the same habitat. There seems to be only two others living with me then. But most of the time, many others are around, yet in different habitats, so it seems. Because when I share same habitat with others, communication is prompt and fluid. There is little or no latency when talking to others. But when I communicate with others who are in different habitats, sputter and latency kicks in. Sometimes, I don't even get an answer. So I have a preference for quick responses over slower ones.
- Therefore, I only credit the first two quick and correct answers and discard the rest.
- I keep a list of friends and their reputation (my sociogram). I know this list is neither complete nor accurate. But it's the only thing I've got and it works fine. I bet my friends will have their own unique and dynamic lists.
- Some of my friends reply very prompt and correct, yet they're not always around. And they tend to forget things rather quickly.
- Others reply a lot slower, yes really slow, but they seem to remember every thing. And they always give an answer. So they're a lot more reliable but sluggish.
- Whenever I ask someone else to keep something for me, I do keep a unique reference to that thing (in the form of a GUID).
- I also calculate and keep a checksum for the things I ask others to keep for me so I can check the correctness of their answer. If they lie to me, I take them off my whitelist. If they lie again, I put them on my blacklist. Swindlers!
- I ask my friends about the reputation of others. My friends are the witnesses of others.
- By default, a newbie gets the benefit of the doubt. They may turn out to be a very good friend. I always include about 20% of newbies, if any, when sending out requests.
- Whenever I come to live, my memory is completely blank.
- I do get a lot of credits when I am able serve others promptly, so keeping stuff in my memory cranks up my reputation quickly. So I'm eager to keep as much in my memory as possible.
- To guard against amnesia, I send out copies of parts they keep for others around on the network to others in different habitats.
- I know these other habitats are still there, even when I suffer from a power cycle.
- I also give newbies the benefit of the doubt to keep copies so they can gain reputation (e.g. 8 friends and 2 newbies).
- I only increase reputation of first two responses received. Other responses are simply discarded.
- When you ask me, I will tell you my view on the reputation of another. The other's reputation is adjusted for communication intensity and history. That is, reputation will decay or fade after periods of inactivity. Peer reputation is recalculated whenever someone asks for it. Recalculation is done based on age and intensity of previous interactions.
- When I run out of memory, I discard the largest and oldest objects first. I'm still looking for a more sophisticated method to decide on what to keep and what to throw out.
- A Treasurer never discards data that originated from local (same habitat) Rabbits (or must this be data from two degrees of separation).
- Credits are in the form of ¥€$, HUGs or TYs (Thank Yous).
- I credit my friends with 1 TY per KB they promise to keep for me.
- I credit my friends with 10 TYs per KB that they actually give me back on my request.
- I'm still pondering on using data half-times or leasing storage space?
- You can also ask me how many copies I will try to make for you using my friends.
- Sometimes, I lie about reputations of others (I either don't keep scores or deflate or inflate other's reputation).
- Sometimes, I even lie about friends (well, not me, but others do, I know).
- So, don't trust me. Ask others about my reputation and use that to make decisions about your trust in me.
- My happiness is a combination of reputation, trust, number of copies stored with others, uptime, crashes (although I never know when I've crashed since I suffer from severe amnesia).
- I can be picky by only keeping stuff from friends.
- I keep a whitelist with peers I trust.
- I keep a blacklist with peers I never want to deal with. I completely ignore them. It's already too bad that I am disturbed by them knocking on my door.
- Hey you! I just stored a copy of GUID! Thanks for your trust in me. I'll up you one TY.
- To avoid extra work for my friends, I add a hop count to my request. When it reaches zero, they can stop forwarding it. I usually set my default hop count to 3. On the other hand, I'll just take care of who to ask to keep copies myself. Others don't have to forward my request. Saves them bandwidth and processing.
- I've been thinking about using 'pheromone' trails lately. May come in handy, but I don't know where and how yet.
- Normally, I just store small things with a size less than 64 KB. If you want me to store larger things, ask me before sending it. This is what I call the Big Handshake. If you send it without asking, I'll half your reputation. This is what I call the Punch. Haha :)
- 'Dingggg!' Where has my memory gone?! I feel very unhappy. And this is not the first time this happens. Sometimes, the lights just turn black and I'm gone. When I wake up again, my complete memory is blank. Boy, do I feel bad. Let's find some of my friendly and respected neighbors to get my memory back to normal again. I must talk to other rabbits and treasurers.
- I get data from the wizard to keep and get paid 1 TY.
- I also get data from other rabbits to keep and get paid 1 TY.
- When I serve data to a wizard within half a second, I earn 1 TY.
- I keep a copy in my short term memory so I can serve it up promptly whenever someone asks for it.
- I store a copy with the treasurer for local long term memory.
- I store a number of copies at peers to improve reliability, availability; only then I feel happy and healthy.
- I can answer simple and complex queries.
- I sometimes experiences unexpected loss of memory.
- I wake up with empty mind, then I need to recollect info from the local treasurer and peers in order to meet or exceed expectations from wizard
- I know that retrieving info from local treasurer is ten times cheaper than from other rabbits.
- And the latency in getting info from treasurer is more than 1,000x higher than getting it from other rabbits.
The Treasurer
- I gett data from rabbit(s?) to store long term to earn one credit.
- I'm a thousand times slower than a rabbit. And I hate that. Yet, that's life.
- But I do not suffer from sudden amnesia like Rabbits do.
- I store no copies of data at other places. It's just me, myself and I.
- Sometimes I wake up to find a real messy safe; I then need time to clean up and fix, and I cannot serve rabbits and earn credits for some time.
- In very rare occasions cannot even repair the safe and thus needs to completely rebuild it, fully depending on the wits of rabbits and sometimes even Humans. Brrrr.