-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathflow_response.py
More file actions
133 lines (106 loc) · 4.09 KB
/
flow_response.py
File metadata and controls
133 lines (106 loc) · 4.09 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
# This file was auto-generated by Fern from our API Definition.
from __future__ import annotations
import datetime as dt
import typing
import pydantic
import typing_extensions
from ..core.pydantic_utilities import IS_PYDANTIC_V2, update_forward_refs
from ..core.serialization import FieldMetadata
from ..core.unchecked_base_model import UncheckedBaseModel
from .environment_response import EnvironmentResponse
from .evaluator_aggregate import EvaluatorAggregate
from .user_response import UserResponse
class FlowResponse(UncheckedBaseModel):
"""
Response model for a Flow.
"""
path: str = pydantic.Field()
"""
Path of the Flow, including the name, which is used as a unique identifier.
"""
id: str = pydantic.Field()
"""
Unique identifier for the Flow.
"""
directory_id: typing.Optional[str] = pydantic.Field(default=None)
"""
ID of the directory that the file is in on Humanloop.
"""
attributes: typing.Dict[str, typing.Optional[typing.Any]] = pydantic.Field()
"""
A key-value object identifying the Flow Version.
"""
version_name: typing.Optional[str] = pydantic.Field(default=None)
"""
Unique name for the Flow version. Version names must be unique for a given Flow.
"""
version_description: typing.Optional[str] = pydantic.Field(default=None)
"""
Description of the Version.
"""
name: str = pydantic.Field()
"""
Name of the Flow.
"""
description: typing.Optional[str] = pydantic.Field(default=None)
"""
Description of the Flow.
"""
schema_: typing_extensions.Annotated[
typing.Optional[typing.Dict[str, typing.Optional[typing.Any]]], FieldMetadata(alias="schema")
] = pydantic.Field(default=None)
"""
The JSON schema for the File.
"""
readme: typing.Optional[str] = pydantic.Field(default=None)
"""
Long description of the file.
"""
tags: typing.Optional[typing.List[str]] = pydantic.Field(default=None)
"""
List of tags associated with the file.
"""
version_id: str = pydantic.Field()
"""
Unique identifier for the specific Flow Version. If no query params provided, the default deployed Flow Version is returned.
"""
type: typing.Optional[typing.Literal["flow"]] = None
environments: typing.Optional[typing.List[EnvironmentResponse]] = pydantic.Field(default=None)
"""
The list of environments the Flow Version is deployed to.
"""
created_at: dt.datetime
updated_at: dt.datetime
created_by: typing.Optional[UserResponse] = pydantic.Field(default=None)
"""
The user who created the Flow.
"""
last_used_at: dt.datetime
version_logs_count: int = pydantic.Field()
"""
The number of logs that have been generated for this Flow Version
"""
evaluator_aggregates: typing.Optional[typing.List[EvaluatorAggregate]] = pydantic.Field(default=None)
"""
Aggregation of Evaluator results for the Flow Version.
"""
evaluators: typing.Optional[typing.List["MonitoringEvaluatorResponse"]] = pydantic.Field(default=None)
"""
The list of Monitoring Evaluators associated with the Flow Version.
"""
if IS_PYDANTIC_V2:
model_config: typing.ClassVar[pydantic.ConfigDict] = pydantic.ConfigDict(extra="allow", frozen=True) # type: ignore # Pydantic v2
else:
class Config:
frozen = True
smart_union = True
extra = pydantic.Extra.allow
from .agent_linked_file_response import AgentLinkedFileResponse # noqa: E402, F401, I001
from .agent_response import AgentResponse # noqa: E402, F401, I001
from .evaluator_response import EvaluatorResponse # noqa: E402, F401, I001
from .monitoring_evaluator_response import MonitoringEvaluatorResponse # noqa: E402, F401, I001
from .prompt_response import PromptResponse # noqa: E402, F401, I001
from .tool_response import ToolResponse # noqa: E402, F401, I001
from .version_deployment_response import VersionDeploymentResponse # noqa: E402, F401, I001
from .version_id_response import VersionIdResponse # noqa: E402, F401, I001
update_forward_refs(FlowResponse)