The Escape From Flatland

A presentation at Empex MTN in May 2022 in Salt Lake City, UT, USA by Brooklyn Zelenka

Slide 1

Slide 1

The Escape From Flatland !⚗ Building the Languages of the Future, Today #$

Slide 2

Slide 2

Slide 3

Slide 3

Language is an instrument of human reason, and not merely a medium for the expression of thought – George Boole

Slide 4

Slide 4

Slide 5

Slide 5

Daring ideas are like chess pieces moved forward. They may be beaten, but they may start a winning game. – Goethe

Slide 6

Slide 6

Brooklyn Zelenka @expede

Slide 7

Slide 7

Brooklyn Zelenka @expede • CTO at Fission (https://fission.codes) • Far edge apps (“post-serverless”) • Goal: make back-ends and DevOps obsolete

Slide 8

Slide 8

Brooklyn Zelenka @expede • CTO at Fission (https://fission.codes) • Far edge apps (“post-serverless”) • Goal: make back-ends and DevOps obsolete • PLT, VMs, DSys

Slide 9

Slide 9

Brooklyn Zelenka @expede • CTO at Fission (https://fission.codes) • Far edge apps (“post-serverless”) • Goal: make back-ends and DevOps obsolete • PLT, VMs, DSys • Original author of Witchcraft, Algae, Exceptional, etc

Slide 10

Slide 10

Brooklyn Zelenka @expede • CTO at Fission (https://fission.codes) • Far edge apps (“post-serverless”) • Goal: make back-ends and DevOps obsolete • PLT, VMs, DSys • Original author of Witchcraft, Algae, Exceptional, etc • Standards: UCAN (editor), EIPs, FVM, Multiformats, others

Slide 11

Slide 11

Brooklyn Zelenka @expede • CTO at Fission (https://fission.codes) • Far edge apps (“post-serverless”) • Goal: make back-ends and DevOps obsolete • PLT, VMs, DSys • Original author of Witchcraft, Algae, Exceptional, etc • Standards: UCAN (editor), EIPs, FVM, Multiformats, others • Founded VanFP, VanBEAM, DSys Reading Group (join us!)

Slide 12

Slide 12

Brooklyn Zelenka @expede • CTO at Fission (https://fission.codes) • Far edge apps (“post-serverless”) • Goal: make back-ends and DevOps obsolete • PLT, VMs, DSys • Original author of Witchcraft, Algae, Exceptional, etc • Standards: UCAN (editor), EIPs, FVM, Multiformats, others • Founded VanFP, VanBEAM, DSys Reading Group (join us!) https://lu.ma/distributed-systems

Slide 13

Slide 13

Meta & Two Keynotes, Both Alike in Dignity %

Slide 14

Slide 14

Meta & Two Keynotes, Both Alike in Dignity %

Slide 15

Slide 15

Meta & Two Keynotes, Both Alike in Dignity %

Slide 16

Slide 16

Meta & Two Keynotes, Both Alike in Dignity % Part I: Empex MTN ’ Part II: CodeBEAM EU (

Slide 17

Slide 17

Meta & Growth Mindset

Slide 18

Slide 18

Meta & Growth Mindset We ❤ Elixir

Slide 19

Slide 19

Meta & Growth Mindset We ❤ Elixir It’s important to think critically about our tools

Slide 20

Slide 20

Meta & Growth Mindset We ❤ Elixir It’s important to think critically about our tools We need to hold Elixir to the highest standard

Slide 21

Slide 21

Meta & Growth Mindset We ❤ Elixir It’s important to think critically about our tools We need to hold Elixir to the highest standard Let’s ask uncomfortable questions

Slide 22

Slide 22

Meta & Growth Mindset We ❤ Elixir It’s important to think critically about our tools We need to hold Elixir to the highest standard Let’s ask uncomfortable questions Growth requires dissatisfaction & inspiration

Slide 23

Slide 23

Meta & Growth Mindset We ❤ Elixir It’s important to think critically about our tools We need to hold Elixir to the highest standard Let’s ask uncomfortable questions Growth requires dissatisfaction & inspiration

Slide 24

Slide 24

The Children of Elixir Manifesto ☎→⚗→X

Slide 25

Slide 25

The Children of Elixir Manifesto ☎→⚗→X

Slide 26

Slide 26

Manifesto ☎→⚗→ My Obsession

Slide 27

Slide 27

Manifesto ☎→⚗→ My Obsession

Slide 28

Slide 28

Manifesto ☎→⚗→ My Obsession The BEAM does so much right +

Slide 29

Slide 29

Manifesto ☎→⚗→ My Obsession The BEAM does so much right + In many ways, we’re actually ahead of the industry

Slide 30

Slide 30

Manifesto ☎→⚗→ My Obsession The BEAM does so much right + In many ways, we’re actually ahead of the industry (mainly using ideas from the late 80s ,)

Slide 31

Slide 31

Manifesto ☎→⚗→ My Obsession The BEAM does so much right + In many ways, we’re actually ahead of the industry (mainly using ideas from the late 80s ,) …but our lead won’t last…

Slide 32

Slide 32

Manifesto ☎→⚗→ My Obsession The BEAM does so much right + In many ways, we’re actually ahead of the industry (mainly using ideas from the late 80s ,) …but our lead won’t last… Where do we go from here?

Slide 33

Slide 33

Manifesto ☎→⚗→ Our Code is Too “Flat”

Slide 34

Slide 34

Manifesto ☎→⚗→ Our Code is Too “Flat” Code in 2022 is needlessly difficult & complex!

Slide 35

Slide 35

Manifesto ☎→⚗→ Our Code is Too “Flat” Code in 2022 is needlessly difficult & complex!

Slide 36

Slide 36

Manifesto ☎→⚗→ Our Code is Too “Flat” Code in 2022 is needlessly difficult & complex! If software is going to continue eating the world, it needs to be faster, more flexible, clearer, correct, and teachable

Slide 37

Slide 37

Manifesto ☎→⚗→ Our Code is Too “Flat” Code in 2022 is needlessly difficult & complex! If software is going to continue eating the world, it needs to be faster, more flexible, clearer, correct, and teachable

Slide 38

Slide 38

Manifesto ☎→⚗→ Our Code is Too “Flat” Code in 2022 is needlessly difficult & complex! If software is going to continue eating the world, it needs to be faster, more flexible, clearer, correct, and teachable How do we build more structure from our existing parts? How do we add dimension?

Slide 39

Slide 39

Manifesto ☎→⚗→ Our Code is Too “Flat” Code in 2022 is needlessly difficult & complex! If software is going to continue eating the world, it needs to be faster, more flexible, clearer, correct, and teachable How do we build more structure from our existing parts? How do we add dimension?

Slide 40

Slide 40

Manifesto ☎→⚗→ Our Code is Too “Flat” Code in 2022 is needlessly difficult & complex! If software is going to continue eating the world, it needs to be faster, more flexible, clearer, correct, and teachable How do we build more structure from our existing parts? How do we add dimension?

Slide 41

Slide 41

Manifesto ☎→⚗→ Our Code is Too “Flat” Code in 2022 is needlessly difficult & complex! If software is going to continue eating the world, it needs to be faster, more flexible, clearer, correct, and teachable How do we build more structure from our existing parts? How do we add dimension?

Slide 42

Slide 42

Manifesto ☎→⚗→ Our Code is Too “Flat” Code in 2022 is needlessly difficult & complex! If software is going to continue eating the world, it needs to be faster, more flexible, clearer, correct, and teachable How do we build more structure from our existing parts? How do we add dimension?

Slide 43

Slide 43

Manifesto ☎→⚗→ Our Code is Too “Flat” Code in 2022 is needlessly difficult & complex! If software is going to continue eating the world, it needs to be faster, more flexible, clearer, correct, and teachable How do we build more structure from our existing parts? How do we add dimension?

Slide 44

Slide 44

Manifesto ☎→⚗→ The Pit of Success

Slide 45

Slide 45

Manifesto ☎→⚗→ The Pit of Success In stark contrast to a summit, a peak, or a journey across a desert to find victory through many trials and surprises, we want [devs] to simply fall into winning practices by using our platform and frameworks. To the extent that we make it easy to get into trouble we fail. – Rico Mariani, Microsoft Research MindSwap 2003

Slide 46

Slide 46

Manifesto ☎→⚗→ Tools For Thought

Slide 47

Slide 47

Manifesto ☎→⚗→ Tools For Thought

Slide 48

Slide 48

Manifesto ☎→⚗→ Tools For Thought • We have better mental tools than our ancestors • Abstraction appears 50k-100k years ago • Arabic numerals > roman numerals • Metric conversions > Imperial • 24-hours & 360-degrees have nice divisiors

Slide 49

Slide 49

Manifesto ☎→⚗→ Tools For Thought • We have better mental tools than our ancestors • Abstraction appears 50k-100k years ago • Arabic numerals > roman numerals • Metric conversions > Imperial • 24-hours & 360-degrees have nice divisiors

Slide 50

Slide 50

Manifesto ☎→⚗→ Random Walk Image by Pradyumna Yadav

Slide 51

Slide 51

Manifesto ☎→⚗→ Random Walk Image by Pradyumna Yadav

Slide 52

Slide 52

Manifesto ☎→⚗→ Random Walk Image by Pradyumna Yadav

Slide 53

Slide 53

Manifesto ☎→⚗→ Random Walk Image by Pradyumna Yadav

Slide 54

Slide 54

Manifesto ☎→⚗→ Random Walk Image by Pradyumna Yadav

Slide 55

Slide 55

Manifesto ☎→⚗→ Random Walk - Image by Pradyumna Yadav

Slide 56

Slide 56

Manifesto ☎→⚗→ Random Walk . / Image by Pradyumna Yadav

Slide 57

Slide 57

Manifesto ☎→⚗→ The World Is Changing

Slide 58

Slide 58

Manifesto ☎→⚗→ The World Is Changing

Slide 59

Slide 59

Manifesto ☎→⚗→ The World Is Changing 23 01 Invention Custom Off-the-Shelf Utility

Slide 60

Slide 60

Manifesto ☎→⚗→ The World Is Changing 23 01 Invention Custom Off-the-Shelf Utility

Slide 61

Slide 61

Manifesto ☎→⚗→ The World Is Changing 23 01 Invention Custom Off-the-Shelf Utility

Slide 62

Slide 62

Manifesto ☎→⚗→ The World Is Changing 23 01 Invention Custom Off-the-Shelf Utility

Slide 63

Slide 63

Manifesto ☎→⚗→ The World Is Changing 23 01 Invention Custom Off-the-Shelf Utility

Slide 64

Slide 64

Manifesto ☎→⚗→ The World Is Changing 23 01 Invention Custom Off-the-Shelf Utility

Slide 65

Slide 65

Manifesto ☎→⚗→ A Cambrian Explosion of Approaches! CC BY-SA 3.0: mariowiki.com

Slide 66

Slide 66

Manifesto ☎→⚗→ A Cambrian Explosion of Approaches! ☎→⚗→Gj CC BY-SA 3.0: mariowiki.com

Slide 67

Slide 67

Manifesto ☎→⚗→ A Cambrian Explosion of Approaches! ☎→⚗→Gj → 4 CC BY-SA 3.0: mariowiki.com

Slide 68

Slide 68

Manifesto ☎→⚗→ A Cambrian Explosion of Approaches! ☎→⚗→Gj → 4 → CC BY-SA 3.0: mariowiki.com

Slide 69

Slide 69

Manifesto ☎→⚗→ A Cambrian Explosion of Approaches! ☎→⚗→Gj → 4 → →5 CC BY-SA 3.0: mariowiki.com

Slide 70

Slide 70

Manifesto ☎→⚗→ A Cambrian Explosion of Approaches! → ☎→⚗→Gj → 4 → →5 CC BY-SA 3.0: mariowiki.com

Slide 71

Slide 71

Manifesto ☎→⚗→ A Cambrian Explosion of Approaches! → $ → ☎→⚗→Gj → 4 → →5 CC BY-SA 3.0: mariowiki.com

Slide 72

Slide 72

Manifesto ☎→⚗→ A Cambrian Explosion of Approaches! 6 → → $ → ☎→⚗→Gj → 4 → →5 CC BY-SA 3.0: mariowiki.com

Slide 73

Slide 73

Manifesto ☎→⚗→ Sources of Inspiration

Slide 74

Slide 74

Manifesto ☎→⚗→ Sources of Inspiration 7 Things I’ve seen work in production

Slide 75

Slide 75

Manifesto ☎→⚗→ Sources of Inspiration 7 Things I’ve seen work in production 8 Ideas from the 70s & 80s

Slide 76

Slide 76

Manifesto ☎→⚗→ Sources of Inspiration 7 Things I’ve seen work in production 8 Ideas from the 70s & 80s 9 Functional Pearls

Slide 77

Slide 77

Manifesto ☎→⚗→ Sources of Inspiration 7 Things I’ve seen work in production 8 Ideas from the 70s & 80s 9 Functional Pearls : Programming language research

Slide 78

Slide 78

Manifesto ☎→⚗→ Sources of Inspiration 7 Things I’ve seen work in production 8 Ideas from the 70s & 80s 9 Functional Pearls : Programming language research ; Distributed databases

Slide 79

Slide 79

Manifesto ☎→⚗→ Sources of Inspiration 7 Things I’ve seen work in production 8 Ideas from the 70s & 80s 9 Functional Pearls : Programming language research ; Distributed databases < Other ecosystems (e.g. Scheme, OCaml, Haxl, Racket)

Slide 80

Slide 80

Manifesto ☎→⚗→ Sources of Inspiration 7 Things I’ve seen work in production 8 Ideas from the 70s & 80s 9 Functional Pearls : Programming language research ; Distributed databases < Other ecosystems (e.g. Scheme, OCaml, Haxl, Racket) = Criminally underused Elixir features

Slide 81

Slide 81

Manifesto ☎→⚗→ Three Stupidly Powerful Concepts

Slide 82

Slide 82

Manifesto ☎→⚗→ Three Stupidly Powerful Concepts eDSL

Slide 83

Slide 83

Manifesto ☎→⚗→ Three Stupidly Powerful Concepts eDSL Code as Data Managed Effects Active Metadata

Slide 84

Slide 84

Manifesto ☎→⚗→ Three Stupidly Powerful Concepts eDSL Expressivity Code as Data Modular Languages Denotational Design Managed Effects Active Metadata

Slide 85

Slide 85

Manifesto ☎→⚗→ Three Stupidly Powerful Concepts eDSL Expressivity Code as Data Modular Languages Denotational Design Managed Effects Active Metadata Derivative DSLs

Slide 86

Slide 86

Manifesto ☎→⚗→ Three Stupidly Powerful Concepts eDSL Expressivity Code as Data Modular Languages Denotational Design Runners Managed Effects Implicit Concurrency Model Testing Active Metadata Derivative DSLs

Slide 87

Slide 87

Manifesto ☎→⚗→ Three Stupidly Powerful Concepts eDSL Expressivity Code as Data Modular Languages Derivative DSLs Denotational Design Runners Managed Effects Implicit Concurrency Model Testing Active Metadata Structural Optimistic

Slide 88

Slide 88

Manifesto ☎→⚗→ Three Stupidly Powerful Concepts eDSL Expressivity Code as Data Modular Languages Derivative DSLs Denotational Design Runners Managed Effects Structural Implicit Concurrency Model Testing Provenance Active Metadata Proof Carrying Code Optimistic

Slide 89

Slide 89

Manifesto ☎→⚗→ Three Stupidly Powerful Concepts eDSL Expressivity Code as Data Modular Languages Derivative DSLs Denotational Design Runners Managed Effects Structural Implicit Concurrency Model Testing Optimistic Provenance Active Metadata Proof Carrying Code Time Travel

Slide 90

Slide 90

Manifesto ☎→⚗→ Three Stupidly Powerful Concepts eDSL Expressivity Code as Data Modular Languages Derivative DSLs Denotational Design Runners Managed Effects Implicit Concurrency Model Testing

Structural Optimistic Provenance Active Metadata Proof Carrying Code Time Travel

Slide 91

Slide 91

Modular Semantics Millions of Tiny Languages

Slide 92

Slide 92

Modular Semantics Millions of Tiny Languages s e g a u g n a L

Slide 93

Slide 93

Millions of Tiny Languages ⚛

Slide 94

Slide 94

Millions of Tiny Languages ⚛ We really don’t want to build a programming language from scratch[…], let’s inherit infrastructure from some other language – Paul Hudak, Building Domain Specific Embedded Languages

Slide 95

Slide 95

Millions of Tiny Languages ⚛ We really don’t want to build a programming language from scratch[…], let’s inherit infrastructure from some other language – Paul Hudak, Building Domain Specific Embedded Languages e m o “S r e oth u g n a l ? ” e g a

Slide 96

Slide 96

Millions of Tiny Languages ⚛ All the Way Down

Slide 97

Slide 97

Millions of Tiny Languages ⚛ All the Way Down

Slide 98

Slide 98

Millions of Tiny Languages ⚛ All the Way Down Binary Physics Mathematics

Slide 99

Slide 99

Millions of Tiny Languages ⚛ All the Way Down Binary Physics Mathematics

Slide 100

Slide 100

Millions of Tiny Languages ⚛ All the Way Down Kernel syscalls x 8 6 / A R M / R I S C-V Binary Physics Mathematics

Slide 101

Slide 101

Millions of Tiny Languages ⚛ All the Way Down Elixir AST BEAM bytecode Kernel syscalls x 8 6 / A R M / R I S C-V Binary Physics Mathematics

Slide 102

Slide 102

Millions of Tiny Languages ⚛ All the Way Down Application Domain Librar y / Framework Elixir Language Elixir AST BEAM bytecode Kernel syscalls x 8 6 / A R M / R I S C-V Binary Physics Mathematics

Slide 103

Slide 103

Millions of Tiny Languages ⚛ All the Way Down Natural Language GUI Metaphor Application Domain Librar y / Framework Elixir Language Elixir AST BEAM bytecode Kernel syscalls x 8 6 / A R M / R I S C-V Binary Physics Mathematics

Slide 104

Slide 104

Millions of Tiny Languages ⚛ Big Three Models

Slide 105

Slide 105

Millions of Tiny Languages ⚛ Big Three Models

Slide 106

Slide 106

Millions of Tiny Languages ⚛ Big Three Models •→• ↓ ↓ ■→▴ A @

Slide 107

Slide 107

Millions of Tiny Languages ⚛ Big Three Models •→• ↓ ↓ ■→▴ A @ Dynamic Operational Mechanical

Slide 108

Slide 108

Millions of Tiny Languages ⚛ Big Three Models •→• ↓ ↓ ■→▴ A @ Dynamic Operational Mechanical

Slide 109

Slide 109

Millions of Tiny Languages ⚛ Big Three Models Universal Denotational Mathematical •→• ↓ ↓ ■→▴ A @ Dynamic Operational Mechanical

Slide 110

Slide 110

Millions of Tiny Languages ⚛ Big Three Models Universal Denotational Mathematical •→• ↓ ↓ ■→▴ A @ Dynamic Operational Mechanical

Slide 111

Slide 111

Millions of Tiny Languages ⚛ Big Three Models Universal Denotational Mathematical •→• ↓ ↓ ■→▴ A Symbolist Semiotic Natural Language @ Dynamic Operational Mechanical

Slide 112

Slide 112

Millions of Tiny Languages ⚛ Big Three Models Universal Denotational Mathematical •→• ↓ ↓ ■→▴ A Symbolist Semiotic Natural Language @ Dynamic Operational Mechanical

Slide 113

Slide 113

Millions of Tiny Languages ⚛ Big Three Models Universal Denotational Mathematical •→• ↓ ↓ ■→▴ A Symbolist Semiotic Natural Language @ Dynamic Operational Mechanical

Slide 114

Slide 114

Millions of Tiny Languages ⚛ Big Three Models A Symbolist Semiotic Natural Language On its ef iz es lB al Universal Denotational Mathematical •→• ↓ ↓ ■→▴ @ Dynamic Operational Mechanical

Slide 115

Slide 115

Millions of Tiny Languages ⚛ Big Three Models A Symbolist Semiotic Natural Language On its ef iz es lB al Universal Denotational Mathematical •→• ↓ ↓ ■→▴ @ Dynamic Operational Mechanical

Slide 116

Slide 116

Manifesto ☎→⚗→ “Expressive” C⚔E>

Slide 117

Slide 117

Manifesto ☎→⚗→ “Expressive” C⚔E>

Slide 118

Slide 118

Millions of Tiny Languages ⚛ Tower of (Expressive) Power

Slide 119

Slide 119

Millions of Tiny Languages ⚛ Tower of (Expressive) Power

Slide 120

Slide 120

Millions of Tiny Languages ⚛ Tower of (Expressive) Power

Slide 121

Slide 121

Millions of Tiny Languages ⚛ Tower of (Expressive) Power

Slide 122

Slide 122

Millions of Tiny Languages ⚛ Tower of (Expressive) Power

Slide 123

Slide 123

Millions of Tiny Languages ⚛ Tower of (Expressive) Power

Slide 124

Slide 124

Millions of Tiny Languages ⚛ Tower of (Expressive) Power

Slide 125

Slide 125

Millions of Tiny Languages ⚛ Tower of (Expressive) Power

Slide 126

Slide 126

Millions of Tiny Languages ⚛ Practical Bounds

Slide 127

Slide 127

Millions of Tiny Languages ⚛ Practical Bounds Can a language be too expressive?

Slide 128

Slide 128

Millions of Tiny Languages ⚛ Practical Bounds Can a language be too expressive? Useful Programs

Slide 129

Slide 129

Millions of Tiny Languages ⚛ Practical Bounds Can a language be too expressive? Useful Programs Buggy Programs

Slide 130

Slide 130

Millions of Tiny Languages ⚛ Practical Bounds Can a language be too expressive? Useful Programs Yours Buggy Programs

Slide 131

Slide 131

Millions of Tiny Languages ⚛ Practical Bounds Can a language be too expressive? Useful Programs Yours Buggy Programs

Slide 132

Slide 132

Millions of Tiny Languages ⚛ Welcome to the Danger Zone ⚠

Slide 133

Slide 133

Millions of Tiny Languages ⚛ What’s So Bad About Control? GH

Slide 134

Slide 134

Millions of Tiny Languages ⚛ What’s So Bad About Control? GH Line 1 Line 2 Line 3 Line 4 Line 5 — GOTO Line 6

Slide 135

Slide 135

Millions of Tiny Languages ⚛ What’s So Bad About Control? GH Line 1 Line 2 Line 3 Line 4 Line 5 — GOTO Line 6

Slide 136

Slide 136

Millions of Tiny Languages ⚛ What’s So Bad About Control? GH Line 1 Line 2 Line 3 Line 4 Line 5 — GOTO Line 6

Slide 137

Slide 137

Millions of Tiny Languages ⚛ What’s So Bad About Control? GH Turing completeness considered harmful Line 1 Line 2 Line 3 Line 4 Line 5 — GOTO Line 6 5

Slide 138

Slide 138

Millions of Tiny Languages ⚛ What’s So Bad About Control? GH Turing completeness considered harmful Line 1 Line 2 Line 3 Line 4 Line 5 — GOTO Line 6 5

Slide 139

Slide 139

Millions of Tiny Languages ⚛ Aside: “Accidentally” Turing Complete https://harrisonwl.github.io/assets/courses/malware/spring2017/papers/mov-is-turing-complete.pdf https://github.com/ealter/vim_turing_machine https://github.com/Microsoft/TypeScript/issues/14833 https://vanbever.eu/pdfs/vanbever_turing_icnp_2013.pdf https://arxiv.org/pdf/1904.09828.pdf https://softwareengineering.stackexchange.com/a/136179

Slide 140

Slide 140

Millions of Tiny Languages ⚛ Aside: “Accidentally” Turing Complete • x86 MOV (just by itself) • TypeScript’s Type System • Vim Normal Mode • Magic the Gathering • BGP • Pokemon Yellow • Peano arithmetic • Unicode (conjectured) • Musical Notation • Sendmail’s Config https://harrisonwl.github.io/assets/courses/malware/spring2017/papers/mov-is-turing-complete.pdf https://github.com/ealter/vim_turing_machine https://github.com/Microsoft/TypeScript/issues/14833 https://vanbever.eu/pdfs/vanbever_turing_icnp_2013.pdf https://arxiv.org/pdf/1904.09828.pdf https://softwareengineering.stackexchange.com/a/136179

Slide 141

Slide 141

Millions of Tiny Languages ⚛ The Lesson I

Slide 142

Slide 142

Millions of Tiny Languages ⚛ The Lesson I The bottom line is that the more powerful a language (i.e. the more that is possible within the language), the harder it is to understand systems constructed in it – Ben Mosley & Peter Marks, Out of the Tarpit

Slide 143

Slide 143

Millions of Tiny Languages ⚛ Three Focused Vocabularies

Slide 144

Slide 144

Millions of Tiny Languages ⚛ Three Focused Vocabularies

Slide 145

Slide 145

Millions of Tiny Languages ⚛ Three Focused Vocabularies

Slide 146

Slide 146

Millions of Tiny Languages ⚛ Three Focused Vocabularies

Slide 147

Slide 147

Millions of Tiny Languages ⚛ Three Focused Vocabularies

Slide 148

Slide 148

Millions of Tiny Languages ⚛ Compositional Vocabularies

Slide 149

Slide 149

Millions of Tiny Languages ⚛ Compositional Vocabularies

Slide 150

Slide 150

Millions of Tiny Languages ⚛ Compositional Vocabularies

Slide 151

Slide 151

Millions of Tiny Languages ⚛ Compositional Vocabularies

Slide 152

Slide 152

Millions of Tiny Languages ⚛ Compositional Vocabularies

Slide 153

Slide 153

Millions of Tiny Languages ⚛ Compositional Vocabularies

Slide 154

Slide 154

Millions of Tiny Languages ⚛ Compositional Vocabularies

Slide 155

Slide 155

Millions of Tiny Languages ⚛ Compositional Vocabularies

Slide 156

Slide 156

Millions of Tiny Languages ⚛ Compositional Vocabularies

Slide 157

Slide 157

Millions of Tiny Languages ⚛ Compositional Vocabularies

Slide 158

Slide 158

Millions of Tiny Languages ⚛ Compositional Vocabularies

Slide 159

Slide 159

Millions of Tiny Languages ⚛ Compositional Vocabularies J K L

Slide 160

Slide 160

Millions of Tiny Languages ⚛ Compositional Vocabularies J K Components: 4 L

Slide 161

Slide 161

Millions of Tiny Languages ⚛ Compositional Vocabularies J K Components: 4 Results: All of computer graphics L

Slide 162

Slide 162

Millions of Tiny Languages ⚛ Interleaved Terms

Slide 163

Slide 163

Millions of Tiny Languages ⚛ Interleaved Terms

Slide 164

Slide 164

Millions of Tiny Languages ⚛ Interleaved Terms

Slide 165

Slide 165

Millions of Tiny Languages ⚛ Interleaved Terms

Slide 166

Slide 166

✨ An AST of Your Own ✨ Building Up & Tearing Down NO

Slide 167

Slide 167

Building Up & Tearing Down NO Shallow Pipes https://hexdocs.pm/ecto/Ecto.Changeset.html#module-validations-and-constraints

Slide 168

Slide 168

Building Up & Tearing Down NO Shallow Pipes • Just use the built-in AST • What it can represent is limited • Single, canonical implementations • e.g. most libraries https://hexdocs.pm/ecto/Ecto.Changeset.html#module-validations-and-constraints

Slide 169

Slide 169

Building Up & Tearing Down NO Shallow Pipes https://github.com/witchcrafters/algae/blob/main/lib/algae/tree/binary_search.ex

Slide 170

Slide 170

Building Up & Tearing Down NO Shallow Pipes https://github.com/witchcrafters/algae/blob/main/lib/algae/tree/binary_search.ex

Slide 171

Slide 171

Building Up & Tearing Down NO Shallow Pipes https://github.com/witchcrafters/algae/blob/main/lib/algae/tree/binary_search.ex

Slide 172

Slide 172

Building Up & Tearing Down NO Shallow Pipes https://github.com/witchcrafters/algae/blob/main/lib/algae/tree/binary_search.ex

Slide 173

Slide 173

Building Up & Tearing Down NO Shallow Pipes https://github.com/witchcrafters/algae/blob/main/lib/algae/tree/binary_search.ex

Slide 174

Slide 174

Building Up & Tearing Down NO Whatever You Want It To Be Natural Language GUI Metaphor Application Domain Librar y / Framework Elixir Language Elixir AST BEAM bytecode Kernel syscalls x 8 6 / A R M / R I S C-V Binary Physics Mathematics

Slide 175

Slide 175

Building Up & Tearing Down NO Whatever You Want It To Be Natural Language GUI Metaphor Application Domain There is nothing sacred about Elixir’s AST; it’s just well suited for its ecological niche Librar y / Framework Elixir Language Elixir AST BEAM bytecode Kernel syscalls x 8 6 / A R M / R I S C-V Binary Physics Mathematics

Slide 176

Slide 176

Building Up & Tearing Down NO Whatever You Want It To Be Natural Language GUI Metaphor Application Domain There is nothing sacred about Elixir’s AST; it’s just well suited for its ecological niche Librar y / Framework Elixir Language Elixir AST BEAM bytecode Kernel syscalls x 8 6 / A R M / R I S C-V Binary Physics Mathematics

Slide 177

Slide 177

Building Up & Tearing Down NO Invocation & Rewriting

Slide 178

Slide 178

Building Up & Tearing Down NO Invocation & Rewriting

  1. Build a game plan

Slide 179

Slide 179

Building Up & Tearing Down NO Invocation & Rewriting

  1. Build a game plan 2. Transform (optional)

Slide 180

Slide 180

Building Up & Tearing Down NO Invocation & Rewriting

  1. Build a game plan 2. Transform (optional) 3. Tear down

Slide 181

Slide 181

Building Up & Tearing Down NO Connectives

Slide 182

Slide 182

Building Up & Tearing Down NO Connectives

Slide 183

Slide 183

Building Up & Tearing Down NO Connectives

Slide 184

Slide 184

Building Up & Tearing Down NO Connectives

Slide 185

Slide 185

Building Up & Tearing Down NO Connectives

Slide 186

Slide 186

Building Up & Tearing Down NO Connectives

Slide 187

Slide 187

Building Up & Tearing Down NO Connectives

Slide 188

Slide 188

Building Up & Tearing Down NO GenEffect

Slide 189

Slide 189

Building Up & Tearing Down NO GenEffect

Slide 190

Slide 190

Building Up & Tearing Down NO GenEffect

Slide 191

Slide 191

Building Up & Tearing Down NO GenEffect

Slide 192

Slide 192

Building Up & Tearing Down NO Interpreter

Slide 193

Slide 193

Building Up & Tearing Down NO Interpreter

Slide 194

Slide 194

Building Up & Tearing Down NO Interpreter

Slide 195

Slide 195

Building Up & Tearing Down NO Interpreter

Slide 196

Slide 196

Building Up & Tearing Down NO Interpreter

Slide 197

Slide 197

Building Up & Tearing Down NO Interpreter Why not use a protocol? Canonicity!

Slide 198

Slide 198

Domain & Denotation Standard Vocabularies P

Slide 199

Slide 199

Standard Vocabularies P What Is Common?

Slide 200

Slide 200

Standard Vocabularies P What Is Common? M ! t n e m e v o

Slide 201

Slide 201

Standard Vocabularies P One Level Down

Slide 202

Slide 202

Standard Vocabularies P One Level Down

Slide 203

Slide 203

Standard Vocabularies P One Level Down

Slide 204

Slide 204

Standard Vocabularies P What’s Important About Laws?

Slide 205

Slide 205

Standard Vocabularies P What’s Important About Laws? Consistent in all contexts

Slide 206

Slide 206

Standard Vocabularies P Denotative Redux

Slide 207

Slide 207

Standard Vocabularies P Denotative Redux

Slide 208

Slide 208

Standard Vocabularies P Denotative Redux We are only drawing a most important distinction — between discovering something and inventing something. But mathematicians make the most important discoveries. – Alan Turing, via Wittgenstein’s Lectures on the Foundations of Mathematics

Slide 209

Slide 209

Standard Vocabularies P

Slide 210

Slide 210

Safety First Purify Your Effects 3⛑R

Slide 211

Slide 211

Purify Your Effects 3⛑R

Slide 212

Slide 212

Purify Your Effects 3⛑R Have no truck with the grubby compromises of imperative programming — Simon Peyton Jones

Slide 213

Slide 213

Purify Your Effects 3⛑R Tools Down

Slide 214

Slide 214

Purify Your Effects 3⛑R Tools Down Elixir is surprisingly imperative, yet gives you all the tools of equational reasoning …so let’s use them!

Slide 215

Slide 215

Purify Your Effects 3⛑R Description vs Invocation

Slide 216

Slide 216

Purify Your Effects 3⛑R Description vs Invocation Impure functions produce side effects Pure functions manipulate data Side effects → managed effects

Slide 217

Slide 217

Purify Your Effects 3⛑R Description vs Invocation Impure functions produce side effects Pure functions manipulate data Side effects → managed effects function

Slide 218

Slide 218

Purify Your Effects 3⛑R Description vs Invocation Impure functions produce side effects Pure functions manipulate data Side effects → managed effects input function

Slide 219

Slide 219

Purify Your Effects 3⛑R Description vs Invocation Impure functions produce side effects Pure functions manipulate data Side effects → managed effects input function output function

Slide 220

Slide 220

Purify Your Effects 3⛑R Description vs Invocation Impure functions produce side effects Pure functions manipulate data Side effects → managed effects effect input effect function output function

Slide 221

Slide 221

Purify Your Effects 3⛑R Description vs Invocation Impure functions produce side effects Pure functions manipulate data Side effects → managed effects effect input function output effect function

Slide 222

Slide 222

Purify Your Effects 3⛑R 4-Layer Architecture

Slide 223

Slide 223

Purify Your Effects 3⛑R 4-Layer Architecture Imperative Managed Effects Pure Functions Data

Slide 224

Slide 224

Purify Your Effects 3⛑R 4-Layer Architecture 5 Action Imperative Managed Effects Pure Functions Data SInformation

Slide 225

Slide 225

Purify Your Effects 3⛑R 4-Layer Architecture 5 Action Unstable T Imperative Managed Effects Pure Functions Data SInformation Stable U

Slide 226

Slide 226

Purify Your Effects 3⛑R Purified Actions

Slide 227

Slide 227

Well Behaved Models Testing Minus the Teeth V

Slide 228

Slide 228

Testing Minus the Teeth V Faking Without Mocks

Slide 229

Slide 229

Testing Minus the Teeth V Faking Without Mocks •Inspect the pure data! •Have tests write to a list as they run •Fake databases with maps •Fake sending email with logs

Slide 230

Slide 230

Testing Minus the Teeth V Faking Without Mocks •Inspect the pure data! •Have tests write to a list as they run •Fake databases with maps •Fake sending email with logs

Slide 231

Slide 231

Testing Minus the Teeth V Faking Without Mocks •Inspect the pure data! •Have tests write to a list as they run •Fake databases with maps •Fake sending email with logs

Slide 232

Slide 232

Testing Minus the Teeth V Faking Without Mocks •Inspect the pure data! •Have tests write to a list as they run •Fake databases with maps •Fake sending email with logs

Slide 233

Slide 233

Control Dominator Take the Wheel Implicit Parallelism W

Slide 234

Slide 234

Implicit Parallelism W Humans are Terrible at Concurrency X

Slide 235

Slide 235

Implicit Parallelism W Humans are Terrible at Concurrency X The main way of dealing with concurrency has been reduced to sequential reasoning […] it requires to cope with many possible, unpredictable behaviors of process, and the communication media Everything is NOT reducible to sequential thinking — Sergio Rajsbaum & Michel Raynal, 60 Years of Mastering Concurrency Through Sequential Thinking

Slide 236

Slide 236

Implicit Parallelism W Coordination Costs

Slide 237

Slide 237

Implicit Parallelism W Throughput Coordination Costs Parallelization

Slide 238

Slide 238

Implicit Parallelism W Ideal (Linear) Throughput Coordination Costs Parallelization

Slide 239

Slide 239

Implicit Parallelism W Coordination Costs Ideal (Linear) Throughput Amdahl’s Law Parallelization

Slide 240

Slide 240

Implicit Parallelism W Coordination Costs Ideal (Linear) Throughput Amdahl’s Law Universal Scaling Law Parallelization

Slide 241

Slide 241

Implicit Parallelism W Coordination Costs Ideal (Linear) Throughput Amdahl’s Law Incoherence, Data Contention Universal Scaling Law Parallelization

Slide 242

Slide 242

Implicit Parallelism W Confluence / Church-Rosser

Slide 243

Slide 243

Implicit Parallelism W Confluence / Church-Rosser

Slide 244

Slide 244

Implicit Parallelism W Confluence / Church-Rosser

Slide 245

Slide 245

Implicit Parallelism W Confluence / Church-Rosser

Slide 246

Slide 246

Implicit Parallelism W Confluence / Church-Rosser

Slide 247

Slide 247

Implicit Parallelism W Confluence / Church-Rosser Commutes!

Slide 248

Slide 248

Implicit Parallelism W Confluence / Church-Rosser Commutes!

Slide 249

Slide 249

Implicit Parallelism W Confluence / Church-Rosser Commutes!

Slide 250

Slide 250

Implicit Parallelism W Dependency Analysis

Slide 251

Slide 251

Implicit Parallelism W Dependency Analysis

Slide 252

Slide 252

Implicit Parallelism W Dependency Analysis

Slide 253

Slide 253

Implicit Parallelism W Dependency Analysis msg recipient upcase send DB.insert date

Slide 254

Slide 254

Implicit Parallelism W Dependency Analysis msg recipient upcase send DB.insert date

Slide 255

Slide 255

Implicit Parallelism W Dependency Analysis msg recipient upcase send DB.insert date

Slide 256

Slide 256

Implicit Parallelism W Dependency Analysis msg recipient upcase send DB.insert date

Slide 257

Slide 257

Implicit Parallelism W Actor Problem: Data Locality Coordination

Slide 258

Slide 258

Implicit Parallelism W Actor Problem: Data Locality Coordination Z Y [

Slide 259

Slide 259

Implicit Parallelism W Actor Problem: Data Locality Coordination \ Z \ Y \ [

Slide 260

Slide 260

Implicit Parallelism W Actor Problem: Data Locality Coordination \ Z] \ Y] \ []

Slide 261

Slide 261

Implicit Parallelism W Actor Problem: Data Locality Coordination \ Z] \ Y] \ [] ✉ ✉ ✉ ✉ ✉ ✉ ✉ ✉ ✉ ✉ ✉ ✉

Slide 262

Slide 262

Implicit Parallelism W Actor Problem: Data Locality Coordination \ Z] ✉ ✉ ✉ ✉ _ \ Y] \ [] ✉ ✉ ✉ ✉ ✉ ✉ ✉ ✉

Slide 263

Slide 263

Implicit Parallelism W Actor Problem: Data Locality Coordination \ Z] ✉ ✉ ✉ ✉ _ \ Y ☠] \ [] ✉ ✉ ✉ ✉ ✉ ✉ ✉ ✉

Slide 264

Slide 264

Implicit Parallelism W Actor Problem: Data Locality Coordination \ Z] ✉ ✉ ✉ ✉ _ a \ Y ☠] \ [] ✉ ✉ ✉ ✉ ✉ ✉ ✉ ✉

