Spaces:
Sleeping
Sleeping
Extend examples for classifier
Browse files
app.py
CHANGED
@@ -226,11 +226,20 @@ def text_to_text_generation(verbose, prompt):
|
|
226 |
|
227 |
is_kubectl_prompt = (
|
228 |
f"You are a helpful assistant who classifies prompts into three categories. [INST] Respond with 0 if it pertains to a 'kubectl' operation. This is an instruction that can be answered with a 'kubectl' action. Look for keywords like 'get', 'list', 'create', 'show', 'view', and other command-like words. This category is an instruction instead of a question. Respond with 1 only if the prompt is a question, and is about a definition related to Kubernetes, or non-action inquiries. Respond with 2 every other scenario, for example if the question is a general question, not related to Kubernetes or 'kubectl'.\n"
|
229 |
-
f"
|
230 |
-
f
|
231 |
-
f"
|
232 |
-
f"
|
233 |
-
f
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
234 |
f"response (0/1/2): "
|
235 |
)
|
236 |
|
|
|
226 |
|
227 |
is_kubectl_prompt = (
|
228 |
f"You are a helpful assistant who classifies prompts into three categories. [INST] Respond with 0 if it pertains to a 'kubectl' operation. This is an instruction that can be answered with a 'kubectl' action. Look for keywords like 'get', 'list', 'create', 'show', 'view', and other command-like words. This category is an instruction instead of a question. Respond with 1 only if the prompt is a question, and is about a definition related to Kubernetes, or non-action inquiries. Respond with 2 every other scenario, for example if the question is a general question, not related to Kubernetes or 'kubectl'.\n"
|
229 |
+
f"Here are some examples:\n"
|
230 |
+
f"text: List all pods in Kubernetes\n"
|
231 |
+
f"response (0/1/2): 0 \n"
|
232 |
+
f"text: What is a headless service and how to create one?\n"
|
233 |
+
f"response (0/1/2): 1 \n"
|
234 |
+
f"text: What is the capital of Hungary?\n"
|
235 |
+
f"response (0/1/2): 2 \n"
|
236 |
+
f"text: Display detailed information about the pod 'web-app-pod-1'\n"
|
237 |
+
f"response (0/1/2): 0 \n"
|
238 |
+
f"text: What are some typical foods in Germany?\n"
|
239 |
+
f"response (0/1/2): 2 \n"
|
240 |
+
f"text: What is a LoadBalancer in Kubernetes?\n"
|
241 |
+
f"response (0/1/2): 1 \n"
|
242 |
+
f'Classify the following: [/INST] \ntext: "{prompt}\n"'
|
243 |
f"response (0/1/2): "
|
244 |
)
|
245 |
|