Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 6f7d9d1

Browse files
feat: update default filter
1 parent 96f394e commit 6f7d9d1

File tree

2 files changed

+10
-1
lines changed

2 files changed

+10
-1
lines changed

‎README.md‎

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -62,6 +62,15 @@ type Params = {
6262
};
6363
};
6464
bodyLimit?: number;
65+
// error catcher settings
66+
error?: {
67+
/**
68+
* throw: 默认模式,直接报错走 fastify 的 error catch
69+
* json: 将会以 json 形式返回错误
70+
* str: 将会以 str 形式返回错误,并且只保留 message
71+
*/
72+
mode?: "throw" | "json" | "str";
73+
};
6574
};
6675
```
6776

‎src/v1/chat/completions.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ const all_safety_category = [
3030
HarmCategory.HARM_CATEGORY_HARASSMENT,
3131
HarmCategory.HARM_CATEGORY_HATE_SPEECH,
3232
HarmCategory.HARM_CATEGORY_SEXUALLY_EXPLICIT,
33-
"HARM_CATEGORY_CIVIC_INTEGRITY" as any as HarmCategory,
33+
// "HARM_CATEGORY_CIVIC_INTEGRITY" as any as HarmCategory,
3434
// HarmCategory.HARM_CATEGORY_UNSPECIFIED,
3535
];
3636
const all_none_safety_settings = {

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /