grammatical-error-correctio.../backend/translation/serializers.py
Wojciech Jarmosz b586f3c7ed GEC-backend
2022-06-01 10:19:32 +02:00

7 lines
263 B
Python

from rest_framework import serializers
LANGUAGE_CHOICES = [('pl', 'Polish')]
class TranslationSerializer(serializers.Serializer):
text = serializers.CharField(max_length=20000, min_length = 1)
language = serializers.ChoiceField(choices=LANGUAGE_CHOICES)