50 lines
1.2 KiB
Markdown
50 lines
1.2 KiB
Markdown
---
|
|
license: mit
|
|
base_model: numind/NuExtract-1.5-tiny
|
|
tags:
|
|
- gguf
|
|
- ingredient-parsing
|
|
- nuextract
|
|
- mealie
|
|
- lora
|
|
- qwen2
|
|
- text-generation
|
|
pipeline_tag: text-generation
|
|
---
|
|
|
|
# NuExtract-1.5-tiny Fine-tuned for Mealie Ingredient Parsing
|
|
|
|
LoRA fine-tuned version of [numind/NuExtract-1.5-tiny](https://huggingface.co/numind/NuExtract-1.5-tiny) (Qwen2.5-0.5B) for structured ingredient extraction in [mealie-llm-server](https://github.com/abyrne55/mealie-llm-server).
|
|
|
|
## Usage
|
|
|
|
Set `MODEL_INGREDIENT_EXTRACTOR` to the local GGUF path:
|
|
|
|
```bash
|
|
MODEL_INGREDIENT_EXTRACTOR=models/nuextract-1.5-tiny-finetuned-q8_0.gguf
|
|
```
|
|
|
|
The model expects the NuExtract 1.5 template format:
|
|
|
|
```
|
|
<|input|>
|
|
### Template:
|
|
{
|
|
"quantity": "",
|
|
"unit": "",
|
|
"food": "",
|
|
"note": ""
|
|
}
|
|
### Text:
|
|
1 cup arborio rice
|
|
|
|
<|output|>
|
|
```
|
|
|
|
Use [constrained grammar](https://github.com/ggml-org/llama.cpp/blob/master/grammars/README.md) during inference for best results.
|
|
|
|
## Training
|
|
|
|
- **Method**: LoRA (rank 16, alpha 32) targeting q/k/v/o projections
|
|
- **Framework**: HuggingFace `trl.SFTTrainer` + `peft`
|
|
- **Dataset**: [mealie-llm-server/training/ingredients.md](https://github.com/abyrne55/mealie-local-ai/blob/main/training/ingredients.md) |