WeSearch

C++ Vs Rust: Which is better for writing AI/ML code with LLMs

Richard Palethorpe· ·7 min read · 0 reactions · 0 comments · 27 views
#rust#which#better#writing#code
TL;DR · WeSearch summary

We do many conversions of AI models from the reference PyTorch implementation to GGML and C++. The reason is GGML/C++ produces a relatively tiny package we can run almost anywhere. The performance usually matches or exceeds PyTorch with a fraction of the dependencies.

Key facts
About this source

Hacker News (AI / LLM) files mainly under ai. We currently carry 2,369 of its stories.

Original article
Richiejp · Richard Palethorpe
Read full at Richiejp →
Opening excerpt (first ~120 words) tap to expand

We do many conversions of AI models from the reference PyTorch implementation to GGML and C++. The reason is GGML/C++ produces a relatively tiny package we can run almost anywhere. The performance usually matches or exceeds PyTorch with a fraction of the dependencies. Personally I despise C++; can’t stand it. I don’t have to write it anymore though, LLMs do it. I sit above a layer of abstraction and only descend into the code to avoid worst case scenarios in much the same way I would randomly go read the code for a library I depended on before AI. Someone asked if we had considered doing these ports in Rust. I am well aware of Rust, got excited about it in the past, but had not seriously considered it because GGML is written in C++.

Excerpt limited to ~120 words for fair-use compliance. The full article is at Richiejp.

Anonymous · no account needed
Share 𝕏 Facebook Reddit LinkedIn Threads WhatsApp Bluesky Mastodon Email

Discussion

0 comments

More from Richiejp