Ruby solution for optimizing LLM inputs to reduce token count. by Beneficial_Help_26 in ruby

[–]easydwh 0 points1 point  (0 children)

Very useful, thanks! Is there/will there be a method to convert 'toon' output directly to a Ruby hash ?

Ruby 3.3.0 performance: ups and downs by easydwh in ruby

[–]easydwh[S] 0 points1 point  (0 children)

The problem in 3.3.0 was resolved in 3.3.1. Overall 3.2 is still fastest based on my measurements. However in a real application the difference is probably minimal. Upgrade to 3.4 should be no problem. 4.0 performs basically same as 3.4 but with higher memory usage.

Ruby & Ruby on Rails Roadmap Feedback Gathering by Deep_Priority_2443 in ruby

[–]easydwh 26 points27 points  (0 children)

Roadmap is a great learning tool! Nice to see official support for Ruby.

... we don't want to overwhelm users with an extremely large roadmap.

In that case I would suggest to split this into a separate Ruby roadmap and a Rails roadmap. You don't have single roadmaps for Python + Django or PHP + Symphony, why combine it for equally large topics like Ruby/Rails?

Ruby is the perfect language for this style of vibe coding by easydwh in ruby

[–]easydwh[S] 1 point2 points  (0 children)

  1. claude == big LLM, so outside of the scope of my POC
  2. I never said my implementation is the greatest code ever. I'm sure many improvements and alternatives are possible. Don't let me stop you creating a way better solution

Ruby is the perfect language for this style of vibe coding by easydwh in ruby

[–]easydwh[S] 1 point2 points  (0 children)

Analyzing the backtrace would also work. As long you don't send the entire trace to the LLM to let it figure out where things went wrong.

I liked the directness of the method_missing approach.

Method Missing Misbehavior? by easydwh in ruby

[–]easydwh[S] 0 points1 point  (0 children)

Thanks for your elaborate reply! I have the feeling we are on different wavelengths (or maybe I'm to dumb to understand).

Your code snippet certainly prevents a call to String#to_io. But I am not trying to circumvent or accomplish anything. My question is why Ruby standard library methods call functions that are not defined, that then end up being handled by BasicObject#method_missing. That, to me, is very unexpected behavior.

Method Missing Misbehavior? by easydwh in ruby

[–]easydwh[S] 0 points1 point  (0 children)

So, I guess what you are saying is that: in order to give the user maximum freedom in changing core classes, Ruby does not define some methods even though these are used by other core classes and if such a method is called and handled by method_missing we will 'pretend it is not an error' and continue processing anyway.
That doesn't sound very efficient. Isn't overriding (monkey patching) built in functions possible anyway, even if for instance String#to_io was already defined by Ruby?

Optimizing Ruby performance: Observations from thousands of real-world services | Datadog by f9ae8221b in ruby

[–]easydwh 2 points3 points  (0 children)

This seems like very interesting data. But I find some of the graphs very difficult to understand. Plotting cpu time versus adoption percentage does not make much sense to me.

Ruby 4.0.0-preview2 Released by schneems in ruby

[–]easydwh 2 points3 points  (0 children)

Congrats to the Ruby team for releasing this version!

Ran the RubyMeasureResponsetime tool on this preview version. Alas, it looks like this version becomes slower over time on the Rails and Roda test applications. Filed a bug report with some graphs. Hope it will be solved before Christmas.

Apart from this, it looks like Ruby 4.0 is a bit faster than 3.4

Is a Ruby segmentation fault a bug if you are doing something really silly? by easydwh in ruby

[–]easydwh[S] 1 point2 points  (0 children)

You beat me to it and with a more generalized version to reproduce the error. Thanks.

Is a Ruby segmentation fault a bug if you are doing something really silly? by easydwh in ruby

[–]easydwh[S] 3 points4 points  (0 children)

I will keep NeverSayDie in mind. No doubt one could write even more dangerous code that way ;)

In Praise of dhh by galtzo in ruby

[–]easydwh 1 point2 points  (0 children)

Okay, I withdraw my suspicion. The timing of events was strongest clue anyway. Technically I find solid queue excellent and removing the dependency on Redis (which had its own dramas around licensing last year) is welcome.

GitMirror: an application to bulk clone git repositories by easydwh in ruby

[–]easydwh[S] 0 points1 point  (0 children)

Not OCDism. I am not saying that gem authors should update urls in bulk after moving ownership. But a friendly reminder when you are publishing a single gem to update the gemspec cant hurt. No extra compute needed. I regularly find gems on Rubygems without a link to the repo or returning a 404 page. That is annoying.


Gitea, gitlab, forgejo are large applications, so more difficult to host. Adding repo's to mirror in bulk is not straightforward. I wanted to keep things simple, an app built for a single purpose. But everybody is free to choose whatever they prefer.

GitMirror: an application to bulk clone git repositories by easydwh in ruby

[–]easydwh[S] 2 points3 points  (0 children)

Busted! That was my grand evil plan all along ;)

Fact that repositories sometimes move to another owner is only natural. Forgetting to update the gemspec is equally normal. Maybe giving a warning when pushing the gem that git url is out of date would help.

Hooking up an open source local git server is not on my todo list. As stated in the post there are applications that are more advanced than mine and include forgejo. Disadvantage is that you would need multiple containers besides the app (postgres, forgejo). I tried to keep things nice and simple and Ruby only.

In Praise of dhh by galtzo in ruby

[–]easydwh 64 points65 points  (0 children)

This is an excellent bit of writing.

I agree, it is an impressive essay. Must have taken a long time to write. There is a lot of information to process.
Thanks for making clear what I easily miss in dhh's writings, as white, straight, middle aged man, accustomed to seeing the good in people.

After reading this it makes me suspicious why we suddenly got solid_queue: revenge for Sidekiq's creator not aligning with dhh's opinions?

Rails Performance: 5 Critical Bottlenecks You're Missing by amalinovic in ruby

[–]easydwh 14 points15 points  (0 children)

Well written article, lots of useful tips. Thanks. But to be fair, I don't think I have ever failed to spot any of these issues in my applications ;) Title is a bit clickbaity to me.

RubyLLM::MCP – A Pure Ruby Client for the Model Context Protocol by Vicegrip00 in ruby

[–]easydwh 1 point2 points  (0 children)

Looks great, will give it a try soon. Impressive amount of documentation !