<commit_before>import unittest
from src.services.helpers import *
from werkzeug.datastructures import ImmutableMultiDict


class SearchHelpersTest(unittest.TestCase):
    def _query_builder(self, query, fields):
        custom_boosts = {
            "id": 120,
            "symbol": 120,
            "synonyms": 120,
            "name": 200,
            "name.symbol": 300,
            "gene_biological_process.symbol": 120,
            "gene_molecular_function.symbol": 120,
            "gene_cellular_component.symbol": 120
        }

        search_fields = fields + [
            "name.symbol",
            "gene_biological_process.symbol",
            "gene_molecular_function.symbol",
            "gene_cellular_component.symbol"
        ]

        queries = []
        for field in search_fields:
            match = {}
            match[field] = {
                'query': query,
                'boost': custom_boosts.get(field, 50)
            }

            partial_match = {}<commit_msg>Updated test to reflect new custom boosts<commit_after>import unittest
from src.services.helpers import *
from werkzeug.datastructures import ImmutableMultiDict


class SearchHelpersTest(unittest.TestCase):
    def _query_builder(self, query, fields):
        custom_boosts = {
            "primaryId": 400,
            "symbol": 500,
            "symbol.raw": 1000,
            "synonyms": 120,
            "synonyms.raw": 200,
            "name": 100,
            "name.symbol": 200,
            "gene_biological_process.symbol": 50,
            "gene_molecular_function.symbol": 50,
            "gene_cellular_component.symbol": 50
        }

        search_fields = fields + [
            "name.symbol",
            "gene_biological_process.symbol",
            "gene_molecular_function.symbol",
            "gene_cellular_component.symbol"
        ]

        queries = []
        for field in search_fields:
            match = {}
            match[field] = {
                'query': query,
                'boost': custom_boosts.get(field, 50)
            }

            partial_match = {}
{'fraction_non_alphanumeric': 0.09928400954653938, 'fraction_numerical': 0.02673031026252983, 'mean_word_length': 1.761528326745718, 'pattern_counts': {'":': 18, '<': 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': '4127661', 'n_tokens_mistral': 647, 'n_tokens_neox': 560, 'n_words': 112}