ccs-llmconnector 1.0.4__tar.gz → 1.0.6__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.
- {ccs_llmconnector-1.0.4 → ccs_llmconnector-1.0.6}/LICENSE +22 -22
- {ccs_llmconnector-1.0.4/src/ccs_llmconnector.egg-info → ccs_llmconnector-1.0.6}/PKG-INFO +38 -2
- {ccs_llmconnector-1.0.4 → ccs_llmconnector-1.0.6}/README.md +405 -369
- {ccs_llmconnector-1.0.4 → ccs_llmconnector-1.0.6}/pyproject.toml +29 -29
- {ccs_llmconnector-1.0.4 → ccs_llmconnector-1.0.6/src/ccs_llmconnector.egg-info}/PKG-INFO +38 -2
- {ccs_llmconnector-1.0.4 → ccs_llmconnector-1.0.6}/src/llmconnector/__init__.py +39 -39
- {ccs_llmconnector-1.0.4 → ccs_llmconnector-1.0.6}/src/llmconnector/anthropic_client.py +233 -217
- {ccs_llmconnector-1.0.4 → ccs_llmconnector-1.0.6}/src/llmconnector/client.py +191 -148
- {ccs_llmconnector-1.0.4 → ccs_llmconnector-1.0.6}/src/llmconnector/client_cli.py +325 -325
- {ccs_llmconnector-1.0.4 → ccs_llmconnector-1.0.6}/src/llmconnector/gemini_client.py +299 -224
- {ccs_llmconnector-1.0.4 → ccs_llmconnector-1.0.6}/src/llmconnector/grok_client.py +186 -170
- {ccs_llmconnector-1.0.4 → ccs_llmconnector-1.0.6}/src/llmconnector/openai_client.py +90 -73
- {ccs_llmconnector-1.0.4 → ccs_llmconnector-1.0.6}/src/llmconnector/py.typed +1 -1
- {ccs_llmconnector-1.0.4 → ccs_llmconnector-1.0.6}/MANIFEST.in +0 -0
- {ccs_llmconnector-1.0.4 → ccs_llmconnector-1.0.6}/setup.cfg +0 -0
- {ccs_llmconnector-1.0.4 → ccs_llmconnector-1.0.6}/src/ccs_llmconnector.egg-info/SOURCES.txt +0 -0
- {ccs_llmconnector-1.0.4 → ccs_llmconnector-1.0.6}/src/ccs_llmconnector.egg-info/dependency_links.txt +0 -0
- {ccs_llmconnector-1.0.4 → ccs_llmconnector-1.0.6}/src/ccs_llmconnector.egg-info/entry_points.txt +0 -0
- {ccs_llmconnector-1.0.4 → ccs_llmconnector-1.0.6}/src/ccs_llmconnector.egg-info/requires.txt +0 -0
- {ccs_llmconnector-1.0.4 → ccs_llmconnector-1.0.6}/src/ccs_llmconnector.egg-info/top_level.txt +0 -0
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
MIT License
|
|
2
|
-
|
|
3
|
-
Copyright (c) 2025 CCS
|
|
4
|
-
|
|
5
|
-
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
-
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
-
in the Software without restriction, including without limitation the rights
|
|
8
|
-
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
-
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
-
furnished to do so, subject to the following conditions:
|
|
11
|
-
|
|
12
|
-
The above copyright notice and this permission notice shall be included in all
|
|
13
|
-
copies or substantial portions of the Software.
|
|
14
|
-
|
|
15
|
-
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
-
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
-
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
-
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
-
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
-
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
-
SOFTWARE.
|
|
22
|
-
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2025 CCS
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
|
22
|
+
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: ccs-llmconnector
|
|
3
|
-
Version: 1.0.
|
|
3
|
+
Version: 1.0.6
|
|
4
4
|
Summary: Lightweight wrapper around different LLM provider Python SDK Responses APIs.
|
|
5
5
|
Author: CCS
|
|
6
6
|
License: MIT
|
|
@@ -91,10 +91,37 @@ vision_response = client.generate_response(
|
|
|
91
91
|
| `reasoning_effort` | `Optional[str]` | No | Present for parity with the OpenAI client; currently ignored by the Gemini SDK. |
|
|
92
92
|
| `images` | `Optional[Sequence[str \| Path]]` | No | Image references (local paths, URLs, or data URLs) read and forwarded to the Gemini SDK. |
|
|
93
93
|
|
|
94
|
-
The method returns the generated model output as a plain string. Optional image
|
|
95
94
|
references are automatically converted into the appropriate `types.Part` instances,
|
|
96
95
|
allowing you to mix text and visuals in a single request.
|
|
97
96
|
|
|
97
|
+
### Image Generation
|
|
98
|
+
|
|
99
|
+
Use `generate_image` to create images using Gemini's image generation models (e.g., `gemini-3-pro-image-preview`).
|
|
100
|
+
|
|
101
|
+
```python
|
|
102
|
+
image_bytes = client.generate_image(
|
|
103
|
+
api_key="your-gemini-api-key",
|
|
104
|
+
prompt="Generate an infographic of the current weather in Tokyo.",
|
|
105
|
+
model="gemini-3-pro-image-preview",
|
|
106
|
+
image_size="2K", # Optional, defaults to "2K"
|
|
107
|
+
aspect_ratio="16:9", # Optional, e.g. "16:9", "4:3"
|
|
108
|
+
)
|
|
109
|
+
|
|
110
|
+
with open("weather_tokyo.png", "wb") as f:
|
|
111
|
+
f.write(image_bytes)
|
|
112
|
+
```
|
|
113
|
+
|
|
114
|
+
You can also provide an input image for editing tasks:
|
|
115
|
+
|
|
116
|
+
```python
|
|
117
|
+
image_bytes = client.generate_image(
|
|
118
|
+
api_key="your-gemini-api-key",
|
|
119
|
+
prompt="Make the background a sunset.",
|
|
120
|
+
model="gemini-3-pro-image-preview",
|
|
121
|
+
image="/path/to/original.png",
|
|
122
|
+
)
|
|
123
|
+
```
|
|
124
|
+
|
|
98
125
|
### Listing models
|
|
99
126
|
|
|
100
127
|
Use `list_models` to enumerate the Gemini models available to your account:
|
|
@@ -318,6 +345,15 @@ anthropic_response = llm_client.generate_response(
|
|
|
318
345
|
# Additional providers can be registered at runtime:
|
|
319
346
|
# llm_client.register_provider("custom", CustomProviderClient())
|
|
320
347
|
# llm_client.generate_response(provider="custom", ...)
|
|
348
|
+
|
|
349
|
+
# Image generation (currently only supported by Gemini)
|
|
350
|
+
image_bytes = llm_client.generate_image(
|
|
351
|
+
provider="gemini",
|
|
352
|
+
api_key="your-gemini-api-key",
|
|
353
|
+
prompt="A futuristic city",
|
|
354
|
+
model="gemini-3-pro-image-preview",
|
|
355
|
+
aspect_ratio="16:9",
|
|
356
|
+
)
|
|
321
357
|
```
|
|
322
358
|
|
|
323
359
|
### Listing models
|