
    g/                     &   d dl mZ ddlmZmZmZmZmZ g dddgdZ	  e            s
 e            	 g ded	<   g d
ed<   g ded<   g ded<   g ded<   g ded<   g ded<   n# e$ r Y nw xY w	  e            s
 e            	 g ded<   g ded<   n# e$ r Y nw xY w	  e            s
 e            	 g ded<   g ded<   n# e$ r Y nw xY werddl	m
Z
mZmZmZmZ ddlmZmZ 	  e            s
 e            	 ddlmZmZmZmZ dd
lmZmZmZmZ ddlmZmZmZ dd l m!Z!m"Z"m#Z#m$Z$m%Z%m&Z&m'Z'm(Z(m)Z)m*Z*m+Z+m,Z,m-Z-m.Z.m/Z/m0Z0m1Z1m2Z2m3Z3m4Z4m5Z5m6Z6m7Z7m8Z8m9Z9m:Z:m;Z;m<Z<m=Z=m>Z>m?Z?m@Z@mAZA dd!lBmCZCmDZDmEZEmFZFmGZGmHZHmIZImJZJmKZK dd"lmLZLmMZMmNZNmOZOmPZPmQZQmRZRmSZSmTZTmUZUmVZVmWZWmXZXmYZYmZZZ dd#l[m\Z\m]Z]m^Z^m_Z_m`Z` n# e$ r Y nw xY w	  e            s
 e            	 ddlambZbmcZcmdZdmeZemfZfmgZgmhZhmiZimjZjmkZkmlZlmmZmmnZnmoZompZp dd$lqmrZrmsZsmtZtmuZumvZvmwZwmxZxmyZymzZzm{Z{m|Z| n# e$ r Y nw xY w	  e            s
 e            	 dd%l}m~Z~mZmZmZmZmZmZmZmZmZmZmZmZmZ dd&lmZmZmZmZ d'S # e$ r Y d'S w xY wd d'lZ ee e            d(         ee)          ej        e<   d'S )*    )TYPE_CHECKING   )OptionalDependencyNotAvailable_LazyModuleis_flax_availableis_tf_availableis_torch_available)BaseWatermarkingConfigGenerationConfigGenerationModeSynthIDTextWatermarkingConfigWatermarkingConfigTextIteratorStreamerTextStreamer)configuration_utils	streamers)
