For these systems there are pre-filters, post-filters, and also RAG.
Pre-filters halt queries that are known to produce an undesired response, related to copyright content, or things along those lines.
Post-filters act upon the generated response. For example they operate content safety...