<commit_before>import warnings

from analyzere.base_resources import (
    DataResource,
    EmbeddedResource,
    MetricsResource,
    Resource,
    load_reference,
    to_dict,
    convert_to_analyzere_object, NestedResource)
from analyzere.requestor import request


# Shared embedded resources

class MonetaryUnit(EmbeddedResource):
    def __init__(self, value, currency, **kwargs):
        super(MonetaryUnit, self).__init__(value=value, currency=currency,
                                           **kwargs)


# Event catalogs

class EventCatalog(DataResource):
    def profile(self):
        path = '%s/profile' % self._get_path(self.id)
        resp = request('get', path)
        return convert_to_analyzere_object(resp)


# Exchange rate tables

class ExchangeRateTable(DataResource):
    pass


class ExchangeRateSelectionRule(EmbeddedResource):
    pass


class ExchangeRateProfile(Resource):
    pass<commit_msg>method for the currencies added to the ExchangeRateTable class<commit_after>import warnings

from analyzere.base_resources import (
    DataResource,
    EmbeddedResource,
    MetricsResource,
    Resource,
    load_reference,
    to_dict,
    convert_to_analyzere_object, NestedResource)
from analyzere.requestor import request


# Shared embedded resources

class MonetaryUnit(EmbeddedResource):
    def __init__(self, value, currency, **kwargs):
        super(MonetaryUnit, self).__init__(value=value, currency=currency,
                                           **kwargs)


# Event catalogs

class EventCatalog(DataResource):
    def profile(self):
        path = '%s/profile' % self._get_path(self.id)
        resp = request('get', path)
        return convert_to_analyzere_object(resp)


# Exchange rate tables

class ExchangeRateTable(DataResource):
    def currencies(self):
        path = '%s/currencies' % self._get_path(self.id)
        resp = request('get', path)
        # response will be an embedded object with currencies list
        # each element of the currencies list is again an embedded object with the structure like:
        #   {
        #       "code": "CAD"
        #   }
        # I think we do not need to convert it to the more concise list, because we can extend the structure
        # in the future like
        #   {
        #       "code": "CAD",
        #       "rate": 1.32
        #   }
        return convert_to_analyzere_object(resp)


class ExchangeRateSelectionRule(EmbeddedResource):
    pass


class ExchangeRateProfile(Resource):
    pass
{'fraction_non_alphanumeric': 0.07921974522292993, 'fraction_numerical': 0.0011942675159235668, 'mean_word_length': 2.902173913043478, 'pattern_counts': {'":': 3, '<': 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': 4, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '1421257', 'n_tokens_mistral': 707, 'n_tokens_neox': 670, 'n_words': 184}