This document shows the documentation of how the website works. This website is a requirement for my OJT it was given to us by our seniors in IT department in the Company that I entered for my internship. It is a product searching website sample to be used in their e-commers website. The file contains the documentation on how it can be used and what are the requirements for it to be tested or run.

# Product Searching Application
## Overview
This is a web application for product searching developed as part of our On-the-Job Training (OJT) program.
The application gives the user search capabilities for their products and options to filter on various criteria: categories, manufacturer, and so on.
## Tools and Frameworks
- Backend:
- Python
- Flask
- Frontend:
- HTML
- CSS
- JavaScript
- Database:
- MySQL
- Typesense (for search engine indexing)
---
## Features
1. Search Products: Customers can search for a product by typing in the search bar.
2. Filtered Options: Products can be filtered by category, manufacturers, and availability.
3. Multiple Faceted Search: The application uses Typesense to implement faceted search, ensuring accurate and fast filtering based on selected criteria.
4. Sorting: The user can choose to sort the products base on their price (asc or desc).
5. Pagination: Results are displayed with pagination for ease of navigation.
## Installation & Setup
#### 1. Clone the repository:
git clone <https://[email protected]/typesensepython/typesense-project.git>
#### 2. Install the required Python packages:
pip install python-dotenv
pip install flask
pip install mysql-connector-python
pip install typesense
#### 3. Set up .env, MySQL, and Typesense Cluster:
- Create Typesense Cluster
- Create a .env file that contains the connection to the MySQL Database and Typesense Cluster
#### 4. Creation of Typesense Collection:
- run python file "typesense_connector.py"
#### 5. Run Flask API :
- run python file "be_flask.py"
## Usage
* Access the application via the browser at <http://localhost:5000>.
* Use the search bar and filters to find products based on your needs.
## Project Structure
* ojt_project/ - Final folder containing the needed files.
* typesense_connector – Import MySQL Database (product table) to Typesense Cluster/Collection
* be_flask – Main Flask application file (*This is the file you need to run!!*).
* static/ – Contains static files (CSS, JS).
* templates/ – HTML templates for the frontend.
## Contributors
* Hontiveros, Jerome Andrei
* Martinez, Kate Eurisse
* Nudalo, Zachary Ralf Crescel Charles
This documentation allows other developers to understand the repository we created or the entire project. It explains the code structure, how it works, and the necessary installations and configurations required to run the site. By providing clear instructions, this documentation ensures a smoother development process and helps prevent errors when running the application.
