def METHOD_NAME(self, content_type_field, model_lookups):
    """
    Configure prefetch_related over generic relations
    Args:
        content_type_field(str): the field name for the ContentType
        model_lookups(dict of (list of class or class, list of str)):
            a mapping of model classes to lookups
    Returns:
        QuerySet: the new queryset with prefetching configured
    """
    qs = self._chain()
    for model_classes, lookups in model_lookups.items():
        # pylint: disable=isinstance-second-argument-not-valid-type
        model_classes = (
            model_classes
            if isinstance(model_classes, Iterable)
            else [model_classes]
        )
        for model_cls in model_classes:
            key = (content_type_field, model_cls)
            # pylint: disable=protected-access
            qs._prefetch_generic_related_lookups[key] = [
                *qs._prefetch_generic_related_lookups.get(key, []),
                *lookups,
            ]
    return qs