ó
    üÞ j)  ã                  ó:   • S r SSKJr  SSKJrJr  SSKrSrSS jrg)zDDeterministic trace sampling, kept consistent across LangSmith SDKs.é    )Úannotations)ÚAnyÚOptionalNi@B c                óê   • Ub  US:¼  a  gUS::  a  gU c  g[         R                  " [        U 5      R                  5       R	                  S5      5      R                  5       nU[        -  nU[        -  U:  $ )zÌDecide whether `identifier` is sampled in at `sampling_rate`.

The decision is a pure function of the identifier, so every process and
every SDK agrees on it, and a run's create and patch never disagree.
é   Tr   Fzutf-8)ÚxxhashÚxxh3_128ÚstrÚlowerÚencodeÚ	intdigestÚ_SAMPLING_HASH_MODULUS)Ú
identifierÚsampling_rateÚdigestÚbuckets       ÚW/var/www/html/gaurav/venv/lib/python3.13/site-packages/langsmith/_internal/_sampling.pyÚis_sampled_by_idr      su   € ð Ñ °Ó 2ØØ˜ÓØØÑØô �_Š_œS ›_×2Ñ2Ó4×;Ñ;¸GÓDÓE×OÑOÓQ€FØÔ,Ñ,€FØÔ*Ñ*¨]Ñ:Ð:ó    )r   r   r   zOptional[float]ÚreturnÚbool)	Ú__doc__Ú
__future__r   Útypingr   r   r   r   r   © r   r   Ú<module>r      s   ðÙ Jå "ç  ã à"Ð õ;r   