Slide 265

Slide 265

Purify Your Effects 3⛑R Optimistic Concurrency: STM https://www.cs.rochester.edu/u/scott/papers/2006_TRANSACT_RSTM.pdf

Slide 266

Slide 266

Purify Your Effects 3⛑R Optimistic Concurrency: STM c b d https://www.cs.rochester.edu/u/scott/papers/2006_TRANSACT_RSTM.pdf

Slide 267

Slide 267

Purify Your Effects 3⛑R Optimistic Concurrency: STM c b d https://www.cs.rochester.edu/u/scott/papers/2006_TRANSACT_RSTM.pdf

Slide 268

Slide 268

Purify Your Effects 3⛑R Optimistic Concurrency: STM c b _ d _ https://www.cs.rochester.edu/u/scott/papers/2006_TRANSACT_RSTM.pdf

Slide 269

Slide 269

Purify Your Effects 3⛑R Optimistic Concurrency: STM c b _ ⚙ d _ ⚙ https://www.cs.rochester.edu/u/scott/papers/2006_TRANSACT_RSTM.pdf

Slide 270

Slide 270

Purify Your Effects 3⛑R Optimistic Concurrency: STM c ⚙ b d _ _ ⚠ ⚠ ⚠ ⚠ ⚙ https://www.cs.rochester.edu/u/scott/papers/2006_TRANSACT_RSTM.pdf

