1👍
✅
The following should give you the answer:
from django.db import Avg
Punctuation.objects.values('pelis_id').annotate(average=Avg('valor'))
Source:stackexchange.com