I'm fond of Vale, where you can write your own rules or grab others off github. I wish we could crowd source a grammarly clone using it. Some efforts have been made to do so, but didn't get far.
LT does have the functionality to add your own tools, and is open source and self-hostable
LanguageTool is based on a pretty powerful open-source tool, that's running in the cloud but can also be run on-prem. So, no need to reinvent the wheel.
This is super cool. How does one find rules from GitHub?
It seems like the org has a collection of rules, but I just now searched by the topic and got a bunch - https://github.com/topics/vale