You're correct that custom rules can only be implemented as plugins. SQLFluff uses pluggy as it's plugin engine, which relies on the python packaging index to discover installed plugins. You don't need to publish your plugin publicly for this to work, you only need to be able to install it locally (i.e. pip install -e /path/to/my/local/plugin). For the necessary structure your plugin has to have there's an example plugin in the SQLFluff GitHub repository.