gated-model / README.md
gamer-to's picture
Upload 12 files
a442c5b verified
|
raw
history blame
1.51 kB
metadata
languages:
  - ar
  - en
license: mit
tags:
  - pytorch
  - llama
  - text-generation
  - conversational
  - chatbot
pipeline_tag: text-generation

Chat Model

This is a custom chat model fine-tuned for conversational AI. The model is based on LLaMA architecture and is specifically designed for Arabic and English conversations.

Model Details

  • Architecture: LLaMA
  • Task: Text Generation
  • Language: Arabic/English
  • License: MIT
  • Model Size: Large
  • Training Data: Custom conversational data
  • Optimization: Quantized (int8)

Usage

from transformers import AutoModelForCausalLM, AutoTokenizer

model = AutoModelForCausalLM.from_pretrained("AMRALMughira/chat-model")
tokenizer = AutoTokenizer.from_pretrained("AMRALMughira/chat-model")

# Example input
input_text = "مرحبا كيف حالك؟"
inputs = tokenizer(input_text, return_tensors="pt")
outputs = model.generate(
    **inputs,
    max_length=256,
    temperature=0.7,
    do_sample=True,
    top_p=0.95
)
response = tokenizer.decode(outputs[0], skip_special_tokens=True)

Inference API

This model is compatible with Hugging Face's Inference API. You can use it with the following endpoint:

POST https://api-inference.huggingface.co/models/AMRALMughira/chat-model

Model Performance

  • Optimized for conversational tasks
  • Supports both Arabic and English
  • Fast response times
  • High-quality responses

Requirements

  • PyTorch
  • Transformers
  • CUDA (optional for GPU acceleration)