'''simple docstring'''

import numpy as np

from transformers import Pipeline







def __UpperCamelCase(   _A					:				Dict    ):
   '''simple docstring'''
   UpperCAmelCase__							:				Union[str, Any]   				=  np.max(_A  ,			axis=-1  ,			keepdims=_A    )
   UpperCAmelCase__							:				Dict   				=  np.exp(outputs - maxes    )
   return shifted_exp / shifted_exp.sum(axis=-1  ,			keepdims=_A    )


class 				_lowercase	(      lowerCAmelCase   ):
      '''simple docstring'''


      def 		lowerCAmelCase__					(				self					,**lowerCamelCase_							)			->			Tuple:



         '''simple docstring'''



         UpperCAmelCase__							:				Tuple   				=  {}
         if "second_text" in kwargs:
            UpperCAmelCase__							:				List[str]   				=  kwargs['''second_text''']
         return preprocess_kwargs, {}, {}




      def 		lowerCAmelCase__					(				self					,lowerCamelCase_					,lowerCamelCase_=None							)			->			str:



         '''simple docstring'''



         return self.tokenizer(lowerCamelCase_					,text_pair=lowerCamelCase_					,return_tensors=self.framework							)




      def 		lowerCAmelCase__					(				self					,lowerCamelCase_							)			->			Union[str, Any]:



         '''simple docstring'''



         return self.model(**lowerCamelCase_							)




      def 		lowerCAmelCase__					(				self					,lowerCamelCase_							)			->			Union[str, Any]:



         '''simple docstring'''



         UpperCAmelCase__							:				int   				=  model_outputs.logits[0].numpy()
         UpperCAmelCase__							:				Optional[int]   				=  softmax(lowerCamelCase_							)

         UpperCAmelCase__							:				str   				=  np.argmax(lowerCamelCase_							)
         UpperCAmelCase__							:				Any   				=  self.model.config.idalabel[best_class]
         UpperCAmelCase__							:				Dict   				=  probabilities[best_class].item()
         UpperCAmelCase__							:				int   				=  logits.tolist()
         return {"label": label, "score": score, "logits": logits}





'''simple docstring'''

def __UpperCamelCase(   _A					:				str  ,			_A					:				str    ):
   '''simple docstring'''
   UpperCAmelCase__							:				int   				=  len(_A    )
   UpperCAmelCase__							:				int   				=  len(_A    )
   UpperCAmelCase__							:				int   				=  (
       first_str_length if first_str_length > second_str_length else second_str_length
   )
   UpperCAmelCase__							:				list   				=  []
   for char_count in range(_A    ):
      if char_count < first_str_length:
         output_list.append(first_str[char_count]    )
      if char_count < second_str_length:
         output_list.append(second_str[char_count]    )
   return "".join(_A    )


if __name__ == "__main__":
  print(alternative_string_arrange('AB', 'XYZ'), end=' ')




