Do you know where Haskell is used?
Hello everyone! We want to continue the series of posts on “where these strange programming languages of yours are used”. Last time we talked about Lisp, and today we will continue talking about functional languages and turn our attention to Haskell. It is the main development language in Typeable and, of course, we couldn’t get past such a topic.
Haskell is a pure functional general-purpose programming language. Its distinctive features include strong static typing, lazy evaluation, algebraic data types, and a solid theoretical foundation. It is a relatively young language, it appeared in 1990, but has already had a significant impact on other languages and on the theory of programming languages in general.
We recently had a post about useful utilities written in Haskell, but they are all aimed at being used by tech-savvy people. Today we will give examples of applied use from various industrial areas.
What and where is written in Haskell?
Perhaps the most googled and well-known example of Haskell being used in large companies is spam filters in
Eaton – a company producing electrical and hydraulic equipment, components for the aviation and automotive industries. The company uses Haskell for day-to-day tasks like scripting, hardware simulation, tools for remotely controlling vehicle systems, etc. But the most interesting thing is that they entrusted the control of the hydraulics to the code written in DSL Atom, which they also implemented in Haskell. Atom is intended for the development of hard real-time systems and allows you to declaratively describe the rules for changing system states. At compile time, tasks are scheduled, so the resulting code has deterministic execution time and constant memory consumption. This greatly simplifies the verification of the received code and, in general, increases the security of the system, which, of course, is very important for this subject area. You can read more about all this at slides and in Atom repositories…
Now let’s move to a completely different area, namely the world of music. Service Chordify allows you to convert music from YouTube, soundCloud, etc. into chords so you can learn to play your favorite songs yourself. Haskell is used for the most part directly in the recognition process, for this developers use the library Harmtracewhich analyzes the sequences of musical harmonics.
Kaspersky Lab develops its own secure operating system KasperskyOS for Internet-connected embedded systems. Of course, this OS has special requirements for reliability and cybersecurity. The KasperskyOS team actively uses Haskell for the security compiler and the creation of auxiliary development tools. The security configuration is described in a special DSL, which is then compiled to C. As you can see, Haskell has once again proven its worth when it comes to security.
Part of internal tools for automotive development in Tesla written in Haskell, as evidenced by the periodic appearance vacancies… As far as I can understand from the job descriptions, Haskell is used for an intermediate high-level representation of internal systems from which C code, documentation, and possibly something else is generated.
BIOCAD Is one of the largest biotechnology companies based in Russia. The company carries out a full cycle of creating medicines, up to mass production and marketing. BIOCAD develops its own internal services for processing and storing data during drug development. The backend of these services is written in Haskell, it uses the Neo4j graph database, for which the company has developed and released a driver to the public. Hasbolt…
Haskell has carved its own niche in development blockchains and cryptocurrencies… Probably most of the Haskell jobs I have come across have been in this area. Of the most famous, perhaps it is worth mentioning Cardano… The main reason for Haskell’s popularity in this area is security again! You can read more about this in post FPComplete…
If blockchains seem to be too boring, serious or “inhuman” area, then I will tell you about Co – Star – astrological app for personalized horoscopes and Mercury retrograde. Their backend is written in Haskell, and the developers described on the application website why they chose this language: https://www.costarastrology.com/why-haskell/
Backend messenger Wire written in Haskell, and the server code is publicly available in company repositories, and detailed documentation has been written for it.
American Museum of Natural History uses Haskell to study phylogenetic graphs reflecting evolutionary relationships between different species. The code of this project is also available on github…
The list of examples for the post was made to show the variety of applications, and of course there is a lot left behind. More information on which companies and industries use Haskell can be found here:
We ourselves at Typeable use Haskell to develop projects in healthcare, tourism, fintech, and more.
We would be glad to receive your additions, stories about work experience or writing pet projects in Haskell!
You May Also Like:
Do you know where Lisp is used now?
Strengths of functional programming
How has functional programming contributed to modern languages?
7 useful tools in Haskell