def METHOD_NAME(changed_translation_pks, project, locale):
    """Update translation memory for a list of translations."""
    memory_entries = [
        TranslationMemoryEntry(
            source=t.tm_source,
            target=t.tm_target,
            locale=locale,
            entity=t.entity,
            translation=t,
            project=project,
        )
        for t in (
            Translation.objects.filter(pk__in=changed_translation_pks).prefetch_related(
                "entity__resource"
            )
        )
    ]
    TranslationMemoryEntry.objects.bulk_create(memory_entries)