Text Generation
Transformers
Safetensors
PyTorch
Indonesian
English
caca
causal-lm
transformer
untrained
gqa
rope
swiglu
rmsnorm
flash-attention
indonesian
bilingual
custom_code
Instructions to use Lyon28/caca-2M-untrained with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use Lyon28/caca-2M-untrained with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="Lyon28/caca-2M-untrained", trust_remote_code=True)# Load model directly from transformers import AutoModelForCausalLM model = AutoModelForCausalLM.from_pretrained("Lyon28/caca-2M-untrained", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use Lyon28/caca-2M-untrained with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "Lyon28/caca-2M-untrained" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Lyon28/caca-2M-untrained", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/Lyon28/caca-2M-untrained
- SGLang
How to use Lyon28/caca-2M-untrained with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "Lyon28/caca-2M-untrained" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Lyon28/caca-2M-untrained", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "Lyon28/caca-2M-untrained" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "Lyon28/caca-2M-untrained", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use Lyon28/caca-2M-untrained with Docker Model Runner:
docker model run hf.co/Lyon28/caca-2M-untrained
File size: 3,202 Bytes
1e8e7ff | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 | {
"architectures": [
"CacaForCausalLM"
],
"attention_bias": false,
"attention_dropout": 0.0,
"attention_pattern": "all_global",
"attention_sink_size": 4,
"attention_sink_window": 1024,
"attention_temperature": 1.0,
"attn_logit_softcapping": null,
"audio_config": {},
"auto_map": {
"AutoConfig": "caca_transformers.CacaConfig",
"AutoModel": "caca_transformers.CacaModel",
"AutoModelForCausalLM": "caca_transformers.CacaForCausalLM"
},
"bos_token_id": 1,
"chat_template": "{% for message in messages %}{% if message['role'] == 'system' %}System: {{ message['content'] }}\n{% elif message['role'] == 'user' %}User: {{ message['content'] }}\n{% elif message['role'] == 'assistant' %}Assistant: {{ message['content'] }}\n{% endif %}{% endfor %}{% if add_generation_prompt %}Assistant:{% endif %}",
"cross_attention_frequency": 4,
"dtype": "float32",
"eos_token_id": 2,
"expert_capacity_factor": 1.0,
"expert_choice_k": 0.125,
"expert_load_monitoring": true,
"expert_load_warn_threshold": 0.3,
"final_logit_softcapping": null,
"global_attention_every_n_layers": 2,
"gradient_checkpointing_granularity": "full",
"head_dim": 32,
"hidden_dropout": 0.1,
"hidden_size": 128,
"initializer_range": 0.02,
"intermediate_size": 256,
"label_smoothing": 0.0,
"layer_scale_init": 1e-05,
"lm_logit_softcapping": 30.0,
"longformer_attention_window": 512,
"lora_alpha": 32.0,
"lora_bias": "none",
"lora_dropout": 0.05,
"lora_rank": 16,
"lora_target_modules": [
"q_proj",
"v_proj"
],
"max_position_embeddings": 512,
"merge_threshold": 0.5,
"mlp_bias": false,
"mod_capacity_factor": 0.5,
"mod_route_method": "learned",
"model_type": "caca",
"moe_layer_frequency": 2,
"mup_base_width": 256,
"nan_recovery_level": 1,
"num_attention_heads": 4,
"num_expert_groups": 1,
"num_experts": 8,
"num_experts_per_tok": 2,
"num_hidden_layers": 7,
"num_key_value_heads": 1,
"pad_token_id": null,
"pipeline_parallel_size": 1,
"pretraining_tp": 1,
"projector_hidden_size": 128,
"qk_norm_eps": 1e-06,
"residual_dropout": 0.1,
"rms_norm_eps": 1e-06,
"rope_ntk_alpha": 1.0,
"rope_parameters": {
"rope_theta": 10000.0,
"rope_type": "default"
},
"rope_theta": 10000.0,
"rope_type": "default",
"router_aux_loss_coef": 0.01,
"router_z_loss_coef": 0.001,
"sliding_window": null,
"stochastic_depth_prob": 0.1,
"tensor_parallel_size": 1,
"tie_word_embeddings": false,
"token_dropout": 0.0,
"transformers_version": "5.14.1",
"use_alibi": false,
"use_attention_sink": false,
"use_cache": true,
"use_cross_attention": false,
"use_expert_choice": false,
"use_flash_attn": true,
"use_grouped_moe": false,
"use_grouped_query_attention": false,
"use_layer_scale": false,
"use_longformer_attention": false,
"use_lora": false,
"use_mixture_of_depths": false,
"use_moe": false,
"use_multi_query_attention": false,
"use_multimodal": false,
"use_mup": false,
"use_qk_norm": true,
"use_rotary_embeddings": true,
"use_soft_merging": false,
"use_spectral_norm": false,
"use_stochastic_depth": false,
"vision_config": {},
"vocab_size": 4000
}
|