Instructions to use WebOrganizer/LM-1b_1x-DCLMFasttext with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use WebOrganizer/LM-1b_1x-DCLMFasttext with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="WebOrganizer/LM-1b_1x-DCLMFasttext")# Load model directly from transformers import AutoModelForCausalLM model = AutoModelForCausalLM.from_pretrained("WebOrganizer/LM-1b_1x-DCLMFasttext", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use WebOrganizer/LM-1b_1x-DCLMFasttext with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "WebOrganizer/LM-1b_1x-DCLMFasttext" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "WebOrganizer/LM-1b_1x-DCLMFasttext", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/WebOrganizer/LM-1b_1x-DCLMFasttext
- SGLang
How to use WebOrganizer/LM-1b_1x-DCLMFasttext 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 "WebOrganizer/LM-1b_1x-DCLMFasttext" \ --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": "WebOrganizer/LM-1b_1x-DCLMFasttext", "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 "WebOrganizer/LM-1b_1x-DCLMFasttext" \ --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": "WebOrganizer/LM-1b_1x-DCLMFasttext", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use WebOrganizer/LM-1b_1x-DCLMFasttext with Docker Model Runner:
docker model run hf.co/WebOrganizer/LM-1b_1x-DCLMFasttext
File size: 1,873 Bytes
fc4aea2 | 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 | ---
library_name: transformers
datasets:
- WebOrganizer/Corpus-200B
---
# WebOrganizer/LM-1b_1x-DCLMFasttext
[[Paper](https://arxiv.org/abs/2502.10341)] [[Website](https://weborganizer.allenai.org)] [[GitHub](https://github.com/CodeCreator/WebOrganizer)]
A 1.4B parameter model trained for 29B tokens from [WebOrganizer/Corpus-200B](https://huggingface.co/datasets/WebOrganizer/Corpus-200B).
The training data for this model was selected via:
1. **Selection method**: Top scores from [DCLM-Fasttext Model](https://huggingface.co/mlfoundations/fasttext-oh-eli5)
2. **Domain definition**: n/a (global selection)
3. **Domain mixture**: n/a
## Repository Contents
Besides the HuggingFace model and tokenizer, the repository contains:
- `open_lm/`: Contains the OpenLM config and final checkpoint
- `evals/`: Evaluation results for various benchmarks
- `core_9mcqa/`: Results of 9 multiple choice QA tasks with the OLMES evaluation framework
- `mmlu/`: MMLU results with the OLMES evaluation framework
- `dclm/`: Results using the DCLM evaluation framework
- `perplexity/`: Perplexity results using the huggingface trainer
- `indices.tar.zst`: The indices for the selected documents in each shard of the Corpus-200B dataset used for training. The indices can be extracted with `tar --use-compress-program "zstd" -xf indices.tar.zst`.
## Usage
To use this model, you need to install the [open_lm](https://github.com/mlfoundations/open_lm) library and add `from open_lm.hf import *` before loading the model with `AutoModel.from_pretrained(...)`.
## Citation
```bibtex
@article{wettig2025organize,
title={Organize the Web: Constructing Domains Enhances Pre-Training Data Curation},
author={Alexander Wettig and Kyle Lo and Sewon Min and Hannaneh Hajishirzi and Danqi Chen and Luca Soldaini},
journal={arXiv preprint arXiv:2502.10341},
year={2025}
}
```
|