Text Generation
Transformers
Safetensors
PEFT
Portuguese
llama
portuguese
instruct
conversational
Eval Results (legacy)
text-generation-inference
Instructions to use lrds-code/boana-7b-instruct with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use lrds-code/boana-7b-instruct with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="lrds-code/boana-7b-instruct") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("lrds-code/boana-7b-instruct") model = AutoModelForCausalLM.from_pretrained("lrds-code/boana-7b-instruct") messages = [ {"role": "user", "content": "Who are you?"}, ] inputs = tokenizer.apply_chat_template( messages, add_generation_prompt=True, tokenize=True, return_dict=True, return_tensors="pt", ).to(model.device) outputs = model.generate(**inputs, max_new_tokens=40) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - PEFT
How to use lrds-code/boana-7b-instruct with PEFT:
Task type is invalid.
- Notebooks
- Google Colab
- Kaggle
- Local Apps
- vLLM
How to use lrds-code/boana-7b-instruct with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "lrds-code/boana-7b-instruct" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "lrds-code/boana-7b-instruct", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/lrds-code/boana-7b-instruct
- SGLang
How to use lrds-code/boana-7b-instruct 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 "lrds-code/boana-7b-instruct" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "lrds-code/boana-7b-instruct", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'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 "lrds-code/boana-7b-instruct" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "lrds-code/boana-7b-instruct", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use lrds-code/boana-7b-instruct with Docker Model Runner:
docker model run hf.co/lrds-code/boana-7b-instruct
Fixing some errors of the leaderboard evaluation results in the ModelCard yaml
Browse filesThe name of a few benchmarks are incorrect on the model metadata. This commit fixes some minor errors of the [last PR](1) on the ModelCard YAML metadata.
README.md
CHANGED
|
@@ -83,6 +83,19 @@ model-index:
|
|
| 83 |
- type: f1_macro
|
| 84 |
value: 48.84
|
| 85 |
name: f1-macro
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 86 |
- type: pearson
|
| 87 |
value: 37.56
|
| 88 |
name: pearson
|
|
@@ -110,7 +123,7 @@ model-index:
|
|
| 110 |
name: Text Generation
|
| 111 |
dataset:
|
| 112 |
name: HateBR Binary
|
| 113 |
-
type:
|
| 114 |
split: test
|
| 115 |
args:
|
| 116 |
num_few_shot: 25
|
|
@@ -118,6 +131,19 @@ model-index:
|
|
| 118 |
- type: f1_macro
|
| 119 |
value: 85.0
|
| 120 |
name: f1-macro
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 121 |
- type: f1_macro
|
| 122 |
value: 67.43
|
| 123 |
name: f1-macro
|
|
|
|
| 83 |
- type: f1_macro
|
| 84 |
value: 48.84
|
| 85 |
name: f1-macro
|
| 86 |
+
source:
|
| 87 |
+
url: https://huggingface.co/spaces/eduagarcia/open_pt_llm_leaderboard?query=lrds-code/boana-7b-instruct
|
| 88 |
+
name: Open Portuguese LLM Leaderboard
|
| 89 |
+
- task:
|
| 90 |
+
type: text-generation
|
| 91 |
+
name: Text Generation
|
| 92 |
+
dataset:
|
| 93 |
+
name: Assin2 STS
|
| 94 |
+
type: eduagarcia/portuguese_benchmark
|
| 95 |
+
split: test
|
| 96 |
+
args:
|
| 97 |
+
num_few_shot: 15
|
| 98 |
+
metrics:
|
| 99 |
- type: pearson
|
| 100 |
value: 37.56
|
| 101 |
name: pearson
|
|
|
|
| 123 |
name: Text Generation
|
| 124 |
dataset:
|
| 125 |
name: HateBR Binary
|
| 126 |
+
type: ruanchaves/hatebr
|
| 127 |
split: test
|
| 128 |
args:
|
| 129 |
num_few_shot: 25
|
|
|
|
| 131 |
- type: f1_macro
|
| 132 |
value: 85.0
|
| 133 |
name: f1-macro
|
| 134 |
+
source:
|
| 135 |
+
url: https://huggingface.co/spaces/eduagarcia/open_pt_llm_leaderboard?query=lrds-code/boana-7b-instruct
|
| 136 |
+
name: Open Portuguese LLM Leaderboard
|
| 137 |
+
- task:
|
| 138 |
+
type: text-generation
|
| 139 |
+
name: Text Generation
|
| 140 |
+
dataset:
|
| 141 |
+
name: PT Hate Speech Binary
|
| 142 |
+
type: hate_speech_portuguese
|
| 143 |
+
split: test
|
| 144 |
+
args:
|
| 145 |
+
num_few_shot: 25
|
| 146 |
+
metrics:
|
| 147 |
- type: f1_macro
|
| 148 |
value: 67.43
|
| 149 |
name: f1-macro
|