raysurfer 0.4.1__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.
- raysurfer/__init__.py +101 -0
- raysurfer/client.py +773 -0
- raysurfer/exceptions.py +21 -0
- raysurfer/sdk_client.py +552 -0
- raysurfer/sdk_types.py +30 -0
- raysurfer/types.py +198 -0
- raysurfer-0.4.1.dist-info/METADATA +157 -0
- raysurfer-0.4.1.dist-info/RECORD +9 -0
- raysurfer-0.4.1.dist-info/WHEEL +4 -0
raysurfer/__init__.py
ADDED
|
@@ -0,0 +1,101 @@
|
|
|
1
|
+
"""
|
|
2
|
+
RaySurfer Python SDK - Drop-in replacement for Claude Agent SDK with caching.
|
|
3
|
+
|
|
4
|
+
Simply swap your import and rename your client:
|
|
5
|
+
|
|
6
|
+
# Before
|
|
7
|
+
from claude_agent_sdk import ClaudeSDKClient, ClaudeAgentOptions
|
|
8
|
+
client = ClaudeSDKClient(options)
|
|
9
|
+
await client.query("task")
|
|
10
|
+
|
|
11
|
+
# After
|
|
12
|
+
from raysurfer import RaysurferClient
|
|
13
|
+
from claude_agent_sdk import ClaudeAgentOptions
|
|
14
|
+
client = RaysurferClient(options)
|
|
15
|
+
await client.raysurfer_query("task")
|
|
16
|
+
|
|
17
|
+
Options come directly from claude_agent_sdk - no Raysurfer-specific options needed.
|
|
18
|
+
Set RAYSURFER_API_KEY to enable caching.
|
|
19
|
+
"""
|
|
20
|
+
|
|
21
|
+
# Main client
|
|
22
|
+
from raysurfer.sdk_client import RaysurferClient
|
|
23
|
+
|
|
24
|
+
# Re-export Claude Agent SDK types for convenience (use these directly)
|
|
25
|
+
from raysurfer.sdk_client import (
|
|
26
|
+
AgentDefinition,
|
|
27
|
+
AssistantMessage,
|
|
28
|
+
ClaudeAgentOptions,
|
|
29
|
+
HookMatcher,
|
|
30
|
+
Message,
|
|
31
|
+
ResultMessage,
|
|
32
|
+
SystemMessage,
|
|
33
|
+
TextBlock,
|
|
34
|
+
ThinkingBlock,
|
|
35
|
+
ToolResultBlock,
|
|
36
|
+
ToolUseBlock,
|
|
37
|
+
UserMessage,
|
|
38
|
+
)
|
|
39
|
+
|
|
40
|
+
# Direct API clients (for advanced use cases)
|
|
41
|
+
from raysurfer.client import AsyncRaySurfer, RaySurfer
|
|
42
|
+
|
|
43
|
+
# Exceptions
|
|
44
|
+
from raysurfer.exceptions import APIError, AuthenticationError, RaySurferError
|
|
45
|
+
|
|
46
|
+
# Types for direct API usage
|
|
47
|
+
from raysurfer.sdk_types import CodeFile, GetCodeFilesResponse
|
|
48
|
+
from raysurfer.types import (
|
|
49
|
+
AgentReview,
|
|
50
|
+
AgentVerdict,
|
|
51
|
+
BestMatch,
|
|
52
|
+
CodeBlock,
|
|
53
|
+
ExecutionIO,
|
|
54
|
+
ExecutionRecord,
|
|
55
|
+
ExecutionState,
|
|
56
|
+
FewShotExample,
|
|
57
|
+
FileWritten,
|
|
58
|
+
SubmitExecutionResultResponse,
|
|
59
|
+
TaskPattern,
|
|
60
|
+
)
|
|
61
|
+
|
|
62
|
+
__version__ = "0.5.0"
|
|
63
|
+
|
|
64
|
+
__all__ = [
|
|
65
|
+
# Main client
|
|
66
|
+
"RaysurferClient",
|
|
67
|
+
# Re-exported from Claude Agent SDK (use these directly)
|
|
68
|
+
"ClaudeAgentOptions",
|
|
69
|
+
"AgentDefinition",
|
|
70
|
+
"HookMatcher",
|
|
71
|
+
"Message",
|
|
72
|
+
"UserMessage",
|
|
73
|
+
"AssistantMessage",
|
|
74
|
+
"SystemMessage",
|
|
75
|
+
"ResultMessage",
|
|
76
|
+
"TextBlock",
|
|
77
|
+
"ThinkingBlock",
|
|
78
|
+
"ToolUseBlock",
|
|
79
|
+
"ToolResultBlock",
|
|
80
|
+
# Direct API clients
|
|
81
|
+
"RaySurfer",
|
|
82
|
+
"AsyncRaySurfer",
|
|
83
|
+
# Types
|
|
84
|
+
"AgentReview",
|
|
85
|
+
"AgentVerdict",
|
|
86
|
+
"BestMatch",
|
|
87
|
+
"CodeBlock",
|
|
88
|
+
"CodeFile",
|
|
89
|
+
"ExecutionIO",
|
|
90
|
+
"ExecutionRecord",
|
|
91
|
+
"ExecutionState",
|
|
92
|
+
"FewShotExample",
|
|
93
|
+
"FileWritten",
|
|
94
|
+
"GetCodeFilesResponse",
|
|
95
|
+
"SubmitExecutionResultResponse",
|
|
96
|
+
"TaskPattern",
|
|
97
|
+
# Exceptions
|
|
98
|
+
"RaySurferError",
|
|
99
|
+
"APIError",
|
|
100
|
+
"AuthenticationError",
|
|
101
|
+
]
|