Skip to content

Commit b90ee68

Browse files
minor: Renamed newly added PlatformHelper.get_exported_tool() (#184)
minor: Renamed newly added PlatformHelper.get_exported_tool() to get_prompt_studio_tool()
1 parent 2ca0978 commit b90ee68

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

src/unstract/sdk/platform.py

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -165,12 +165,11 @@ def get_platform_details(self) -> dict[str, Any] | None:
165165
)
166166
return response.get("details")
167167

168-
def get_exported_tool(self, prompt_registry_id: str) -> dict[str, Any]:
168+
def get_prompt_studio_tool(self, prompt_registry_id: str) -> dict[str, Any]:
169169
"""Get exported custom tool by the help of unstract DB tool.
170170
171171
Args:
172172
prompt_registry_id (str): ID of the prompt_registry_id
173-
tool (AbstractTool): Instance of AbstractTool
174173
Required env variables:
175174
PLATFORM_HOST: Host of platform service
176175
PLATFORM_PORT: Port of platform service

src/unstract/sdk/prompt.py

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -223,7 +223,9 @@ def _call_service(
223223
return response.json()
224224

225225
@staticmethod
226-
@deprecated(version="v0.71.0", reason="Use remote FS APIs from SDK")
226+
@deprecated(
227+
version="v0.71.0", reason="Use `PlatformHelper.get_prompt_studio_tool` instead"
228+
)
227229
def get_exported_tool(
228230
tool: BaseTool, prompt_registry_id: str
229231
) -> dict[str, Any] | None:
@@ -241,4 +243,6 @@ def get_exported_tool(
241243
platform_port=tool.get_env_or_die(ToolEnv.PLATFORM_PORT),
242244
platform_host=tool.get_env_or_die(ToolEnv.PLATFORM_HOST),
243245
)
244-
return platform_helper.get_exported_tool(prompt_registry_id=prompt_registry_id)
246+
return platform_helper.get_prompt_studio_tool(
247+
prompt_registry_id=prompt_registry_id
248+
)

0 commit comments

Comments
 (0)