


from maths.prime_check import is_prime






def   _lowercase(					__a				:						int     ):
							if not isinstance(__a    ,     __a     ):
														a__      =f"""Input value of [number={number}] must be an integer"""
														raise TypeError(__a     )
							if is_prime(__a     ) and is_prime(number + 2     ):
														return number + 2
							else:
														return -1


if __name__ == "__main__":
	import doctest

	doctest.testmod()





import unittest

from transformers import is_torch_available
from transformers.testing_utils import require_sentencepiece, require_tokenizers, require_torch, slow, torch_device


if is_torch_available():
	from transformers import AutoModelForSeqaSeqLM, AutoTokenizer




@require_torch
@require_sentencepiece
@require_tokenizers
class       lowercase_					(unittest.TestCase   ):





				@slow
				def 						__UpperCamelCase    (				self)  -> Optional[int]:
											a__      =AutoModelForSeqaSeqLM.from_pretrained('google/mt5-small'       ,  return_dict=lowercase_).to(lowercase_)
											a__      =AutoTokenizer.from_pretrained('google/mt5-small')

											a__      =tokenizer('Hello there'       ,  return_tensors='pt').input_ids
											a__      =tokenizer('Hi I am'       ,  return_tensors='pt').input_ids

											a__      =model(input_ids.to(lowercase_)       ,  labels=labels.to(lowercase_)).loss
											a__      =-(labels.shape[-1] * loss.item())

											a__      =-84.91_27
											self.assertTrue(abs(mtf_score - EXPECTED_SCORE) < 1e-4)

