Product Categorization
Generates suitable categories for a product, along with their relevance scores.
By providing the product name and its parameters, this API returns related categories and their weights as float values ranging from 1.0 to 10.0, where 10 represents the highest relevance.
This API is highly useful for developers building e-commerce platforms, product catalogue management systems, or bulk product processing tools. It automates the categorization of products, ensuring accuracy and consistency. Use cases include populating product catalogue data, enhancing product search algorithms, and improving inventory management systems.
You can set your preferred writing style by providing a voice_tone
parameter.
It can be adjectives like funny
or joyous
, or even the name of a famous writer.
Within an additional optional parameter context
, you can provide a list of other categories that will be taken into consideration during the mapping process (for example your current e-commerce categories).
You can limit the output with the max_quantity
parameter.
Only the content
parameter is required.
AI jobs involve two key steps::
- Submitting the AI job: Initiating the process by sending the job request.
- Monitoring and receiving results: Continuously checking the job status and obtaining the final output upon successful completion.
Step 1. Submit the AI Job request
Attribute | Type | Mandatory | Description |
---|---|---|---|
content | String | Yes | Product name and its parameters to generate the categories. |
language | String | No | Specify the language of the output, defaults to English . |
max_quantity | Number | No | Maximum number of product categories to generate. |
voice_tone | String | No | Preferred writing style parameter. It can be adjectives like funny or joyous , or even the name of a famous writer . |
context | String | No | The list of other categories that will be taken into consideration during the mapping process (for example your current e-commerce categories) |
REQUEST EXAMPLE:
{
"content": "Razer Blade 16 Gaming Laptop: NVIDIA GeForce RTX 4090-13th Gen Intel test 24-Core i9 HX CPU - 16\" Dual Mode Mini LED (4K UHD+ 120Hz & FHD+ 240Hz) - 32GB RAM - 2TB SSD - Compact GaN Charger - Windows 11",
"language": "English",
"max_quantity":100,
"voice_tone": "neutral",
"context":"Razer Laptops,Razer Gear"
}
RESPONSE EXAMPLE:
{
"status_url": "https://sharpapi.com/api/v1/content/translate/job/status/5de4887a-0dfd-49b6-8edb-9280e468c210",
"job_id": "5de4887a-0dfd-49b6-8edb-9280e468c210"
}
Step 2. Monitor & Fetch AI Job Results
Endpoint: GET - v1/ecommerce/product_categories/job/status/:uuid
An endpoint is used to check on the progress of the requested API job.
RESULT EXAMPLE:
{
"data": {
"type": "api_job_result",
"id": "6d3fec8c-34f8-4071-a5ba-af14910b4d77",
"attributes": {
"status": "success",
"type": "ecommerce_product_categories",
"result": [
{
"name": "Gaming Laptops",
"weight": 10
},
{
"name": "Razer Laptops",
"weight": 10
},
{
"name": "High-Performance Laptops",
"weight": 9.5
},
{
"name": "Laptops",
"weight": 9
},
{
"name": "Razer Gear",
"weight": 8.5
},
{
"name": "Electronics",
"weight": 8
},
{
"name": "Computers & Accessories",
"weight": 7.5
},
{
"name": "PC Gaming",
"weight": 7
},
{
"name": "Portable Computers",
"weight": 6.5
},
{
"name": "Tech Gadgets",
"weight": 6
}
]
}
}
}
- Related Keywords:
- Categorization
- E-commerce
When Laravel/PHP E-commerce App Meets AI
Jan 1, 2024
Hey fellow Laravel enthusiasts! In the ever-evolving landscape of e-commerce, integrating AI into your Laravel applications is not just a luxury, it’s a necessity. With SharpAPI’s Laravel package, it’s now easier than ever. In this blog, I’ll guide you through 10 transformative use cases for enhancing your Laravel-based e-commerce applications using SharpAPI.
Feb 2, 2024
SharpAPI is a powerful AI-powered API, which provides a range of workflow automation endpoints to help improve efficiency across various industries. It has features for E-commerce, Content & Marketing Automation, SEO, HR Tech, and Travel & Hospitality industries.
Leveraging AI for Enhanced Online Engagement
Jul 18, 2024
Let’s explore how AI can be leveraged to build scalable solutions for online engagement across various industries seeking to enhance efficiency and productivity through AI-driven workflow automation.