You should be using dbt instead of string manipulation for serious query building.
polars is code and can be version controlled too. Dataframes in my opinion are more elegant, and with the right backends and some lineage enhancements, could serve a much wider set of use cases than what DBT does
If you don't have a data warehouse / OLAP system you are generally not in the niche for those tools.