Skip to content

ChasingCode34/safe-step

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

3 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

🛠️ SafeStep: AI-Powered Manufacturing SOP Generator

SafeStep is a full-stack web application designed to streamline the creation, management, and accessibility of Standard Operating Procedures (SOPs) for the manufacturing industry.

By leveraging advanced AI models, SafeStep allows managers to generate detailed SOPs from scratch (via machine parameters) or by extracting context from existing manuals. It then converts those technical documents into worker-friendly conversational scripts and synthesizes them into highly customized, multilingual audio tracks.

✨ Key Features

  • Context Engine: Initialize SOPs by defining operational parameters (Machine Type, PPE, Worker Expertise) or by uploading existing PDF manuals for AI text extraction.
  • 7-Step Drafting Wizard: Step-by-step AI-assisted drafting for standard SOP sections (Purpose, Scope, References, Definitions, Roles, Procedure, Appendices).
  • Script Simplifier: Automatically translates dense, technical SOPs into conversational, easy-to-understand scripts designed for floor workers.
  • Voice Design Engineering: Integrates with the ElevenLabs Voice Design API to generate dynamic, custom AI voices tailored by age, gender, emotion, and pacing.
  • SOP Library: A centralized dashboard to view, download (PDF/Audio), edit, and manage all generated SOPs.

💻 Tech Stack

Frontend:

Backend:

Third-Party Services & APIs:

  • Google Gemini API (gemini-flash-latest): Used for PDF summarization, contextual drafting, and script simplification.
  • ElevenLabs API: Used for text-to-speech and on-the-fly Voice Design generation.
  • Cloudflare R2: S3-compatible object storage used to host uploaded manuals, generated .txt scripts, and .mp3 audio files.

🚀 Getting Started

Follow these instructions to set up and run the project locally.

Prerequisites

Make sure you have the following installed and set up on your machine:

  • Node.js (v18 or higher recommended)
  • Git
  • A MongoDB cluster (e.g., MongoDB Atlas)
  • A Cloudflare account with an R2 Bucket created
  • API Keys for Google Gemini and ElevenLabs

1. Clone the Repository

git clone https://github.com/YourUsername/YourNewRepo.git
cd YourNewRepo

2. Backend Setup

  1. Navigate to the backend directory:
    cd backend
  2. Install the backend dependencies:
    npm install
  3. Create a .env file in the backend directory and add your secret keys. Do not commit this file!
    PORT=5000
    MONGO_URI=your_mongodb_connection_string
    GEMINI_API_KEY=your_gemini_api_key
    ELEVENLABS_API_KEY=your_elevenlabs_api_key
    
    # Cloudflare R2 Storage Configurations
    R2_ACCOUNT_ID=your_cloudflare_account_id
    R2_ACCESS_KEY_ID=your_r2_access_key
    R2_SECRET_ACCESS_KEY=your_r2_secret_key
    R2_BUCKET_NAME=your_r2_bucket_name
    R2_PUBLIC_URL=your_r2_public_routing_url

3. Frontend Setup

  1. Open a new terminal window/tab and navigate to the frontend directory:
    cd frontend
  2. Install the frontend dependencies:
    npm install

4. Running the Application

You will need to run the backend and frontend servers simultaneously in two separate terminal windows.

Start the Backend Server:

cd backend
npm run dev

(The backend runs on http://localhost:5000)

Start the Frontend Server:

cd frontend
npm run dev

(The frontend runs on http://localhost:5173)

Once both are running, open your browser and navigate to http://localhost:5173 to use SafeStep!


Developed for the modern manufacturing floor.

About

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages