Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
45 commits
Select commit Hold shift + click to select a range
26ff31b
Adding scalar encoding, make tools use signature and update fixtures
datvo06 Feb 16, 2026
67d9e2c
Lint
datvo06 Feb 16, 2026
415aa6e
Lint
datvo06 Feb 16, 2026
e5cd229
More general wrappedencodable
datvo06 Feb 16, 2026
59f8c06
Lint
datvo06 Feb 16, 2026
c2a8312
Architectural fixes
datvo06 Feb 17, 2026
e5d90ac
Removing embedded_type
datvo06 Feb 17, 2026
a8d9a8a
Lint
datvo06 Feb 17, 2026
0ac1875
Minor
datvo06 Feb 17, 2026
8755647
Minor fix
datvo06 Feb 17, 2026
1ace406
Lint
datvo06 Feb 17, 2026
e78acce
Add param_schema_type
datvo06 Feb 17, 2026
bd0bbd7
Minor
datvo06 Feb 17, 2026
09654d8
New Encodable's architecture
datvo06 Feb 17, 2026
7bb09a1
Recursive dataclass encodable
datvo06 Feb 17, 2026
7dae26a
Linting
datvo06 Feb 17, 2026
29bf580
Simplify encodable
datvo06 Feb 18, 2026
eab5c4d
Minor
datvo06 Feb 18, 2026
285e69f
Fix test
datvo06 Feb 18, 2026
318ec7f
Lint
datvo06 Feb 18, 2026
564486a
Trim
datvo06 Feb 18, 2026
390c3a1
More trimming
datvo06 Feb 18, 2026
40c9191
Handling images
datvo06 Feb 18, 2026
6e0bfef
Lint
datvo06 Feb 18, 2026
ae8d92d
Further trimming
datvo06 Feb 19, 2026
3a06ba6
Updating test template formatting
datvo06 Feb 19, 2026
583d271
Minor
datvo06 Feb 19, 2026
fa4752c
Add MappingEncodable and cover more tests
datvo06 Feb 19, 2026
952805e
Lint
datvo06 Feb 19, 2026
6d1c43d
More precise BaseEncodable
datvo06 Feb 19, 2026
c6e1eba
Lint
datvo06 Feb 19, 2026
73c6dbc
Removing adapter from base
datvo06 Feb 19, 2026
c4a1600
Move wrapped model to a staticmethod
datvo06 Feb 19, 2026
dc367ae
More concise handling of empty lists
datvo06 Feb 19, 2026
4729074
Minor
datvo06 Feb 19, 2026
de2fe7c
Use nested_type as _wrapped_model is resolved
datvo06 Feb 19, 2026
80818e1
Remove DTC_IDS
datvo06 Feb 19, 2026
197d412
Minor fix
datvo06 Feb 19, 2026
3f5182f
Special typeddict handling
datvo06 Feb 19, 2026
6466ea8
Complex Encodable
datvo06 Feb 19, 2026
545ec44
Removing casts
datvo06 Feb 19, 2026
8ed937b
Add Encoding/Integration Parameterized Tests (#582)
datvo06 Feb 20, 2026
3633cd4
Enforce Tool and Image to be PydanticBase model
datvo06 Feb 20, 2026
f34635d
Update fixtures
datvo06 Feb 20, 2026
61a0726
Update minor fixture
datvo06 Feb 20, 2026
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions effectful/handlers/llm/completions.py
Original file line number Diff line number Diff line change
Expand Up @@ -228,8 +228,9 @@ def call_assistant[T, U](
"final response from the model should be a string"
)
try:
raw_result = response_format.deserialize(serialized_result)
result = response_format.decode(raw_result)
result = response_format.decode(
response_format.deserialize(serialized_result)
)
except (pydantic.ValidationError, TypeError, ValueError, SyntaxError) as e:
raise ResultDecodingError(e, raw_message=raw_message) from e

Expand All @@ -251,7 +252,6 @@ def call_tool(tool_call: DecodedToolCall) -> Message:
except Exception as e:
raise ToolCallExecutionError(raw_tool_call=tool_call, original_error=e) from e

# serialize back to U using encoder for return type
return_type = Encodable.define(
typing.cast(type[typing.Any], nested_type(result).value)
)
Expand Down
Loading