CoolFace
Modelpublic

AventIQ-AI/Text-Summarization-for-Inventory-Reports

sourceHugging Faceupdated 1y agoView on Hugging Face
0likes8downloads
Model Card

๐Ÿง  TextSummarizerForInventoryReport-T5

A T5-based text summarization model fine-tuned on inventory report data. This model generates concise summaries of detailed inventory-related texts, making it useful for warehouse management, stock reporting, and supply chain documentation.

โœจ Model Highlights

  • โ€”๐Ÿ“Œ Based on t5-small from Hugging Face ๐Ÿค—
  • โ€”๐Ÿ” Fine-tuned on structured inventory report data (reporttext โ†’ summarytext)
  • โ€”๐Ÿ“‹ Generates meaningful and human-readable summaries
  • โ€”โšก Supports maximum input length of 512 tokens and output length of 128 tokens
  • โ€”๐Ÿง  Built using Hugging Face Transformers and PyTorch

๐Ÿง  Intended Uses

  • โ€”โœ… Inventory report summarization
  • โ€”โœ… Warehouse/logistics management automation
  • โ€”โœ… Business analytics and reporting dashboards

๐Ÿšซ Limitations

  • โ€”โŒ Not optimized for very long reports (>512 tokens)
  • โ€”๐ŸŒ Trained primarily on English-language technical/business reports
  • โ€”๐Ÿงพ Performance may degrade on unstructured or noisy input text
  • โ€”๐Ÿค” Not designed for creative or narrative summarization

๐Ÿ‹๏ธโ€โ™‚๏ธ Training Details

AttributeValue
Base Modelt5-small
DatasetCustom inventory reports
Max Input Tokens512
Max Output Tokens128
Epochs3
Batch Size2
OptimizerAdamW
Loss FunctionCrossEntropyLosS(with -100 padding mask)
FrameworkPyTorch + Hugging Face Transformers
HardwareCUDA-enabled GPU

๐Ÿš€ Usage

python

from transformers import T5Tokenizer, T5ForConditionalGeneration, Trainer, TrainingArguments
from datasets import Dataset
import torch
import torch.nn.functional as F

model_name = "AventIQ-AI/Text_Summarization_For_inventory_Report"
tokenizer = AutoTokenizer.from_pretrained(model_name)
model = AutoModelForSequenceClassification.from_pretrained(model_name)
model.eval()

def preprocess(example):
    input_text = "summarize: " + example["full_text"]
    input_enc = tokenizer(input_text, truncation=True, padding="max_length", max_length=512)
    target_enc = tokenizer(example["summary"], truncation=True, padding="max_length", max_length=64)
    input_enc["labels"] = target_enc["input_ids"]
    return input_enc

# Generate summary
summary = summarize(long_text, model, tokenizer)
print("Summary:", summary)

Repository Structure

.
 โ”œโ”€โ”€ model/               # Contains the quantized model files
 โ”œโ”€โ”€ tokenizer_config/    # Tokenizer configuration and vocabulary files
 โ”œโ”€โ”€ model.safensors/     # Fine Tuned Model
 โ”œโ”€โ”€ README.md            # Model documentation
 

๐Ÿค Contributing Contributions are welcome! Feel free to open an issue or submit a pull request if you have suggestions, improvements, or want to adapt the model to new domains.