Instructions to use katuni4ka/tiny-random-falcon-40b with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use katuni4ka/tiny-random-falcon-40b with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="katuni4ka/tiny-random-falcon-40b")# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("katuni4ka/tiny-random-falcon-40b") model = AutoModelForCausalLM.from_pretrained("katuni4ka/tiny-random-falcon-40b") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use katuni4ka/tiny-random-falcon-40b with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "katuni4ka/tiny-random-falcon-40b" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "katuni4ka/tiny-random-falcon-40b", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/katuni4ka/tiny-random-falcon-40b
- SGLang
How to use katuni4ka/tiny-random-falcon-40b 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 "katuni4ka/tiny-random-falcon-40b" \ --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": "katuni4ka/tiny-random-falcon-40b", "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 "katuni4ka/tiny-random-falcon-40b" \ --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": "katuni4ka/tiny-random-falcon-40b", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use katuni4ka/tiny-random-falcon-40b with Docker Model Runner:
docker model run hf.co/katuni4ka/tiny-random-falcon-40b
Update config.json
Browse files- config.json +0 -8
config.json
CHANGED
|
@@ -6,14 +6,6 @@
|
|
| 6 |
"FalconForCausalLM"
|
| 7 |
],
|
| 8 |
"attention_dropout": 0.0,
|
| 9 |
-
"auto_map": {
|
| 10 |
-
"AutoConfig": "configuration_falcon.FalconConfig",
|
| 11 |
-
"AutoModel": "modeling_falcon.FalconModel",
|
| 12 |
-
"AutoModelForCausalLM": "modeling_falcon.FalconForCausalLM",
|
| 13 |
-
"AutoModelForQuestionAnswering": "modeling_falcon.FalconForQuestionAnswering",
|
| 14 |
-
"AutoModelForSequenceClassification": "modeling_falcon.FalconForSequenceClassification",
|
| 15 |
-
"AutoModelForTokenClassification": "modeling_falcon.FalconForTokenClassification"
|
| 16 |
-
},
|
| 17 |
"bias": false,
|
| 18 |
"bos_token_id": 11,
|
| 19 |
"eos_token_id": 11,
|
|
|
|
| 6 |
"FalconForCausalLM"
|
| 7 |
],
|
| 8 |
"attention_dropout": 0.0,
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 9 |
"bias": false,
|
| 10 |
"bos_token_id": 11,
|
| 11 |
"eos_token_id": 11,
|