Slide 271

Slide 271

Purify Your Effects 3⛑R Optimistic Concurrency: STM c ⚙ b d _ _ ⚠ ⚠ ⚠ ⚠ f ⚙ f https://www.cs.rochester.edu/u/scott/papers/2006_TRANSACT_RSTM.pdf

Slide 272

Slide 272

Purify Your Effects 3⛑R Optimistic Concurrency: STM c ⚙ b d _ _ ⚠ ⚠ ⚠ ⚠ f g ⚙ f g https://www.cs.rochester.edu/u/scott/papers/2006_TRANSACT_RSTM.pdf

Slide 273

Slide 273

Purify Your Effects 3⛑R Optimistic Concurrency: STM c ⚙ b d _ _ ⚠ ⚠ ⚠ ⚠ f g c b d ⚙ f g https://www.cs.rochester.edu/u/scott/papers/2006_TRANSACT_RSTM.pdf

Slide 274

Slide 274

Purify Your Effects 3⛑R Optimistic Concurrency: STM c ⚙ b d _ _ ⚠ ⚠ ⚠ ⚠ f g c b d ⚙ f g https://www.cs.rochester.edu/u/scott/papers/2006_TRANSACT_RSTM.pdf

Slide 275

Slide 275

Purify Your Effects 3⛑R Optimistic Concurrency: STM c ⚙ b d _ _ ⚠ ⚠ ⚠ ⚠ f g c c h b d d h ⚙ f g https://www.cs.rochester.edu/u/scott/papers/2006_TRANSACT_RSTM.pdf

