Skip to content

SharathChandra1546/Jewelry-Design-Pattern

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

1 Commit
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

"# HALSVAR - Jewellery Generator

A full-stack web application that transforms jewelry design concepts into stunning visual representations using AI-powered image generation. HALSVAR provides three core services: text-to-image generation, sketch-to-reality rendering, and monochrome-to-color conversion.

Features

🎨 Three AI-Powered Services

  1. Text to Visuals

    • Convert descriptive text into jewelry design images
    • Multi-language support with auto-translation (Hindi, French, Spanish, Chinese, German, English, Telugu, Japanese)
    • Voice input with speech recognition
    • Real-time image generation
  2. Sketches to Reality

    • Transform hand-drawn sketches into professional-grade jewelry renders
    • Upload sketch images and receive fully rendered outputs
    • High-resolution image processing (1280x1280)
  3. Monochrome to Multicolor

    • Colorize black and white jewelry images
    • Advanced colorization algorithms
    • Preserve design details while adding vibrant colors

πŸ” User Authentication

  • Traditional username/password registration and login
  • Google OAuth integration
  • JWT-based session management
  • Password reset functionality
  • reCAPTCHA protection

πŸ’Ύ Data Management

  • MongoDB database with GridFS for image storage
  • User-specific design history
  • Persistent storage of input/output pairs
  • Secure cookie-based authentication

🎯 User Interface

  • Responsive React-based frontend
  • Bootstrap styling with custom CSS
  • Interactive dashboard with smooth scrolling
  • Profile management
  • Contact form

Tech Stack

Frontend

  • React 18.3.1 - UI framework
  • React Router 6.27.0 - Navigation
  • Bootstrap 5.3.3 - Styling
  • Axios - HTTP client
  • FontAwesome - Icons
  • Three.js - 3D graphics (optional features)

Backend

  • Node.js with Express 4.21.1
  • MongoDB with Mongoose 8.8.0
  • GridFS - Large file storage
  • JWT - Authentication
  • bcrypt - Password hashing
  • Multer - File uploads
  • Google OAuth2 - Social login

External Services

  • AI image generation APIs (ports 5001, 8000, 8001)
  • MyMemory Translation API
  • Google reCAPTCHA
  • Web Speech API

Project Structure

β”œβ”€β”€ src/
β”‚   β”œβ”€β”€ App.js              # Main app component with routing
β”‚   β”œβ”€β”€ Main.js             # Alternative main component
β”‚   β”œβ”€β”€ login.js            # Login/registration page
β”‚   β”œβ”€β”€ dashboard.js        # User dashboard
β”‚   β”œβ”€β”€ text.js             # Text-to-image service
β”‚   β”œβ”€β”€ sketch.js           # Sketch-to-reality service
β”‚   β”œβ”€β”€ black.js            # Monochrome-to-color service
β”‚   β”œβ”€β”€ contactus.js        # Contact form
β”‚   └── components/         # Reusable components
β”œβ”€β”€ models/
β”‚   └── User.js             # User schema
β”œβ”€β”€ public/                 # Static assets and Python scripts
β”œβ”€β”€ server.js               # Main authentication server (port 5000)
β”œβ”€β”€ servertext.js           # Text-to-image backend (port 1234)
β”œβ”€β”€ serversketch.js         # Sketch service backend (port 4567)
β”œβ”€β”€ serverblack.js          # Colorization backend (port 7654)
└── package.json            # Dependencies

Installation

  1. Clone the repository:
git clone <repository-url>
cd halsvar
  1. Install dependencies:
npm install
  1. Set up MongoDB:

    • Create a MongoDB Atlas account or use local MongoDB
    • Update the connection string in server files
  2. Configure environment variables:

    • Google OAuth Client ID
    • reCAPTCHA keys
    • JWT secret key

Running the Application

Start all servers:

  1. Frontend (port 3000):
npm start
  1. Authentication Server (port 5000):
node server.js
  1. Text-to-Image Service (port 1234):
node servertext.js
  1. Sketch Service (port 4567):
node serversketch.js
  1. Colorization Service (port 7654):
node serverblack.js
  1. AI Generation Services:
    • Port 5001: Text-to-image generation
    • Port 8000: Sketch rendering
    • Port 8001: Image colorization

API Endpoints

Authentication (Port 5000)

  • POST /register - User registration
  • POST /login - User login with reCAPTCHA
  • POST /google-login - Google OAuth login
  • POST /forgot-password - Password recovery
  • PATCH /reset-password - Password reset
  • GET /protected-route - JWT-protected endpoint

Text Service (Port 1234)

  • POST /upload-text-and-image - Save text prompt and generated image

Sketch Service (Port 4567)

  • POST /upload-sketches - Save input sketch and rendered output

Colorization Service (Port 7654)

  • POST /upload-images - Save B&W input and colorized output
  • GET /get-image/:id - Retrieve image by GridFS ID

Features in Detail

Multi-Language Support

The text-to-image service supports voice input in multiple languages with automatic translation to English for processing.

Image Storage

All images are stored in MongoDB using GridFS, allowing efficient storage and retrieval of large files.

User Dashboard

Personalized dashboard showing:

  • User profile with first letter avatar
  • Quick access to all three services
  • Smooth scroll navigation
  • Logout functionality

Security

  • Password hashing with bcrypt
  • JWT token authentication
  • HTTP-only cookies
  • reCAPTCHA verification
  • CORS protection

Browser Compatibility

  • Chrome (recommended for speech recognition)
  • Firefox
  • Safari
  • Edge

Contributing

Contributions are welcome! Please follow these steps:

  1. Fork the repository
  2. Create a feature branch
  3. Commit your changes
  4. Push to the branch
  5. Open a pull request

License

Β© HALSVAR. All Rights Reserved.

Contact

Acknowledgments

Built by the HALSVAR team with modern web technologies and AI integration."

About

A Multi domain image translation tool specified for jewellery design pattern conversion and generation using custom Pix2pix GAN

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors