Skip to content

Commit

Permalink
feat(api): update via SDK Studio (#12)
Browse files Browse the repository at this point in the history
  • Loading branch information
stainless-app[bot] authored and stainless-bot committed Jun 4, 2024
1 parent 6ebe199 commit e668e94
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 11 deletions.
14 changes: 7 additions & 7 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ chat = client.chat.chat(
"role": "user",
}
],
model="palmyra-x-v2",
model="palmyra-chat-v2-32k",
)
print(chat.id)
```
Expand Down Expand Up @@ -72,7 +72,7 @@ async def main() -> None:
"role": "user",
}
],
model="palmyra-x-v2",
model="palmyra-chat-v2-32k",
)
print(chat.id)

Expand Down Expand Up @@ -148,7 +148,7 @@ try:
"role": "user",
}
],
model="palmyra-x-v2",
model="[object Object]",
)
except writerai.APIConnectionError as e:
print("The server could not be reached")
Expand Down Expand Up @@ -199,7 +199,7 @@ client.with_options(max_retries=5).chat.chat(
"role": "user",
}
],
model="palmyra-x-v2",
model="[object Object]",
)
```

Expand Down Expand Up @@ -230,7 +230,7 @@ client.with_options(timeout=5.0).chat.chat(
"role": "user",
}
],
model="palmyra-x-v2",
model="[object Object]",
)
```

Expand Down Expand Up @@ -275,7 +275,7 @@ response = client.chat.with_raw_response.chat(
"content": "Hello!",
"role": "user",
}],
model="palmyra-x-v2",
model="[object Object]",
)
print(response.headers.get('X-My-Header'))

Expand All @@ -301,7 +301,7 @@ with client.chat.with_streaming_response.chat(
"role": "user",
}
],
model="palmyra-x-v2",
model="[object Object]",
) as response:
print(response.headers.get("X-My-Header"))

Expand Down
8 changes: 4 additions & 4 deletions tests/test_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -728,7 +728,7 @@ def test_retrying_timeout_errors_doesnt_leak(self, respx_mock: MockRouter) -> No
"role": "user",
}
],
model="palmyra-x-v2",
model="[object Object]",
),
),
cast_to=httpx.Response,
Expand All @@ -754,7 +754,7 @@ def test_retrying_status_errors_doesnt_leak(self, respx_mock: MockRouter) -> Non
"role": "user",
}
],
model="palmyra-x-v2",
model="[object Object]",
),
),
cast_to=httpx.Response,
Expand Down Expand Up @@ -1459,7 +1459,7 @@ async def test_retrying_timeout_errors_doesnt_leak(self, respx_mock: MockRouter)
"role": "user",
}
],
model="palmyra-x-v2",
model="[object Object]",
),
),
cast_to=httpx.Response,
Expand All @@ -1485,7 +1485,7 @@ async def test_retrying_status_errors_doesnt_leak(self, respx_mock: MockRouter)
"role": "user",
}
],
model="palmyra-x-v2",
model="[object Object]",
),
),
cast_to=httpx.Response,
Expand Down

0 comments on commit e668e94

Please sign in to comment.