Text Generation
Transformers
Safetensors
English
falcon
text-generation-inference
Eval Results (legacy)
Instructions to use ericzzz/falcon-rw-1b-instruct-openorca with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use ericzzz/falcon-rw-1b-instruct-openorca with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="ericzzz/falcon-rw-1b-instruct-openorca")# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("ericzzz/falcon-rw-1b-instruct-openorca") model = AutoModelForCausalLM.from_pretrained("ericzzz/falcon-rw-1b-instruct-openorca", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use ericzzz/falcon-rw-1b-instruct-openorca with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "ericzzz/falcon-rw-1b-instruct-openorca" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "ericzzz/falcon-rw-1b-instruct-openorca", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }'Use Docker
docker model run hf.co/ericzzz/falcon-rw-1b-instruct-openorca
- SGLang
How to use ericzzz/falcon-rw-1b-instruct-openorca 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 "ericzzz/falcon-rw-1b-instruct-openorca" \ --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": "ericzzz/falcon-rw-1b-instruct-openorca", "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 "ericzzz/falcon-rw-1b-instruct-openorca" \ --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": "ericzzz/falcon-rw-1b-instruct-openorca", "prompt": "Once upon a time,", "max_tokens": 512, "temperature": 0.5 }' - Docker Model Runner
How to use ericzzz/falcon-rw-1b-instruct-openorca with Docker Model Runner:
docker model run hf.co/ericzzz/falcon-rw-1b-instruct-openorca
|
Download README.md from ericzzz/falcon-rw-1b-instruct-openorca: direct link, hf CLI and curl.
- Browser
- Download file 7.27 kB
-
https://huggingface.co/ericzzz/falcon-rw-1b-instruct-openorca/resolve/main/README.md
- Command line
-
hf download hf://ericzzz/falcon-rw-1b-instruct-openorca/README.md
-
curl -L -o README.md https://huggingface.co/ericzzz/falcon-rw-1b-instruct-openorca/resolve/main/README.md
7.27 kB
| language: | |
| - en | |
| license: apache-2.0 | |
| tags: | |
| - text-generation-inference | |
| datasets: | |
| - Open-Orca/SlimOrca | |
| pipeline_tag: text-generation | |
| inference: false | |
| model-index: | |
| - name: falcon-rw-1b-instruct-openorca | |
| results: | |
| - task: | |
| type: text-generation | |
| name: Text Generation | |
| dataset: | |
| name: AI2 Reasoning Challenge (25-Shot) | |
| type: ai2_arc | |
| config: ARC-Challenge | |
| split: test | |
| args: | |
| num_few_shot: 25 | |
| metrics: | |
| - type: acc_norm | |
| value: 34.56 | |
| name: normalized accuracy | |
| source: | |
| url: https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=ericzzz/falcon-rw-1b-instruct-openorca | |
| name: Open LLM Leaderboard | |
| - task: | |
| type: text-generation | |
| name: Text Generation | |
| dataset: | |
| name: HellaSwag (10-Shot) | |
| type: hellaswag | |
| split: validation | |
| args: | |
| num_few_shot: 10 | |
| metrics: | |
| - type: acc_norm | |
| value: 60.93 | |
| name: normalized accuracy | |
| source: | |
| url: https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=ericzzz/falcon-rw-1b-instruct-openorca | |
| name: Open LLM Leaderboard | |
| - task: | |
| type: text-generation | |
| name: Text Generation | |
| dataset: | |
| name: MMLU (5-Shot) | |
| type: cais/mmlu | |
| config: all | |
| split: test | |
| args: | |
| num_few_shot: 5 | |
| metrics: | |
| - type: acc | |
| value: 28.77 | |
| name: accuracy | |
| source: | |
| url: https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=ericzzz/falcon-rw-1b-instruct-openorca | |
| name: Open LLM Leaderboard | |
| - task: | |
| type: text-generation | |
| name: Text Generation | |
| dataset: | |
| name: TruthfulQA (0-shot) | |
| type: truthful_qa | |
| config: multiple_choice | |
| split: validation | |
| args: | |
| num_few_shot: 0 | |
| metrics: | |
| - type: mc2 | |
| value: 37.42 | |
| source: | |
| url: https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=ericzzz/falcon-rw-1b-instruct-openorca | |
| name: Open LLM Leaderboard | |
| - task: | |
| type: text-generation | |
| name: Text Generation | |
| dataset: | |
| name: Winogrande (5-shot) | |
| type: winogrande | |
| config: winogrande_xl | |
| split: validation | |
| args: | |
| num_few_shot: 5 | |
| metrics: | |
| - type: acc | |
| value: 60.69 | |
| name: accuracy | |
| source: | |
| url: https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=ericzzz/falcon-rw-1b-instruct-openorca | |
| name: Open LLM Leaderboard | |
| - task: | |
| type: text-generation | |
| name: Text Generation | |
| dataset: | |
| name: GSM8k (5-shot) | |
| type: gsm8k | |
| config: main | |
| split: test | |
| args: | |
| num_few_shot: 5 | |
| metrics: | |
| - type: acc | |
| value: 3.41 | |
| name: accuracy | |
| source: | |
| url: https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard?query=ericzzz/falcon-rw-1b-instruct-openorca | |
| name: Open LLM Leaderboard | |
| # 🌟 Falcon-RW-1B-Instruct-OpenOrca | |
| Falcon-RW-1B-Instruct-OpenOrca is a 1B parameter, causal decoder-only model based on [Falcon-RW-1B](https://huggingface.co/tiiuae/falcon-rw-1b) and finetuned on the [Open-Orca/SlimOrca](https://huggingface.co/datasets/Open-Orca/SlimOrca) dataset. | |
| **✨Check out our new conversational model [Falcon-RW-1B-Chat](https://huggingface.co/ericzzz/falcon-rw-1b-chat)!✨** | |
| **📊 Evaluation Results** | |
| Falcon-RW-1B-Instruct-OpenOrca was the #1 ranking model (unfortunately not anymore) on [Open LLM Leaderboard](https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard) in ~1.5B parameters category! A detailed result can be found [here](https://huggingface.co/datasets/open-llm-leaderboard/details_ericzzz__falcon-rw-1b-instruct-openorca). | |
| | Metric | falcon-rw-1b-instruct-openorca | falcon-rw-1b | | |
| |------------|-------------------------------:|-------------:| | |
| | ARC | 34.56 | 35.07 | | |
| | HellaSwag | 60.93 | 63.56 | | |
| | MMLU | 28.77 | 25.28 | | |
| | TruthfulQA | 37.42 | 35.96 | | |
| | Winogrande | 60.69 | 62.04 | | |
| | GSM8K | 3.41 | 0.53 | | |
| | **Average**| **37.63** | **37.07** | | |
| **🚀 Motivations** | |
| 1. To create a smaller, open-source, instruction-finetuned, ready-to-use model accessible for users with limited computational resources (lower-end consumer GPUs). | |
| 2. To harness the strength of Falcon-RW-1B, a competitive model in its own right, and enhance its capabilities with instruction finetuning. | |
| ## 📖 How to Use | |
| The model operates with a structured prompt format, incorporating `<SYS>`, `<INST>`, and `<RESP>` tags to demarcate different parts of the input. The system message and instruction are placed within these tags, with the `<RESP>` tag triggering the model's response. | |
| **📝 Example Code** | |
| ```python | |
| from transformers import AutoTokenizer, AutoModelForCausalLM | |
| import transformers | |
| import torch | |
| model = 'ericzzz/falcon-rw-1b-instruct-openorca' | |
| tokenizer = AutoTokenizer.from_pretrained(model) | |
| pipeline = transformers.pipeline( | |
| 'text-generation', | |
| model=model, | |
| tokenizer=tokenizer, | |
| torch_dtype=torch.bfloat16, | |
| device_map='auto', | |
| ) | |
| system_message = 'You are a helpful assistant. Give short answers.' | |
| instruction = 'What is AI? Give some examples.' | |
| prompt = f'<SYS> {system_message} <INST> {instruction} <RESP> ' | |
| response = pipeline( | |
| prompt, | |
| max_length=200, | |
| repetition_penalty=1.05 | |
| ) | |
| print(response[0]['generated_text']) | |
| # AI, or Artificial Intelligence, refers to the ability of machines and software to perform tasks that require human intelligence, such as learning, reasoning, and problem-solving. It can be used in various fields like computer science, engineering, medicine, and more. Some common applications include image recognition, speech translation, and natural language processing. | |
| ``` | |
| ## ⚠️ Limitations | |
| This model may generate inaccurate or misleading information and is prone to hallucination, creating plausible but false narratives. It lacks the ability to discern factual content from fiction and may inadvertently produce biased, harmful or offensive content. Its understanding of complex, nuanced queries is limited. Users should be aware of this and verify any information obtained from the model. | |
| The model is provided 'as is' without any warranties, and the creators are not liable for any damages arising from its use. Users are responsible for their interactions with the model. | |
| ## 📬 Contact | |
| For further inquiries or feedback, please contact at eric.fu96@aol.com. | |
| ## [Open LLM Leaderboard Evaluation Results](https://huggingface.co/spaces/HuggingFaceH4/open_llm_leaderboard) | |
| Detailed results can be found [here](https://huggingface.co/datasets/open-llm-leaderboard/details_ericzzz__falcon-rw-1b-instruct-openorca) | |
| | Metric |Value| | |
| |---------------------------------|----:| | |
| |Avg. |37.63| | |
| |AI2 Reasoning Challenge (25-Shot)|34.56| | |
| |HellaSwag (10-Shot) |60.93| | |
| |MMLU (5-Shot) |28.77| | |
| |TruthfulQA (0-shot) |37.42| | |
| |Winogrande (5-shot) |60.69| | |
| |GSM8k (5-shot) | 3.41| | |