Sign in

Jose Farias

@jose.omg.lol
283 followers 221 following 42 posts

AI, Rails, and React at GrowthXAI. Prev 37signals, Harvest. Blog jose.omg.lol

PostsRepliesMedia
Jose Farias @jose.omg.lol · 05/10/2025
Working on adding Replicate support to RubyLLM github.com/crmne/ruby_l...
github.com
Add Replicate provider by josefarias · Pull Request #435 · crmne/ruby_llm
What this does This PR adds Replicate as a provider. Replicate may stand out from other providers in several areas: They don’t expose pricing via API (that I can tell). I’ve opted for not includin...
030
Jose Farias @jose.omg.lol · 05/07/2025
github.com/josefarias/h...
github.com
RailsConf 2025 ideas — Attendees start here! · Issue #254 · josefarias/hotwire_combobox
Welcome to our RailsConf 2025 Hack Space! Join me in contributing to HotwireCombobox at RailsConf day 2 (July 9th)! Location: Banquet Hall Hack Space Station: Teal Station Schedule Time: July 9th, ...
000
Jose Farias @jose.omg.lol · 05/07/2025
If you’re going to RailsConf next week and are interested in pairing on HotwireCombobox during day 2’s Hack Spaces—I’ve written up some ideas for what issues we could work on. We can also work on whatever else, or just chat. Hit me up at the teal station from 10:00AM ~ 12:40PM.
Screenshot of the GH issue linked in the thread. A list of ideas we could work on.
130
Jose Farias @jose.omg.lol · 18/04/2025
Yeah I don’t mind this syntax 👌
010
Jose Farias @jose.omg.lol · 17/04/2025
Yeah I guess that also works! Too verbose for my taste though 😄. You’re not alone—someone else brought it up on _the other site_.
140
Jose Farias @jose.omg.lol · 17/04/2025
re: `protected` methods—there’s usually so few of them you can see the access modifier immediately anyway. But I’d consider them an edge case.
010
Jose Farias @jose.omg.lol · 17/04/2025
Indenting private methods tells you what the intended access policy is without having to orient yourself inside the class. Specially useful when reviewing diffs and you’re not even shown the full context by default. This is why it’s my preference in Ruby.
260
Jose Farias @jose.omg.lol · 10/03/2025
Oh no! Does it happen upon submitting the form, or when attempting to confirm the subscription?
100
Jose Farias @jose.omg.lol · 10/03/2025
Thanks for reading! Phoenix contexts are interesting. While they make it obvious where to put things, my opinion is in the end they’re unnecessary overhead in an object oriented codebase. They’re well suited for FP though. Might write more about that in the future. Good topic!
010
Jose Farias @jose.omg.lol · 10/03/2025
Mil gracias Julia! 😄
010
Jose Farias @jose.omg.lol · 10/03/2025
Thanks Stephan! Yeah I’ll probably add that soon. This is the reason I’ve avoided it: bsky.app/profile/jose...
010
Jose Farias @jose.omg.lol · 10/03/2025
Wild! I actually did not know about this. And here I am reinventing the wheel. Thanks for sharing!
110
Jose Farias @jose.omg.lol · 10/03/2025
I’ve just added a mailing list form if you’re interested! Check out part 2 (just posted), it’s at the bottom of the post. Thanks for reading!
020
Jose Farias @jose.omg.lol · 10/03/2025
Right! I’d actually suggest putting it in models (even if more than one) over using service objects. But we’ll get to that further in the series. I just published what that might look like in part 2. Thanks for reading!
010
Jose Farias @jose.omg.lol · 10/03/2025
RSS is a great idea, thanks Rosa! I just wired up buttondown for a mailing list. Check out part 2 (just posted) if you’d like to sign up 😄 The reason I’ve avoided RSS/email before is I don’t want to make sure things look good there before posting 😅. But I might just link to my site instead.
120
Jose Farias @jose.omg.lol · 10/03/2025
Of course! That’s why I tried the service initially. No worries about what happened way back when. It was years ago. Just wired things up again and it seems to be working beautifully. Appreciate you offering!
020
Jose Farias @jose.omg.lol · 10/03/2025
Here’s post 2 in my Object-Oriented Rails series. Post 1 argued business logic doesn’t belong in active jobs. But it lacked some code examples. Now we put pen to paper explaining how to move the logic into the model and out of your job. Also, email newsletter is live! jose.omg.lol/posts/just-w...
jose.omg.lol
Just Write English
How to move logic out of your jobs and into your domain model.
3182
Jose Farias @jose.omg.lol · 09/03/2025
Nice!
000
Jose Farias @jose.omg.lol · 09/03/2025
I did try buttondown once but got turned off from it when my single test email landed in spam. I’ll give it another chance though. I probably just caught a temporary bug. Nbd. Really just looking for something that’ll let me turn off open rate tracking and won’t sell my subscriber’s data.
220
Jose Farias @jose.omg.lol · 09/03/2025
Thanks a bunch Zack!
010
Jose Farias @jose.omg.lol · 09/03/2025
I really need to get on that 😅. Really I’m just avoiding having to choose a privacy-conscious mailing list provider. I don’t know of any offhand and researching seems like super dull work.
120
Jose Farias @jose.omg.lol · 09/03/2025
Right! Choosing between those `_at` columns and a model would be a great topic for one of these. Same goes for the many-to-many relationships. I’ll keep those in mind!
030
Jose Farias @jose.omg.lol · 08/03/2025
I’m kicking off a series of blog posts called "object-oriented Rails". First off — why business logic doesn’t belong in active jobs. Let me know what you think! jose.omg.lol/posts/its-no...
jose.omg.lol
It’s none of their business
Why business logic doesn’t belong in active jobs.
4253
Jose Farias @jose.omg.lol · 08/03/2025
Thanks Chris! I’m really excited about this 💪
010
Jose Farias @jose.omg.lol · 08/03/2025
After 2.5 years at 37signals I’m moving on to a new role as a Senior Software Engineer at Harvest. I start next week! 😄
3240
Jose Farias @jose.omg.lol · 25/12/2024
Merry Christmas Chris!
010
Jose Farias @jose.omg.lol · 15/12/2024
It did! 😄
120
Jose Farias @jose.omg.lol · 15/12/2024
Guess it was necessary lol
Two commit messages.
First one reads: "Unnecessary include". CI failed.
Second one reverts the first one. CI passes.
1270
Jose Farias @jose.omg.lol · 12/12/2024
Yes! I think a lambda would’ve been fine, too.
010
Jose Farias @jose.omg.lol · 12/12/2024
I think that important condition is fine to be implied as long as the context is at-hand (rarely is). That said, I don’t feel particularly strong about the name of that method. I wouldn’t insist on it. Mostly trying to illustrate the main point that code can be context-aware and thus simpler.
000
Jose Farias @jose.omg.lol · 11/12/2024
Totally! I have a similar history with them. A sharp tool for sure. But when it’s the one for the job, it’s great. Easy to misuse though, was just talking about this with @avi.nyc
000
Jose Farias @jose.omg.lol · 11/12/2024
I’d encourage you (or anyone reading) to implement side-by-side and compare! 😄 Consider the conditional is coupled to the active record’s lifecycle – by design of ActiveModel::Dirty, not anything to do with our code.
010
Jose Farias @jose.omg.lol · 11/12/2024
Oh that’s pretty far from what I’d recommend tbh. But that’s alright! In this case the context is readily available at a glance, which means the code can be context-aware and thus simple. I’d suggest waiting until it’s actually complex before complicating further.
100
Jose Farias @jose.omg.lol · 11/12/2024
Of course! Ideally I wouldn’t be changing code I don’t understand, but I get that’s not always possible due to time constraints. In that case it’s not only the inherent complexity, but my own lack of context that will likely complicate my code. That’s a price to weigh and pay!
100
Jose Farias @jose.omg.lol · 11/12/2024
Read more: jose.omg.lol/posts/code-c...
jose.omg.lol
Code Can Be Context-Aware
Because programmers can (and should be) context-aware
141
Jose Farias @jose.omg.lol · 11/12/2024
Wrote some words about this code snippet _Code can be context-aware — because programmers can (and should be) context-aware_
class Project < ApplicationRecord
  after_save_commit :grant_access_to_everyone

  private
    def grant_access_to_everyone
      accesses.grant_to(account.users) if all_access_previously_changed?(to: true)
    end