Slide 276

Slide 276

Purify Your Effects 3⛑R Optimistic Concurrency: STM c ⚙ b d _ _ ⚠ ⚠ ⚠ ⚠ f g c c b d d h h ⚙ ⚙ f g https://www.cs.rochester.edu/u/scott/papers/2006_TRANSACT_RSTM.pdf

Slide 277

Slide 277

Purify Your Effects 3⛑R Optimistic Concurrency: STM c ⚙ b d _ _ ⚠ ⚠ ⚠ ⚠ f g c c b d d h h ⚙ ⚙ _ _ f g https://www.cs.rochester.edu/u/scott/papers/2006_TRANSACT_RSTM.pdf

Slide 278

Slide 278

Purify Your Effects 3⛑R Optimistic Concurrency: STM c ⚙ b d _ _ ⚠ ⚠ ⚠ ⚠ f g c c b d d h h ⚙ ⚙ _O _ f g https://www.cs.rochester.edu/u/scott/papers/2006_TRANSACT_RSTM.pdf

Slide 279

Slide 279

Purify Your Effects 3⛑R Optimistic Concurrency: STM c ⚙ b d _ _ ⚠ ⚠ ⚠ ⚠ f g c c b d d h h ⚙ ⚙ _O _ c d f g https://www.cs.rochester.edu/u/scott/papers/2006_TRANSACT_RSTM.pdf

