[HN Gopher] Clojure's machine learning ecosystem
       ___________________________________________________________________
        
       Clojure's machine learning ecosystem
        
       Author : kmclean
       Score  : 74 points
       Date   : 2024-04-05 20:49 UTC (2 days ago)
        
 (HTM) web link (codewithkira.com)
 (TXT) w3m dump (codewithkira.com)
        
       | kleiba wrote:
       | I remember there used to be so much excitement about Clojure - it
       | certainly was the "tech du jour" for a long while, also on the HN
       | front page. It was the "...in Rust" of its day.
       | 
       | But is it just me or has it gotten awfully quiet around Clojure?
       | I mean, it is of course expected that no novelty can stay in the
       | lime light forever. But what has become of all of the excitement?
       | 
       | My impression is that Clojure failed to live up to the hype, but
       | has found its niche - but it is a rather small niche. In the end,
       | despite its attempts to differentiate itself from Lisp pitfalls,
       | it has gone the way of all Lisps: it's this cool, intellectually
       | stimulating language that in practice almost nobody uses.
       | 
       | Is that view wrong? Please feel free to correct me, and sorry if
       | this post is about Clojure in general and not specifically about
       | its machine learning ecosystem.
        
         | zelphirkalt wrote:
         | I think there is a lack of companies willing to hire for it,
         | and also a lack of qualified people to hire.
         | 
         | I would like to learn it and probably would like to work with
         | it. Only downsides I see is reliance on JVM (which is also a
         | strength) and not as good ways of recursion as other Lisps or
         | Schemes (simply call the function, duh, because it just works
         | and doesn't need extra keywords or syntax).
         | 
         | But I liked the talks and that is seems to have the functional
         | datastructured one needs, if one wants to avoid mutation.
        
         | nextos wrote:
         | I would not say it is such a small niche. There are job
         | openings here and there. It is much easier to find a Clojure
         | job than a F# or a Haskell job in my experience. This may be of
         | course different depending on your location.
         | 
         | The problem is that an entire ecosystem is more than just a new
         | language. Clojure has some really interesting libraries, but
         | the rest relies on Java. It is a good ecosystem nonetheless.
         | Julia is having the same issue. It has grown a very respectable
         | ecosystem, but it is hard to grow further to catch up with
         | Python in some fronts without massive corporate funding.
         | 
         | It is interesting to note that, at some point circa 2010, it
         | looked like Clojure could revive Lisp-Stat with Incanter. But,
         | eventually, the project declined in popularity and died.
         | Reaching mainstream relies on getting a critical mass of
         | developers at the right time and for the right domain.
        
           | actionfromafar wrote:
           | And imagine if F# had an alternative native "runtime" (i.e.
           | not married CLR and dotnet) grafted onto Fortran. Resistance
           | is futile, indeed.
        
             | Capricorn2481 wrote:
             | I don't even care about the runtime, imagine if F# devs
             | made anything that wasn't on top of Asp.net. The small
             | community coupled with breaking changes from Asp.net leads
             | to a lot of issues, and the interop story of F#/C# and
             | Clojure/Java is night and day
             | 
             | I like Asp.net, but the thing I've run into several times
             | in F# is there are breaking changes in libraries that the
             | developers of F# can't keep up with.
             | 
             | - Giraffe doesn't support swagger docs, you have to use
             | Asp.net directly, because the swagger generation isn't
             | compatible with the way Giraffe does routing
             | 
             | - Microsoft Identity uses EF core by default. The
             | EFcore.FSharp library doesn't support past .NET 6. You
             | could use your own backend, but at this point, it's easier
             | to just use C# interop
             | 
             | You could use C# for the routing of your app and F# for the
             | business logic. But then there's the C#/F# interop story.
             | Lots of little finicky type differences you have to
             | convert. Whereas using Java from Clojure feels easy and
             | natural to me.
             | 
             | And even if you use Asp.net directly and do interop
             | correctly, you're basically using C# at that point. You're
             | missing a lot of benefits of a functional language. It's
             | not worth it in my opinion, even though F# is a wonderful
             | language to me.
             | 
             | It's tough to learn the ecosystem in Clojure. But once you
             | do, I've found the "small libraries" approach much better
             | than the whole ecosystem tying itself to one web framework
             | it can't even keep up with.
        
           | bachmeier wrote:
           | > at some point circa 2010, it looked like Clojure could
           | revive Lisp-Stat with Incanter
           | 
           | I think there was hope that would happen, but Incanter simply
           | didn't have the functionality or documentation needed to
           | become a player in that space in 2010. It was a doomed effort
           | because of the (intentional) difficulty of native
           | interoperability on the JVM. They'd have had to rewrite tens
           | of millions of lines of code to realize their goals.
        
         | gorjusborg wrote:
         | I feel like Clojure did live up to the hype, but is different
         | enough that there was little chance that it would dominate in
         | the mainstream.
         | 
         | The language ecosystem reflects the smaller numbers of
         | contributors.
        
         | synthc wrote:
         | I think the language has indeed reached a stable point and
         | found its niche, which is small, but there are certainly
         | domains where Clojure is the best fit.
         | 
         | The ideas behind Clojure (functional, immutable datastructures,
         | homoiconic syntax, focus on simplicity, JVM interop) still
         | stand strong IMO.
         | 
         | There are still some exciting projects done in Clojure:
         | Electric Clojure and Rama come to mind.
        
           | yawn wrote:
           | > but there are certainly domains where Clojure is the best
           | fit
           | 
           | Honest question: what domains?
        
             | yayitswei wrote:
             | Financial services for one. Might be the Nubank influence.
        
             | dustingetz wrote:
             | clojure is everywhere in fintech - nubank, guaranteed rate,
             | kroo bank, griffin, pennymac, two sigma, dividend finance,
             | treasury prime, gravie. Other big areas are healthcare and
             | midmarket adtech. And of course startups outside of SF/NYC
             | with smaller seed rounds looking for tech advantage -
             | midwest USA, Europe/UK, Latin america
             | 
             | The further you get from silicon valley the more clojure
             | you see -- anyone with a network at FANG spent the last 10
             | years trying to break in and get that huge salary, which
             | means conforming to the recruiting process, i.e. spending
             | your time off grinding leetcode instead of learning new PLs
        
               | agumonkey wrote:
               | is clojure market still growing ? i'd love to work in a
               | clojure shop one day
        
         | lgrapenthin wrote:
         | Clojure focuses on quality over hype, at great success. Its
         | hypesters never really understood Clojure, and have long moved
         | on. So will the hypesters of Rust and other hyped languages,
         | unless they get a chance to ruin them.
        
         | cess11 wrote:
         | Aren't they having problems with new Java versions? Heard
         | someone say something along those lines a while ago, or I
         | misunderstood.
         | 
         | It also seems Rich Hickey kind of stopped doing interesting
         | talks, and some big bank bought into it and no one really likes
         | banks.
        
           | yayitswei wrote:
           | Interesting is subjective, but Rich gave a talk at the most
           | recent Clojure Conj.
        
           | lgrapenthin wrote:
           | None of this is true.
        
         | lispisok wrote:
         | I think Clojure absolutely does live up to the hype but during
         | Clojure's peak HN hype days all the people upvoting the posts
         | and commenting in the threads never actually gave Clojure a
         | proper try or a try at all. Rust on HN might be in a similar
         | boat.
        
       | BaculumMeumEst wrote:
       | For web server stuff, I still think Clojure is extremely solid.
       | But I've come to really prefer Racket for general purpose
       | programming.
       | 
       | I really like the package manager, I like that there's an IDE
       | with a visual step debugger (seriously, why do almost no lisp
       | people value this?), that it's multi paradigm, and that the
       | language continues to improve and evolve.
       | 
       | Clojure just has so many finicky or annoying things about it. The
       | design of deps.edn/clojure CLI and the lack of user friendly
       | tooling is forever frustrating. Laziness and its implications
       | being invisibly core to the language is annoying as well.
        
         | lgrapenthin wrote:
         | Most Clojure devs I know already have lots of experience and
         | can debug faster in their head, with the occasional help of
         | printing a value. But check out this cool Clojure debugger, it
         | even has time travel https://www.flow-storm.org/
         | 
         | We also have a debugger in Emacs/CIDER.
         | 
         | Your other complaints read like you haven't dug really far, or
         | they are outdated.
        
         | thih9 wrote:
         | Very true. Also, while I agree that Clojure is solid for web
         | server stuff, it wouldn't be my first choice in the context of
         | general purpose web apps or APIs.
         | 
         | The "do-it-yourself" mentality that is at the core of Clojure
         | dev culture results in a less rich library ecosystem. Not only
         | you often end up writing custom code for a generic feature, the
         | rest of your team cannot reuse their past experience but has to
         | learn your custom code and maintain it.
        
           | lgrapenthin wrote:
           | What? If anything, we have a "do-it-right" mentality :) The
           | Clojure library ecosystem is very rich with new libraries
           | coming out every week. We also reuse the rich Java library
           | ecosystem to a large degree. I'm with Clojure for 10+ years
           | and I don't "often end up writing custom code for a generic
           | feature". Its quite the opposite. Clojure is a language that
           | has hundreds of extremely well composing generic functions
           | built in, that operate on a very rich set of first class
           | immutable datastructures. Whatever Clojure you base your
           | impressions on is very different from the one I know and
           | use...
        
         | indigosun wrote:
         | > The design of deps.edn/clojure CLI and the lack of user
         | friendly tooling is forever frustrating.
         | 
         | "user friendly tooling" and ANY Scheme in the same sentence?!
         | 
         | I kid, but I always have held that Schemes feel like "tools for
         | building a programming language" (the insanity that is (car ),
         | (cdr ), (caadadr ) suddenly reveals its usefulness when you
         | write an s-expression parser) and Clojure feels like "an actual
         | programming language" with its benevolent use of brackets,
         | build tools, and library ecosystem.                   (defn my-
         | func [arg0 arg1] ..)    -- Clojure         (define (my-func
         | arg0 arg1) ..)  -- Scheme (of which Racket is one)
         | 
         | Racket seems to want to inhabit the space between those two
         | with its package system and ability to compile to an
         | executable.
         | 
         | One thing I've always liked about Racket is its refusal to
         | accept (if )s without else statements, insisting instead on
         | using (when )s.
        
         | Lyngbakr wrote:
         | While I love Clojure, I have to agree about tooling. I recently
         | started using Gleam* and was impressed at how easy it was to
         | get up and running with the CLI tool. I think this is an
         | important part of getting people to adopt a language and
         | Clojure dropped the ball a bit on this.
         | 
         | * https://gleam.run/
        
         | cmiles74 wrote:
         | The big push for people to use the Clojure CLI tool seems like
         | shooting themselves in the foot.
        
       | j13n wrote:
       | It's great to see reports of the excellent work Daniel Slutsky
       | and others are doing to make data science more straightforward
       | for everyone.
       | 
       | I'm grateful that I get to benefit from these community efforts.
        
         | bmitc wrote:
         | Good luck getting academics to adopt anything they don't know
         | about, and all they know about is Python.
        
           | sokoloff wrote:
           | Academics is much older than Python. At some point, they
           | adopted _that_.
        
           | bachmeier wrote:
           | This is a strange comment that probably reflects the sliver
           | of academics you're familiar with. Who do you think wrote and
           | continues to develop R and all those packages? There are
           | actually many types of software in use by academics.
        
           | kmclean wrote:
           | [delayed]
        
       | Lyngbakr wrote:
       | Something I really like in the Clojure data science stack that
       | isn't mentioned is Clerk* -- an interesting take on notebooks. I
       | think it's a good gateway into Clojure for those coming from a
       | Python or R background.
       | 
       | *https://clerk.vision/
        
         | kmclean wrote:
         | [delayed]
        
       ___________________________________________________________________
       (page generated 2024-04-07 23:00 UTC)