Text Generation
Transformers
Safetensors
English
qwen3_5_text
aviation
notam
text-classification
conversational
Eval Results (legacy)
Instructions to use jgalego/notam-subject-qwen3.5-0.8b with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use jgalego/notam-subject-qwen3.5-0.8b with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-generation", model="jgalego/notam-subject-qwen3.5-0.8b") messages = [ {"role": "user", "content": "Who are you?"}, ] pipe(messages)# pip install -U transformers accelerate # Load model directly from transformers import AutoTokenizer, AutoModelForCausalLM tokenizer = AutoTokenizer.from_pretrained("jgalego/notam-subject-qwen3.5-0.8b") model = AutoModelForCausalLM.from_pretrained("jgalego/notam-subject-qwen3.5-0.8b", device_map="auto") 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=256) print(tokenizer.decode(outputs[0][inputs["input_ids"].shape[-1]:])) - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use jgalego/notam-subject-qwen3.5-0.8b with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "jgalego/notam-subject-qwen3.5-0.8b" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "jgalego/notam-subject-qwen3.5-0.8b", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }'Use Docker
docker model run hf.co/jgalego/notam-subject-qwen3.5-0.8b
- SGLang
How to use jgalego/notam-subject-qwen3.5-0.8b 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 "jgalego/notam-subject-qwen3.5-0.8b" \ --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": "jgalego/notam-subject-qwen3.5-0.8b", "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 "jgalego/notam-subject-qwen3.5-0.8b" \ --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": "jgalego/notam-subject-qwen3.5-0.8b", "messages": [ { "role": "user", "content": "What is the capital of France?" } ] }' - Docker Model Runner
How to use jgalego/notam-subject-qwen3.5-0.8b with Docker Model Runner:
docker model run hf.co/jgalego/notam-subject-qwen3.5-0.8b
|
Download README.md from jgalego/notam-subject-qwen3.5-0.8b: direct link, hf CLI and curl.
- Browser
- Download file 3.83 kB
-
https://huggingface.co/jgalego/notam-subject-qwen3.5-0.8b/resolve/main/README.md
- Command line
-
hf download hf://jgalego/notam-subject-qwen3.5-0.8b/README.md
-
curl -L -o README.md https://huggingface.co/jgalego/notam-subject-qwen3.5-0.8b/resolve/main/README.md
3.83 kB
| base_model: Qwen/Qwen3.5-0.8B | |
| datasets: | |
| - DEEL-AI/NOTAM | |
| - AirsideLabs/notam-typed-decisions | |
| language: en | |
| library_name: transformers | |
| license: apache-2.0 | |
| pipeline_tag: text-generation | |
| tags: | |
| - aviation | |
| - notam | |
| - text-classification | |
| model-index: | |
| - name: notam-subject-qwen3.5-0.8b | |
| results: | |
| - task: | |
| type: text-classification | |
| dataset: | |
| name: NOTAM subject, template-disjoint | |
| type: AirsideLabs/notam-typed-decisions | |
| metrics: | |
| - type: accuracy | |
| value: 0.948 | |
| name: Accuracy | |
| - type: macro_f1 | |
| value: 0.942 | |
| name: Macro-F1 | |
| # notam-subject-qwen3.5-0.8b | |
| [Qwen/Qwen3.5-0.8B](https://huggingface.co/Qwen/Qwen3.5-0.8B) fine-tuned with LoRA to name the subject of a NOTAM: one of the 13 classes in [DEEL-AI/NOTAM](https://huggingface.co/datasets/DEEL-AI/NOTAM). | |
| > [!WARNING] | |
| > **Research aid only. Not for flight operations.** Not certified or validated for flight planning, dispatch or pilot briefing. Always read the original NOTAM. | |
| > [!NOTE] | |
| > **What is a NOTAM?** A NOTAM is a short, standardized notice that alerts flight crews and dispatchers to a condition that may affect a flight, such as a closed runway, an unavailable navigation aid or a temporary airspace restriction. The compressed wording can be cryptic: `RWY 09/27 CLSD DUE TO WIP` means runway 09/27 is closed because work is in progress. | |
| ## 🚀 Usage | |
| ```python | |
| from transformers import AutoModelForCausalLM, AutoTokenizer | |
| repo = "jgalego/notam-subject-qwen3.5-0.8b" | |
| tokenizer = AutoTokenizer.from_pretrained(repo) | |
| model = AutoModelForCausalLM.from_pretrained(repo, dtype="auto") | |
| messages = [ | |
| {"role": "system", "content": "Name the main subject of the NOTAM. Answer with one of: Airspaces, Communication and Radar, GPS, Landing Navaids, Obstacles, Parking, Procedure, Runway, Services and Facilities, Signs and Lights, Taxiway, Terminal or Enroute Navaids, Wildlife."}, | |
| {"role": "user", "content": "RWY 09/27 CLSD DUE TO WIP"}, | |
| ] | |
| inputs = tokenizer.apply_chat_template( | |
| messages, | |
| add_generation_prompt=True, | |
| enable_thinking=False, | |
| return_tensors="pt", | |
| return_dict=True, | |
| ) | |
| out = model.generate(**inputs, max_new_tokens=12, do_sample=False) | |
| print(tokenizer.decode(out[0, inputs["input_ids"].shape[1] :], skip_special_tokens=True)) | |
| ``` | |
| Labels: Airspaces, Communication and Radar, GPS, Landing Navaids, Obstacles, Parking, Procedure, Runway, Services and Facilities, Signs and Lights, Taxiway, Terminal or Enroute Navaids, Wildlife. | |
| ## 🏋️ Training | |
| | | | | |
| |---|---| | |
| | Base | [Qwen/Qwen3.5-0.8B](https://huggingface.co/Qwen/Qwen3.5-0.8B) | | |
| | Data | [DEEL-AI/NOTAM](https://huggingface.co/datasets/DEEL-AI/NOTAM), train split | | |
| | Method | LoRA, r=16, alpha=32, all linear layers, merged | | |
| | Steps | 522 (2.0 epochs), batch size 16 | | |
| | Learning rate | 0.0002, cosine | | |
| | Mean train loss | 0.0672 | | |
| | Hardware | NVIDIA A10G, 16 min | | |
| ## 📊 Results | |
| Template-disjoint group of [AirsideLabs/notam-typed-decisions](https://huggingface.co/datasets/AirsideLabs/notam-typed-decisions): NOTAMs whose templates do not appear in training. Greedy decoding; answers outside the label set count as wrong. | |
| | Model | n | Accuracy | Macro-F1 | Invalid | | |
| |---|---|---|---|---| | |
| | jgalego/notam-subject-qwen3.5-0.8b | 3252 | 0.948 | 0.942 | 1 | | |
| | Qwen/Qwen3.5-0.8B | 3252 | 0.195 | 0.117 | 13 | | |
| Reference baselines reported by [Airside Labs](https://huggingface.co/datasets/AirsideLabs/notam-typed-decisions/blob/main/baselines.md) on the same group (n=3,252): | |
| | Model | Accuracy | Macro-F1 | | |
| |---|---|---| | |
| | TF-IDF + logistic regression | 0.936 | 0.930 | | |
| | Qwen3.5-4B, self-distilled | 0.904 | 0.894 | | |
| | Qwen3.5-4B, zero-shot | 0.787 | 0.750 | | |
| ## ⚠️ Limitations | |
| - Trained on 13 fixed classes; NOTAMs about anything else get the nearest one. | |
| - English ICAO-style NOTAM text only. |