Blockchain Vs Safe Network.(Smart Contracts)

Thanks a lot for the reply @dirvine !

I’ve been mulling this over for a while.

So, the A and B in your example, are both MDs?
But only an agent on a node running code, could do the actual signing right? (I hope I haven’t totally missed that MDs can sign other MDs? Sorry for the confusion.)
My understanding is that an agent would need to be an app running code, which connects to safe to read and sign MDs.

A and B both being MDs and one signing the other confused me a bit.

I’m thinking like this:

There is a NAL-agent running on several nodes (an app interacting with safe libraries). A user/IOT/AI interacts with this NAL-agent, by calling some method on it, which starts the process:

  1. The local agent on this node receives input and runs it through some logic (the L part of the NAL).
  2. The output is saved to an MD, and signed by this local agent.
  3. Next step is to call out to the group (how, the network messaging?) to ask them to run the same logic with the same input, and store their output to the same MD, with their signature.
    The group knows how many signatures on same value of output is needed for quorum, and so the first node (agent) that sees that its signature is the last needed for quorum, will execute the final action, which in your example would be sending a coin. (is that really right? what gives it the permission to do this? what hinders it from sending it without the signatures?)
    I.e. 5 nodes, evaluate (1+1). Two nodes have signed the output (1+1=2), and when the third also signs the output (1+1=2), quorum is reached (because they all know the group is of 5), and this 3rd node executes the final action.

So, was this more or less what you meant?

This seems like something that would to a large extent re-use group/quorum algos already used in the network today.
And I can very much see this as an app that people can just download and run together with the safe libraries.

If there is not some error in my thinking, my main concerns would be

a) performance/latency of running more complicated apps, and needing to query data in the network,
b) the communication between the agents
c) the final execution (i.e. as mentioned above).
d) auth for this NAL-agent to use a specific publicIds data is something I would not be sure about. Receive credentials directly, or is it interacting with the authenticator?

for doing this as a smart contract app, running an arbitrary file of code, I would also consider the execution of the code to be a complicating factor, in case more than one or a few language(s) should be supported.

So, basically, I see the option do do a smart contract foundation running as an app on SAFENetwork. App developers could then code apps which hooked up to this smart contract app, and have their apps run distributed over the network.
The obstacles associated with that would for example be which node runs what source code. And do they run part of it or all of it? Or is it assumed that smart contracts are so small, that it is always the case that a node has all the source code?
Another option is to design one single app, which runs in a distributed fashion like above described.
I do have an idea for that actually. the scope of the project becomes smaller when it can be specific to a single app.

5 Likes

I totally agree with you! :wink:

What do you actually mean by Mutable Data “receiving” or “signing” some other data?

It’s not like that. I misread it at the time too :slight_smile:

There’s a much more detailed explanation of how it might go about in this topic

1 Like