inferencesh 0.4.7__tar.gz → 0.4.9__tar.gz

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 inferencesh might be problematic. Click here for more details.

Files changed (22) hide show
  1. {inferencesh-0.4.7/src/inferencesh.egg-info → inferencesh-0.4.9}/PKG-INFO +1 -1
  2. {inferencesh-0.4.7 → inferencesh-0.4.9}/pyproject.toml +1 -1
  3. {inferencesh-0.4.7 → inferencesh-0.4.9}/src/inferencesh/models/file.py +18 -5
  4. {inferencesh-0.4.7 → inferencesh-0.4.9/src/inferencesh.egg-info}/PKG-INFO +1 -1
  5. {inferencesh-0.4.7 → inferencesh-0.4.9}/LICENSE +0 -0
  6. {inferencesh-0.4.7 → inferencesh-0.4.9}/README.md +0 -0
  7. {inferencesh-0.4.7 → inferencesh-0.4.9}/setup.cfg +0 -0
  8. {inferencesh-0.4.7 → inferencesh-0.4.9}/src/inferencesh/__init__.py +0 -0
  9. {inferencesh-0.4.7 → inferencesh-0.4.9}/src/inferencesh/client.py +0 -0
  10. {inferencesh-0.4.7 → inferencesh-0.4.9}/src/inferencesh/models/__init__.py +0 -0
  11. {inferencesh-0.4.7 → inferencesh-0.4.9}/src/inferencesh/models/base.py +0 -0
  12. {inferencesh-0.4.7 → inferencesh-0.4.9}/src/inferencesh/models/llm.py +0 -0
  13. {inferencesh-0.4.7 → inferencesh-0.4.9}/src/inferencesh/utils/__init__.py +0 -0
  14. {inferencesh-0.4.7 → inferencesh-0.4.9}/src/inferencesh/utils/download.py +0 -0
  15. {inferencesh-0.4.7 → inferencesh-0.4.9}/src/inferencesh/utils/storage.py +0 -0
  16. {inferencesh-0.4.7 → inferencesh-0.4.9}/src/inferencesh.egg-info/SOURCES.txt +0 -0
  17. {inferencesh-0.4.7 → inferencesh-0.4.9}/src/inferencesh.egg-info/dependency_links.txt +0 -0
  18. {inferencesh-0.4.7 → inferencesh-0.4.9}/src/inferencesh.egg-info/entry_points.txt +0 -0
  19. {inferencesh-0.4.7 → inferencesh-0.4.9}/src/inferencesh.egg-info/requires.txt +0 -0
  20. {inferencesh-0.4.7 → inferencesh-0.4.9}/src/inferencesh.egg-info/top_level.txt +0 -0
  21. {inferencesh-0.4.7 → inferencesh-0.4.9}/tests/test_client.py +0 -0
  22. {inferencesh-0.4.7 → inferencesh-0.4.9}/tests/test_sdk.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: inferencesh
3
- Version: 0.4.7
3
+ Version: 0.4.9
4
4
  Summary: inference.sh Python SDK
5
5
  Author-email: "Inference Shell Inc." <hello@inference.sh>
6
6
  Project-URL: Homepage, https://github.com/inference-sh/sdk
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "inferencesh"
7
- version = "0.4.7"
7
+ version = "0.4.9"
8
8
  description = "inference.sh Python SDK"
9
9
  authors = [
10
10
  {name = "Inference Shell Inc.", email = "hello@inference.sh"},
@@ -7,6 +7,8 @@ import urllib.parse
7
7
  import hashlib
8
8
  from pathlib import Path
9
9
  from tqdm import tqdm
10
+ from pydantic_core import core_schema
11
+ from pydantic_core.core_schema import GetJsonSchemaHandler, JsonSchemaValue
10
12
 
11
13
 
12
14
  class File(BaseModel):
@@ -242,10 +244,21 @@ class File(BaseModel):
242
244
  schema["$id"] = "/schemas/File"
243
245
  # Create a schema that accepts either a string or the full object
244
246
  return {
245
- "anyOf": [
247
+ "oneOf": [
246
248
  {"type": "string"}, # Accept string input
247
249
  schema # Accept full object input
248
- ],
249
- "title": "File",
250
- "description": "A class representing a file in the inference.sh ecosystem."
251
- }
250
+ ]
251
+ }
252
+
253
+ @classmethod
254
+ def __get_pydantic_json_schema__(
255
+ cls, core_schema: core_schema.CoreSchema, handler: GetJsonSchemaHandler
256
+ ) -> JsonSchemaValue:
257
+ schema = handler(core_schema) # this is the "normal" schema
258
+ return {
259
+ "oneOf": [
260
+ {"type": "string"},
261
+ schema
262
+ ]
263
+ }
264
+
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: inferencesh
3
- Version: 0.4.7
3
+ Version: 0.4.9
4
4
  Summary: inference.sh Python SDK
5
5
  Author-email: "Inference Shell Inc." <hello@inference.sh>
6
6
  Project-URL: Homepage, https://github.com/inference-sh/sdk
File without changes
File without changes
File without changes