end
491
Jose Farias @jose.omg.lol · 26/11/2024
Bluesky is probably the best use I've given my omg lol subdomain
160
Jose Farias @jose.omg.lol · 17/11/2024
Really enjoying this setup which lets me route LLM prompts to different models by flipping a switch. Makes it easy to experiment.
use_o1: &use_o1
  provider: OpenAI
  model: o1-preview

use_claude_sonnet: &use_claude_sonnet
  provider: Anthropic
  model: claude-3-5-sonnet

determine_a_b_c:
  <<: *use_o1
  messages: # ...

write_x_y_z:
  <<: *use_claude_sonnet
  system: # ...
  messages: # ...
030
Jose Farias @jose.omg.lol · 13/11/2024
Ha! Just replied 😂
010
Jose Farias @jose.omg.lol · 13/11/2024
Started at 1, leveled up to 4
ActionService.call(...)
ActionPerformer.perform_now(...)
ThingDoer.new(...).do_thing
Thing.new(...).act
160
Jose Farias @jose.omg.lol · 12/11/2024
Been building a ton for AI lately. It still involves lots of traditional coding. Architecture, modeling, provisioning, monitoring, it's almost like building a regular app — with many more network calls.
031
Jose Farias @jose.omg.lol · 04/11/2024
That looks great Andrea! I’m glad you’re enjoying it! Hoping to make a new release soon 😄
010