Live data from Hacker News

RubyLLM: A delightful Ruby way to work with AI

github.com

71–80 of 182 posts

Re: RubyLLM: A delightful Ruby way to work with AI

#72
post #7
post #2

Such a breath of fresh air compared to poor DX libraries like langchain

langchain and llamaindex are such garbage libraries: not only they never document half of the features they have, but they keep breaking their APIs from one version to the next.

I was about to mention those. I decided a while ago to build everything myself instead of relying on these libraries. We could use a PythonLLM over here because it seems like nobody cares about developer experience in the Python space.

Re: RubyLLM: A delightful Ruby way to work with AI

#73
post #57

Earlier quoted context omitted.

It's not. The method, RubyLLM.chat creates a new instance of the Chat object, as has been copied here: module RubyLLM class Error https://github.com/crmne/ruby_llm/blob/9825f4fea089b1b974961... If you're wondering about module RubyLLM. That's just how Ruby is often written. Addendum: Ruby does not require you to put the opening and closing parenthesis on a function to run that function, and it's not always put there…

> Ruby does not require you to put the opening and closing parenthesis on a function to run that function, and it's not always put there when you have zero or 1 parameter mind = blown I always liked how functionName denotes the function and functionName() calls the function, and then it denotes the result e.g. in JavaScript or in math. But just saying functionName to call a function makes the code read more like Engl…

You'd like the ML-family languages, which don't use parentheses to call functions.

Re: RubyLLM: A delightful Ruby way to work with AI

#74
post #36

Earlier quoted context omitted.

It's worth remembering that the trolls that complain about Ruby do so because they care about it. You'll often see the same names coming back on every post to angrily insist that no one is interested in Ruby ...apart from them obviously because if they didn't they would be busy trolling something else. :P

I'm not sure what your point is. I care about Ruby and want it to die because I have worked on the Gitlab codebase, which is written in Ruby. It's a bad language and it stopped me being able to understand behaviours and fix bugs. In contrast I have also worked on VSCode which is similarly huge but written in Typescript. Faaaar easier to work with, enough that I've been able to contribute a couple of medium sized feat…

IIRC Github was originally written in Ruby as well.

Now that they use something "far easier to work with", the UX gets to suffer accordingly.

I've never been in a situation where making the customer happy was synonymous with applying best practices to the tech stack or otherwise making it so everyone and their dog can contribute.

Re: RubyLLM: A delightful Ruby way to work with AI

#76
post #36

Earlier quoted context omitted.

It's worth remembering that the trolls that complain about Ruby do so because they care about it. You'll often see the same names coming back on every post to angrily insist that no one is interested in Ruby ...apart from them obviously because if they didn't they would be busy trolling something else. :P

I'm not sure what your point is. I care about Ruby and want it to die because I have worked on the Gitlab codebase, which is written in Ruby. It's a bad language and it stopped me being able to understand behaviours and fix bugs. In contrast I have also worked on VSCode which is similarly huge but written in Typescript. Faaaar easier to work with, enough that I've been able to contribute a couple of medium sized feat…

I think you are confusing the beauty and elegance of the language with the crap thatpeople write.

My experience is that the sort of folks who misuse Ruby's powerful features are the sort of idiotes who dont realise that because a thing can be done, doesn't mean that it should be done. These are the sort of people who are capable of misusing most languages.

Re: RubyLLM: A delightful Ruby way to work with AI

#77
post #42
post #5

Earlier quoted context omitted.

Matz said he designed Ruby to optimize for developer happiness, it’s just a core principle of the language since it was created

Happiness of a developer writing code can be a misery of a one having to read / debug it. I worked in ruby for a couple years around 2009 and having to deal with a code that implemented most of its logic via method missing is still one of the strongest negative memories I have about coding.

`binding.irb` and `show_source` have been magical in my Ruby debugging experience. `binding.irb` to trigger a breakpoint, and `show_source` will find the source code for a method name, even in generated code somehow.

Re: RubyLLM: A delightful Ruby way to work with AI

#78
post #36

Earlier quoted context omitted.

It's worth remembering that the trolls that complain about Ruby do so because they care about it. You'll often see the same names coming back on every post to angrily insist that no one is interested in Ruby ...apart from them obviously because if they didn't they would be busy trolling something else. :P

I'm not sure what your point is. I care about Ruby and want it to die because I have worked on the Gitlab codebase, which is written in Ruby. It's a bad language and it stopped me being able to understand behaviours and fix bugs. In contrast I have also worked on VSCode which is similarly huge but written in Typescript. Faaaar easier to work with, enough that I've been able to contribute a couple of medium sized feat…

Was it really idiomatic ruby that "stopped you from being unable to understand behaviors"? Or was it unorganized monkey patching?

I'm having a hard time thinking that ruby is difficult to understand, particularly compared to its opposites lisp, erlang, Haskell, e.g. languages that are extremely simple to the point where the burden of complexity is shoved into code space.

Re: RubyLLM: A delightful Ruby way to work with AI

#79
post #78

Earlier quoted context omitted.

I'm not sure what your point is. I care about Ruby and want it to die because I have worked on the Gitlab codebase, which is written in Ruby. It's a bad language and it stopped me being able to understand behaviours and fix bugs. In contrast I have also worked on VSCode which is similarly huge but written in Typescript. Faaaar easier to work with, enough that I've been able to contribute a couple of medium sized feat…

Was it really idiomatic ruby that "stopped you from being unable to understand behaviors"? Or was it unorganized monkey patching? I'm having a hard time thinking that ruby is difficult to understand, particularly compared to its opposites lisp, erlang, Haskell, e.g. languages that are extremely simple to the point where the burden of complexity is shoved into code space.

> Was it really idiomatic ruby that "stopped you from being unable to understand behaviors"?

I think so. I'm not an expert but the Gitlab codebase seems like fairly typical Ruby to me.

Post reply on HN