[Haskell'23] The Evolution of Effects

  Рет қаралды 6,489

ACM SIGPLAN

ACM SIGPLAN

Күн бұрын

The Evolution of Effects (Keynote) (Video, Haskell 2023)
Nicolas Wu
(Imperial College London, UK)
Abstract: Functional programming has been celebrated for its promise of pure functions, delivering referential transparency and elegant reasoning about programs. However, real-world applications are not pure, and necessitate interaction with the outside world, introducing computational effects such as IO, state, and exceptions. The journey to harmonize these seemingly contradictory paradigms has led to a fascinating evolution of effectful programming in Haskell.
The introduction of monads as a practical programming tool was a pivotal discovery, enabling controlled sequencing of effectful computations and addressing the challenge of handling side effects in a pure language. However, it soon became evident that the lack of modularity in composing effects using monads posed a limitation to effectful programming. To overcome this obstacle, monad transformers emerged as a solution, providing a composable manner of building effects on top of one another.
More recent advancements have led to algebraic effects as an alternative framework that is easy to extend, particularly as domain-specific languages crafted to work in specific contexts. Nevertheless, these effects are not without quirks and limitations, leading to the development of higher-order effects. These higher-order effects extend the capabilities of algebraic effects, providing greater flexibility for expressing effectful computations, while also shedding light on the connection between the monad approach and the algebraic approach to effects.
This talk will survey the historical milestones that have shaped the landscape of effectful programming in Haskell, exploring the transition from monads to monad transformers and the emergence of algebraic and higher-order effects.
Article: doi.org/10.114...
ORCID: orcid.org/0000...
Video Tags: icfpws23haskellmain-key2-p, doi:10.1145/3609026.3615581, orcid:0000-0002-4161-985X
Presentation at the Haskell 2023 conference, September 8-9, 2023, icfp23.sigplan...
Sponsored by ACM SIGPLAN, www.sigplan.org/

Пікірлер: 13
@mskiptr
@mskiptr Жыл бұрын
I've actually found a use for the backwards state monad once. And I didn't even know about it at the time. For an information theory class we were tasked with implementing some compression algorithms. Since we were free to choose the language - and I was very much into Haskell at the time - I picked that. I wanted the implementation to be single-pass. I don't remember the full details, but since there were cases where the algorithm would need to look up things in its future output and that sort of thing is possible with lazy data structures I started looking around how to do that with the State type. Ultimately I arrived at Control.Monad.Tardis which provides "the time-traveling monad". It provides two states: one wired-up normally and one going backwards.
@paryoticu
@paryoticu Жыл бұрын
Terrific presentation.
@davidespinosa1910
@davidespinosa1910 3 ай бұрын
This excellent history omits Eugenio Moggi's "Abstract View of Programming Languages" notes, which he wrote in Spring 1989, while visiting John Mitchell at Stanford. These notes include a complete and detailed discussion of monad transformers, which were not understood by the rest of the community until January 1995, even though Phil Wadler cited Moggi's notes in his "Comprehending Monads" paper (1990) and "Essence of FP" paper (1992). Another important reference is Jon Beck's paper on Distributive Laws from the 1966/67 Seminar on Triples [ triples are monads !] and Categorical Homology Theory, which is available as a TAC reprint. Monads were the new hotness in 1967. 🙂
@federicoagustinsawadyoconn2716
@federicoagustinsawadyoconn2716 8 ай бұрын
It took me a week to watch the whole video 🤣, thanks for all this and excellent talk.
@statebased
@statebased Жыл бұрын
I loved the "row type" comment. I tried many years ago to write my own effect aware language compiler with row types, but got blocked by complexity. Still, this did teach me that formulating coeffects was "easier" than working with effects. Something I still believe.
@GrzegorzMilka
@GrzegorzMilka Жыл бұрын
Excellent talk
@asdfghyter
@asdfghyter Жыл бұрын
thank you! very helpful history lesson!
@anarchymatt
@anarchymatt Жыл бұрын
Imagine giving a presentation about Haskell and you get a question from Simon 🤣
@vpatryshev
@vpatryshev 9 ай бұрын
Seems like you've mixed up applicative functor (aka closed functor) and state monad.
@laughingvampire7555
@laughingvampire7555 11 ай бұрын
summary: monads were too much, maybe Lisp was onto something. Lispers: the right answer has always been Lisp
@abj136
@abj136 7 ай бұрын
I didn’t understand everything, but what I did understand does not agree with your summary.
@meme_gawd
@meme_gawd Жыл бұрын
We start in Church
@korigamik
@korigamik 11 ай бұрын
You getting married?
[Haskell'23] Effect Handlers for Programmable Inference
26:24
[PLMW@POPL'24] The Evolution of Effects
55:08
ACM SIGPLAN
Рет қаралды 428
Try this prank with your friends 😂 @karina-kola
00:18
Andrey Grechka
Рет қаралды 9 МЛН
Что-что Мурсдей говорит? 💭 #симбочка #симба #мурсдей
00:19
Правильный подход к детям
00:18
Beatrise
Рет қаралды 11 МЛН
The Death of Monads? Direct Style Algebraic Effects
17:13
Impure Pics
Рет қаралды 20 М.
"Propositions as Types" by Philip Wadler
42:43
Strange Loop Conference
Рет қаралды 131 М.
How we program multicores - Joe Armstrong
58:53
RISE SICS
Рет қаралды 72 М.
How language model post-training is done today
53:51
Interconnects AI
Рет қаралды 6 М.
Visualizing transformers and attention | Talk for TNG Big Tech Day '24
57:45
Simon Peyton Jones - Haskell is useless
6:23
bunidanoable
Рет қаралды 372 М.
Raymond Hettinger, Keynote on Concurrency, PyBay 2017
1:13:53
SF Python
Рет қаралды 154 М.
George Wilson - The Extended Functor Family
21:57
Compose Conference
Рет қаралды 16 М.
"Building Haskell Programs with Fused Effects" by Patrick Thomson
40:44
Strange Loop Conference
Рет қаралды 18 М.
Laziness in Haskell - Part 1: Prologue
14:47
Tweag
Рет қаралды 9 М.