Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
@@ -15,23 +15,17 @@ generation_config = {
|
|
15 |
}
|
16 |
|
17 |
safety_settings = [
|
18 |
-
|
19 |
-
|
20 |
-
|
21 |
-
|
22 |
-
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
|
28 |
-
|
29 |
-
},
|
30 |
-
{
|
31 |
-
"category": "HARM_CATEGORY_DANGEROUS_CONTENT",
|
32 |
-
"threshold": "BLOCK_NONE"
|
33 |
-
},
|
34 |
-
]
|
35 |
|
36 |
model = genai.GenerativeModel(
|
37 |
model_name="gemini-pro",
|
|
|
15 |
}
|
16 |
|
17 |
safety_settings = [
|
18 |
+
{"category": "HARM_CATEGORY_HARASSMENT", "threshold": "BLOCK_NONE"},
|
19 |
+
{"category": "HARM_CATEGORY_HATE_SPEECH", "threshold": "BLOCK_NONE"},
|
20 |
+
{
|
21 |
+
"category": "HARM_CATEGORY_SEXUALLY_EXPLICIT",
|
22 |
+
"threshold": "BLOCK_NONE",
|
23 |
+
},
|
24 |
+
{
|
25 |
+
"category": "HARM_CATEGORY_DANGEROUS_CONTENT",
|
26 |
+
"threshold": "BLOCK_NONE",
|
27 |
+
},
|
28 |
+
]
|
|
|
|
|
|
|
|
|
|
|
|
|
29 |
|
30 |
model = genai.GenerativeModel(
|
31 |
model_name="gemini-pro",
|