[D] Have their been any attempts to create a programming language specifically for machine learning?

This page summarizes the projects mentioned and recommended in the original post on /r/MachineLearning

InfluxDB – Built for High-Performance Time Series Workloads
InfluxDB 3 OSS is now GA. Transform, enrich, and act on time series data directly in the database. Automate critical tasks and eliminate the need to move data externally. Download now.
www.influxdata.com
featured
SaaSHub - Software Alternatives and Reviews
SaaSHub helps you find the best software and product alternatives
www.saashub.com
featured
  1. dex-lang

    Research language for array processing in the Haskell/ML family

    That said, there are some things that try to do this. Haskell has a port of torch called HaskTorch that includes this kind of typed tensor shapes, and calls the Z3 theorem prover on the backend to solve type inference. It can get away with this because of the LiquidHaskell compiler extension, which has refinement types capable of solving this kind of typing problem, and is already pretty mature. Dex is a research language from Google that's based on Haskell and built to explore this kind of typechecking. Really you'd want to do this in Rust, because that's where the tradeoff of speed and safety for convenience makes the most sense, but rust is just barely on the edge of having a type system capable of this. You have to get really clever with the type system to make it work at all, and there's been no sustained push from any company to develop this into a mature solution. Hopefully something better comes along soon

  2. InfluxDB

    InfluxDB – Built for High-Performance Time Series Workloads. InfluxDB 3 OSS is now GA. Transform, enrich, and act on time series data directly in the database. Automate critical tasks and eliminate the need to move data externally. Download now.

    InfluxDB logo
  3. jaxtyping

    Type annotations and runtime checking for shape and dtype of JAX/NumPy/PyTorch/etc. arrays. https://docs.kidger.site/jaxtyping/

    On static shape checking: have a look at jaxtyping, which offers compile-time shape checks for JAX/PyTorch/etc.

  4. hasktorch

    Tensors and neural networks in Haskell

    That said, there are some things that try to do this. Haskell has a port of torch called HaskTorch that includes this kind of typed tensor shapes, and calls the Z3 theorem prover on the backend to solve type inference. It can get away with this because of the LiquidHaskell compiler extension, which has refinement types capable of solving this kind of typing problem, and is already pretty mature. Dex is a research language from Google that's based on Haskell and built to explore this kind of typechecking. Really you'd want to do this in Rust, because that's where the tradeoff of speed and safety for convenience makes the most sense, but rust is just barely on the edge of having a type system capable of this. You have to get really clever with the type system to make it work at all, and there's been no sustained push from any company to develop this into a mature solution. Hopefully something better comes along soon

  5. miniF2F

    Formal to Formal Mathematics Benchmark

    That said, you *can* write down a desired type and have a system write down a ton of type annotations or generate a bunch of code to prove that the type you wrote down is satisfied by your program. There's been recent work on this in deep learning for theorem proving, such as this work which uses GPT for proving theorems in Lean, a dependently type programming language and theorem prover. A better approach though would be to combine this with an actual tree search algorithm to allow a more structured search over the space of proofs, instead of trying to generate full correct proofs in one shot. Hypertree Proof Search does this, using a variant of AlphaZero to search and fine-tune the neural net. Unfortunately it hasn't been open-sourced though, and it's pretty compute intensive, so we can't use this for actual type inference yet. But yeah there's active interest in doing this kind of thing, both as a proving ground for using RL for reasoning tasks and from mathematicians for theorem-proving.

  6. MindsDB

    AI's query engine - Platform for building AI that can learn and answer questions over large scale federated data.

    Not a programming language, but a database solution, called MindsDB. From the tab "How does MindsDB work?":

  7. einops

    Flexible and powerful tensor operations for readable and reliable code (for pytorch, jax, TF and others)

    Einops all the things! https://einops.rocks/

  8. torchtyping

    Type annotations and dynamic checking for a tensor's shape, dtype, names, etc.

    Not really an answer to your question, but there are Python packages that try to solve the problem of tensor shapes that you mentioned, e.g. https://github.com/patrick-kidger/torchtyping or https://github.com/deepmind/tensor_annotations

  9. SaaSHub

    SaaSHub - Software Alternatives and Reviews. SaaSHub helps you find the best software and product alternatives

    SaaSHub logo
  10. tensor_annotations

    Annotating tensor shapes using Python types

    Not really an answer to your question, but there are Python packages that try to solve the problem of tensor shapes that you mentioned, e.g. https://github.com/patrick-kidger/torchtyping or https://github.com/deepmind/tensor_annotations

  11. FL

    FL language specification and reference implementations

    I absolutely agree with the OP. Out of the same frustration I actually ended up designing my own language and wrote a compiler for it, and now I use it for all my ML modelling. It probably only solves my particular problems and I don't expect it to be very useful for anyone else, but here goes, in case anyone is curious: https://github.com/waveworks-ai/fl

  12. tiny-cuda-nn

    Lightning fast C++/CUDA neural network framework

    In the opposite direction from your question is a very interesting project, TinyNN all implemented as close to the metal as possible and very fast: https://github.com/NVlabs/tiny-cuda-nn

NOTE: The number of mentions on this list indicates mentions on common posts plus user suggested alternatives. Hence, a higher number means a more popular project.

Suggest a related project

Related posts

  • How to Install & Run VideoLLaMA3-7B Locally

    3 projects | dev.to | 13 Feb 2025
  • Top 5 Production-Ready Open Source AI Libraries for Engineering Teams

    7 projects | dev.to | 4 Oct 2024
  • A straight line teaches machines to learn

    2 projects | news.ycombinator.com | 8 May 2025
  • Ask HN: Freelancer? Seeking freelancer? (May 2025)

    5 projects | news.ycombinator.com | 1 May 2025
  • 💡 TinyLlama Meets LoRA: A Lightweight Approach to Emotion Classification

    4 projects | dev.to | 5 May 2025

Did you know that Python is
the 2nd most popular programming language
based on number of references?