Skip to content

Commit ea34fc1

Browse files
author
jinhaiyang
committed
【web_search】web_search
1 parent e172041 commit ea34fc1

File tree

2 files changed

+48
-0
lines changed

2 files changed

+48
-0
lines changed

zhipuai/types/web_search/__init__.py

Whitespace-only changes.
Lines changed: 48 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,48 @@
1+
2+
from __future__ import annotations
3+
4+
from typing import Union, Optional, List
5+
from typing_extensions import Literal, Required, TypedDict
6+
7+
__all__ = ["WebSearchParams"]
8+
9+
10+
class WebSearchParams(TypedDict):
11+
12+
search_engine: str
13+
"""搜索引擎"""
14+
15+
search_query: str
16+
"""搜索query文本"""
17+
18+
request_id: str
19+
"""由用户端传参,需保证唯一性;用于区分每次请求的唯一标识,用户端不传时平台会默认生成。"""
20+
21+
user_id: str
22+
"""用户端。"""
23+
24+
sensitive_word_check: Optional[SensitiveWordCheckRequest]
25+
26+
27+
28+
29+
/**
30+
* 用户端
31+
*/
32+
@JsonProperty("user_id")
33+
private String userId;
34+
35+
/**
36+
* 敏感词检测控制
37+
*/
38+
@JsonProperty("sensitive_word_check")
39+
private SensitiveWordCheckRequest sensitiveWordCheck;
40+
41+
42+
model: str
43+
request_id: Optional[str]
44+
stream: Optional[bool]
45+
messages: Union[str, List[str], List[int], object, None]
46+
scope: Optional[str] = None
47+
location: Optional[str] = None
48+
recent_days: Optional[int] = None

0 commit comments

Comments
 (0)