galileo-core 3.80.0__py3-none-any.whl → 3.81.0__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
galileo_core/__init__.py CHANGED
@@ -1 +1 @@
1
- __version__ = "3.80.0"
1
+ __version__ = "3.81.0"
@@ -1,7 +1,8 @@
1
1
  from datetime import datetime, timezone
2
- from typing import Dict, List, Optional, Sequence, Type, Union
2
+ from typing import Dict, List, Optional, Sequence, Type, TypeAlias, Union
3
3
 
4
4
  from pydantic import UUID4, BaseModel, Field, TypeAdapter, field_validator
5
+ from pydantic_partial import PartialModelMixin
5
6
  from typing_extensions import Annotated, Any, get_args
6
7
 
7
8
  from galileo_core.schemas.logging.session import BaseSession
@@ -20,7 +21,7 @@ class RecordIdsWithMetrics(BaseModel):
20
21
  metrics: Dict[str, Any]
21
22
 
22
23
 
23
- class BaseRecord(BaseStep):
24
+ class BaseRecord(PartialModelMixin, BaseStep):
24
25
  id: UUID4 = Field(title="ID", description="Galileo ID of the session, trace or span")
25
26
  session_id: UUID4 = Field(title="Session ID", description="Galileo ID of the session")
26
27
  trace_id: Optional[UUID4] = Field(
@@ -234,3 +235,43 @@ class SessionRecordWithChildren(SessionRecord, RecordWithChildTraces):
234
235
 
235
236
 
236
237
  SpanRecordWithChildrenAdapter: TypeAdapter[SpanRecordWithChildren] = TypeAdapter(SpanRecordWithChildren)
238
+
239
+
240
+ PartialAgentSpanRecord: TypeAlias = AgentSpanRecord.model_as_partial() # type: ignore[valid-type]
241
+ PartialWorkflowSpanRecord: TypeAlias = WorkflowSpanRecord.model_as_partial() # type: ignore[valid-type]
242
+ PartialLlmSpanRecord: TypeAlias = LlmSpanRecord.model_as_partial() # type: ignore[valid-type]
243
+ PartialToolSpanRecord: TypeAlias = ToolSpanRecord.model_as_partial() # type: ignore[valid-type]
244
+ PartialRetrieverSpanRecord: TypeAlias = RetrieverSpanRecord.model_as_partial() # type: ignore[valid-type]
245
+ PartialTraceRecord: TypeAlias = TraceRecord.model_as_partial() # type: ignore[valid-type]
246
+ PartialSessionRecord: TypeAlias = SessionRecord.model_as_partial() # type: ignore[valid-type]
247
+
248
+
249
+ PartialSpanRecord: TypeAlias = Annotated[
250
+ Union[
251
+ PartialAgentSpanRecord,
252
+ PartialWorkflowSpanRecord,
253
+ PartialLlmSpanRecord,
254
+ PartialToolSpanRecord,
255
+ PartialRetrieverSpanRecord,
256
+ ],
257
+ Field(discriminator="type"),
258
+ ]
259
+
260
+
261
+ PartialSpanRecordAdapter: TypeAdapter[PartialSpanRecord] = TypeAdapter(PartialSpanRecord) # type: ignore[valid-type]
262
+
263
+
264
+ PartialSpanRecordTypes: List[Type[BaseRecord]] = list(get_args(get_args(PartialSpanRecord)[0]))
265
+
266
+
267
+ PartialRecordType: TypeAlias = Annotated[
268
+ Union[
269
+ PartialTraceRecord,
270
+ PartialSpanRecord,
271
+ PartialSessionRecord,
272
+ ],
273
+ Field(discriminator="type"),
274
+ ]
275
+
276
+
277
+ PartialRecordTypeAdapter: TypeAdapter[PartialRecordType] = TypeAdapter(PartialRecordType) # type: ignore[valid-type]
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.3
2
2
  Name: galileo-core
3
- Version: 3.80.0
3
+ Version: 3.81.0
4
4
  Summary: Shared schemas and configuration for Galileo's Python packages.
5
5
  License: Apache-2.0
6
6
  Keywords: llm,quality,language_models,galileo
@@ -31,6 +31,7 @@ Classifier: Typing :: Typed
31
31
  Provides-Extra: testing
32
32
  Requires-Dist: httpx (>=0.27.0,<0.29.0)
33
33
  Requires-Dist: pydantic (>=2.6.0,<3.0.0)
34
+ Requires-Dist: pydantic-partial (>=0.10.1,<0.11.0)
34
35
  Requires-Dist: pydantic-settings (>=2.2.1,<3.0.0)
35
36
  Requires-Dist: pyjwt (>=2.8.0,<3.0.0)
36
37
  Requires-Dist: pytest (>=8.2.1,<9.0.0) ; extra == "testing"
@@ -1,4 +1,4 @@
1
- galileo_core/__init__.py,sha256=9kHWlwK_NdaRDkSZqYPi2gl6X15DwsW3dOeK5xPOh5U,23
1
+ galileo_core/__init__.py,sha256=HNRblLuZoS2yJW9FwHR4inHitiqokCTC0JFja9KuSNo,23
2
2
  galileo_core/constants/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
3
3
  galileo_core/constants/config.py,sha256=MYvixj3X3CoiC38QVMdidApURKFOAaPaYoHhFESOJlU,329
4
4
  galileo_core/constants/dataset_format.py,sha256=H6ZigDd2QMpRcRhLC38e0hRoMh0kKbvdhbmS5yK1gZU,116
@@ -99,7 +99,7 @@ galileo_core/schemas/shared/message.py,sha256=-LQoadmHzeMYWAtmQEBwy0gDHw2VYfaSYf
99
99
  galileo_core/schemas/shared/message_role.py,sha256=fljQ9y6Rqgp2tAEsgRA25ys59waaR1F7JYZoG6sj-NA,186
100
100
  galileo_core/schemas/shared/messages.py,sha256=ENLwaLVSRbBL6HyOAXCbre-MoecjXG088hluVzastTk,423
101
101
  galileo_core/schemas/shared/metric.py,sha256=_Hw64RsLK7FBpx03minpQZwWb3oSfqiTU4KYEIBbpiI,249
102
- galileo_core/schemas/shared/records.py,sha256=0NctLyPrsXPomHrNVrC5zTZU0lRZ_AtFSLRx__Uok-8,8359
102
+ galileo_core/schemas/shared/records.py,sha256=W8BHCqTQq-oA3zIk3_KyqqiTsLs1E02r097AaHM6zeE,9908
103
103
  galileo_core/schemas/shared/scorers/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
104
104
  galileo_core/schemas/shared/scorers/base_configs.py,sha256=ejZpnCmyj_n_6FPhDsRG2Y16IwCMH0mc27fUvJNUT2E,2631
105
105
  galileo_core/schemas/shared/scorers/chain_aggregation.py,sha256=OpuCmR6wJ8GGFJEyJHKT5yvPJqdmx9YI51i-gdwQDDo,145
@@ -122,8 +122,8 @@ galileo_core/utils/dataset.py,sha256=wjm3NdNRuxj5mK7GqQUdA-Map_EB0SpFfM1QKapd6-A
122
122
  galileo_core/utils/json.py,sha256=ug5P-iozgmqXRhLZS3Dm_JPViTICboKukg1mqqBq2i4,327
123
123
  galileo_core/utils/name.py,sha256=kaDeZJ1K3-SSazYrUeSbUsQrnZlnOBYU42t-QvX-coE,204
124
124
  galileo_core/utils/scorer_validation.py,sha256=bjNmDZhNsmmb8qHBfndXVAL60W5nCvoDdKrAoAegxJg,11259
125
- galileo_core-3.80.0.dist-info/LICENSE,sha256=4D_6tarPnIYkAqF-0LzrodE9wFtSulO3V4RZf__MriE,10946
126
- galileo_core-3.80.0.dist-info/METADATA,sha256=oDcQb9GteeJlWkPjLrQktjhUAd4VhH8dPRKBp0SupVk,2680
127
- galileo_core-3.80.0.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
128
- galileo_core-3.80.0.dist-info/entry_points.txt,sha256=epOvdlN6_7ua8stNHURhJhXDIIrheccwYv0Z-QFmHJU,61
129
- galileo_core-3.80.0.dist-info/RECORD,,
125
+ galileo_core-3.81.0.dist-info/LICENSE,sha256=4D_6tarPnIYkAqF-0LzrodE9wFtSulO3V4RZf__MriE,10946
126
+ galileo_core-3.81.0.dist-info/METADATA,sha256=a01eAPr43IVC3tTjoEPrLk-kzAVkzHd_VQGQZYFm_2w,2731
127
+ galileo_core-3.81.0.dist-info/WHEEL,sha256=b4K_helf-jlQoXBBETfwnf4B04YC67LOev0jo4fX5m8,88
128
+ galileo_core-3.81.0.dist-info/entry_points.txt,sha256=epOvdlN6_7ua8stNHURhJhXDIIrheccwYv0Z-QFmHJU,61
129
+ galileo_core-3.81.0.dist-info/RECORD,,