Slide 280

Slide 280

Purify Your Effects 3⛑R Optimistic Concurrency: STM c ⚙ b d _ _ ⚠ ⚠ ⚠ ⚠ f g f g c c b d d h h ⚙ _O _ c d ⚙ ⚙ ⚙ https://www.cs.rochester.edu/u/scott/papers/2006_TRANSACT_RSTM.pdf

Slide 281

Slide 281

Purify Your Effects 3⛑R Optimistic Concurrency: STM c ⚙ b d _ _ ⚠ ⚠ ⚠ ⚠ f g f g c c b d d h h ⚙ _O _ c d ⚙ ⚙ f f ⚙ https://www.cs.rochester.edu/u/scott/papers/2006_TRANSACT_RSTM.pdf

Slide 282

Slide 282

Purify Your Effects 3⛑R Optimistic Concurrency: STM c ⚙ b d _ _ ⚠ ⚠ ⚠ ⚠ f g f g c c b d d h h ⚙ _O _ c d ⚙ ⚙ f g f g ⚙ https://www.cs.rochester.edu/u/scott/papers/2006_TRANSACT_RSTM.pdf

Slide 283

Slide 283

Purify Your Effects 3⛑R Optimistic Concurrency: STM c ⚙ b d _ _ ⚠ ⚠ ⚠ ⚠ f g f g c c b d d h h ⚙ _O _ c d ⚙ ⚙ f g f g ⚙ https://www.cs.rochester.edu/u/scott/papers/2006_TRANSACT_RSTM.pdf

