promptlayer 1.0.69__py3-none-any.whl → 1.0.70__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.
Potentially problematic release.
This version of promptlayer might be problematic. Click here for more details.
- promptlayer/__init__.py +1 -1
- promptlayer/templates.py +4 -4
- promptlayer/utils.py +6 -6
- {promptlayer-1.0.69.dist-info → promptlayer-1.0.70.dist-info}/METADATA +1 -1
- {promptlayer-1.0.69.dist-info → promptlayer-1.0.70.dist-info}/RECORD +7 -7
- {promptlayer-1.0.69.dist-info → promptlayer-1.0.70.dist-info}/WHEEL +0 -0
- {promptlayer-1.0.69.dist-info → promptlayer-1.0.70.dist-info}/licenses/LICENSE +0 -0
promptlayer/__init__.py
CHANGED
promptlayer/templates.py
CHANGED
|
@@ -20,8 +20,8 @@ class TemplateManager:
|
|
|
20
20
|
def publish(self, body: PublishPromptTemplate):
|
|
21
21
|
return publish_prompt_template(body, self.api_key)
|
|
22
22
|
|
|
23
|
-
def all(self, page: int = 1, per_page: int = 30,
|
|
24
|
-
return get_all_prompt_templates(page, per_page, self.api_key,
|
|
23
|
+
def all(self, page: int = 1, per_page: int = 30, label: str = None):
|
|
24
|
+
return get_all_prompt_templates(page, per_page, self.api_key, label)
|
|
25
25
|
|
|
26
26
|
|
|
27
27
|
class AsyncTemplateManager:
|
|
@@ -31,5 +31,5 @@ class AsyncTemplateManager:
|
|
|
31
31
|
async def get(self, prompt_name: str, params: Union[GetPromptTemplate, None] = None):
|
|
32
32
|
return await aget_prompt_template(prompt_name, params, self.api_key)
|
|
33
33
|
|
|
34
|
-
async def all(self, page: int = 1, per_page: int = 30,
|
|
35
|
-
return await aget_all_prompt_templates(page, per_page, self.api_key,
|
|
34
|
+
async def all(self, page: int = 1, per_page: int = 30, label: str = None):
|
|
35
|
+
return await aget_all_prompt_templates(page, per_page, self.api_key, label)
|
promptlayer/utils.py
CHANGED
|
@@ -1193,12 +1193,12 @@ async def apublish_prompt_template(
|
|
|
1193
1193
|
|
|
1194
1194
|
|
|
1195
1195
|
def get_all_prompt_templates(
|
|
1196
|
-
page: int = 1, per_page: int = 30, api_key: str = None,
|
|
1196
|
+
page: int = 1, per_page: int = 30, api_key: str = None, label: str = None
|
|
1197
1197
|
) -> List[ListPromptTemplateResponse]:
|
|
1198
1198
|
try:
|
|
1199
1199
|
params = {"page": page, "per_page": per_page}
|
|
1200
|
-
if
|
|
1201
|
-
params["
|
|
1200
|
+
if label:
|
|
1201
|
+
params["label"] = label
|
|
1202
1202
|
response = requests.get(
|
|
1203
1203
|
f"{URL_API_PROMPTLAYER}/prompt-templates",
|
|
1204
1204
|
headers={"X-API-KEY": api_key},
|
|
@@ -1215,12 +1215,12 @@ def get_all_prompt_templates(
|
|
|
1215
1215
|
|
|
1216
1216
|
|
|
1217
1217
|
async def aget_all_prompt_templates(
|
|
1218
|
-
page: int = 1, per_page: int = 30, api_key: str = None,
|
|
1218
|
+
page: int = 1, per_page: int = 30, api_key: str = None, label: str = None
|
|
1219
1219
|
) -> List[ListPromptTemplateResponse]:
|
|
1220
1220
|
try:
|
|
1221
1221
|
params = {"page": page, "per_page": per_page}
|
|
1222
|
-
if
|
|
1223
|
-
params["
|
|
1222
|
+
if label:
|
|
1223
|
+
params["label"] = label
|
|
1224
1224
|
async with _make_httpx_client() as client:
|
|
1225
1225
|
response = await client.get(
|
|
1226
1226
|
f"{URL_API_PROMPTLAYER}/prompt-templates",
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
promptlayer/__init__.py,sha256=
|
|
1
|
+
promptlayer/__init__.py,sha256=rmNkVTlgU9h1Mc6KGq3S6-3u1O86hdDAOxZ7xU4xxJo,140
|
|
2
2
|
promptlayer/groups/__init__.py,sha256=xhOAolLUBkr76ZHvJr29OwjCIk1V9qKQXjZCuyTJUIY,429
|
|
3
3
|
promptlayer/groups/groups.py,sha256=YPROicy-TzpkrpA8vOpZS2lwvJ6VRtlbQ1S2oT1N0vM,338
|
|
4
4
|
promptlayer/promptlayer.py,sha256=hxzzq5bXkOJXvRCbBmtDLCSb4JlozpTJ00Ofk5Y_pQg,22901
|
|
@@ -9,14 +9,14 @@ promptlayer/streaming/__init__.py,sha256=nKWwUsAy4FjJLT6rxntXCyVlKOov-xT2dk7sOXr
|
|
|
9
9
|
promptlayer/streaming/blueprint_builder.py,sha256=lz4aGo_1tytuPB7AkA3y-xyl1ZQHnHOA2fZZl5CaK2Q,12769
|
|
10
10
|
promptlayer/streaming/response_handlers.py,sha256=wtl9ubb0kEB-ZuIpl0_kOvw9wZI4XRKyKqT3-d4EtWE,35410
|
|
11
11
|
promptlayer/streaming/stream_processor.py,sha256=atnaBg31kmTPSF433DF7uV3jiLuJOnA5Vz8tVCQ5v2Y,4083
|
|
12
|
-
promptlayer/templates.py,sha256=
|
|
12
|
+
promptlayer/templates.py,sha256=oRCuELDet8SAKhtqNvyLQpOAa9sVesJwIBEFX1PbXd4,1231
|
|
13
13
|
promptlayer/track/__init__.py,sha256=tyweLTAY7UpYpBHWwY-T3pOPDIlGjcgccYXqU_r0694,1710
|
|
14
14
|
promptlayer/track/track.py,sha256=A-awcYwsSwxktrlCMchy8NITIquwxU1UXbgLZMwqrA0,3164
|
|
15
15
|
promptlayer/types/__init__.py,sha256=xJcvQuOk91ZBBePb40-1FDNDKYrZoH5lPE2q6_UhprM,111
|
|
16
16
|
promptlayer/types/prompt_template.py,sha256=cqxNX9QQHKh1lwpwSp-IjNI8Yw9jOVNI3frAflz23sQ,5155
|
|
17
17
|
promptlayer/types/request_log.py,sha256=xU6bcxQar6GaBOJlgZTavXUV3FjE8sF_nSjPu4Ya_00,174
|
|
18
|
-
promptlayer/utils.py,sha256=
|
|
19
|
-
promptlayer-1.0.
|
|
20
|
-
promptlayer-1.0.
|
|
21
|
-
promptlayer-1.0.
|
|
22
|
-
promptlayer-1.0.
|
|
18
|
+
promptlayer/utils.py,sha256=bcNQc9MvJXP5vaYDKzQqkG2iJ60pes1lPozFgCxuwns,61199
|
|
19
|
+
promptlayer-1.0.70.dist-info/METADATA,sha256=1k36X6MGhGnyv_RJZ_pm868y9QHes8ZGj9P_nAVkkW0,4892
|
|
20
|
+
promptlayer-1.0.70.dist-info/WHEEL,sha256=zp0Cn7JsFoX2ATtOhtaFYIiE2rmFAD4OcMhtUki8W3U,88
|
|
21
|
+
promptlayer-1.0.70.dist-info/licenses/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
|
|
22
|
+
promptlayer-1.0.70.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|