<commit_before># -*- encoding: utf-8 -*-
import requests
import os

from flask_restful import Resource

import os, sys
sys.path.append(os.path.abspath('..'))

from api.base import BaseForAPIGW
from api_gateway.settings import BACKEND_POLITICS_BASE_URL, \
    BACKEND_POLITICS_API_KEY_QUERY


class BaseForPoliticsAPIGW(BaseForAPIGW):
    def __init__(self):
        self.base_url = BACKEND_POLITICS_BASE_URL
        self.api_key_query = BACKEND_POLITICS_API_KEY_QUERY


class BillList(BaseForPoliticsAPIGW, Resource):
    def get(self):
        resource = '/bill/'
        text = self.response_text_from_request(resource)
        return text


class BillDetail(BaseForPoliticsAPIGW, Resource):
    def get(self, id):
        resource = '/bill/%d' % id
        text = self.response_text_from_request(resource)
        return text
<commit_msg>last slash for get resource<commit_after># -*- encoding: utf-8 -*-
import requests
import os

from flask_restful import Resource

import os, sys
sys.path.append(os.path.abspath('..'))

from api.base import BaseForAPIGW
from api_gateway.settings import BACKEND_POLITICS_BASE_URL, \
    BACKEND_POLITICS_API_KEY_QUERY


class BaseForPoliticsAPIGW(BaseForAPIGW):
    def __init__(self):
        self.base_url = BACKEND_POLITICS_BASE_URL
        self.api_key_query = BACKEND_POLITICS_API_KEY_QUERY


class BillList(BaseForPoliticsAPIGW, Resource):
    def get(self):
        resource = '/bill/'
        text = self.response_text_from_request(resource)
        return text


class BillDetail(BaseForPoliticsAPIGW, Resource):
    def get(self, id):
        resource = '/bill/%d/' % id
        text = self.response_text_from_request(resource)
        return text

{'fraction_non_alphanumeric': 0.08780200353565115, 'fraction_numerical': 0.0011785503830288745, 'mean_word_length': 3.716666666666667, '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': '212096', 'n_tokens_mistral': 582, 'n_tokens_neox': 554, 'n_words': 116}