Skip to content

This project implements automated script generation using transformer-based machine learning models like GPT-2, GPT-3, and LLaMA. It fine-tunes pre-trained models on a dataset of movie scripts to generate coherent and contextually relevant dialogues.

License

Notifications You must be signed in to change notification settings

vikas83pal/Automated-Script-Generation-ML

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

23 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Automated Script Generation using Machine Learning

This project implements automated script generation using transformer-based machine learning models like GPT-2, GPT-3, and LLaMA. It fine-tunes pre-trained models on a dataset of movie scripts to generate coherent and contextually relevant dialogues.

Features

  • Fine-tuning GPT-2 on a custom dataset
  • Deploying the model on Hugging Face Spaces
  • Exposing API for chatbot interaction
  • Integrating with a React frontend

Deployment on Hugging Face Spaces

The model is deployed on Hugging Face Spaces using Gradio, which provides a user-friendly web interface for interaction. Below are the steps involved in deployment:

  1. Prepare the Model:

    • Use transformers from Hugging Face to load and fine-tune GPT-2 on a dataset of movie scripts.
    • Save the trained model and tokenizer for deployment.
  2. Create a Hugging Face Space:

    • Navigate to Hugging Face Spaces and create a new space.
    • Select Gradio as the application type.
  3. Upload the Model and Code:

    • Push the fine-tuned model and script files to the space repository using Git.
    • Implement a Gradio interface for real-time text generation.
  4. Expose the API:

    • The Gradio interface runs on server_name="0.0.0.0", server_port=7860.
    • The model API is available for integration with external applications like a React frontend.

Screenshots

Screenshot 1 Screenshot 2 Screenshot 3 Screenshot 4 Screenshot 5

Visit the Web Interface

Click the link below to interact with the AI script generator:

🔗 Hugging Face Space

About

This project implements automated script generation using transformer-based machine learning models like GPT-2, GPT-3, and LLaMA. It fine-tunes pre-trained models on a dataset of movie scripts to generate coherent and contextually relevant dialogues.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published