





"""simple docstring"""





from ...configuration_utils import PretrainedConfig
from ...utils import logging


lowerCAmelCase__     			=			logging.get_logger(__name__)

lowerCAmelCase__     			=			{
    '''RWKV/rwkv-4-169m-pile''': '''https://huggingface.co/RWKV/rwkv-4-169m-pile/resolve/main/config.json''',
    '''RWKV/rwkv-4-430m-pile''': '''https://huggingface.co/RWKV/rwkv-4-430m-pile/resolve/main/config.json''',
    '''RWKV/rwkv-4-1b5-pile''': '''https://huggingface.co/RWKV/rwkv-4-1b5-pile/resolve/main/config.json''',
    '''RWKV/rwkv-4-3b-pile''': '''https://huggingface.co/RWKV/rwkv-4-3b-pile/resolve/main/config.json''',
    '''RWKV/rwkv-4-7b-pile''': '''https://huggingface.co/RWKV/rwkv-4-7b-pile/resolve/main/config.json''',
    '''RWKV/rwkv-4-14b-pile''': '''https://huggingface.co/RWKV/rwkv-4-14b-pile/resolve/main/config.json''',
    '''RWKV/rwkv-raven-1b5''': '''https://huggingface.co/RWKV/rwkv-raven-1b5/resolve/main/config.json''',
    '''RWKV/rwkv-raven-3b''': '''https://huggingface.co/RWKV/rwkv-raven-3b/resolve/main/config.json''',
    '''RWKV/rwkv-raven-7b''': '''https://huggingface.co/RWKV/rwkv-raven-7b/resolve/main/config.json''',
    '''RWKV/rwkv-raven-14b''': '''https://huggingface.co/RWKV/rwkv-raven-14b/resolve/main/config.json''',
}





class        _lowerCamelCase      (       _lowercase ):
						UpperCAmelCase_ =			"rwkv"
						UpperCAmelCase_ =			{"max_position_embeddings": "context_length"}


						def __init__(self   ,							__a=5_02_77   ,							__a=10_24   ,							__a=40_96   ,							__a=32   ,							__a=None   ,							__a=None   ,							__a=1e-5   ,							__a=0   ,							__a=0   ,							__a=6   ,							__a=False   ,							__a=True   ,							**__a   ,							) ->   Dict:
								UpperCamelCase   =	vocab_size
								UpperCamelCase   =	context_length
								UpperCamelCase   =	hidden_size
								UpperCamelCase   =	num_hidden_layers
								UpperCamelCase   =	attention_hidden_size if attention_hidden_size is not None else hidden_size
								UpperCamelCase   =	intermediate_size if intermediate_size is not None else 4 * hidden_size
								UpperCamelCase   =	layer_norm_epsilon
								UpperCamelCase   =	rescale_every
								UpperCamelCase   =	use_cache

								UpperCamelCase   =	bos_token_id
								UpperCamelCase   =	eos_token_id

								super().__init__(
								    tie_word_embeddings=__a   ,							bos_token_id=__a   ,							eos_token_id=__a   ,							**__a		)













"""simple docstring"""





import os

from huggingface_hub.constants import HUGGINGFACE_HUB_CACHE, hf_cache_home


lowerCAmelCase__     			=			HUGGINGFACE_HUB_CACHE


lowerCAmelCase__     			=			'''config.json'''
lowerCAmelCase__     			=			'''diffusion_pytorch_model.bin'''
lowerCAmelCase__     			=			'''diffusion_flax_model.msgpack'''
lowerCAmelCase__     			=			'''model.onnx'''
lowerCAmelCase__     			=			'''diffusion_pytorch_model.safetensors'''
lowerCAmelCase__     			=			'''weights.pb'''
lowerCAmelCase__     			=			'''https://huggingface.co'''
lowerCAmelCase__     			=			default_cache_path
lowerCAmelCase__     			=			'''diffusers_modules'''
lowerCAmelCase__     			=			os.getenv('''HF_MODULES_CACHE''', os.path.join(hf_cache_home, '''modules'''))
lowerCAmelCase__     			=			['''fp16''', '''non-ema''']
lowerCAmelCase__     			=			'''.self_attn'''






