DISTINCT does not apply to ORM.
But you could define a ModelSQL with a table_query which is based on a DISTINCT query. This way it will be integrated with the ORM.
Otherwise, you have to run a SQL query, there is no issue to use them when it is needed.