ConstraintConstraintListStateDisjunctiveConstraintPhrasalConstraintbeam_constraints)BeamHypotheses
BeamScorerBeamSearchScorerConstrainedBeamSearchScorerbeam_search)AssistedCandidateGeneratorCandidateGeneratorPromptLookupCandidateGeneratorcandidate_generator)!#AlternatingCodebooksLogitsProcessor%ClassifierFreeGuidanceLogitsProcessor#EncoderNoRepeatNGramLogitsProcessor'EncoderRepetitionPenaltyLogitsProcessorEpsilonLogitsWarperEtaLogitsWarperExponentialDecayLengthPenaltyForcedBOSTokenLogitsProcessorForcedEOSTokenLogitsProcessorHammingDiversityLogitsProcessorInfNanRemoveLogitsProcessorLogitNormalizationLogitsProcessorLogitsProcessorListLogitsWarperMinLengthLogitsProcessor!MinNewTokensLengthLogitsProcessorMinPLogitsWarperNoBadWordsLogitsProcessorNoRepeatNGramLogitsProcessor PrefixConstrainedLogitsProcessor RepetitionPenaltyLogitsProcessorSequenceBiasLogitsProcessorSuppressTokensLogitsProcessor$SuppressTokensAtBeginLogitsProcessor#SynthIDTextWatermarkLogitsProcessorTemperatureLogitsWarperTopKLogitsWarperTopPLogitsWarperTypicalLogitsWarper.UnbatchedClassifierFreeGuidanceLogitsProcessorWhisperTimeStampLogitsProcessorWatermarkLogitsProcessorlogits_process)	MaxNewTokensCriteriaMaxLengthCriteriaMaxTimeCriteriaConfidenceCriteriaEosTokenCriteriaStoppingCriteriaStoppingCriteriaListvalidate_stopping_criteriaStopStringCriteriastopping_criteria)GenerationMixin GreedySearchEncoderDecoderOutputGreedySearchDecoderOnlyOutputSampleEncoderDecoderOutputSampleDecoderOnlyOutputBeamSearchEncoderDecoderOutputBeamSearchDecoderOnlyOutputBeamSampleEncoderDecoderOutputBeamSampleDecoderOnlyOutput%ContrastiveSearchEncoderDecoderOutput"ContrastiveSearchDecoderOnlyOutputGenerateBeamDecoderOnlyOutput GenerateBeamEncoderDecoderOutputGenerateDecoderOnlyOutputGenerateEncoderDecoderOutpututils)WatermarkDetectorWatermarkDetectorOutputBayesianDetectorModelBayesianDetectorConfigSynthIDTextWatermarkDetectorwatermarking)TFForcedBOSTokenLogitsProcessorTFForcedEOSTokenLogitsProcessorTFForceTokensLogitsProcessorTFLogitsProcessorTFLogitsProcessorListTFLogitsWarperTFMinLengthLogitsProcessorTFNoBadWordsLogitsProcessorTFNoRepeatNGramLogitsProcessor"TFRepetitionPenaltyLogitsProcessor&TFSuppressTokensAtBeginLogitsProcessorTFSuppressTokensLogitsProcessorTFTemperatureLogitsWarperTFTopKLogitsWarperTFTopPLogitsWarpertf_logits_process)TFGenerationMixinTFGreedySearchDecoderOnlyOutput"TFGreedySearchEncoderDecoderOutputTFSampleEncoderDecoderOutputTFSampleDecoderOnlyOutput TFBeamSearchEncoderDecoderOutputTFBeamSearchDecoderOnlyOutput TFBeamSampleEncoderDecoderOutputTFBeamSampleDecoderOnlyOutput'TFContrastiveSearchEncoderDecoderOutput$TFContrastiveSearchDecoderOnlyOutputtf_utils)!FlaxForcedBOSTokenLogitsProcessor!FlaxForcedEOSTokenLogitsProcessorFlaxForceTokensLogitsProcessorFlaxLogitsProcessorFlaxLogitsProcessorListFlaxLogitsWarperFlaxMinLengthLogitsProcessor(FlaxSuppressTokensAtBeginLogitsProcessor!FlaxSuppressTokensLogitsProcessorFlaxTemperatureLogitsWarperFlaxTopKLogitsWarperFlaxTopPLogitsWarper#FlaxWhisperTimeStampLogitsProcessor FlaxNoRepeatNGramLogitsProcessorflax_logits_process)FlaxGenerationMixinFlaxGreedySearchOutputFlaxSampleOutputFlaxBeamSearchOutput
flax_utils   )r   r   )!r!   r"   r#   r$   r%   r&   r'   r(   r)   r*   r+   r,   r-   r.   r/   r0   r1   r2   r3   r4   r5   r6   r7   r9   r8   r:   r;   r<   r=   r>   r?   rA   r@   )	rF   rG   rD   rC   rE   rH   rI   rK   rJ   )rU   rT   rS   rR   rW   rV   rX   rY   rZ   r[   rM   rO   rN   rQ   rP   )r`   r_   ra   r]   r^   )r{   rz   ry   rx   r}   r|   rs   rt   ru   rw   rv   )r   r   r   r   r   r   r   r   r   r   r   r   r   r   )r   r   r   r   N__file__)module_spec)typingr   r\   r   r   r   r   r	   _import_structurer   r
   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r    r   r   r   rB   r!   r"   r#   r$   r%   r&   r'   r(   r)   r*   r+   r,   r-   r.   r/   r0   r1   r2   r3   r4   r5   r6   r7   r9   r8   r:   r;   r<   r=   r>   r?   rA   r@   rL   rF   rG   rD   rC   rE   rH   rI   rK   rJ   rU   rT   rS   rR   rW   rV   rX   rY   rZ   r[   rM   rO   rN   rQ   rP   rb   r`   r_   ra   r]   r^   rr   rc   rd   re   rf   rg   rh   ri   rj   rk   rl   rm   rn   ro   rp   rq   r~   r{   rz   ry   rx   r}   r|   rs   rt   ru   rw   rv   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   r   sys__name__globals__spec__modules     \/var/www/html/ai-engine/env/lib/python3.11/site-packages/transformers/generation/__init__.py<module>r      s	   !           w w w w w w w w w w w w w w   ).9	 	 \ /,,.../
- - -()( ( (m$0 0 0+,
"+ "+ "+&'F
. 
. 
.)*" " "g") ) )n%%g & 	 	 	D	v#? /,,.../
. . .)*"% % %j!!) & 	 	 	D	D /,,.../
0 0 0+, ' ' 'l##' & 	 	 	D	4  Yr              >=======N
!!## 	300222	3
 	pooooooooooojjjjjjjjjjjjwwwwwwwwww"	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
 "	
F
	
 
	
 
	
 
	
 
	
 
	
 
	
 
	
 
	
 
	
 
	
 
	
 
	
 
	
 
	
 
	
 
	
 
	
 
	
 
	
 
	
 
	
	
 	
 	
 	
 	
 	
 	
 	
 	
 	
 	
 	
 	
 	
 	
 	
 	
 	
 	
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