<commit_before>from core.models import Size
from rest_framework import serializers
from .provider_summary_serializer import ProviderSummarySerializer


class SizeSerializer(serializers.ModelSerializer):
    provider = ProviderSummarySerializer()

    class Meta:
        model = Size
        fields = ('id', 'alias', 'name', 'cpu', 'disk', 'mem', 'active', 'provider', 'start_date', 'end_date')<commit_msg>hyperlink size serializer<commit_after>from core.models import Size
from rest_framework import serializers
from .provider_summary_serializer import ProviderSummarySerializer


class SizeSerializer(serializers.HyperlinkedModelSerializer):
    provider = ProviderSummarySerializer()

    class Meta:
        model = Size
        view_name = 'api_v2:size-detail'
        fields = ('id', 'url', 'alias', 'name', 'cpu', 'disk', 'mem', 'active', 'provider', 'start_date', 'end_date')
{'fraction_non_alphanumeric': 0.11325028312570781, 'fraction_numerical': 0.0011325028312570782, 'mean_word_length': 5.225352112676056, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 3, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '5200222', 'n_tokens_mistral': 241, 'n_tokens_neox': 231, 'n_words': 66}