Slide 284

Slide 284

Purify Your Effects 3⛑R Optimistic Concurrency: STM l k i j :

Slide 285

Slide 285

Purify Your Effects 3⛑R Optimistic Concurrency: STM

Slide 286

Slide 286

Effectful Proof, Provenance, & Power Metadata in Motion m

Slide 287

Slide 287

Effectful Proof, Provenance, & Power Metadata in Motion nm

Slide 288

Slide 288

Metadata in Motion mn

Slide 289

Slide 289

Metadata in Motion mn It’s only data provenance if it’s derived from the Provence region of France. Otherwise it’s just sparkling metadata. – Adapted from @onfiv

Slide 290

Slide 290

Metadata in Motion mn Proof Carrying Code

Slide 291

Slide 291

Metadata in Motion mn Proof Carrying Code

Slide 292

Slide 292

Metadata in Motion mn Proof Carrying Code

Slide 293

Slide 293

Metadata in Motion mn Proof Carrying Code

Slide 294

Slide 294

Metadata in Motion mn Proof Carrying Code mergesort is way easier now

Slide 295

Slide 295

Metadata in Motion mn Carrying Capabilities https://kataskeue.com/gdp.pdf https://arxiv.org/pdf/1907.07154.pdf

Slide 296

Slide 296

Metadata in Motion mn Carrying Capabilities https://kataskeue.com/gdp.pdf https://arxiv.org/pdf/1907.07154.pdf

