Skip to content
0:00 / 0:00

#free-monad#cats#monads

Free Monad in Scala

Rock the JVM

27K subscribers • 59 videos on Hallway

YouTube
  • Recommended by 1 person: 1 in engineering communities.

Advanced. Deep dive for people who know the field.

9.6K views4 years ago1 recommendation

Programming languagesSoftware designScalaFunctional programming

An explanation of the Free Monad abstraction and how to implement a simple version from scratch in Scala.

Written form: blog.rockthejvm.com/free-monad/ In this video, we'll talk about the Free Monad, an abstraction that allows us to write better, more modularized, more easily maintainable and more testable Scala code. We'll discuss about "normal" monads, the structure of the Free monad, an example of situation where the Free monad is particularly useful, and we're going to implement a simple version of the Free monad from scratch. Free monads are part of the cats-free library (and others). If you want to learn more about Cats, we teach this at Rock the JVM: Cats: rockthejvm.com/p/cats Follow Rock the JVM on: LinkedIn: linkedin.com/company/rockthejvm Twitter: twitter.com/rockthejvm Blog: rockthejvm.com/blog ------------------------------------------------------------------------- Home: rockthejvm.com -------------------------------------------------------------------------

Why it's here

1 person recommends this

What people say. Recommended as a clear explanation and implementation guide for Free Monads in Scala.

Moments people linked to

u/danielciocirlanin r/scala • Recommends

Free Monads in Scala

u/rafafrdzin r/scala • Mentions

Free Monad vs Tagless Final Hi everyone! I've been reading about free monads and watching some videos like this two: 1 - Free Monads—Paweł Szulc - [video 2 - Free Monad in Scala - [video And I was asking, why don't use tagless final to work with the description of the logic (algebra) and its evaluation by just switching the tag instead of using Free Monad? I don't know if there is a trivial answer just like 'To use the way you feel more comfortable' or maybe there is a good reason to do that. Thanks so much! :)

u/scalausrin r/scala • Mentions

How to implement generic FlatMap in Free Monad? I read this article - Free Monad in Scala, and its link to this video, where it implements FlatMap with natural transformation. My question: if I want to implement a generic version of Free Monad (it's generic enough a little bit like ZIO, Cats but it doesn't need to be production grade), is this the right direction? I have this question because I want to play with this concept by implementing it myself. Then I started to search online, finding an explanation like this. I understand the point (though not thoroughly understand everything regarding this term I suppose); however, when checking the examples on the internet, most of them use \`List\A\ => O…
8View on Reddit