Text Generation
Transformers
Safetensors
PyTorch
English
pebble_50m
chat
mamba
experimental
mamba2
hybrid
slm
custom_code
Run this model with HF Jobs
Run basically-experimental/Pebble-50M-Chat-beta on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.
Paste one of these prompts into your coding agent:
Fine-tune on my dataset
Use HF Jobs and TRL to fine-tune https://huggingface.co/basically-experimental/Pebble-50M-Chat-beta. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.
Run batch inference
Use HF Jobs to run batch inference with https://huggingface.co/basically-experimental/Pebble-50M-Chat-beta on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.
Evaluate on a benchmark
Use HF Jobs to evaluate https://huggingface.co/basically-experimental/Pebble-50M-Chat-beta. Ask me which benchmark to run, then save the scores and the per-example results to a new dataset repo. Run `hf jobs --help` first to learn the CLI.
Quantize for lower memory use
Use HF Jobs to create a 4-bit version of https://huggingface.co/basically-experimental/Pebble-50M-Chat-beta. Push it to a new model repo, then reload it from there and report its memory footprint. Run `hf jobs --help` first to learn the CLI.
Instructions to use basically-experimental/Pebble-50M-Chat-beta with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use basically-experimental/Pebble-50M-Chat-beta with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="basically-experimental/Pebble-50M-Chat-beta", trust_remote_code=True)# pip install -U transformers accelerate # Load model directly from transformers import AutoModelForCausalLM model = AutoModelForCausalLM.from_pretrained("basically-experimental/Pebble-50M-Chat-beta", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use basically-experimental/Pebble-50M-Chat-beta with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "basically-experimental/Pebble-50M-Chat-beta" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "basically-experimental/Pebble-50M-Chat-beta", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/basically-experimental/Pebble-50M-Chat-beta
- SGLang
How to use basically-experimental/Pebble-50M-Chat-beta 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 "basically-experimental/Pebble-50M-Chat-beta" \ --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": "basically-experimental/Pebble-50M-Chat-beta", "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 "basically-experimental/Pebble-50M-Chat-beta" \ --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": "basically-experimental/Pebble-50M-Chat-beta", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use basically-experimental/Pebble-50M-Chat-beta with Docker Model Runner:
docker model run hf.co/basically-experimental/Pebble-50M-Chat-beta
SFT step 50
Browse filesFiles changed (6)
- config.jsonAdded+32
- configuration_pebble.pyAdded+41
- model.safetensorsAdded+3
- special_tokens_map.jsonAdded+16
- tokenizer.jsonAdded
- tokenizer_config.jsonAdded+27
1234567891011121314151617181920212223242526272829303132{ "architectures": [ "PebbleForCausalLM" ], "attention": { "is_causal": true, "rope_theta": 10000.0 }, "auto_map": { "AutoConfig": "configuration_pebble.PebbleConfig", "AutoModelForCausalLM": "modeling_pebble.PebbleForCausalLM" }, "block_pattern": "mmma|mmma", "dtype": "bfloat16", "hidden_size": 768, "hybrid_ratio": "3:1 mamba2:attention", "intermediate_size": 3072, "mamba2": { "d_conv": 4, "d_state": 128, "expand": 2, "headdim": 64, "use_mem_eff_path": true }, "max_position_embeddings": 16384, "model_type": "pebble_50m", "num_attention_heads": 12, "num_hidden_layers": 8, "rms_norm_eps": 1e-06, "transformers_version": "4.57.1", "vocab_size": 16384}1234567891011121314151617181920212223242526272829303132333435363738394041from transformers import PretrainedConfig
class PebbleConfig(PretrainedConfig): model_type = "pebble_50m"
def __init__( self, vocab_size=16384, hidden_size=768, intermediate_size=3072, num_hidden_layers=8, num_attention_heads=12, block_pattern="mmma|mmma", hybrid_ratio="3:1 mamba2:attention", max_position_embeddings=16384, rms_norm_eps=1e-6, tie_word_embeddings=True, mamba2=None, attention=None, **kwargs, ): self.vocab_size = vocab_size self.hidden_size = hidden_size self.intermediate_size = intermediate_size self.num_hidden_layers = num_hidden_layers self.num_attention_heads = num_attention_heads self.block_pattern = block_pattern self.hybrid_ratio = hybrid_ratio self.max_position_embeddings = max_position_embeddings self.rms_norm_eps = rms_norm_eps self.tie_word_embeddings = tie_word_embeddings # Default dictionaries if not provided in config.json self.mamba2 = mamba2 or { "d_state": 128, "d_conv": 4, "expand": 2, "headdim": 64, "use_mem_eff_path": True } self.attention = attention or { "rope_theta": 10000.0, "is_causal": True } super().__init__(**kwargs)123version https://git-lfs.github.com/spec/v1oid sha256:178ce18d0e95615d34023efa3faf87aff5485d852f050714aeedde3974c903e4size 9867542412345678910111213141516{ "bos_token": { "content": "<|eos|>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false }, "eos_token": { "content": "<|eos|>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false }}123456789101112131415161718192021222324252627{ "add_bos_token": false, "add_eos_token": false, "added_tokens_decoder": { "0": { "content": "<|eos|>", "lstrip": false, "normalized": false, "rstrip": false, "single_word": false, "special": true } }, "bos_token": "<|eos|>", "clean_up_tokenization_spaces": false, "eos_token": "<|eos|>", "eos_token_id": 0, "extra_special_tokens": {}, "model_input_names": [ "input_ids" ], "model_max_length": 16384, "pad_token": null, "tokenizer_class": "PreTrainedTokenizerFast", "unk_token": null, "vocab_size": 16384}config.jsonAdded+32
configuration_pebble.pyAdded+41
model.safetensorsAdded+3
special_tokens_map.jsonAdded+16
tokenizer.jsonAdded
tokenizer_config.jsonAdded+27