Slide 297

Slide 297

Metadata in Motion mn Carrying Capabilities https://kataskeue.com/gdp.pdf https://arxiv.org/pdf/1907.07154.pdf

Slide 298

Slide 298

Metadata in Motion mn Provenance

Slide 299

Slide 299

Metadata in Motion mn Provenance

Slide 300

Slide 300

Metadata in Motion mn Provenance

Slide 301

Slide 301

Metadata in Motion mn Provenance

Slide 302

Slide 302

Metadata in Motion mn Provenance++

Slide 303

Slide 303

Tools for The Intrepid ⚒

Slide 304

Slide 304

Wrapping Up Tools for The Intrepid ⚒

Slide 305

Slide 305

Tools for The Intrepid ⚒

Slide 306

Slide 306

Tools for The Intrepid ⚒ A programming language influences the way that its users think about programming; matching a language to a methodology increases the likelihood that the methodology will be used – Barbara Liskov et al, Abstraction Mechanisms in CLU

Slide 307

Slide 307

Tools for The Intrepid ⚒ What Just Happened?

Slide 308

Slide 308

Tools for The Intrepid ⚒ What Just Happened?

  1. Add structure & dimension

Slide 309

Slide 309

Tools for The Intrepid ⚒ What Just Happened?

  1. Add structure & dimension 2. Make reusable DSLs

