T5 Base Art Generation Multi-Instruct ONNX

ONNX version of Mitchins/t5-base-artgen-multi-instruct for optimized CPU inference.

Model Details

  • Base Model: T5-base (Google)
  • Training Samples: 297,282
  • Parameters: 222M
  • Format: ONNX (FP32)
  • Optimization: CPU inference optimized

Quad-Instruction Capabilities

  1. Standard Enhancement: Enhance this prompt: {text}
  2. Clean Enhancement: Enhance this prompt (no lora): {text}
  3. Technical Enhancement: Enhance this prompt (with lora): {text}
  4. Simplification: Simplify this prompt: {text}

Usage

from optimum.onnxruntime import ORTModelForSeq2SeqLM
from transformers import T5Tokenizer

# Load ONNX model
model = ORTModelForSeq2SeqLM.from_pretrained("Mitchins/t5-base-artgen-multi-instruct-ONNX")
tokenizer = T5Tokenizer.from_pretrained("Mitchins/t5-base-artgen-multi-instruct-ONNX")

# Example usage
text = "woman in red dress"
prompt = f"Enhance this prompt (no lora): {text}"

inputs = tokenizer(prompt, return_tensors="pt")
outputs = model.generate(**inputs, max_length=80)
result = tokenizer.decode(outputs[0], skip_special_tokens=True)

Performance

Optimized for CPU inference with significant speedup compared to PyTorch on CPU.

Downloads last month
5
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐Ÿ™‹ Ask for provider support

Model tree for Mitchins/t5-base-artgen-multi-instruct-ONNX

Base model

google-t5/t5-base
Quantized
(1)
this model