id
int64
0
328k
repository_name
stringlengths
7
58
file_path
stringlengths
9
302
class_name
stringlengths
5
256
human_written_code
stringlengths
16
2.16M
class_skeleton
stringlengths
18
1.49M
total_program_units
int64
1
1.76k
total_doc_str
int64
0
771
AvgCountLine
float64
0
7.89k
AvgCountLineBlank
float64
0
297
AvgCountLineCode
float64
0
7.89k
AvgCountLineComment
float64
0
7.89k
AvgCyclomatic
float64
0
130
CommentToCodeRatio
float64
0
168
CountClassBase
float64
0
40
CountClassCoupled
float64
0
583
CountClassCoupledModified
float64
0
575
CountClassDerived
float64
0
5.35k
CountDeclInstanceMethod
float64
0
529
CountDeclInstanceVariable
float64
0
296
CountDeclMethod
float64
0
599
CountDeclMethodAll
float64
0
1.12k
CountLine
float64
1
40.4k
CountLineBlank
float64
0
8.16k
CountLineCode
float64
1
25.7k
CountLineCodeDecl
float64
1
8.15k
CountLineCodeExe
float64
0
24.2k
CountLineComment
float64
0
16.5k
CountStmt
float64
1
9.71k
CountStmtDecl
float64
1
8.15k
CountStmtExe
float64
0
9.69k
MaxCyclomatic
float64
0
759
MaxInheritanceTree
float64
0
16
MaxNesting
float64
0
34
SumCyclomatic
float64
0
2.9k
324,600
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/aigc/conversation.py
dashscope.aigc.conversation.HistoryItem
from dashscope.common.constants import DEPRECATED_MESSAGE, HISTORY, PROMPT from dashscope.common.logging import logger from typing import Any, Dict, Generator, List, Union class HistoryItem(dict): """A conversation history item. """ def __init__(self, role: str, text: str=None, **kwargs): """Init...
class HistoryItem(dict): '''A conversation history item. ''' def __init__(self, role: str, text: str=None, **kwargs): '''Init a history item. Args: role (str): The role name. text (str): The text history. Default ot None. kwargs: The key/value pair of hi...
3
3
13
2
5
7
2
1.36
1
2
0
0
2
1
2
29
31
5
11
5
8
15
11
5
8
3
2
1
4
324,601
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/aigc/generation.py
dashscope.aigc.generation.AioGeneration
from typing import Any, Dict, Generator, List, Union from dashscope.common.error import InputRequired, ModelRequired import json from dashscope.common.utils import _get_task_group_and_task from dashscope.client.base_api import BaseAioApi, BaseApi from dashscope.api_entities.dashscope_response import GenerationResponse,...
class AioGeneration(BaseAioApi): class Models: '''@deprecated, use qwen_turbo instead''' @classmethod async def call(cls, model: str, prompt: Any=None, history: list=None, api_key: str=None, messages: List[Message]=None, plugins: Union[str, Dict[str, Any]]=None, workspace: str=None, **kwargs) -> U...
4
2
118
2
40
76
6
1.57
1
9
5
0
0
0
1
3
136
5
51
27
37
80
28
16
25
6
1
2
6
324,602
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/aigc/generation.py
dashscope.aigc.generation.Generation
from dashscope.api_entities.dashscope_response import GenerationResponse, Message, Role import copy from dashscope.common.logging import logger from dashscope.client.base_api import BaseAioApi, BaseApi from dashscope.common.error import InputRequired, ModelRequired from dashscope.common.utils import _get_task_group_and...
class Generation(BaseApi): class Models: '''@deprecated, use qwen_turbo instead''' @classmethod def call(cls, model: str, prompt: Any=None, history: list=None, api_key: str=None, messages: List[Message]=None, plugins: Union[str, Dict[str, Any]]=None, workspace: str=None, **kwargs) -> Union[Generat...
6
2
78
2
38
38
9
0.92
1
10
6
0
0
0
2
4
175
8
87
34
70
80
54
21
50
11
1
2
17
324,603
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/aigc/image_synthesis.py
dashscope.aigc.image_synthesis.AioImageSynthesis
from dashscope.api_entities.dashscope_response import DashScopeAPIResponse, ImageSynthesisResponse from dashscope.client.base_api import BaseAsyncApi, BaseApi, BaseAsyncAioApi, BaseAioApi from dashscope.common.utils import _get_task_group_and_task from typing import Any, Dict, List, Union class AioImageSynthesis(BaseA...
class AioImageSynthesis(BaseAsyncAioApi): @classmethod async def call(cls, model: str, prompt: Any, negative_prompt: Any=None, images: List[str]=None, api_key: str=None, sketch_image_url: str=None, ref_img: str=None, workspace: str=None, extra_input: Dict=None, task: str=None, function: str=None, mask_image_u...
15
7
34
2
16
17
1
1.01
1
8
4
0
0
0
7
18
255
20
117
91
37
118
26
19
18
1
2
0
7
324,604
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/aigc/image_synthesis.py
dashscope.aigc.image_synthesis.ImageSynthesis
from dashscope.common.utils import _get_task_group_and_task from dashscope.client.base_api import BaseAsyncApi, BaseApi, BaseAsyncAioApi, BaseAioApi from dashscope.api_entities.dashscope_response import DashScopeAPIResponse, ImageSynthesisResponse from dashscope.utils.oss_utils import check_and_upload_local from dashsc...
class ImageSynthesis(BaseAsyncApi): class Models: @classmethod def call(cls, model: str, prompt: Any, negative_prompt: Any=None, images: List[str]=None, api_key: str=None, sketch_image_url: str=None, ref_img: str=None, workspace: str=None, extra_input: Dict=None, task: str=None, function: str=None, mask_...
18
7
40
3
23
15
3
0.62
1
8
4
0
0
0
8
17
344
30
194
111
101
120
70
28
60
17
2
2
24
324,605
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/aigc/multimodal_conversation.py
dashscope.aigc.multimodal_conversation.AioMultiModalConversation
from typing import Generator, List, Union from dashscope.api_entities.dashscope_response import MultiModalConversationResponse from dashscope.common.utils import _get_task_group_and_task from dashscope.common.error import InputRequired, ModelRequired from dashscope.client.base_api import BaseAioApi, BaseApi import copy...
class AioMultiModalConversation(BaseAioApi): '''Async MultiModal conversational robot interface. ''' class Models: @classmethod async def call(cls, model: str, messages: List, api_key: str=None, workspace: str=None, **kwargs) -> Union[MultiModalConversationResponse, Generator[MultiModalConversati...
6
3
54
2
24
28
5
1.05
1
11
3
0
0
0
2
4
119
6
55
29
40
58
33
18
29
5
1
4
10
324,606
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/aigc/multimodal_conversation.py
dashscope.aigc.multimodal_conversation.MultiModalConversation
from dashscope.common.error import InputRequired, ModelRequired from dashscope.common.utils import _get_task_group_and_task from dashscope.api_entities.dashscope_response import MultiModalConversationResponse from typing import Generator, List, Union from dashscope.utils.oss_utils import preprocess_message_element from...
class MultiModalConversation(BaseApi): '''MultiModal conversational robot interface. ''' class Models: @classmethod def call(cls, model: str, messages: List, api_key: str=None, workspace: str=None, **kwargs) -> Union[MultiModalConversationResponse, Generator[MultiModalConversationResponse, None, ...
6
3
54
2
24
28
5
1.05
1
11
3
0
0
0
2
4
119
6
55
29
40
58
33
18
29
5
1
4
10
324,607
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/aigc/video_synthesis.py
dashscope.aigc.video_synthesis.AioVideoSynthesis
from dashscope.api_entities.dashscope_response import DashScopeAPIResponse, VideoSynthesisResponse from dashscope.common.utils import _get_task_group_and_task from typing import Any, Dict, Union from dashscope.client.base_api import BaseAsyncApi, BaseAsyncAioApi class AioVideoSynthesis(BaseAsyncAioApi): @classmet...
class AioVideoSynthesis(BaseAsyncAioApi): @classmethod async def call(cls, model: str, prompt: Any=None, img_url: str=None, extend_prompt: bool=True, negative_prompt: str=None, template: str=None, api_key: str=None, extra_input: Dict=None, workspace: str=None, task: str=None, head_frame: str=None, tail_frame:...
13
6
35
3
16
16
1
0.92
1
8
3
0
0
0
6
17
221
21
104
74
38
96
21
15
14
2
2
0
7
324,608
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/aigc/video_synthesis.py
dashscope.aigc.video_synthesis.VideoSynthesis
from dashscope.api_entities.dashscope_response import DashScopeAPIResponse, VideoSynthesisResponse from dashscope.common.constants import PROMPT from dashscope.common.utils import _get_task_group_and_task from typing import Any, Dict, Union from dashscope.client.base_api import BaseAsyncApi, BaseAsyncAioApi from dashsc...
class VideoSynthesis(BaseAsyncApi): class Models: '''@deprecated, use wanx2.1-t2v-plus instead''' @classmethod def call(cls, model: str, prompt: Any=None, extend_prompt: bool=True, negative_prompt: str=None, template: str=None, img_url: str=None, api_key: str=None, extra_input: Dict=None, workspac...
16
7
41
4
24
14
4
0.55
1
7
2
0
0
0
7
16
322
36
185
103
104
101
73
31
64
18
2
2
25
324,609
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/aiohttp_request.py
dashscope.api_entities.aiohttp_request.AioHttpRequest
from dashscope.common.utils import async_to_sync from dashscope.common.constants import DEFAULT_REQUEST_TIMEOUT_SECONDS, SSE_CONTENT_TYPE, HTTPMethod from dashscope.common.error import UnsupportedHTTPMethod from dashscope.api_entities.base_request import AioBaseRequest import aiohttp from http import HTTPStatus from da...
class AioHttpRequest(AioBaseRequest): def __init__(self, url: str, api_key: str, http_method: str, stream: bool=True, async_request: bool=False, query: bool=False, timeout: int=DEFAULT_REQUEST_TIMEOUT_SECONDS, task_id: str=None) -> None: '''HttpSSERequest, processing http server sent event stream. ...
9
1
27
0
26
1
6
0.05
1
15
3
0
8
7
8
31
226
10
206
47
189
11
138
37
129
20
6
5
48
324,610
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/api_request_data.py
dashscope.api_entities.api_request_data.ApiRequestData
from dashscope.common.constants import ApiProtocol import aiohttp from urllib.parse import urlencode from dashscope.io.input_output import InputResolver import json class ApiRequestData: def __init__(self, model, task_group, task, function, input, form, is_binary_input, api_protocol) -> None: self.model =...
class ApiRequestData: def __init__(self, model, task_group, task, function, input, form, is_binary_input, api_protocol) -> None: pass def add_parameters(self, **params): pass def add_resources(self, resources): pass def to_request_object(self) -> str: '''Convert data...
13
5
12
0
9
3
2
0.35
0
4
2
0
12
14
12
12
158
16
106
52
83
37
78
42
65
5
0
2
27
324,611
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/base_request.py
dashscope.api_entities.base_request.AioBaseRequest
from abc import ABC, abstractmethod class AioBaseRequest(BaseRequest): @abstractmethod async def aio_call(self): raise NotImplementedError()
class AioBaseRequest(BaseRequest): @abstractmethod async def aio_call(self): pass
3
0
2
0
2
0
1
0
1
1
0
3
1
0
1
23
4
0
4
3
1
0
3
2
1
1
5
0
1
324,612
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/base_request.py
dashscope.api_entities.base_request.BaseRequest
import os import platform from dashscope.common.constants import DASHSCOPE_DISABLE_DATA_INSPECTION_ENV from dashscope.version import __version__ from abc import ABC, abstractmethod class BaseRequest(ABC): def __init__(self) -> None: ua = 'dashscope/%s; python/%s; platform/%s; processor/%s' % (__version__,...
class BaseRequest(ABC): def __init__(self) -> None: pass @abstractmethod def call(self): pass
4
0
8
1
7
0
2
0
1
1
0
1
2
1
2
22
18
2
16
7
12
0
9
6
6
2
4
1
3
324,613
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/chat_completion_types.py
dashscope.api_entities.chat_completion_types.ChatCompletion
from dataclasses import dataclass from dashscope.common.base_type import BaseObjectMixin from typing import List, Literal, Optional @dataclass(init=False) class ChatCompletion(BaseObjectMixin): status_code: int 'The call response status_code, 200 indicate create success.\n ' code: str 'The request f...
@dataclass(init=False) class ChatCompletion(BaseObjectMixin): def __init__(self, **kwargs): pass
3
0
16
1
15
0
4
0.73
1
3
2
0
1
0
1
10
53
8
26
6
24
19
22
6
20
4
2
2
4
324,614
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/chat_completion_types.py
dashscope.api_entities.chat_completion_types.ChatCompletionChunk
from typing import List, Literal, Optional from dataclasses import dataclass from dashscope.common.base_type import BaseObjectMixin @dataclass(init=False) class ChatCompletionChunk(BaseObjectMixin): status_code: int 'The call response status_code, 200 indicate create success.\n ' code: str 'The requ...
@dataclass(init=False) class ChatCompletionChunk(BaseObjectMixin): def __init__(self, **kwargs): pass
3
0
16
1
15
0
4
1.04
1
3
2
0
1
0
1
10
62
9
26
6
24
27
22
6
20
4
2
2
4
324,615
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/chat_completion_types.py
dashscope.api_entities.chat_completion_types.ChatCompletionMessage
from typing import List, Literal, Optional from dataclasses import dataclass from dashscope.common.base_type import BaseObjectMixin @dataclass(init=False) class ChatCompletionMessage(BaseObjectMixin): content: Optional[str] = None 'The contents of the message.' role: Literal['assistant'] 'The role of t...
@dataclass(init=False) class ChatCompletionMessage(BaseObjectMixin): def __init__(self, **kwargs): pass
3
0
14
2
12
0
4
0.41
1
3
2
0
1
0
1
10
30
6
17
7
15
7
14
7
12
4
2
2
4
324,616
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/chat_completion_types.py
dashscope.api_entities.chat_completion_types.ChatCompletionMessageToolCall
from dataclasses import dataclass from typing import List, Literal, Optional from dashscope.common.base_type import BaseObjectMixin @dataclass(init=False) class ChatCompletionMessageToolCall(BaseObjectMixin): id: str 'The ID of the tool call.' function: Function 'The function that the model called.' ...
@dataclass(init=False) class ChatCompletionMessageToolCall(BaseObjectMixin): def __init__(self, **kwargs): pass
3
0
8
1
7
0
2
0.27
1
2
1
0
1
0
1
10
17
3
11
2
9
3
9
2
7
2
2
1
2
324,617
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/chat_completion_types.py
dashscope.api_entities.chat_completion_types.ChatCompletionTokenLogprob
from dataclasses import dataclass from typing import List, Literal, Optional from dashscope.common.base_type import BaseObjectMixin @dataclass(init=False) class ChatCompletionTokenLogprob(BaseObjectMixin): token: str 'The token.' bytes: Optional[List[int]] = None 'A list of integers representing the UT...
@dataclass(init=False) class ChatCompletionTokenLogprob(BaseObjectMixin): def __init__(self, **kwargs): pass
3
0
11
1
10
0
3
1.07
1
1
0
0
1
0
1
10
38
7
15
5
13
16
13
5
11
3
2
2
3
324,618
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/chat_completion_types.py
dashscope.api_entities.chat_completion_types.Choice
from dashscope.common.base_type import BaseObjectMixin from typing import List, Literal, Optional from dataclasses import dataclass @dataclass(init=False) class Choice(BaseObjectMixin): finish_reason: Literal['stop', 'length', 'tool_calls', 'content_filter', 'function_call'] 'The reason the model stopped gener...
@dataclass(init=False) class Choice(BaseObjectMixin): def __init__(self, **kwargs): pass
3
0
12
2
10
0
3
0.63
1
3
2
0
1
0
1
10
32
6
16
3
14
10
12
3
10
3
2
1
3
324,619
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/chat_completion_types.py
dashscope.api_entities.chat_completion_types.ChoiceLogprobs
from dataclasses import dataclass from typing import List, Literal, Optional from dashscope.common.base_type import BaseObjectMixin @dataclass(init=False) class ChoiceLogprobs(BaseObjectMixin): content: Optional[List[ChatCompletionTokenLogprob]] = None 'A list of message content tokens with log probability inf...
@dataclass(init=False) class ChoiceLogprobs(BaseObjectMixin): def __init__(self, **kwargs): pass
3
0
11
1
10
0
3
0.08
1
2
1
0
1
0
1
10
14
1
12
5
10
1
10
5
8
3
2
2
3
324,620
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/chat_completion_types.py
dashscope.api_entities.chat_completion_types.CompletionUsage
from dataclasses import dataclass from dashscope.common.base_type import BaseObjectMixin @dataclass(init=False) class CompletionUsage(BaseObjectMixin): completion_tokens: int 'Number of tokens in the generated completion.' prompt_tokens: int 'Number of tokens in the prompt.' total_tokens: int '...
@dataclass(init=False) class CompletionUsage(BaseObjectMixin): def __init__(self, **kwargs): pass
3
0
2
0
2
0
1
0.5
1
1
0
0
1
0
1
10
11
2
6
2
4
3
6
2
4
1
2
0
1
324,621
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/chat_completion_types.py
dashscope.api_entities.chat_completion_types.Function
from dataclasses import dataclass from dashscope.common.base_type import BaseObjectMixin @dataclass(init=False) class Function(BaseObjectMixin): arguments: str '\n The arguments to call the function with, as generated by the model in JSON\n format. Note that the model does not always generate valid JSON,...
@dataclass(init=False) class Function(BaseObjectMixin): def __init__(self, **kwargs): pass
3
0
2
0
2
0
1
1.4
1
1
0
0
1
0
1
10
13
1
5
2
3
7
5
2
3
1
2
0
1
324,622
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/chat_completion_types.py
dashscope.api_entities.chat_completion_types.FunctionCall
from dataclasses import dataclass from dashscope.common.base_type import BaseObjectMixin @dataclass(init=False) class FunctionCall(BaseObjectMixin): arguments: str '\n The arguments to call the function with, as generated by the model in JSON\n format. Note that the model does not always generate valid J...
@dataclass(init=False) class FunctionCall(BaseObjectMixin): def __init__(self, **kwargs): pass
3
0
2
0
2
0
1
1.4
1
1
0
0
1
0
1
10
13
1
5
2
3
7
5
2
3
1
2
0
1
324,623
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/chat_completion_types.py
dashscope.api_entities.chat_completion_types.TopLogprob
from dataclasses import dataclass from typing import List, Literal, Optional from dashscope.common.base_type import BaseObjectMixin @dataclass(init=False) class TopLogprob(BaseObjectMixin): token: str 'The token.' bytes: Optional[List[int]] = None 'A list of integers representing the UTF-8 bytes repres...
@dataclass(init=False) class TopLogprob(BaseObjectMixin): def __init__(self, **kwargs): pass
3
0
2
0
2
0
1
1.83
1
1
0
0
1
0
1
10
21
4
6
3
4
11
6
3
4
1
2
0
1
324,624
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.Choice
from dataclasses import dataclass @dataclass(init=False) class Choice(DictMixin): finish_reason: str message: Message def __init__(self, finish_reason: str=None, message: Message=None, **kwargs): msgObject = None if message is not None and message: msgObject = Message(**message...
@dataclass(init=False) class Choice(DictMixin): def __init__(self, finish_reason: str=None, message: Message=None, **kwargs): pass
3
0
10
0
10
0
2
0
1
3
1
0
1
0
1
46
14
1
13
6
8
0
8
3
6
2
3
1
2
324,625
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.ConversationResponse
from dataclasses import dataclass @dataclass(init=False) class ConversationResponse(GenerationResponse): pass
@dataclass(init=False) class ConversationResponse(GenerationResponse): pass
2
0
0
0
0
0
0
0
1
0
0
0
0
0
0
47
2
0
2
1
1
0
2
1
1
0
5
0
0
324,626
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.DashScopeAPIResponse
from typing import Any, Dict, List, Union from dataclasses import dataclass @dataclass(init=False) class DashScopeAPIResponse(DictMixin): """The response content Args: request_id (str): The request id. status_code (int): HTTP status code, 200 indicates that the request was successf...
@dataclass(init=False) class DashScopeAPIResponse(DictMixin): '''The response content Args: request_id (str): The request id. status_code (int): HTTP status code, 200 indicates that the request was successful, and others indicate an error。 code (str): Error code if error occu...
3
1
15
0
15
0
1
0.45
1
4
0
11
1
0
1
46
34
2
22
9
13
10
9
2
7
1
3
0
1
324,627
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.DictMixin
from typing import Any, Dict, List, Union from dataclasses import dataclass import json @dataclass(init=False) class DictMixin(dict): __slots__ = () def __init__(self, *args, **kwargs): super().__init__(*args, **kwargs) def __getitem__(self, key): return super().__getitem__(key) def ...
@dataclass(init=False) class DictMixin(dict): def __init__(self, *args, **kwargs): pass def __getitem__(self, key): pass def __copy__(self): pass def __deepcopy__(self, memo): pass def __setitem__(self, key, value): pass def __delitem__(self, key): ...
20
0
2
0
2
0
1
0
1
3
0
34
18
0
18
45
61
18
43
22
24
0
43
22
24
2
2
1
19
324,628
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.GenerationOutput
from typing import Any, Dict, List, Union from dataclasses import dataclass @dataclass(init=False) class GenerationOutput(DictMixin): text: str choices: List[Choice] finish_reason: str def __init__(self, text: str=None, finish_reason: str=None, choices: List[Choice]=None, **kwargs): chs = None...
@dataclass(init=False) class GenerationOutput(DictMixin): def __init__(self, text: str=None, finish_reason: str=None, choices: List[Choice]=None, **kwargs): pass
3
0
14
0
14
0
3
0
1
3
1
0
1
0
1
46
19
1
18
8
12
0
11
4
9
3
3
2
3
324,629
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.GenerationResponse
from dataclasses import dataclass from http import HTTPStatus @dataclass(init=False) class GenerationResponse(DashScopeAPIResponse): output: GenerationOutput usage: GenerationUsage @staticmethod def from_api_response(api_response: DashScopeAPIResponse): if api_response.status_code == HTTPStatu...
@dataclass(init=False) class GenerationResponse(DashScopeAPIResponse): @staticmethod def from_api_response(api_response: DashScopeAPIResponse): pass
4
0
18
1
17
0
3
0
1
3
2
1
0
0
1
47
23
2
21
4
18
0
10
3
8
3
4
2
3
324,630
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.GenerationUsage
from dataclasses import dataclass @dataclass(init=False) class GenerationUsage(DictMixin): input_tokens: int output_tokens: int def __init__(self, input_tokens: int=0, output_tokens: int=0, **kwargs): super().__init__(input_tokens=input_tokens, output_tokens=output_tokens, **kwargs)
@dataclass(init=False) class GenerationUsage(DictMixin): def __init__(self, input_tokens: int=0, output_tokens: int=0, **kwargs): pass
3
0
7
0
7
0
1
0
1
2
0
0
1
0
1
46
11
1
10
5
5
0
5
2
3
1
3
0
1
324,631
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.ImageSynthesisOutput
from typing import Any, Dict, List, Union from dataclasses import dataclass @dataclass(init=False) class ImageSynthesisOutput(DictMixin): task_id: str task_status: str results: List[ImageSynthesisResult] def __init__(self, task_id: str=None, task_status: str=None, results: List[ImageSynthesisResult]=[...
@dataclass(init=False) class ImageSynthesisOutput(DictMixin): def __init__(self, task_id: str=None, task_status: str=None, results: List[ImageSynthesisResult]=[], **kwargs): pass
3
0
14
0
14
0
3
0
1
3
1
0
1
0
1
46
19
1
18
8
12
0
10
4
8
3
3
2
3
324,632
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.ImageSynthesisResponse
from http import HTTPStatus from dataclasses import dataclass @dataclass(init=False) class ImageSynthesisResponse(DashScopeAPIResponse): output: ImageSynthesisOutput usage: ImageSynthesisUsage @staticmethod def from_api_response(api_response: DashScopeAPIResponse): if api_response.status_code ...
@dataclass(init=False) class ImageSynthesisResponse(DashScopeAPIResponse): @staticmethod def from_api_response(api_response: DashScopeAPIResponse): pass
4
0
21
2
19
0
4
0
1
3
2
0
0
0
1
47
26
3
23
5
20
0
13
4
11
4
4
2
4
324,633
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.ImageSynthesisResult
from dataclasses import dataclass @dataclass(init=False) class ImageSynthesisResult(DictMixin): url: str def __init__(self, url: str='', **kwargs) -> None: super().__init__(url=url, **kwargs)
@dataclass(init=False) class ImageSynthesisResult(DictMixin): def __init__(self, url: str='', **kwargs) -> None: pass
3
0
2
0
2
0
1
0
1
2
0
0
1
0
1
46
5
1
4
2
2
0
4
2
2
1
3
0
1
324,634
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.ImageSynthesisUsage
from dataclasses import dataclass @dataclass(init=False) class ImageSynthesisUsage(DictMixin): image_count: int def __init__(self, image_count: int=None, **kwargs): super().__init__(image_count=image_count, **kwargs)
@dataclass(init=False) class ImageSynthesisUsage(DictMixin): def __init__(self, image_count: int=None, **kwargs): pass
3
0
2
0
2
0
1
0
1
2
0
0
1
0
1
46
5
1
4
2
2
0
4
2
2
1
3
0
1
324,635
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.Message
from typing import Any, Dict, List, Union class Message(DictMixin): role: str content: Union[str, List] def __init__(self, role: str, content: str=None, **kwargs): super().__init__(role=role, content=content, **kwargs) @classmethod def from_generation_response(cls, response: DictMixin): ...
class Message(DictMixin): def __init__(self, role: str, content: str=None, **kwargs): pass @classmethod def from_generation_response(cls, response: DictMixin): pass @classmethod def from_conversation_response(cls, response: DictMixin): pass
6
0
3
0
3
0
1
0
1
3
1
0
1
0
3
48
18
3
15
7
9
0
12
5
8
2
3
1
4
324,636
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.MultiModalConversationOutput
from dataclasses import dataclass from typing import Any, Dict, List, Union @dataclass(init=False) class MultiModalConversationOutput(DictMixin): choices: List[Choice] def __init__(self, text: str=None, finish_reason: str=None, choices: List[Choice]=None, **kwargs): chs = None if choices is no...
@dataclass(init=False) class MultiModalConversationOutput(DictMixin): def __init__(self, text: str=None, finish_reason: str=None, choices: List[Choice]=None, **kwargs): pass
3
0
14
0
14
0
3
0
1
3
1
0
1
0
1
46
17
1
16
8
10
0
9
4
7
3
3
2
3
324,637
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.MultiModalConversationResponse
from dataclasses import dataclass from http import HTTPStatus @dataclass(init=False) class MultiModalConversationResponse(DashScopeAPIResponse): output: MultiModalConversationOutput usage: MultiModalConversationUsage @staticmethod def from_api_response(api_response: DashScopeAPIResponse): if a...
@dataclass(init=False) class MultiModalConversationResponse(DashScopeAPIResponse): @staticmethod def from_api_response(api_response: DashScopeAPIResponse): pass
4
0
19
1
18
0
3
0
1
3
2
0
0
0
1
47
24
2
22
4
19
0
10
3
8
3
4
2
3
324,638
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.MultiModalConversationUsage
from dataclasses import dataclass @dataclass(init=False) class MultiModalConversationUsage(DictMixin): input_tokens: int output_tokens: int def __init__(self, input_tokens: int=0, output_tokens: int=0, **kwargs): super().__init__(input_tokens=input_tokens, output_tokens=output_tokens, **kwargs)
@dataclass(init=False) class MultiModalConversationUsage(DictMixin): def __init__(self, input_tokens: int=0, output_tokens: int=0, **kwargs): pass
3
0
7
0
7
0
1
0.1
1
2
0
0
1
0
1
46
13
2
10
5
5
1
5
2
3
1
3
0
1
324,639
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.ReRankOutput
from dataclasses import dataclass from typing import Any, Dict, List, Union @dataclass(init=False) class ReRankOutput(DictMixin): results: List[ReRankResult] def __init__(self, results: List[ReRankResult]=None, **kwargs): ress = None if results is not None: ress = [] fo...
@dataclass(init=False) class ReRankOutput(DictMixin): def __init__(self, results: List[ReRankResult]=None, **kwargs): pass
3
0
7
0
7
0
3
0
1
2
1
0
1
0
1
46
10
1
9
4
7
0
9
4
7
3
3
2
3
324,640
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.ReRankResponse
from dataclasses import dataclass from http import HTTPStatus @dataclass(init=False) class ReRankResponse(DashScopeAPIResponse): output: ReRankOutput usage: GenerationUsage @staticmethod def from_api_response(api_response: DashScopeAPIResponse): if api_response.status_code == HTTPStatus.OK: ...
@dataclass(init=False) class ReRankResponse(DashScopeAPIResponse): @staticmethod def from_api_response(api_response: DashScopeAPIResponse): pass
4
0
17
1
16
0
3
0
1
3
2
0
0
0
1
47
22
2
20
4
17
0
10
3
8
3
4
2
3
324,641
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.ReRankResult
from dataclasses import dataclass from typing import Any, Dict, List, Union @dataclass(init=False) class ReRankResult(DictMixin): index: int relevance_score: float document: Dict = None def __init__(self, index: int, relevance_score: float, document: Dict=None, **kwargs): super().__init__(inde...
@dataclass(init=False) class ReRankResult(DictMixin): def __init__(self, index: int, relevance_score: float, document: Dict=None, **kwargs): pass
3
0
9
0
9
0
1
0
1
3
0
0
1
0
1
46
14
1
13
7
7
0
6
3
4
1
3
0
1
324,642
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.ReRankUsage
from dataclasses import dataclass @dataclass(init=False) class ReRankUsage(DictMixin): total_tokens: int def __init__(self, total_tokens=None, **kwargs): super().__init__(total_tokens=total_tokens, **kwargs)
@dataclass(init=False) class ReRankUsage(DictMixin): def __init__(self, total_tokens=None, **kwargs): pass
3
0
2
0
2
0
1
0
1
1
0
0
1
0
1
46
5
1
4
2
2
0
4
2
2
1
3
0
1
324,643
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.RecognitionOutput
from dataclasses import dataclass from typing import Any, Dict, List, Union @dataclass(init=False) class RecognitionOutput(DictMixin): sentence: Union[Dict[str, Any], List[Any]] def __init__(self, sentence: Union[Dict[str, Any], List[Any]], **kwargs): super().__init__(sentence=sentence, **kwargs)
@dataclass(init=False) class RecognitionOutput(DictMixin): def __init__(self, sentence: Union[Dict[str, Any], List[Any]], **kwargs): pass
3
0
2
0
2
0
1
0
1
3
0
0
1
0
1
46
5
1
4
2
2
0
4
2
2
1
3
0
1
324,644
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.RecognitionResponse
from http import HTTPStatus from dataclasses import dataclass from typing import Any, Dict, List, Union @dataclass(init=False) class RecognitionResponse(DashScopeAPIResponse): output: RecognitionOutput usage: RecognitionUsage @staticmethod def from_api_response(api_response: DashScopeAPIResponse): ...
@dataclass(init=False) class RecognitionResponse(DashScopeAPIResponse): @staticmethod def from_api_response(api_response: DashScopeAPIResponse): pass @staticmethod def is_sentence_end(sentence: Dict[str, Any]) -> bool: '''Determine whether the speech recognition result is the end of a s...
6
1
16
1
13
2
4
0.1
1
6
2
1
0
0
2
48
38
4
31
8
26
3
19
6
16
5
4
3
7
324,645
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.RecognitionUsage
from dataclasses import dataclass @dataclass(init=False) class RecognitionUsage(DictMixin): duration: int def __init__(self, duration: int=0, **kwargs): super().__init__(duration=duration, **kwargs)
@dataclass(init=False) class RecognitionUsage(DictMixin): def __init__(self, duration: int=0, **kwargs): pass
3
0
2
0
2
0
1
0
1
2
0
0
1
0
1
46
5
1
4
2
2
0
4
2
2
1
3
0
1
324,646
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.Role
class Role: USER = 'user' SYSTEM = 'system' BOT = 'bot' ASSISTANT = 'assistant' ATTACHMENT = 'attachment'
class Role: pass
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
6
0
6
6
5
0
6
6
5
0
0
0
0
324,647
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.SpeechSynthesisOutput
from dataclasses import dataclass from typing import Any, Dict, List, Union @dataclass(init=False) class SpeechSynthesisOutput(DictMixin): sentence: Dict[str, Any] def __init__(self, sentence: Dict[str, Any], **kwargs): super().__init__(sentence=sentence, **kwargs)
@dataclass(init=False) class SpeechSynthesisOutput(DictMixin): def __init__(self, sentence: Dict[str, Any], **kwargs): pass
3
0
2
0
2
0
1
0
1
3
0
0
1
0
1
46
5
1
4
2
2
0
4
2
2
1
3
0
1
324,648
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.SpeechSynthesisResponse
from http import HTTPStatus from dataclasses import dataclass @dataclass(init=False) class SpeechSynthesisResponse(DashScopeAPIResponse): output: SpeechSynthesisOutput usage: SpeechSynthesisUsage @staticmethod def from_api_response(api_response: DashScopeAPIResponse): if api_response.status_co...
@dataclass(init=False) class SpeechSynthesisResponse(DashScopeAPIResponse): @staticmethod def from_api_response(api_response: DashScopeAPIResponse): pass
4
0
23
2
21
0
4
0
1
3
2
0
0
0
1
47
28
3
25
5
22
0
13
4
11
4
4
2
4
324,649
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.SpeechSynthesisUsage
from dataclasses import dataclass @dataclass(init=False) class SpeechSynthesisUsage(DictMixin): characters: int def __init__(self, characters: int=0, **kwargs): super().__init__(characters=characters, **kwargs)
@dataclass(init=False) class SpeechSynthesisUsage(DictMixin): def __init__(self, characters: int=0, **kwargs): pass
3
0
2
0
2
0
1
0
1
2
0
0
1
0
1
46
5
1
4
2
2
0
4
2
2
1
3
0
1
324,650
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.TextToSpeechAudio
from dataclasses import dataclass @dataclass(init=False) class TextToSpeechAudio(DictMixin): expires_at: int id: str data: str url: str def __init__(self, expires_at: int, id: str, data: str=None, url: str=None, **kwargs): super().__init__(expires_at=expires_at, id=id, data=data, url=url, ...
@dataclass(init=False) class TextToSpeechAudio(DictMixin): def __init__(self, expires_at: int, id: str, data: str=None, url: str=None, **kwargs): pass
3
0
11
0
11
0
1
0
1
3
0
0
1
0
1
46
17
1
16
7
9
0
7
2
5
1
3
0
1
324,651
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.TextToSpeechOutput
from dataclasses import dataclass @dataclass(init=False) class TextToSpeechOutput(DictMixin): finish_reason: str audio: TextToSpeechAudio def __init__(self, finish_reason: str=None, audio: TextToSpeechAudio=None, **kwargs): super().__init__(finish_reason=finish_reason, audio=audio, **kwargs)
@dataclass(init=False) class TextToSpeechOutput(DictMixin): def __init__(self, finish_reason: str=None, audio: TextToSpeechAudio=None, **kwargs): pass
3
0
7
0
7
0
1
0
1
3
1
0
1
0
1
46
11
1
10
5
5
0
5
2
3
1
3
0
1
324,652
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.TextToSpeechResponse
from http import HTTPStatus from dataclasses import dataclass @dataclass(init=False) class TextToSpeechResponse(DashScopeAPIResponse): output: TextToSpeechOutput usage: MultiModalConversationUsage @staticmethod def from_api_response(api_response: DashScopeAPIResponse): if api_response.status_c...
@dataclass(init=False) class TextToSpeechResponse(DashScopeAPIResponse): @staticmethod def from_api_response(api_response: DashScopeAPIResponse): pass
4
0
19
1
18
0
3
0
1
4
3
0
0
0
1
47
24
2
22
4
19
0
10
3
8
3
4
2
3
324,653
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.TranscriptionOutput
from dataclasses import dataclass @dataclass(init=False) class TranscriptionOutput(DictMixin): task_id: str task_status: str def __init__(self, task_id: str, task_status: str, **kwargs): super().__init__(task_id=task_id, task_status=task_status, **kwargs)
@dataclass(init=False) class TranscriptionOutput(DictMixin): def __init__(self, task_id: str, task_status: str, **kwargs): pass
3
0
2
0
2
0
1
0
1
2
0
0
1
0
1
46
6
1
5
2
3
0
5
2
3
1
3
0
1
324,654
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.TranscriptionResponse
from http import HTTPStatus from dataclasses import dataclass @dataclass(init=False) class TranscriptionResponse(DashScopeAPIResponse): output: TranscriptionOutput usage: TranscriptionUsage @staticmethod def from_api_response(api_response: DashScopeAPIResponse): if api_response.status_code == ...
@dataclass(init=False) class TranscriptionResponse(DashScopeAPIResponse): @staticmethod def from_api_response(api_response: DashScopeAPIResponse): pass
4
0
21
2
19
0
4
0
1
3
2
0
0
0
1
47
26
3
23
5
20
0
13
4
11
4
4
2
4
324,655
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.TranscriptionUsage
from dataclasses import dataclass @dataclass(init=False) class TranscriptionUsage(DictMixin): def __init__(self, **kwargs): super().__init__(**kwargs)
@dataclass(init=False) class TranscriptionUsage(DictMixin): def __init__(self, **kwargs): pass
3
0
2
0
2
0
1
0
1
1
0
0
1
0
1
46
3
0
3
2
1
0
3
2
1
1
3
0
1
324,656
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.VideoSynthesisOutput
from dataclasses import dataclass @dataclass(init=False) class VideoSynthesisOutput(DictMixin): task_id: str task_status: str video_url: str def __init__(self, task_id: str, task_status: str, video_url: str='', **kwargs): super().__init__(self, task_id=task_id, task_status=task_status, video_u...
@dataclass(init=False) class VideoSynthesisOutput(DictMixin): def __init__(self, task_id: str, task_status: str, video_url: str='', **kwargs): pass
3
0
10
0
10
0
1
0
1
2
0
0
1
0
1
46
15
1
14
6
8
0
6
2
4
1
3
0
1
324,657
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.VideoSynthesisResponse
from http import HTTPStatus from dataclasses import dataclass @dataclass(init=False) class VideoSynthesisResponse(DashScopeAPIResponse): output: VideoSynthesisOutput usage: VideoSynthesisUsage @staticmethod def from_api_response(api_response: DashScopeAPIResponse): if api_response.status_code ...
@dataclass(init=False) class VideoSynthesisResponse(DashScopeAPIResponse): @staticmethod def from_api_response(api_response: DashScopeAPIResponse): pass
4
0
21
2
19
0
4
0
1
3
2
0
0
0
1
47
26
3
23
5
20
0
13
4
11
4
4
2
4
324,658
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/dashscope_response.py
dashscope.api_entities.dashscope_response.VideoSynthesisUsage
from dataclasses import dataclass @dataclass(init=False) class VideoSynthesisUsage(DictMixin): video_count: int video_duration: int video_ratio: str def __init__(self, video_count: int=1, video_duration: int=0, video_ratio: str='', **kwargs): super().__init__(video_count=video_count, video_dur...
@dataclass(init=False) class VideoSynthesisUsage(DictMixin): def __init__(self, video_count: int=1, video_duration: int=0, video_ratio: str='', **kwargs): pass
3
0
9
0
9
0
1
0
1
3
0
0
1
0
1
46
14
1
13
6
7
0
6
2
4
1
3
0
1
324,659
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/encryption.py
dashscope.api_entities.encryption.Encryption
import dashscope import requests import base64 from dashscope.common.constants import ENCRYPTION_AES_SECRET_KEY_BYTES, ENCRYPTION_AES_IV_LENGTH import json from cryptography.hazmat.primitives import serialization, hashes from cryptography.hazmat.primitives.ciphers import Cipher, algorithms, modes from cryptography.hazm...
class Encryption: def __init__(self): pass def initialize(self): pass def encrypt(self, dict_plaintext): pass def decrypt(self, base64_ciphertext): pass def is_valid(self): pass def get_pub_key_id(self): pass def get_encrypted_aes_key_s...
21
3
10
2
7
1
1
0.17
0
5
0
0
8
7
14
14
161
40
103
54
82
18
80
48
65
3
0
1
18
324,660
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/http_request.py
dashscope.api_entities.http_request.HttpRequest
from dashscope.common.constants import DEFAULT_REQUEST_TIMEOUT_SECONDS, SSE_CONTENT_TYPE, HTTPMethod import certifi from dashscope.api_entities.encryption import Encryption from dashscope.api_entities.dashscope_response import DashScopeAPIResponse from dashscope.common.utils import _handle_aio_stream, _handle_aiohttp_f...
class HttpRequest(AioBaseRequest): def __init__(self, url: str, api_key: str, http_method: str, stream: bool=True, async_request: bool=False, query: bool=False, timeout: int=DEFAULT_REQUEST_TIMEOUT_SECONDS, task_id: str=None, flattened_output: bool=False, encryption: Optional[Encryption]=None) -> None: ''...
13
1
33
1
31
1
7
0.04
1
26
4
0
9
9
10
33
352
15
326
68
303
13
210
52
198
21
6
5
82
324,661
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/api_entities/websocket_request.py
dashscope.api_entities.websocket_request.WebSocketRequest
from typing import Tuple, Union from dashscope.common.logging import logger from dashscope.common.utils import async_to_sync from dashscope.api_entities.dashscope_response import DashScopeAPIResponse from dashscope.api_entities.base_request import AioBaseRequest import uuid from http import HTTPStatus from dashscope.co...
class WebSocketRequest(AioBaseRequest): def __init__(self, url: str, api_key: str, stream: bool=True, ws_stream_mode: str=WebsocketStreamingMode.OUT, is_binary_input: bool=False, timeout: int=DEFAULT_REQUEST_TIMEOUT_SECONDS, flattened_output: bool=False, pre_task_id=None) -> None: pass def add_header...
17
1
20
0
18
3
4
0.14
1
20
7
0
16
9
16
39
336
22
287
75
259
40
193
61
176
14
6
6
67
324,662
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/app/application.py
dashscope.app.application.Application
from dashscope.api_entities.api_request_factory import _build_api_request from dashscope.client.base_api import BaseApi from dashscope.api_entities.dashscope_response import Message, Role import copy from dashscope.app.application_response import ApplicationResponse from dashscope.common.api_key import get_default_api_...
class Application(BaseApi): class DocReferenceType: ''' doc reference type for rag completion ''' @classmethod def _validate_params(cls, api_key, app_id): pass @classmethod def call(cls, app_id: str, prompt: str=None, history: list=None, workspace: str=None, api_key: str=None, mess...
8
2
54
6
27
21
6
0.72
1
7
5
0
0
0
3
5
179
24
90
36
72
65
61
23
56
12
1
2
19
324,663
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/app/application_response.py
dashscope.app.application_response.ApplicationDocReference
from typing import Dict, List, Optional from dataclasses import dataclass from dashscope.api_entities.dashscope_response import DashScopeAPIResponse, DictMixin @dataclass(init=False) class ApplicationDocReference(DictMixin): index_id: str title: str doc_id: str doc_name: str doc_url: str text: ...
@dataclass(init=False) class ApplicationDocReference(DictMixin): def __init__(self, index_id: str=None, title: str=None, doc_id: str=None, doc_name: str=None, doc_url: str=None, text: str=None, biz_id: str=None, images: List[str]=None, page_number: List[int]=None, **kwargs): ''' Doc references for retrieva...
3
1
34
2
21
11
1
0.35
1
3
0
0
1
0
1
46
45
3
31
12
19
11
12
2
10
1
3
0
1
324,664
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/app/application_response.py
dashscope.app.application_response.ApplicationModelUsage
from dashscope.api_entities.dashscope_response import DashScopeAPIResponse, DictMixin from dataclasses import dataclass @dataclass(init=False) class ApplicationModelUsage(DictMixin): model_id: str input_tokens: int output_tokens: int def __init__(self, model_id: str=None, input_tokens: int=0, output_t...
@dataclass(init=False) class ApplicationModelUsage(DictMixin): def __init__(self, model_id: str=None, input_tokens: int=0, output_tokens: int=0, **kwargs): pass
3
0
9
0
9
0
1
0
1
3
0
0
1
0
1
46
14
1
13
6
7
0
6
2
4
1
3
0
1
324,665
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/app/application_response.py
dashscope.app.application_response.ApplicationOutput
from dashscope.api_entities.dashscope_response import DashScopeAPIResponse, DictMixin from typing import Dict, List, Optional from dataclasses import dataclass @dataclass(init=False) class ApplicationOutput(DictMixin): text: str finish_reason: str session_id: str thoughts: List[ApplicationThought] ...
@dataclass(init=False) class ApplicationOutput(DictMixin): def __init__(self, text: str=None, finish_reason: str=None, session_id: str=None, thoughts: List[ApplicationThought]=None, doc_references: List[ApplicationDocReference]=None, workflow_message: WorkflowMessage=None, **kwargs): pass
3
0
28
3
25
0
5
0
1
5
3
0
1
0
1
46
36
4
32
13
23
0
19
6
17
5
3
2
5
324,666
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/app/application_response.py
dashscope.app.application_response.ApplicationResponse
from dashscope.api_entities.dashscope_response import DashScopeAPIResponse, DictMixin from http import HTTPStatus from dataclasses import dataclass @dataclass(init=False) class ApplicationResponse(DashScopeAPIResponse): output: ApplicationOutput usage: ApplicationUsage @staticmethod def from_api_respo...
@dataclass(init=False) class ApplicationResponse(DashScopeAPIResponse): @staticmethod def from_api_response(api_response: DashScopeAPIResponse): pass
4
0
18
1
17
0
3
0
1
3
2
0
0
0
1
47
23
2
21
4
18
0
10
3
8
3
4
2
3
324,667
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/app/application_response.py
dashscope.app.application_response.ApplicationThought
from dashscope.api_entities.dashscope_response import DashScopeAPIResponse, DictMixin from dataclasses import dataclass from typing import Dict, List, Optional @dataclass(init=False) class ApplicationThought(DictMixin): thought: str action_type: str response: str action_name: str action: str ac...
@dataclass(init=False) class ApplicationThought(DictMixin): def __init__(self, thought: str=None, action_type: str=None, response: str=None, action_name: str=None, action: str=None, action_input_stream: str=None, action_input: Dict=None, observation: str=None, **kwargs): ''' Thought of app completion call ...
3
1
33
2
19
12
1
0.43
1
2
0
0
1
0
1
46
43
3
28
11
17
12
11
2
9
1
3
0
1
324,668
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/app/application_response.py
dashscope.app.application_response.ApplicationUsage
from dashscope.api_entities.dashscope_response import DashScopeAPIResponse, DictMixin from typing import Dict, List, Optional from dataclasses import dataclass @dataclass(init=False) class ApplicationUsage(DictMixin): models: List[ApplicationModelUsage] def __init__(self, models: List[ApplicationModelUsage]=N...
@dataclass(init=False) class ApplicationUsage(DictMixin): def __init__(self, models: List[ApplicationModelUsage]=None, **kwargs): pass
3
0
8
1
7
0
3
0
1
2
1
0
1
0
1
46
11
2
9
4
7
0
9
4
7
3
3
2
3
324,669
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/app/application_response.py
dashscope.app.application_response.WorkflowMessage
from dashscope.api_entities.dashscope_response import DashScopeAPIResponse, DictMixin from dataclasses import dataclass @dataclass(init=False) class WorkflowMessage(DictMixin): node_id: str node_name: str node_type: str node_status: str node_is_completed: str node_msg_seq_id: int message: s...
@dataclass(init=False) class WorkflowMessage(DictMixin): class Message(DictMixin): def __init__(self, node_id: str=None, node_name: str=None, node_type: str=None, node_status: str=None, node_is_completed: str=None, node_msg_seq_id: int=None, message: Message=None, **kwargs): ''' Workflow message. ...
4
1
29
2
17
10
1
0.36
1
4
1
0
1
0
1
46
42
4
28
11
17
10
13
3
10
1
3
0
1
324,670
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/assistants/assistant_types.py
dashscope.assistants.assistant_types.Assistant
from dashscope.common.base_type import BaseList, BaseObjectMixin from typing import Dict, List, Optional, Union from dataclasses import dataclass @dataclass(init=False) class Assistant(BaseObjectMixin): status_code: int 'The call response status_code, 200 indicate create success.\n ' code: str 'The ...
@dataclass(init=False) class Assistant(BaseObjectMixin): def __init__(self, **kwargs): pass
3
0
3
0
3
0
1
0.45
1
1
0
0
1
0
1
10
38
6
22
12
20
10
22
12
20
1
2
0
1
324,671
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/assistants/assistant_types.py
dashscope.assistants.assistant_types.AssistantFile
from dataclasses import dataclass from dashscope.common.base_type import BaseList, BaseObjectMixin @dataclass(init=False) class AssistantFile(BaseObjectMixin): id: str assistant_id: str created_at: int object: str def __init__(self, **kwargs): super().__init__(**kwargs)
@dataclass(init=False) class AssistantFile(BaseObjectMixin): def __init__(self, **kwargs): pass
3
0
2
0
2
0
1
0
1
1
0
0
1
0
1
10
8
1
7
2
5
0
7
2
5
1
2
0
1
324,672
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/assistants/assistant_types.py
dashscope.assistants.assistant_types.AssistantFileList
from dashscope.common.base_type import BaseList, BaseObjectMixin from typing import Dict, List, Optional, Union from dataclasses import dataclass @dataclass(init=False) class AssistantFileList(BaseList): data: List[AssistantFile] def __init__(self, has_more: bool=None, last_id: Optional[str]=None, first_id: O...
@dataclass(init=False) class AssistantFileList(BaseList): def __init__(self, has_more: bool=None, last_id: Optional[str]=None, first_id: Optional[str]=None, data: List[AssistantFile]=[], **kwargs): pass
3
0
11
0
11
0
1
0
1
4
1
0
1
0
1
11
14
1
13
7
6
0
4
2
2
1
3
0
1
324,673
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/assistants/assistant_types.py
dashscope.assistants.assistant_types.AssistantList
from dataclasses import dataclass from dashscope.common.base_type import BaseList, BaseObjectMixin from typing import Dict, List, Optional, Union @dataclass(init=False) class AssistantList(BaseList): data: List[Assistant] def __init__(self, has_more: bool=None, last_id: Optional[str]=None, first_id: Optional[...
@dataclass(init=False) class AssistantList(BaseList): def __init__(self, has_more: bool=None, last_id: Optional[str]=None, first_id: Optional[str]=None, data: List[Assistant]=[], **kwargs): pass
3
0
11
0
11
0
1
0
1
4
1
0
1
0
1
11
14
1
13
7
6
0
4
2
2
1
3
0
1
324,674
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/assistants/assistant_types.py
dashscope.assistants.assistant_types.DeleteResponse
from dashscope.common.base_type import BaseList, BaseObjectMixin from dataclasses import dataclass @dataclass(init=False) class DeleteResponse(BaseObjectMixin): id: str deleted: bool def __init__(self, **kwargs): super().__init__(**kwargs)
@dataclass(init=False) class DeleteResponse(BaseObjectMixin): def __init__(self, **kwargs): pass
3
0
2
0
2
0
1
0
1
1
0
0
1
0
1
10
6
1
5
2
3
0
5
2
3
1
2
0
1
324,675
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/assistants/assistant_types.py
dashscope.assistants.assistant_types.FunctionDefinition
from dashscope.common.base_type import BaseList, BaseObjectMixin from typing import Dict, List, Optional, Union from dataclasses import dataclass @dataclass(init=False) class FunctionDefinition(BaseObjectMixin): name: str description: Optional[str] = None parameters: Optional[Dict[str, object]] = None ...
@dataclass(init=False) class FunctionDefinition(BaseObjectMixin): def __init__(self, **kwargs): pass
3
0
2
0
2
0
1
0
1
1
0
0
1
0
1
10
7
1
6
4
4
0
6
4
4
1
2
0
1
324,676
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/assistants/assistant_types.py
dashscope.assistants.assistant_types.ToolCodeInterpreter
from dashscope.common.base_type import BaseList, BaseObjectMixin from dataclasses import dataclass @dataclass(init=False) class ToolCodeInterpreter(BaseObjectMixin): type: str = 'code_interpreter' def __init__(self, **kwargs): super().__init__(**kwargs)
@dataclass(init=False) class ToolCodeInterpreter(BaseObjectMixin): def __init__(self, **kwargs): pass
3
0
2
0
2
0
1
0
1
1
0
0
1
0
1
10
5
1
4
3
2
0
4
3
2
1
2
0
1
324,677
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/assistants/assistant_types.py
dashscope.assistants.assistant_types.ToolFunction
from dataclasses import dataclass from dashscope.common.base_type import BaseList, BaseObjectMixin @dataclass(init=False) class ToolFunction(BaseObjectMixin): function: FunctionDefinition type: str = 'function' def __init__(self, **kwargs): self.function = FunctionDefinition(**kwargs.pop('function...
@dataclass(init=False) class ToolFunction(BaseObjectMixin): def __init__(self, **kwargs): pass
3
0
3
0
3
0
1
0
1
2
1
0
1
0
1
10
7
1
6
3
4
0
6
3
4
1
2
0
1
324,678
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/assistants/assistant_types.py
dashscope.assistants.assistant_types.ToolSearch
from dashscope.common.base_type import BaseList, BaseObjectMixin from dataclasses import dataclass @dataclass(init=False) class ToolSearch(BaseObjectMixin): type: str = 'search' def __init__(self, **kwargs): super().__init__(**kwargs)
@dataclass(init=False) class ToolSearch(BaseObjectMixin): def __init__(self, **kwargs): pass
3
0
2
0
2
0
1
0
1
1
0
0
1
0
1
10
5
1
4
3
2
0
4
3
2
1
2
0
1
324,679
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/assistants/assistant_types.py
dashscope.assistants.assistant_types.ToolWanX
from dataclasses import dataclass from dashscope.common.base_type import BaseList, BaseObjectMixin @dataclass(init=False) class ToolWanX(BaseObjectMixin): type: str = 'wanx' def __init__(self, **kwargs): super().__init__(**kwargs)
@dataclass(init=False) class ToolWanX(BaseObjectMixin): def __init__(self, **kwargs): pass
3
0
2
0
2
0
1
0
1
1
0
0
1
0
1
10
5
1
4
3
2
0
4
3
2
1
2
0
1
324,680
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/assistants/assistants.py
dashscope.assistants.assistants.Assistants
from dashscope.assistants.assistant_types import Assistant, AssistantList, DeleteResponse from typing import Dict, List, Optional from dashscope.client.base_api import CancelMixin, CreateMixin, DeleteMixin, GetStatusMixin, ListObjectMixin, UpdateMixin from dashscope.common.error import ModelRequired class Assistants(C...
class Assistants(CreateMixin, CancelMixin, DeleteMixin, ListObjectMixin, GetStatusMixin, UpdateMixin): @classmethod def _create_assistant_object(cls, model: str=None, name: str=None, description: str=None, instructions: str=None, tools: Optional[List[Dict]]=None, file_ids: Optional[List[str]]=[], metadata: Di...
17
7
35
2
21
11
3
0.5
6
8
4
0
0
0
8
14
297
26
181
104
85
90
53
17
44
10
1
1
21
324,681
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/assistants/files.py
dashscope.assistants.files.Files
from typing import Optional from dashscope.common.error import InputRequired from dashscope.client.base_api import CreateMixin, DeleteMixin, GetStatusMixin, ListObjectMixin from dashscope.assistants.assistant_types import AssistantFile, AssistantFileList, DeleteResponse class Files(CreateMixin, DeleteMixin, ListObject...
class Files(CreateMixin, DeleteMixin, ListObjectMixin, GetStatusMixin): @classmethod def call(cls, assistant_id: str, *, file_id: str, workspace: str=None, api_key: str=None, **kwargs) -> AssistantFile: '''Create assistant file. Args: assistant_id (str): The target assistant id. ...
13
6
28
3
15
10
2
0.61
4
7
4
0
0
0
6
10
184
23
100
58
48
61
25
13
18
2
1
1
9
324,682
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/audio/asr/asr_phrase_manager.py
dashscope.audio.asr.asr_phrase_manager.AsrPhraseManager
from dashscope.api_entities.dashscope_response import DashScopeAPIResponse from http import HTTPStatus from dashscope.common.error import InvalidParameter from dashscope.client.base_api import BaseAsyncApi from dashscope.customize.finetunes import FineTunes from typing import Any, Dict from dashscope.common.logging imp...
class AsrPhraseManager(BaseAsyncApi): '''Hot word management for speech recognition. ''' @classmethod def create_phrases(cls, model: str, phrases: Dict[str, Any], training_type: str='compile_asr_phrase', workspace: str=None, **kwargs) -> DashScopeAPIResponse: '''Create hot words. Args: ...
11
6
36
6
19
11
3
0.57
1
7
3
0
0
0
5
14
191
32
101
42
69
58
55
16
49
5
2
1
17
324,683
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/audio/asr/recognition.py
dashscope.audio.asr.recognition.Recognition
import time from http import HTTPStatus from queue import Queue from dashscope.client.base_api import BaseApi from dashscope.api_entities.dashscope_response import RecognitionResponse import threading from dashscope.common.utils import _get_task_group_and_task import uuid from dashscope.common.logging import logger fro...
class Recognition(BaseApi): '''Speech recognition interface. Args: model (str): The requested model_id. callback (RecognitionCallback): A callback that returns speech recognition results. format (str): The input audio format for speech recognition. sample_rate (int):...
15
10
27
2
20
5
5
0.33
1
24
10
0
14
18
14
16
419
51
279
66
255
92
219
56
204
16
1
6
66
324,684
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/audio/asr/recognition.py
dashscope.audio.asr.recognition.RecognitionCallback
class RecognitionCallback: """An interface that defines callback methods for getting speech recognition results. # noqa E501 Derive from this class and implement its function to provide your own data. """ def on_open(self) -> None: pass def on_complete(self) -> None: pass d...
class RecognitionCallback: '''An interface that defines callback methods for getting speech recognition results. # noqa E501 Derive from this class and implement its function to provide your own data. ''' def on_open(self) -> None: pass def on_complete(self) -> None: pass...
6
1
2
0
2
0
1
0.27
0
1
1
2
5
0
5
5
18
4
11
6
5
3
11
6
5
1
0
0
5
324,685
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/audio/asr/recognition.py
dashscope.audio.asr.recognition.RecognitionResult
from dashscope.api_entities.dashscope_response import RecognitionResponse import json from typing import Any, Dict, List, Union class RecognitionResult(RecognitionResponse): """The result set of speech recognition, including the single-sentence recognition result returned by the callback mode, and all recog...
class RecognitionResult(RecognitionResponse): '''The result set of speech recognition, including the single-sentence recognition result returned by the callback mode, and all recognition results in a synchronized manner. ''' def __init__(self, response: RecognitionResponse, sentences: List[A...
8
5
9
0
7
2
2
0.3
1
3
0
0
5
7
6
54
63
6
44
19
33
13
32
15
25
5
5
4
14
324,686
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/audio/asr/transcription.py
dashscope.audio.asr.transcription.Transcription
from dashscope.client.base_api import BaseAsyncApi import asyncio from dashscope.common.constants import ApiProtocol, HTTPMethod import aiohttp import time from typing import List, Union from dashscope.common.logging import logger from dashscope.common.utils import _get_task_group_and_task from dashscope.api_entities.d...
class Transcription(BaseAsyncApi): '''API for File Transcription models. ''' class Models: @classmethod def call(cls, model: str, file_urls: List[str], phrase_id: str=None, api_key: str=None, workspace: str=None, **kwargs) -> TranscriptionResponse: '''Transcribe the given files synchronou...
16
6
27
3
15
10
2
0.63
1
10
4
0
0
0
7
16
215
28
115
58
74
72
60
24
51
4
2
3
17
324,687
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/audio/asr/translation_recognizer.py
dashscope.audio.asr.translation_recognizer.SentenceBaseObj
from typing import Any, Dict, List import json class SentenceBaseObj: def __init__(self) -> None: self.sentence_id: int = -1 self.text: str = None self.begin_time: int = None self.end_time: int = None self.words: List[WordObj] = [] self._raw_data = None @static...
class SentenceBaseObj: def __init__(self) -> None: pass @staticmethod def from_json(json_data: Dict[str, Any]): '''Create a SentenceBase object from a JSON dictionary. ''' pass def __str__(self) -> str: pass def __repr__(self): pass
6
1
7
0
6
1
1
0.07
0
4
1
2
3
6
4
4
32
3
27
13
21
2
23
12
18
2
0
1
5
324,688
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/audio/asr/translation_recognizer.py
dashscope.audio.asr.translation_recognizer.ThreadSafeBool
import threading class ThreadSafeBool: def __init__(self, initial_value=False): self._value = initial_value self._lock = threading.Lock() def set(self, value): with self._lock: self._value = value def get(self): with self._lock: return self._value
class ThreadSafeBool: def __init__(self, initial_value=False): pass def set(self, value): pass def get(self): pass
4
0
3
0
3
0
1
0
0
0
0
0
3
2
3
3
12
2
10
6
6
0
10
6
6
1
0
1
3
324,689
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/audio/asr/translation_recognizer.py
dashscope.audio.asr.translation_recognizer.TranscriptionResult
from typing import Any, Dict, List import json class TranscriptionResult(SentenceBaseObj): def __init__(self) -> None: self.stash: SentenceBaseObj = None self.is_sentence_end = False self.vad_pre_end: bool = False self.pre_end_failed: bool = False self.pre_end_timemillis: i...
class TranscriptionResult(SentenceBaseObj): def __init__(self) -> None: pass @staticmethod def from_json(json_data: Dict[str, Any]): '''Create a TranscriptionResult object from a JSON dictionary. ''' pass def __str__(self) -> str: pass def __repr__(self): ...
6
1
11
0
10
1
3
0.07
1
5
1
0
3
8
4
8
48
3
42
15
36
3
37
14
32
7
1
1
10
324,690
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/audio/asr/translation_recognizer.py
dashscope.audio.asr.translation_recognizer.Translation
import json from typing import Any, Dict, List class Translation(SentenceBaseObj): def __init__(self) -> None: self.language: str = None self.stash: SentenceBaseObj = None self.is_sentence_end = False self.vad_pre_end: bool = False self.pre_end_failed: bool = False ...
class Translation(SentenceBaseObj): def __init__(self) -> None: pass @staticmethod def from_json(json_data: Dict[str, Any]): '''Create a Translation object from a JSON dictionary. ''' pass def __str__(self) -> str: pass def __repr__(self): pass
6
1
11
0
10
1
3
0.07
1
5
1
0
3
9
4
8
50
4
43
16
37
3
39
15
34
7
1
1
10
324,691
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/audio/asr/translation_recognizer.py
dashscope.audio.asr.translation_recognizer.TranslationRecognizerCallback
class TranslationRecognizerCallback: """An interface that defines callback methods for getting translation recognizer results. # noqa E501 Derive from this class and implement its function to provide your own data. """ def on_open(self) -> None: pass def on_complete(self) -> None: ...
class TranslationRecognizerCallback: '''An interface that defines callback methods for getting translation recognizer results. # noqa E501 Derive from this class and implement its function to provide your own data. ''' def on_open(self) -> None: pass def on_complete(self) -> None...
6
1
2
0
2
0
1
0.25
0
2
2
1
5
0
5
5
19
4
12
7
5
3
11
6
5
1
0
0
5
324,692
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/audio/asr/translation_recognizer.py
dashscope.audio.asr.translation_recognizer.TranslationRecognizerChat
import uuid from dashscope.protocol.websocket import WebsocketStreamingMode from dashscope.common.logging import logger from threading import Timer from dashscope.common.constants import ApiProtocol from dashscope.common.error import InputDataRequired, InputRequired, InvalidParameter, InvalidTask, ModelRequired from ht...
class TranslationRecognizerChat(BaseApi): '''TranslationRecognizerChat interface. Args: model (str): The requested model_id. callback (TranslationRecognizerChat): A callback that returns TranslationRecognizerChat results. format (str): The input audio format. sample_...
14
9
21
1
16
4
4
0.33
1
19
10
0
13
21
13
15
313
35
211
54
188
70
165
45
151
12
1
5
52
324,693
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/audio/asr/translation_recognizer.py
dashscope.audio.asr.translation_recognizer.TranslationRecognizerRealtime
from queue import Queue import uuid from dashscope.common.logging import logger from dashscope.client.base_api import BaseApi from http import HTTPStatus from dashscope.common.utils import _get_task_group_and_task from dashscope.common.constants import ApiProtocol import threading from threading import Timer from dashs...
class TranslationRecognizerRealtime(BaseApi): '''TranslationRecognizerRealtime interface. Args: model (str): The requested model_id. callback (TranslationRecognizerRealtime): A callback that returns TranslationRecognizerRealtime results. format (str): The input audio format....
15
10
27
2
20
5
5
0.33
1
23
11
0
14
21
14
16
418
49
279
68
252
93
216
55
201
17
1
5
66
324,694
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/audio/asr/translation_recognizer.py
dashscope.audio.asr.translation_recognizer.TranslationRecognizerResultPack
from typing import Any, Dict, List class TranslationRecognizerResultPack: def __init__(self) -> None: self.transcription_result_list: List[TranscriptionResult] = [] self.translation_result_list: List[TranslationResult] = [] self.usage_list: List = [] self.request_id: str = None ...
class TranslationRecognizerResultPack: def __init__(self) -> None: pass
2
0
6
0
6
0
1
0
0
3
2
0
1
5
1
1
7
0
7
7
5
0
7
7
5
1
0
0
1
324,695
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/audio/asr/translation_recognizer.py
dashscope.audio.asr.translation_recognizer.TranslationResult
from typing import Any, Dict, List from dashscope.common.error import InputDataRequired, InputRequired, InvalidParameter, InvalidTask, ModelRequired import json class TranslationResult: def __init__(self) -> None: self.translations: Dict[str:Translation] = {} self.is_sentence_end = False s...
class TranslationResult: def __init__(self) -> None: pass def get_translation(self, language) -> Translation: pass def get_language_list(self) -> List[str]: pass @staticmethod def from_json(json_data: List): '''Create a TranslationResult object from a JSON diction...
8
1
5
0
5
0
2
0.06
0
5
2
0
5
3
6
6
39
5
32
14
24
2
28
13
21
4
0
3
11
324,696
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/audio/asr/translation_recognizer.py
dashscope.audio.asr.translation_recognizer.WordObj
from typing import Any, Dict, List import json class WordObj: def __init__(self) -> None: self.text: str = None self.begin_time: int = None self.end_time: int = None self.fixed: bool = False self._raw_data = None @staticmethod def from_json(json_data: Dict[str, Any...
class WordObj: def __init__(self) -> None: pass @staticmethod def from_json(json_data: Dict[str, Any]): '''Create a Word object from a JSON dictionary. ''' pass def __str__(self) -> str: pass def __repr__(self): pass
6
1
5
0
5
1
1
0.1
0
4
0
0
3
5
4
4
25
3
20
12
14
2
19
11
14
1
0
0
4
324,697
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/audio/asr/vocabulary.py
dashscope.audio.asr.vocabulary.VocabularyService
import time import aiohttp from typing import List from dashscope.common.constants import ApiProtocol, HTTPMethod import asyncio from dashscope.client.base_api import BaseApi from dashscope.common.logging import logger class VocabularyService(BaseApi): """ API for asr vocabulary service """ MAX_QUERY_T...
class VocabularyService(BaseApi): ''' API for asr vocabulary service ''' def __init__(self, api_key=None, workspace=None, model=None, **kwargs) -> None: pass def __call_with_input(self, input): pass def create_vocabulary(self, target_model: str, prefix: str, vocabulary: List[...
9
6
17
0
14
4
2
0.28
1
9
3
0
8
5
8
10
152
9
112
32
94
31
59
22
50
4
1
3
18
324,698
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/audio/asr/vocabulary.py
dashscope.audio.asr.vocabulary.VocabularyServiceException
class VocabularyServiceException(Exception): def __init__(self, request_id: str, status_code: int, code: str, error_message: str) -> None: self._request_id = request_id self._status_code = status_code self._code = code self._error_message = error_message def __str__(self): ...
class VocabularyServiceException(Exception): def __init__(self, request_id: str, status_code: int, code: str, error_message: str) -> None: pass def __str__(self): pass
3
0
4
0
4
0
1
0
1
2
0
0
2
4
2
12
10
1
9
8
5
0
8
7
5
1
3
0
2
324,699
dashscope/dashscope-sdk-python
/Users/umroot/Documents/PhD_works/PhD-Core-Contents/Class-level-dataset-curation/unseen_data/git_repos_for_analysis/dashscope_dashscope-sdk-python/dashscope/audio/qwen_omni/omni_realtime.py
dashscope.audio.qwen_omni.omni_realtime.AudioFormat
from enum import Enum, unique @unique class AudioFormat(Enum): PCM_16000HZ_MONO_16BIT = ('pcm', 16000, 'mono', '16bit', 'pcm16') PCM_24000HZ_MONO_16BIT = ('pcm', 24000, 'mono', '16bit', 'pcm16') def __init__(self, format, sample_rate, channels, bit_rate, format_str): self.format = format s...
@unique class AudioFormat(Enum): def __init__(self, format, sample_rate, channels, bit_rate, format_str): pass def __repr__(self): pass def __str__(self): pass
5
0
3
0
3
0
1
0.08
1
0
0
0
3
5
3
52
17
3
13
11
9
1
13
11
9
1
4
0
3