Slide 310

Slide 310

Tools for The Intrepid ⚒ What Just Happened?

  1. Add structure & dimension 2. Make reusable DSLs 3. Manage your effects

Slide 311

Slide 311

Tools for The Intrepid ⚒ What Just Happened?

  1. Add structure & dimension 2. Make reusable DSLs 3. Manage your effects 4. Mechanize the hard stuff (e.g. concurrency)

Slide 312

Slide 312

Tools for The Intrepid ⚒ What Just Happened?

  1. Add structure & dimension 2. Make reusable DSLs 3. Manage your effects 4. Mechanize the hard stuff (e.g. concurrency) 5. Pass around context

Slide 313

Slide 313

Tools for The Intrepid ⚒

Slide 314

Slide 314

Tools for The Intrepid ⚒ Is this the future?

Slide 315

Slide 315

Tools for The Intrepid ⚒ Is this the future? I don’t know! p

Slide 316

Slide 316

Tools for The Intrepid ⚒ Is this the future? I don’t know! p We need to experiment with more directions

Slide 317

Slide 317

Tools for The Intrepid ⚒ Is this the future? I don’t know! p We need to experiment with more directions These are but a few options

Slide 318

Slide 318

Tools for The Intrepid ⚒ Is this the future? I don’t know! p We need to experiment with more directions These are but a few options Go explore! q

Slide 319

Slide 319

Tools for The Intrepid ⚒ Is this the future? I don’t know! p We need to experiment with more directions These are but a few options Go explore! q (And share what you find)

Slide 320

Slide 320

r Thank You, Salt Lake City! ’ https://lu.ma/distributed-systems https://fission.codes/discord github.com/expede @expede