Fractalide:
A Cryptocontract Marketplace
Summary
- Terminology
- The Problem
- How marketplace entities structure themselves.
- What is Fractalide?
- How Fractalide maps to a healthy marketplace
- Conclusion
- Sources
Terminology
- A "contract" means an agreement between two or more parties or software components.
- "cryptocontract" disambiguates
- I might use the words "component" or "node" interchangeably
The Problem
Ethereum Classic is currently a speculative currency.
The Solution
Understand how crypto{currency, contract} users organize themselves, then build a set of development tools that compliment their workflow and provide a means for them to sell their work.
This will assist in evolving from a speculative currency to utilitarian currency
How marketplace entities structure themselves.
Supply and demand isn't so interesting
What's more interesting is how each organization structures itself.
- Frederic Laloux
Laloux Culture Model
Every level up unlocks an order of magnitude in power
Red organizations
- Red organizations found today: street gangs, mafia, mercenary armies etc
- Guiding metaphor: Wolf pack
- Primary characteristics: Power, Fear
- Magic / Tribal era
- 10,000 years ago
- Useful in situations of chaos
- Alpha leader instills fear.
- Unstable system, with younger stronger people taking out the alpha leader
- Red concepts used:
- Command authority
- Division of labour
Red organizations
Reason for evolution
Instability of fear based power structures could not accomplish long term projects
Amber organizations
- Amber organizations found today: most government agencies, public school systems, Catholic Church, and Armies
- Guiding metaphor: Army
- Primary characteristics: Hierarchy, Stability, Control
- Cast system
- Traditional / Agrarian era
- 5000 years ago
- Amber concepts used:
- Formal hierarchy
- Replicable processes
- Long term outlook
Amber organizations
Reason for evolution
Entrenched Amber organizations were unable to adapt to changing conditions
Orange organizations
- Orange organizations found today: Multinational organizations, Wall Street
- Guiding metaphor: Machine
- Primary characteristics: Competition, Profit, Objectives
- 200 years ago
- Scientific / Industrial era
- Pyramid structure remains
- "Command and Control" becomes "Predict and Control"
- Orange concepts used:
- Innovation
- Accountability
- Meritocracy
Orange organizations
People feel the profit motive is not fulfilling enough and often become disengaged with the organization's view of them as cogs in a machine
Reason for evolution
2013 Gallup poll showed some 70% were disengaged
People are seeking more meaning in their work
Green organizations
- Green organizations found today: Southwest Airlines, Ben & Jerry’s, Zappos
- Guiding metaphor: Family
- Primary characteristics: Delight customers, Shared values, Engagement
- "Culture eats strategy for lunch"
- Post Modern / Information era
- Post WW2
- Resembles a family, with the CEO as the parental figure
- Green concepts invented:
- Culture over strategy
- Empowerment
- Stakeholder balance
Green organizations
Green hits it's limit when consensus building results in overly slow decision making
Reason for evolution
The hierarchical structures still existing in Green begin to conflict with peoples' desires to have greater autonomy
Teal Organizations
- Teal organizations found today: Patagonia, Morningstar, Buurtzorg
- Guiding metaphor: Living system
- Primary characteristics: Anti-fragile organization, Higher purpose, Distributed decision making (using the advice process)
- Consciously operate as complex adaptive systems with distributed authority
- Teal concepts used:
- Wholeness
- Self-management
- Evolutionary purpose
Teal Organizations
- Autonomous teams
- No bosses or organization chart
- No job descriptions or job titles
- Distributed decision-making
- Set own salaries
- Advanced self tracking tools
- Open Information flow
- No unilateral dismissals
- Conflict resolution
Teal Organizations
- Bank in your pocket
- Fast, cheap, convenient, programmable international tranfers
- No need for business registration or company bank account
- Immutable contracts that uphold business logic.
Cryptocurrency holders (especially the programmers) have the right conditions to form into a sprawling Teal community
Cryptocurrency can push Teal further
Conway's Law
organizations which design systems ... are constrained to produce designs which are copies of the communication structures of these organizations.
— M. Conway
If the parts of an organization (e.g., teams, departments, or subdivisions) do not closely reflect the essential parts of the product, or if the relationship between organizations do not reflect the relationships between product parts, then the project will be in trouble... Therefore: Make sure the organization is compatible with the product architecture.
— James O. Coplien and Neil B. Harrison
Therefore: Make sure the organization is compatible with the product architecture.
Therefore: Make sure the product architecture is compatible with a decentralized (Teal) community.
What is
?
Fractal
An object whose parts, at infinitely many levels of magnification, appear geometrically similar to the whole.
IDE
Integrated Development Environment
The NoFlo IDE
Flow-based Programing
flow-based programming (FBP) is a programming paradigm that defines applications as networks of "black box" processes, which exchange data across predefined connections by message passing, where the connections are specified externally to the processes. These black box processes can be reconnected endlessly to form different applications without having to be changed internally.
- Wikipedia
Flow-based Programing
Flow-based Programming is a particular form of dataflow programming based on bounded buffers, information packets with defined lifetimes, named ports, and separate definition of connections.
- Wikipedia
This is an "Agent"
It does one thing, and does it well
Read File
It reads a file's contents
Classical UNIX philosophy
This is a named port
path
Read File
A port receives data via a bounded buffer
#[derive(Clone, Debug)]
pub struct FsPath(pub String);
We call it an "Edge"
path
Read File
#[derive(Clone, Debug)]
pub struct FsPath(pub String);
text
error
#[derive(Clone, Debug)]
pub struct FsFileError (pub String);
#[derive(Debug, Clone)]
pub enum FsFileDesc {
Start(String),
Text(String),
End(String),
}
#[macro_use]
extern crate rustfbp;
use std::fs::File;
use std::io::BufReader;
use std::io::BufRead;
agent! {
input(path: FsPath),
output(text: FsFileDesc, error: FsFileError),
fn run(&mut self) -> Result<Signal> {
// Get the path
let mut path = self.input.path.recv()?.0;
let file = match File::open(&path) {
Ok(file) => { file },
Err(_) => {
let _ = self.output.error.send(FsFileError(path));
return Ok(End);
}
};
// Send start
self.output.text.send(FsFileDesc::Start(path.clone()))?;
// Send lines
let file = BufReader::new(&file);
for line in file.lines() {
self.output.text.send(FsFileDesc::Text(line?))?;
}
// Send stop
self.output.text.send(FsFileDesc::End(path))?;
Ok(End)
}
}
Contents of the "Read File" agent
All logic is kept in one place and not spread out all over the code base.
Making the code easier to reason about.
path
Read File
text
#[derive(Debug, Clone)]
pub enum FsFileDesc {
Start(String),
Text(String),
End(String),
}
Print File
input
This is a contract between two nodes
Data description can be arbitrarily deep scaling up to describe complex interactions between organizations, not only simple inter-node descriptions
path
Read File
text
Print File
input
path
Print File
This is a Subgraph
A Subgraph hides implementation details and allows for powers of abstraction
Supports arbitrarily deep nesting
path
Read File
text
Print File
input
path
Subgraph
path
Read File
Agent
Allowing us to use familiar Graph Theory terminology "Nodes and Edges"
Node =
#[derive(Clone, Debug)]
pub struct FsPath(pub String);
Edge =
A Subgraph contains other Subgraphs and/or Agents
An Agent contains code
An Edge passes data
Flow-based Programming is reusable in nature
But each node has a life cycle and it becomes hard to manage the life cycles of a thousand nodes
We need to make every node reproducible!
Reproducibility is essential for the Scientific Method
Every dependency is deterministic so it's a pleasure to reason about
{ agent, edges, mods, pkgs }:
agent {
src = ./.;
edges = with edges.rs; [ FsPath FsFileDesc FsFileError ];
mods = with mods.rs; [ rustfbp ];
osdeps = with pkgs; [ openssl ];
}
We use the Nix Package manager.
We now have a Reproducible, Reusable and Composable system.
Many consider this the Holy Grail in the software world.
How Fractalide maps to a healthy marketplace?
Domain Specialists
- Scientists
- Mathematicians
- Engineers
- Biologists
- Non-technical users
Programmers
Read File
Print File
Subgraphs
Snap subgraphs together like lego. They don't need programming knowledge
Read File
Agent
#[macro_use]
extern crate rustfbp;
use std::fs::File;
use std::io::BufReader;
use std::io::BufRead;
agent! {
input(path: FsPath),
output(text: FsFileDesc, error: FsFileError),
fn run(&mut self) -> Result<Signal> {
// Get the path
let mut path = self.input.path.recv()?.0;
let file = match File::open(&path) {
Ok(file) => { file },
Err(_) => {
let _ = self.output.error.send(FsFileError(path));
return Ok(End);
}
};
// Send start
self.output.text.send(FsFileDesc::Start(path.clone()))?;
// Send lines
let file = BufReader::new(&file);
for line in file.lines() {
self.output.text.send(FsFileDesc::Text(line?))?;
}
// Send stop
self.output.text.send(FsFileDesc::End(path))?;
Ok(End)
}
}
Agent Source Code
#[macro_use]
extern crate rustfbp;
use std::fs::File;
use std::io::BufReader;
use std::io::BufRead;
agent! {
input(path: FsPath),
output(text: FsFileDesc, error: FsFileError),
fn run(&mut self) -> Result<Signal> {
// Get the path
let mut path = self.input.path.recv()?.0;
let file = match File::open(&path) {
Ok(file) => { file },
Err(_) => {
let _ = self.output.error.send(FsFileError(path));
return Ok(End);
}
};
// Send start
self.output.text.send(FsFileDesc::Start(path.clone()))?;
// Send lines
let file = BufReader::new(&file);
for line in file.lines() {
self.output.text.send(FsFileDesc::Text(line?))?;
}
// Send stop
self.output.text.send(FsFileDesc::End(path))?;
Ok(End)
}
}
Free and Open Source
OR
Time out Free and Open Source
#[macro_use]
extern crate rustfbp;
use std::fs::File;
use std::io::BufReader;
use std::io::BufRead;
agent! {
input(path: FsPath),
output(text: FsFileDesc, error: FsFileError),
fn run(&mut self) -> Result<Signal> {
// Get the path
let mut path = self.input.path.recv()?.0;
let file = match File::open(&path) {
Ok(file) => { file },
Err(_) => {
let _ = self.output.error.send(FsFileError(path));
return Ok(End);
}
};
// Send start
self.output.text.send(FsFileDesc::Start(path.clone()))?;
// Send lines
let file = BufReader::new(&file);
for line in file.lines() {
self.output.text.send(FsFileDesc::Text(line?))?;
}
// Send stop
self.output.text.send(FsFileDesc::End(path))?;
Ok(End)
}
}
Agent Source Code
May publish their source code
May choose to adopt a 2~3 year timeout license. Such that the code automatically publishes after you've made a profit
Programmers
Read File
Bob
Print File
Alice
Read File
Print File
Carol
Non-programmer Domain Specialists
End User
Print File
Dave
Making it easy to use any currency and associated applications
n+1
n+1
IoT
Conclusion
- Described different structures of organizations.
- Which type of organization Fractalide is suitable for.
- Described the modular nature of Fractalide.
- Illustrated how first principles engineering allows for reusable, reproducible and composable applications.
- Described how Fractalide's marketplace works.
Sources
- Reinventing Organizations - Frederic Laloux
- Flow-Based Programming, 2nd Edition: A New Approach to Application Development - J.P. Morrison
- http://www.github.com/fractalide/fractalide
- http://fractalide.com/pdf/fractalideCOP.pdf
- Wikipedia - Conway's law, Flow-based Programming
A Cryptocontract Marketplace
By stewart mackenzie
A Cryptocontract Marketplace
- 1,614