Introducing BitShares Object Graph

Started by bytemaster, December 24, 2014, 06:36:18 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

jsidhu

#17
groundbreaking and thought provoking!  +5%

u mistyped primtive btw.

Ethereum stuck to primitives or assembly.. And a double directed graph would cut down dev costs and ease of use on primitives.. however the million dollar question is: Is there a case you can think of where you would not want to use a graph but use primitives to solve a problem?

I guess vitalik assumes others will build on top if there is a market todo so while we give a leg up on beginners to solve problems quicker but if its a subset of problems then there is a case for primitives or assembly still.  That is when will flexibility of primitives be needed in this context where a graph wouldnt work for a layman?
Hired by blockchain | Developer
delegate: dev.sidhujag

Crossover

#16
very interesting, how fast its gonna work compared to relational databases from MS/ibm?

found answer in wiki:
"Compared with relational databases, graph databases are often faster for associative data sets[citation needed], and map more directly to the structure of object-oriented applications. They can scale more naturally to large data sets as they do not typically require expensive join operations. As they depend less on a rigid schema, they are more suitable to manage ad hoc and changing data with evolving schemas. Conversely, relational databases are typically faster at performing the same operation on large numbers of data elements.

Graph databases are a powerful tool for graph-like queries, for example computing the shortest path between two nodes in the graph. Other graph-like queries can be performed over a graph database in a natural way (for example graph's diameter computations or community detection)."

julian1

Very interesting. I noticed the object manipulation api before - assume it's the same?

blockchain_get_object <id>                                                                         
wallet_object_create <account> [user_data] [m] [owners]                                             
wallet_object_list <account> 

Ander

"The Object Graph will become the foundation for the future BitShares scripting environment. Every scripting language has a data model and this data model has a dramatic impact on the efficiency of scripting.

Ethereum has adopted a very simplistic database, a key-value store. A key-value store is a fundamental building block of all databases and is turing complete. By adopting a higher level data representation we can greatly accelerate many operations that would be expensive using a key-value store. It is like the difference between programing in assembly vs a higher level language like Java Script. We can optimize the graph database that the scripting environment runs on in ways that you would be unable to optimize a key-value store directly. In other words, Ethereum will force developers to build a graph database within their scripting environment on top of their key-value primitve. This will mean the graph database will be interpreted rather than fully optimized and compiled. "


I think we just went to Crypto 3.0. :)
[url="https://metaexchange.info"]https://metaexchange.info[/url] | Bitcoin<->Altcoin exchange | Instant | Safe | Low spreads

sumantso

#13
Quote from: Rune on December 24, 2014, 07:44:45 PM
Is this the last big addition to the protocol before 1.0? Looks really interesting and it will be great if we can advertise that we have a better data structure than ethereum.

I was posting it at BTCtalk and I was careful to avoid the better than Ethereum line (tempting as it was). I think at this point we should just focus on positives and let them draw the better than xyz conclusion (also one of the reason I want to pitch them BitBTC as something which enhances BTC, rather than trying to sell them BTS saying how they should abandon mining).

You can pitch in in this thread or create a new topic https://bitcointalk.org/index.php?topic=895637.msg9937028#msg9937028

liondani

I buy more BTS and I promise to short all active bitAssets...

PS BM know's how to make Christmas gifts !!!
[url="https://www.steempeak.com/@liondani"]https://www.steempeak.com/@liondani[/url]

Rune

Is this the last big addition to the protocol before 1.0? Looks really interesting and it will be great if we can advertise that we have a better data structure than ethereum.

fluxer555

I have no idea what's going on, but I'm excited  :D
Bitshares Wallet Recovery Service:
[url="https://bitsharestalk.org/index.php/topic,24436.0.html"]https://bitsharestalk.org/index.php/topic,24436.0.html[/url]

sumantso

Question: Why did Ethereum chose that model? There has to be some benefit.

Can you add a small section where it directly shows the difference between Bitcoin and Bitshares (like we have a comparison between Bitshares and Ethereum)?

arhag

Quote from: toast on December 24, 2014, 07:22:19 PM
It's not necessary and maybe not useful, but we're not going to add complexity to remove a feature =)

So it seems like the primitives in the BitShares Object Graph are node and edge objects which are very similar to one another (both can have arbitrary JSON associated) with the following important differences:

  • The edge object needs a source object (perhaps only restricted to node objects, TBD) and a destination object while the node object does not have those things.
  • The node object has an ACL (multisig owners and multisig updaters) defined on it while the edge object does not. These permissions are the source that propagate the ACL to the edges spreading out from the node.

Quote from: bytemaster on December 24, 2014, 07:22:46 PM
And edge cannot be a source Vertex only a destination vertex. 

If that is the case, you should fix the following statement in your blog post.
Quote
This means that you can construct an edge from a node to an edge or from an edge to an edge.

toast

Quote from: bytemaster on December 24, 2014, 07:25:09 PM

Quote from: toast on December 24, 2014, 07:23:40 PM
Quote from: bytemaster on December 24, 2014, 07:22:46 PM
And edge cannot be a source Vertex only a destination vertex.

Well right now an edge can be a source, shall we change it?

You could make validation non-Constant time Because you may have to look back source source source source owner.

There's a recursion depth limit, which I don't think we can remove because an object can be owned by another object which can be owned by another...
Do not use this post as information for making any important decisions. The only agreements I ever make are informal and non-binding. Take the same precautions as when dealing with a compromised account, scammer, sockpuppet, etc.

bytemaster


Quote from: toast on December 24, 2014, 07:23:40 PM
Quote from: bytemaster on December 24, 2014, 07:22:46 PM
And edge cannot be a source Vertex only a destination vertex.

Well right now an edge can be a source, shall we change it?

You could make validation non-Constant time Because you may have to look back source source source source owner. 
For the latest updates checkout my blog: [url="http://bytemaster.bitshares.org"]http://bytemaster.bitshares.org[/url]
Anything said on these forums does not constitute an intent to create a legal obligation or contract between myself and anyone else.   These are merely my opinions and I reserve the right to change them at any time.

toast

Quote from: bytemaster on December 24, 2014, 07:22:46 PM
And edge cannot be a source Vertex only a destination vertex.

Well right now an edge can be a source, shall we change it?
Do not use this post as information for making any important decisions. The only agreements I ever make are informal and non-binding. Take the same precautions as when dealing with a compromised account, scammer, sockpuppet, etc.

bytemaster

And edge cannot be a source Vertex only a destination vertex. 
For the latest updates checkout my blog: [url="http://bytemaster.bitshares.org"]http://bytemaster.bitshares.org[/url]
Anything said on these forums does not constitute an intent to create a legal obligation or contract between myself and anyone else.   These are merely my opinions and I reserve the right to change them at any time.

toast

Quote from: arhag on December 24, 2014, 07:19:06 PM
Whoa, edges are also objects (meaning nodes/vertices)?

Can you give me an example of why that is necessary or would be useful?

It's not necessary and maybe not useful, but we're not going to add complexity to remove a feature =)
Quote
So if I have:

(N1) --E1--> (N2) ---E2---> (N3)
        ^            |
        |-----E3-----|

First is this an acceptable "graph" in BitShares? And who "owns" edge 3? The source "node" of edge 3 is edge 2. The source node of edge 2 is node 2. So does that mean that the owners of N2 control edges 2 and 3?

Edge objects are always defined to be owned by the owner of the "from" object. So you got it right.
Do not use this post as information for making any important decisions. The only agreements I ever make are informal and non-binding. Take the same precautions as when dealing with a compromised account, scammer, sockpuppet, etc.