Skip to content

LuckyYaduvanshi5/Youtube-Script-Writer

Repository files navigation

Miniai Logo Premium YouTube Script Generator Film Projector

Generate engaging, SEO-optimized YouTube scripts effortlessly using the power of advanced AI, tailored to a personal, motivational, and relatable style!

App Screenshot

✨ Features

  • High Voltage AI-Powered Script Generation: Leverages cutting-edge AI to create unique scripts based on your topic.
  • Smiling Face with Sunglasses Customizable Tone: Generates scripts in a personal, desi, motivational, and slightly raw style.
  • Sparkles Engaging Structure: Follows a proven Hook β†’ Intro β†’ Content Body β†’ CTA β†’ Motivation structure.
  • Check Mark Button Built-in Checklist: Ensures key elements like hooks, examples, and CTAs are included.
  • Desktop Computer Vibrant & Responsive UI: Modern, full-width design that looks great on all devices.
  • Clipboard Markdown Formatting: Displays generated scripts with clear headings, lists, and emphasis.
  • Floppy Disk Export to DOCX: Easily download your formatted script as a .docx file.
  • Saluting Face Copy Raw Script: Copy the original Markdown text to your clipboard.

πŸ› οΈ Tech Stack

  • Frontend: HTML5, CSS3, Vanilla JavaScript
  • Backend: Node.js, Express.js
  • AI Model: Accessed via GitHub Models endpoint (e.g., GPT-4.1 / 4.5) using @azure/ai-inference
  • Markdown Rendering: Marked.js
  • DOCX Export: html-to-docx-buffer, FileSaver.js
  • Icons: Font Awesome

πŸš€ How to Use

Follow these steps to set up and run the script generator locally:

  1. Clone the Repository:

    git clone https://github.com/your-username/your-repo-name.git # Replace with your actual repo URL
    cd your-repo-name
  2. Install Dependencies: You need Node.js and npm installed. Run the following command in the project directory:

    npm install
  3. Get Your GitHub Personal Access Token (PAT):

    • The script generator requires a GitHub PAT to authenticate with the AI model endpoint provided by GitHub.
    • How to find/create a PAT:
      • Go to your GitHub Settings.
      • Navigate to Developer settings in the left sidebar.
      • Click on Personal access tokens > Tokens (classic).
      • Click Generate new token > Generate new token (classic).
      • Give your token a descriptive Note (e.g., "YouTube Script Generator").
      • Set an Expiration period (recommended for security).
      • Under Select scopes, make sure to check the read:public_key scope (or potentially other scopes required by the specific GitHub Models API you are using - consult their documentation if unsure). Do not grant excessive permissions.
      • Click Generate token.
      • 🚨 Important: Copy your new PAT immediately. You won't be able to see it again! Store it securely.
    • For more detailed instructions, visit the official GitHub documentation: Creating a personal access token
  4. Set Environment Variable:

    • You need to set your PAT as an environment variable named GITHUB_TOKEN before running the server. Do not hardcode it in the source code.
    • Linux/macOS:
      export GITHUB_TOKEN="your_actual_pat_here"
    • Windows (Command Prompt):
      set GITHUB_TOKEN=your_actual_pat_here
    • Windows (PowerShell):
      $env:GITHUB_TOKEN="your_actual_pat_here"
    • Replace your_actual_pat_here with the actual PAT you copied.
  5. Run the Server: Make sure you are in the project's root directory and have set the environment variable in the same terminal session.

    node server.js

    You should see output like Server running at http://localhost:3000.

  6. Access the App: Open your web browser and navigate to: http://localhost:3000

  7. Generate Scripts! Enter your desired script topic and click "Generate Script".

πŸ”’ Security Note

  • Your GitHub Personal Access Token (PAT) is sensitive. Keep it secure and never commit it directly into your source code or share it publicly.
  • Using environment variables (as implemented in server.js) is the recommended way to handle such secrets.
  • Grant only the minimum necessary scopes to your PAT.

🀝 Contributing (Optional)

Contributions, issues, and feature requests are welcome! Feel free to check issues page.

πŸ“„ License (Optional)

This project is licensed under the MIT License - see the LICENSE.md file for details. (You'll need to create a LICENSE.md file, typically containing the MIT License text if you choose MIT)

About

πŸ€– AI-powered YouTube script generator creating professional video scripts in minutes | 10K+ scripts generated

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors