I just discovered Nim a few months ago and holy shit, where has this language been my entire life? I've been doing AI stuff in Python for years like everyone else, dealing with the constant pain of dependency hell, slow debugging cycles, and mysterious performance bottlenecks, and then I find Nim and it's like someone handed me a superpower. Python feels like you're driving a beat-up Honda while Nim is a damn Formula 1 car - it compiles to native machine code so your neural networks actually run fast instead of crawling through interpreted bytecode, the syntax is clean and readable like Python but without all the runtime surprises, memory management is automatic but predictable so you're not dealing with garbage collection pauses during training, the type system catches your tensor dimension mismatches at compile time instead of 3 hours into a training run, there's no pip dependency nightmare because everything compiles into a single binary that just works, operator overloading actually makes sense so your math code looks like math instead of a bunch of nested function calls, and the best part is you can understand exactly what your code is doing because there's no hidden NumPy black magic - when you write a matrix multiplication you can see the actual loops and know the performance characteristics. The Python AI ecosystem has everyone convinced that slow development cycles and runtime surprises are just the cost of doing business, but Nim proves that's complete bullshit - you can have both the productivity of a high-level language and the performance of C, and once you experience writing neural networks that compile to optimized machine code and never break because of dependency conflicts, going back to Python feels like programming with one hand tied behind your back.
I'm doing my masters in cybersecurity right now but planning a PhD focused on AI research, and I've made a decision that might sound crazy - everything AI-related in my PhD will be built in Nim, not Python. Yeah I know Nim basically has no AI libraries and the ecosystem is tiny compared to Python's massive ML toolkit, but honestly that's exactly why this is the right move. Everyone in academia just defaults to Python and PyTorch without questioning if there's a better way, meanwhile I'm sitting here with Nim that compiles to blazing fast native code, has compile-time safety that catches bugs before they waste weeks of training time, produces single binary deployments with zero dependency nightmares, and lets me write mathematical operations that actually look like math instead of buried function calls. The lack of existing libraries isn't a problem, it's an opportunity - I'll build exactly what I need from scratch and actually understand every line of code instead of hoping some black box library works correctly. By the time I finish my PhD I'll have contributed real AI tools to the Nim ecosystem while everyone else is still dealing with Python's runtime surprises and performance bottlenecks. Academic research should be about pushing boundaries and trying new approaches, not just using whatever everyone else uses because it's popular. Nim gives me performance, safety, and clarity that Python can't match, and if I have to build the tools myself to prove it works for serious AI research, then that's exactly what I'm going to do.
Your plan sounds like a lot of fun, and I wish you the best of luck! If you end up being able to go through with it, make sure to post your progress on the forum, and you will probably get good feedback.
You may want to first have a look at:
Also, to give you some advice on the "PhD side" of the idea too:
while you build something bigger
It's fantastic to see this kind of enthusiasm so good luck!
My main advice would be to at least have a deep look at Arraymancer. The AI/ML parts of it are not very complete, but the tensor part is really good (IMHO). Perhaps you could focus on completing what Arraymancer is missing. That might be the most impactful way to contribute to the nim ecosystem if that is one of your goals.
This guy Nims! ;)
Seriously, you got it- you totally got the value of Nim. And you made a very articulate description of it as well- I'm going to quote liberally from it ;)