Welcome to the Text Classification API documentation. This API allows you to effortlessly categorize text into predefined themes such as sports, news, and entertainment. By leveraging a model trained on various text examples, you can quickly identify the most relevant category for any given text. Explore how to use the API to integrate text classification into your applications and access detailed information on making requests and interpreting responses.
Customizable Text Classification
With our Text Classification API, you have complete control over the categories used for classification. You can define your own set of categories and provide training data tailored to your specific needs. This flexibility allows you to create a classification model that perfectly matches your requirements, ensuring that the API delivers accurate and relevant results based on your custom categories.
By managing the training data, you can directly influence how the API classifies texts. You have the power to include diverse examples for each category, ensuring that the model understands the nuances of your specific classification criteria. This approach gives you the advantage of fine-tuning the classification process to meet your unique needs and preferences, making it an ideal solution for applications that require personalized text categorization.
Request Example
{
"text": "The team scored a last-minute goal to win the championship.",
"training": [
{
"label": "sports",
"text": "The player hit a home run to win the game in the final inning."
},
{
"label": "sports",
"text": "The football match ended with a thrilling penalty shootout."
},
{
"label": "news",
"text": "The government has announced new economic policies to boost the market."
},
{
"label": "news",
"text": "There was a major earthquake in the region causing widespread damage."
},
{
"label": "entertainment",
"text": "The new movie release was a huge hit at the box office."
},
{
"label": "entertainment",
"text": "The celebrity attended the glamorous award ceremony last night."
}
]
}
Usage Notes
Ensure that the training data is diverse and representative of the categories you wish to classify.