raindrop-ai 0.0.31__tar.gz → 0.0.33__tar.gz

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.
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: raindrop-ai
3
- Version: 0.0.31
3
+ Version: 0.0.33
4
4
  Summary: Raindrop AI (Python SDK)
5
5
  License: MIT
6
6
  Author: Raindrop AI
@@ -13,7 +13,7 @@ Classifier: Programming Language :: Python :: 3.11
13
13
  Classifier: Programming Language :: Python :: 3.12
14
14
  Requires-Dist: pydantic (>=2.09,<3)
15
15
  Requires-Dist: requests (>=2.32.3,<3.0.0)
16
- Requires-Dist: traceloop-sdk (==0.45.6)
16
+ Requires-Dist: traceloop-sdk (>=0.46.0)
17
17
  Description-Content-Type: text/markdown
18
18
 
19
19
  # Raindrop Python SDK
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "raindrop-ai"
3
- version = "0.0.31"
3
+ version = "0.0.33"
4
4
  description = "Raindrop AI (Python SDK)"
5
5
  authors = ["Raindrop AI <sdk@raindrop.ai>"]
6
6
  license = "MIT"
@@ -11,7 +11,7 @@ packages = [{include = "raindrop"}]
11
11
  python = ">=3.10,<3.12.1 || >3.12.1,<4.0"
12
12
  pydantic = ">=2.09,<3"
13
13
  requests = "^2.32.3"
14
- traceloop-sdk = "0.45.6"
14
+ traceloop-sdk = ">=0.46.0"
15
15
 
16
16
 
17
17
  [tool.poetry.group.dev.dependencies]
@@ -16,10 +16,10 @@ class Attachment(BaseModel):
16
16
  language: Optional[str] = None # for code snippets
17
17
 
18
18
  @model_validator(mode="after")
19
- def _require_value(cls, values):
20
- if not values.value:
19
+ def _require_value(self):
20
+ if not self.value:
21
21
  raise ValueError("value must be non-empty.")
22
- return values
22
+ return self
23
23
 
24
24
 
25
25
  class AIData(_Base):
@@ -29,10 +29,10 @@ class AIData(_Base):
29
29
  convo_id: Optional[str]
30
30
 
31
31
  @model_validator(mode="after")
32
- def _require_input_or_output(cls, values):
33
- if not (values.input or values.output):
32
+ def _require_input_or_output(self):
33
+ if not (self.input or self.output):
34
34
  raise ValueError("Either 'input' or 'output' must be non-empty.")
35
- return values
35
+ return self
36
36
 
37
37
 
38
38
  class TrackAIEvent(_Base):
@@ -94,10 +94,9 @@ class FeedbackSignal(BaseSignal):
94
94
  signal_type: Literal["feedback"]
95
95
 
96
96
  @model_validator(mode="after")
97
- def _check_comment_in_properties(cls, values):
97
+ def _check_comment_in_properties(self):
98
98
  # Check properties safely after potential initialization
99
- # Use getattr to safely access properties, returning None if not present
100
- props = getattr(values, "properties", None)
99
+ props = self.properties
101
100
  if not isinstance(props, dict):
102
101
  raise ValueError("'properties' must be a dictionary for feedback signals.")
103
102
  comment = props.get("comment")
@@ -105,7 +104,7 @@ class FeedbackSignal(BaseSignal):
105
104
  raise ValueError(
106
105
  "'properties' must contain a non-empty string 'comment' for feedback signals."
107
106
  )
108
- return values
107
+ return self
109
108
 
110
109
 
111
110
  class EditSignal(BaseSignal):
@@ -114,9 +113,9 @@ class EditSignal(BaseSignal):
114
113
  signal_type: Literal["edit"]
115
114
 
116
115
  @model_validator(mode="after")
117
- def _check_after_in_properties(cls, values):
116
+ def _check_after_in_properties(self):
118
117
  # Check properties safely after potential initialization
119
- props = getattr(values, "properties", None)
118
+ props = self.properties
120
119
  if not isinstance(props, dict):
121
120
  raise ValueError("'properties' must be a dictionary for edit signals.")
122
121
  after = props.get("after")
@@ -124,7 +123,7 @@ class EditSignal(BaseSignal):
124
123
  raise ValueError(
125
124
  "'properties' must contain a non-empty string 'after' for edit signals."
126
125
  )
127
- return values
126
+ return self
128
127
 
129
128
 
130
129
  # Discriminated Union for Signal Events
@@ -0,0 +1 @@
1
+ VERSION = "0.0.33"
@@ -1 +0,0 @@
1
- VERSION = "0.0.31"
File without changes