dagster-openai 0.24.0__tar.gz → 0.24.1__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 dagster-openai might be problematic. Click here for more details.

@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: dagster-openai
3
- Version: 0.24.0
3
+ Version: 0.24.1
4
4
  Summary: A Open AI client resource for interacting with Open AI API.
5
5
  Home-page: https://github.com/dagster-io/dagster/tree/master/python_modules/libraries/dagster-openai
6
6
  Author: Dagster Labs
@@ -180,6 +180,9 @@ class OpenAIResource(ConfigurableResource):
180
180
  """
181
181
 
182
182
  api_key: str = Field(description=("OpenAI API key. See https://platform.openai.com/api-keys"))
183
+ organization: Optional[str] = Field(default=None)
184
+ project: Optional[str] = Field(default=None)
185
+ base_url: Optional[str] = Field(default=None)
183
186
 
184
187
  _client: Client = PrivateAttr()
185
188
 
@@ -212,7 +215,12 @@ class OpenAIResource(ConfigurableResource):
212
215
 
213
216
  def setup_for_execution(self, context: InitResourceContext) -> None:
214
217
  # Set up an OpenAI client based on the API key.
215
- self._client = Client(api_key=self.api_key)
218
+ self._client = Client(
219
+ api_key=self.api_key,
220
+ organization=self.organization,
221
+ project=self.project,
222
+ base_url=self.base_url,
223
+ )
216
224
 
217
225
  @public
218
226
  @contextmanager
@@ -0,0 +1 @@
1
+ __version__ = "0.24.1"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: dagster-openai
3
- Version: 0.24.0
3
+ Version: 0.24.1
4
4
  Summary: A Open AI client resource for interacting with Open AI API.
5
5
  Home-page: https://github.com/dagster-io/dagster/tree/master/python_modules/libraries/dagster-openai
6
6
  Author: Dagster Labs
@@ -0,0 +1,2 @@
1
+ dagster==1.8.1
2
+ openai
@@ -32,7 +32,7 @@ setup(
32
32
  ],
33
33
  packages=find_packages(exclude=["dagster_openai_tests*"]),
34
34
  install_requires=[
35
- "dagster==1.8.0",
35
+ "dagster==1.8.1",
36
36
  "openai",
37
37
  ],
38
38
  zip_safe=False,
@@ -1 +0,0 @@
1
- __version__ = "0.24.0"
@@ -1,2 +0,0 @@
1
- dagster==1.8.0
2
- openai
File without changes