From 64c40d16f06534d36ca84806441879195c9bc697 Mon Sep 17 00:00:00 2001 From: Raphael Mitsch Date: Wed, 11 Oct 2023 12:06:16 +0200 Subject: [PATCH] Remove binary textcat example. Format. --- website/docs/api/large-language-models.mdx | 37 ++-------------------- 1 file changed, 3 insertions(+), 34 deletions(-) diff --git a/website/docs/api/large-language-models.mdx b/website/docs/api/large-language-models.mdx index 6f4ba344e..eaa896d74 100644 --- a/website/docs/api/large-language-models.mdx +++ b/website/docs/api/large-language-models.mdx @@ -673,22 +673,6 @@ prompt. The formatting of few-shot examples is the same as those for the [v1](#textcat-v1) implementation. -If you want to perform few-shot learning with a binary classifier, you can -provide positive and negative examples - e. g.: - -```json -[ - { - "text": "You won the lottery! Wire a fee of 200$ to be able to withdraw your winnings.", - "answer": "Spam" - }, - { - "text": "Your order #123456789 has arrived", - "answer": "NotSpam" - } -] -``` - #### spacy.TextCat.v2 {id="textcat-v2"} V2 includes all v1 functionality, with an improved prompt template. @@ -718,22 +702,6 @@ V2 includes all v1 functionality, with an improved prompt template. The formatting of few-shot examples is the same as those for the [v1](#textcat-v1) implementation. -If you want to perform few-shot learning with a binary classifier, you can -provide positive and negative examples - e. g.: - -```json -[ - { - "text": "You won the lottery! Wire a fee of 200$ to be able to withdraw your winnings.", - "answer": "Spam" - }, - { - "text": "Your order #123456789 has arrived", - "answer": "NotSpam" - } -] -``` - #### spacy.TextCat.v1 {id="textcat-v1"} Version 1 of the built-in TextCat task supports both zero-shot and few-shot @@ -784,8 +752,9 @@ supports `.yml`, `.yaml`, `.json` and `.jsonl`. path = "textcat_examples.json" ``` -If you want to perform few-shot learning with a binary classifier (i. e. a text either should or should not be assigned -to a given class), you can provide positive and negative examples with the POS/NEG label. An example for spam +If you want to perform few-shot learning with a binary classifier (i. e. a text +either should or should not be assigned to a given class), you can provide +positive and negative examples with the POS/NEG label. An example for spam classification: ```json