Text Generation
Transformers
Safetensors
English
gpt2
materials-science
crystallography
generative-ai
inverse-design
chemistry
unconditional
text-generation-inference
Instructions to use c-bone/CrystaLLM-pi_base with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use c-bone/CrystaLLM-pi_base with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="c-bone/CrystaLLM-pi_base")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("c-bone/CrystaLLM-pi_base") model = AutoModelForCausalLM.from_pretrained("c-bone/CrystaLLM-pi_base", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use c-bone/CrystaLLM-pi_base with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "c-bone/CrystaLLM-pi_base" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "c-bone/CrystaLLM-pi_base", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/c-bone/CrystaLLM-pi_base
- SGLang
How to use c-bone/CrystaLLM-pi_base 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 "c-bone/CrystaLLM-pi_base" \ --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": "c-bone/CrystaLLM-pi_base", "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 "c-bone/CrystaLLM-pi_base" \ --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": "c-bone/CrystaLLM-pi_base", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use c-bone/CrystaLLM-pi_base with Docker Model Runner:
docker model run hf.co/c-bone/CrystaLLM-pi_base
Add the training config that produced this checkpoint
Browse files- training_args.json +77 -0
training_args.json
ADDED
|
@@ -0,0 +1,77 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
{
|
| 2 |
+
"activate_conditionality": null,
|
| 3 |
+
"adam_beta1": 0.85,
|
| 4 |
+
"adam_beta2": 0.98,
|
| 5 |
+
"attention_dropout": 0.1,
|
| 6 |
+
"auto_find_batch_size": false,
|
| 7 |
+
"codecarbon": true,
|
| 8 |
+
"cond_dropout": null,
|
| 9 |
+
"cond_lr": null,
|
| 10 |
+
"cond_wd": null,
|
| 11 |
+
"condition_columns": null,
|
| 12 |
+
"config": "/tmp/claude-1001/-home-cyprien/349b5436-5abc-447d-ba9d-b7a3a8831932/scratchpad/hf_cards/configs/CrystaLLM-pi_base/training_config.jsonc",
|
| 13 |
+
"context_length": 1024,
|
| 14 |
+
"data_seed": 1,
|
| 15 |
+
"dataset_HF": "c-bone/lematerial_clean",
|
| 16 |
+
"dataset_streaming": false,
|
| 17 |
+
"deepspeed_config": "_config_files/deepspeed_default.json",
|
| 18 |
+
"do_sample": "True",
|
| 19 |
+
"early_stopping_patience": 10,
|
| 20 |
+
"early_stopping_threshold": 1e-05,
|
| 21 |
+
"embedding_dropout": 0.1,
|
| 22 |
+
"eval_batch_size": 32,
|
| 23 |
+
"eval_steps": 5000,
|
| 24 |
+
"eval_strategy": "steps",
|
| 25 |
+
"fp16": true,
|
| 26 |
+
"gen_max_length": 1024,
|
| 27 |
+
"grad_clip": 1.0,
|
| 28 |
+
"gradient_accumulation_steps": 1,
|
| 29 |
+
"greater_is_better": false,
|
| 30 |
+
"input_parquet": null,
|
| 31 |
+
"learning_rate": 0.001,
|
| 32 |
+
"load_best_model_at_end": true,
|
| 33 |
+
"logging_steps": 500,
|
| 34 |
+
"lr_scheduler_kwargs": {
|
| 35 |
+
"min_lr_rate": 0.001
|
| 36 |
+
},
|
| 37 |
+
"lr_scheduler_type": "cosine_with_min_lr",
|
| 38 |
+
"max_return_attempts": 1,
|
| 39 |
+
"max_samples": null,
|
| 40 |
+
"max_steps": 1250000,
|
| 41 |
+
"metric_for_best_model": "eval_loss",
|
| 42 |
+
"model_ckpt_dir": "model_ckpts/cif-gpt2-small/checkpoint-400",
|
| 43 |
+
"muon_lr": 0.02,
|
| 44 |
+
"muon_momentum": 0.95,
|
| 45 |
+
"n_embd": 512,
|
| 46 |
+
"n_head": 8,
|
| 47 |
+
"n_heads_sharing_slider": null,
|
| 48 |
+
"n_hidden_cond": null,
|
| 49 |
+
"n_layer": 8,
|
| 50 |
+
"n_prefix_tokens": null,
|
| 51 |
+
"num_return_sequences": 1,
|
| 52 |
+
"optimizer": "adamw",
|
| 53 |
+
"output_dir": "model_ckpts/mpdb-small-base-lematerial",
|
| 54 |
+
"output_parquet": null,
|
| 55 |
+
"pretrained_model_dir": null,
|
| 56 |
+
"pretrained_tokenizer_dir": "HF-cif-tokenizer",
|
| 57 |
+
"remove_CIFs_above_context": false,
|
| 58 |
+
"remove_CIFs_with_unk": true,
|
| 59 |
+
"report_to": "wandb",
|
| 60 |
+
"residual_dropout": 0.1,
|
| 61 |
+
"save_strategy": "steps",
|
| 62 |
+
"save_total_limit": 2,
|
| 63 |
+
"scoring_mode": "None",
|
| 64 |
+
"seed": 42,
|
| 65 |
+
"share_layers": null,
|
| 66 |
+
"target_valid_cifs": 1,
|
| 67 |
+
"temperature": 1.0,
|
| 68 |
+
"top_k": 15,
|
| 69 |
+
"top_p": 0.95,
|
| 70 |
+
"torch_compile": true,
|
| 71 |
+
"tracker_project": "CrystaLLM-pi",
|
| 72 |
+
"train_batch_size": 32,
|
| 73 |
+
"wandb_project_folder": "CrystaLLM_pi",
|
| 74 |
+
"warmup_ratio": 0.02,
|
| 75 |
+
"warmup_steps": 0,
|
| 76 |
+
"weight_decay": 0.1
|
| 77 |
+
}
|