lightning-sdk 2025.8.8__py3-none-any.whl → 2025.8.8.post1__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.
- lightning_sdk/__init__.py +1 -1
- lightning_sdk/job/base.py +12 -5
- lightning_sdk/lightning_cloud/openapi/models/v1_user_features.py +1 -27
- lightning_sdk/llm/llm.py +67 -37
- lightning_sdk/llm/public_assistants.py +3 -3
- lightning_sdk/studio.py +2 -1
- lightning_sdk/utils/resolve.py +13 -0
- {lightning_sdk-2025.8.8.dist-info → lightning_sdk-2025.8.8.post1.dist-info}/METADATA +1 -1
- {lightning_sdk-2025.8.8.dist-info → lightning_sdk-2025.8.8.post1.dist-info}/RECORD +13 -13
- {lightning_sdk-2025.8.8.dist-info → lightning_sdk-2025.8.8.post1.dist-info}/LICENSE +0 -0
- {lightning_sdk-2025.8.8.dist-info → lightning_sdk-2025.8.8.post1.dist-info}/WHEEL +0 -0
- {lightning_sdk-2025.8.8.dist-info → lightning_sdk-2025.8.8.post1.dist-info}/entry_points.txt +0 -0
- {lightning_sdk-2025.8.8.dist-info → lightning_sdk-2025.8.8.post1.dist-info}/top_level.txt +0 -0
lightning_sdk/__init__.py
CHANGED
lightning_sdk/job/base.py
CHANGED
|
@@ -4,7 +4,7 @@ from typing import TYPE_CHECKING, Any, Dict, Optional, TypedDict, Union
|
|
|
4
4
|
|
|
5
5
|
from lightning_sdk.api.cloud_account_api import CloudAccountApi
|
|
6
6
|
from lightning_sdk.api.utils import _get_cloud_url
|
|
7
|
-
from lightning_sdk.utils.resolve import _resolve_deprecated_cluster, _resolve_teamspace, in_studio
|
|
7
|
+
from lightning_sdk.utils.resolve import _resolve_deprecated_cluster, _resolve_teamspace, in_studio, skip_studio_setup
|
|
8
8
|
|
|
9
9
|
if TYPE_CHECKING:
|
|
10
10
|
from lightning_sdk.machine import CloudProvider, Machine
|
|
@@ -145,9 +145,15 @@ class _BaseJob(ABC):
|
|
|
145
145
|
|
|
146
146
|
if image is None:
|
|
147
147
|
if not isinstance(studio, Studio):
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
148
|
+
with skip_studio_setup():
|
|
149
|
+
studio = Studio(
|
|
150
|
+
name=studio,
|
|
151
|
+
teamspace=teamspace,
|
|
152
|
+
org=org,
|
|
153
|
+
user=user,
|
|
154
|
+
cloud_account=cloud_account,
|
|
155
|
+
create_ok=False,
|
|
156
|
+
)
|
|
151
157
|
|
|
152
158
|
# studio is a Studio instance at this point
|
|
153
159
|
if teamspace is None:
|
|
@@ -192,7 +198,8 @@ class _BaseJob(ABC):
|
|
|
192
198
|
)
|
|
193
199
|
if cloud_account is None and in_studio():
|
|
194
200
|
try:
|
|
195
|
-
|
|
201
|
+
with skip_studio_setup():
|
|
202
|
+
resolve_studio = Studio(teamspace=teamspace, user=user, org=org)
|
|
196
203
|
cloud_account = resolve_studio.cloud_account
|
|
197
204
|
except (ValueError, ApiException):
|
|
198
205
|
warnings.warn("Could not infer cloud account from studio. Using teamspace default.")
|
|
@@ -93,7 +93,6 @@ class V1UserFeatures(object):
|
|
|
93
93
|
'mmt_strategy_selector': 'bool',
|
|
94
94
|
'model_api_dashboard': 'bool',
|
|
95
95
|
'model_api_dashboard_clickhouse': 'bool',
|
|
96
|
-
'multicloud_folders': 'bool',
|
|
97
96
|
'multiple_studio_versions': 'bool',
|
|
98
97
|
'nerf_fs_nonpaying': 'bool',
|
|
99
98
|
'onboarding_v2': 'bool',
|
|
@@ -186,7 +185,6 @@ class V1UserFeatures(object):
|
|
|
186
185
|
'mmt_strategy_selector': 'mmtStrategySelector',
|
|
187
186
|
'model_api_dashboard': 'modelApiDashboard',
|
|
188
187
|
'model_api_dashboard_clickhouse': 'modelApiDashboardClickhouse',
|
|
189
|
-
'multicloud_folders': 'multicloudFolders',
|
|
190
188
|
'multiple_studio_versions': 'multipleStudioVersions',
|
|
191
189
|
'nerf_fs_nonpaying': 'nerfFsNonpaying',
|
|
192
190
|
'onboarding_v2': 'onboardingV2',
|
|
@@ -226,7 +224,7 @@ class V1UserFeatures(object):
|
|
|
226
224
|
'writable_s3_connections': 'writableS3Connections'
|
|
227
225
|
}
|
|
228
226
|
|
|
229
|
-
def __init__(self, academic_tier: 'bool' =None, add_data_v2: 'bool' =None, affiliate_links: 'bool' =None, agents_v2: 'bool' =None, ai_hub_monetization: 'bool' =None, auto_fast_load: 'bool' =None, auto_join_orgs: 'bool' =None, b2c_experience: 'bool' =None, byo_machine_type: 'bool' =None, cap_add: 'list[str]' =None, cap_drop: 'list[str]' =None, capacity_reservation_byoc: 'bool' =None, capacity_reservation_dry_run: 'bool' =None, chat_models: 'bool' =None, cloudspace_schedules: 'bool' =None, code_tab: 'bool' =None, collab_screen_sharing: 'bool' =None, control_center_monitoring: 'bool' =None, cost_attribution_settings: 'bool' =None, custom_app_domain: 'bool' =None, datasets: 'bool' =None, default_one_cluster: 'bool' =None, deployment_persistent_disk: 'bool' =None, drive_v2: 'bool' =None, enterprise_compute_admin: 'bool' =None, f227: 'bool' =None, f234: 'bool' =None, f236: 'bool' =None, f237: 'bool' =None, f238: 'bool' =None, f239: 'bool' =None, f240: 'bool' =None, f241: 'bool' =None, f242: 'bool' =None, f243: 'bool' =None, f244: 'bool' =None, fair_share: 'bool' =None, featured_studios_admin: 'bool' =None, gcp_overprovisioning: 'bool' =None, gcs_connections_optimized: 'bool' =None, gcs_folders: 'bool' =None, instant_capacity_reservation: 'bool' =None, job_artifacts_v2: 'bool' =None, kubernetes_cluster_ui: 'bool' =None, kubernetes_clusters: 'bool' =None, landing_studios: 'bool' =None, lit_logger: 'bool' =None, marketplace: 'bool' =None, mmt_fault_tolerance: 'bool' =None, mmt_strategy_selector: 'bool' =None, model_api_dashboard: 'bool' =None, model_api_dashboard_clickhouse: 'bool' =None,
|
|
227
|
+
def __init__(self, academic_tier: 'bool' =None, add_data_v2: 'bool' =None, affiliate_links: 'bool' =None, agents_v2: 'bool' =None, ai_hub_monetization: 'bool' =None, auto_fast_load: 'bool' =None, auto_join_orgs: 'bool' =None, b2c_experience: 'bool' =None, byo_machine_type: 'bool' =None, cap_add: 'list[str]' =None, cap_drop: 'list[str]' =None, capacity_reservation_byoc: 'bool' =None, capacity_reservation_dry_run: 'bool' =None, chat_models: 'bool' =None, cloudspace_schedules: 'bool' =None, code_tab: 'bool' =None, collab_screen_sharing: 'bool' =None, control_center_monitoring: 'bool' =None, cost_attribution_settings: 'bool' =None, custom_app_domain: 'bool' =None, datasets: 'bool' =None, default_one_cluster: 'bool' =None, deployment_persistent_disk: 'bool' =None, drive_v2: 'bool' =None, enterprise_compute_admin: 'bool' =None, f227: 'bool' =None, f234: 'bool' =None, f236: 'bool' =None, f237: 'bool' =None, f238: 'bool' =None, f239: 'bool' =None, f240: 'bool' =None, f241: 'bool' =None, f242: 'bool' =None, f243: 'bool' =None, f244: 'bool' =None, fair_share: 'bool' =None, featured_studios_admin: 'bool' =None, gcp_overprovisioning: 'bool' =None, gcs_connections_optimized: 'bool' =None, gcs_folders: 'bool' =None, instant_capacity_reservation: 'bool' =None, job_artifacts_v2: 'bool' =None, kubernetes_cluster_ui: 'bool' =None, kubernetes_clusters: 'bool' =None, landing_studios: 'bool' =None, lit_logger: 'bool' =None, marketplace: 'bool' =None, mmt_fault_tolerance: 'bool' =None, mmt_strategy_selector: 'bool' =None, model_api_dashboard: 'bool' =None, model_api_dashboard_clickhouse: 'bool' =None, multiple_studio_versions: 'bool' =None, nerf_fs_nonpaying: 'bool' =None, onboarding_v2: 'bool' =None, org_level_member_permissions: 'bool' =None, org_usage_limits: 'bool' =None, persistent_disk: 'bool' =None, plugin_distributed: 'bool' =None, plugin_inference: 'bool' =None, plugin_label_studio: 'bool' =None, plugin_langflow: 'bool' =None, plugin_python_profiler: 'bool' =None, plugin_service: 'bool' =None, plugin_sweeps: 'bool' =None, pricing_updates: 'bool' =None, product_generator: 'bool' =None, product_license: 'bool' =None, project_selector: 'bool' =None, publish_pipelines: 'bool' =None, r2_data_connections: 'bool' =None, reserved_machines_tab: 'bool' =None, restartable_jobs: 'bool' =None, runnable_public_studio_page: 'bool' =None, security_docs: 'bool' =None, show_dev_admin: 'bool' =None, single_wallet: 'bool' =None, slurm: 'bool' =None, specialised_studios: 'bool' =None, storage_overuse_deletion: 'bool' =None, studio_config: 'bool' =None, studio_sharing_v2: 'bool' =None, studio_version_visibility: 'bool' =None, trainium2: 'bool' =None, use_internal_data_connection_mounts: 'bool' =None, use_rclone_mounts_only: 'bool' =None, vultr: 'bool' =None, weka: 'bool' =None, writable_s3_connections: 'bool' =None): # noqa: E501
|
|
230
228
|
"""V1UserFeatures - a model defined in Swagger""" # noqa: E501
|
|
231
229
|
self._academic_tier = None
|
|
232
230
|
self._add_data_v2 = None
|
|
@@ -280,7 +278,6 @@ class V1UserFeatures(object):
|
|
|
280
278
|
self._mmt_strategy_selector = None
|
|
281
279
|
self._model_api_dashboard = None
|
|
282
280
|
self._model_api_dashboard_clickhouse = None
|
|
283
|
-
self._multicloud_folders = None
|
|
284
281
|
self._multiple_studio_versions = None
|
|
285
282
|
self._nerf_fs_nonpaying = None
|
|
286
283
|
self._onboarding_v2 = None
|
|
@@ -423,8 +420,6 @@ class V1UserFeatures(object):
|
|
|
423
420
|
self.model_api_dashboard = model_api_dashboard
|
|
424
421
|
if model_api_dashboard_clickhouse is not None:
|
|
425
422
|
self.model_api_dashboard_clickhouse = model_api_dashboard_clickhouse
|
|
426
|
-
if multicloud_folders is not None:
|
|
427
|
-
self.multicloud_folders = multicloud_folders
|
|
428
423
|
if multiple_studio_versions is not None:
|
|
429
424
|
self.multiple_studio_versions = multiple_studio_versions
|
|
430
425
|
if nerf_fs_nonpaying is not None:
|
|
@@ -1592,27 +1587,6 @@ class V1UserFeatures(object):
|
|
|
1592
1587
|
|
|
1593
1588
|
self._model_api_dashboard_clickhouse = model_api_dashboard_clickhouse
|
|
1594
1589
|
|
|
1595
|
-
@property
|
|
1596
|
-
def multicloud_folders(self) -> 'bool':
|
|
1597
|
-
"""Gets the multicloud_folders of this V1UserFeatures. # noqa: E501
|
|
1598
|
-
|
|
1599
|
-
|
|
1600
|
-
:return: The multicloud_folders of this V1UserFeatures. # noqa: E501
|
|
1601
|
-
:rtype: bool
|
|
1602
|
-
"""
|
|
1603
|
-
return self._multicloud_folders
|
|
1604
|
-
|
|
1605
|
-
@multicloud_folders.setter
|
|
1606
|
-
def multicloud_folders(self, multicloud_folders: 'bool'):
|
|
1607
|
-
"""Sets the multicloud_folders of this V1UserFeatures.
|
|
1608
|
-
|
|
1609
|
-
|
|
1610
|
-
:param multicloud_folders: The multicloud_folders of this V1UserFeatures. # noqa: E501
|
|
1611
|
-
:type: bool
|
|
1612
|
-
"""
|
|
1613
|
-
|
|
1614
|
-
self._multicloud_folders = multicloud_folders
|
|
1615
|
-
|
|
1616
1590
|
@property
|
|
1617
1591
|
def multiple_studio_versions(self) -> 'bool':
|
|
1618
1592
|
"""Gets the multiple_studio_versions of this V1UserFeatures. # noqa: E501
|
lightning_sdk/llm/llm.py
CHANGED
|
@@ -5,6 +5,7 @@ from lightning_sdk.api import TeamspaceApi, UserApi
|
|
|
5
5
|
from lightning_sdk.api.llm_api import LLMApi, authenticate
|
|
6
6
|
from lightning_sdk.lightning_cloud.openapi.models.v1_conversation_response_chunk import V1ConversationResponseChunk
|
|
7
7
|
from lightning_sdk.llm.public_assistants import PUBLIC_MODELS
|
|
8
|
+
from lightning_sdk.utils.resolve import _resolve_org, _resolve_teamspace
|
|
8
9
|
|
|
9
10
|
PUBLIC_MODEL_PROVIDERS: Dict[str, str] = {
|
|
10
11
|
"openai": "OpenAI",
|
|
@@ -31,33 +32,33 @@ class LLM:
|
|
|
31
32
|
) -> None:
|
|
32
33
|
"""Initializes the LLM instance with teamspace information, which is required for billing purposes.
|
|
33
34
|
|
|
34
|
-
Teamspace information is resolved through the following methods:
|
|
35
|
-
1. `.lightning/credentials.json` - Attempts to retrieve the teamspace from the local credentials file.
|
|
36
|
-
2. Environment Variables - Checks for `LIGHTNING_*` environment variables.
|
|
37
|
-
3. User Authentication - Redirects the user to the login page if teamspace information is not found.
|
|
38
|
-
|
|
39
35
|
Args:
|
|
40
36
|
name (str): The name of the model or resource.
|
|
41
|
-
teamspace (Optional[str]): The specified teamspace for billing. If not provided, it will
|
|
42
|
-
|
|
37
|
+
teamspace (Optional[str]): The specified teamspace for billing. If not provided, it will
|
|
38
|
+
use the available default teamspace.
|
|
43
39
|
enable_async (Optional[bool]): Enable async requests
|
|
44
40
|
|
|
45
41
|
Raises:
|
|
46
42
|
ValueError: If teamspace information cannot be resolved.
|
|
47
43
|
"""
|
|
48
44
|
teamspace_name = None
|
|
45
|
+
teamspace_owner = None
|
|
49
46
|
if teamspace:
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
47
|
+
if "/" in teamspace:
|
|
48
|
+
try:
|
|
49
|
+
teamspace_owner, teamspace_name = teamspace.split("/", maxsplit=1)
|
|
50
|
+
except ValueError as e:
|
|
51
|
+
raise ValueError(
|
|
52
|
+
f"Invalid teamspace format: '{teamspace}'. "
|
|
53
|
+
"Teamspace should be specified as '{org}/{teamspace_name}' or '{org}'"
|
|
54
|
+
"(e.g., 'my-org/my-teamspace', 'my-org')."
|
|
55
|
+
) from e
|
|
56
|
+
else:
|
|
57
|
+
# org is given
|
|
58
|
+
teamspace_name = teamspace
|
|
58
59
|
|
|
59
60
|
self._model_provider, self._model_name = self._parse_model_name(name)
|
|
60
|
-
self._get_auth_info(teamspace_name)
|
|
61
|
+
self._get_auth_info(teamspace_owner, teamspace_name)
|
|
61
62
|
|
|
62
63
|
self._enable_async = enable_async
|
|
63
64
|
|
|
@@ -88,34 +89,63 @@ class LLM:
|
|
|
88
89
|
|
|
89
90
|
return int(context_info["context_length"])
|
|
90
91
|
|
|
91
|
-
def _get_auth_info(self, teamspace_name: Optional[str] = None) -> None:
|
|
92
|
-
# TODO: Validate user input teamspace name
|
|
92
|
+
def _get_auth_info(self, teamspace_owner: Optional[str] = None, teamspace_name: Optional[str] = None) -> None:
|
|
93
93
|
if not LLM._auth_info_cached:
|
|
94
|
-
if
|
|
95
|
-
#
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
94
|
+
if teamspace_owner and teamspace_name:
|
|
95
|
+
# org with specific teamspace
|
|
96
|
+
try:
|
|
97
|
+
t = _resolve_teamspace(teamspace=teamspace_name, org=None, user=teamspace_owner)
|
|
98
|
+
except Exception:
|
|
99
|
+
try:
|
|
100
|
+
t = _resolve_teamspace(teamspace=teamspace_name, org=teamspace_owner, user=None)
|
|
101
|
+
except Exception as err:
|
|
102
|
+
raise ValueError(
|
|
103
|
+
f"Teamspace {teamspace_owner}/{teamspace_name} not found."
|
|
104
|
+
"Please verify owner name (username or organization) and the teamspace name are correct."
|
|
105
|
+
) from err
|
|
106
|
+
|
|
107
|
+
os.environ["LIGHTNING_TEAMSPACE"] = t.name
|
|
108
|
+
os.environ["LIGHTNING_CLOUD_PROJECT_ID"] = t.id
|
|
109
|
+
|
|
110
|
+
elif teamspace_name and teamspace_owner is None:
|
|
111
|
+
# if only org name is given, use the default teamspace
|
|
100
112
|
try:
|
|
101
|
-
|
|
113
|
+
org = _resolve_org(teamspace_name)
|
|
102
114
|
teamspace_api = TeamspaceApi()
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
default_teamspace = teamspace_api.list_teamspaces(owner_id=authed_user.id)[0]
|
|
106
|
-
teamspace_name = default_teamspace.name
|
|
107
|
-
teamspace_id = default_teamspace.id
|
|
108
|
-
os.environ["LIGHTNING_CLOUD_PROJECT_ID"] = teamspace_id
|
|
109
|
-
os.environ["LIGHTNING_TEAMSPACE"] = teamspace_name
|
|
115
|
+
teamspace = teamspace_api.list_teamspaces(org.id)[0]
|
|
116
|
+
|
|
110
117
|
except Exception as err:
|
|
111
|
-
# throw an appropriate error that guides users to login through the platform
|
|
112
118
|
raise ValueError(
|
|
113
|
-
"
|
|
114
|
-
"If this is your first time using LitAI, please log in at https://lightning.ai/sign-up "
|
|
115
|
-
"and re-run your script, or set the environment variable LIGHTNING_TEAMSPACE=<your-teamspace>."
|
|
119
|
+
f"Organization {teamspace_name} not found. Please verify the organization name."
|
|
116
120
|
) from err
|
|
121
|
+
os.environ["LIGHTNING_CLOUD_PROJECT_ID"] = teamspace.id
|
|
122
|
+
os.environ["LIGHTNING_TEAMSPACE"] = teamspace.name
|
|
123
|
+
|
|
124
|
+
else:
|
|
125
|
+
if teamspace_name is None:
|
|
126
|
+
# studio users
|
|
127
|
+
teamspace_name = os.environ.get("LIGHTNING_TEAMSPACE", None)
|
|
128
|
+
|
|
129
|
+
if teamspace_name is None:
|
|
130
|
+
# local users with no given teamspace
|
|
131
|
+
try:
|
|
132
|
+
authenticate(model=f"{self.provider}/{self.name}")
|
|
133
|
+
teamspace_api = TeamspaceApi()
|
|
134
|
+
user_api = UserApi()
|
|
135
|
+
authed_user = user_api._client.auth_service_get_user()
|
|
136
|
+
default_teamspace = teamspace_api.list_teamspaces(owner_id=authed_user.id)[0]
|
|
137
|
+
teamspace_name = default_teamspace.name
|
|
138
|
+
teamspace_id = default_teamspace.id
|
|
139
|
+
os.environ["LIGHTNING_CLOUD_PROJECT_ID"] = teamspace_id
|
|
140
|
+
os.environ["LIGHTNING_TEAMSPACE"] = teamspace_name
|
|
141
|
+
except Exception as err:
|
|
142
|
+
# throw an appropriate error that guides users to login through the platform
|
|
143
|
+
raise ValueError(
|
|
144
|
+
"Teamspace information is missing. "
|
|
145
|
+
"If this is your first time using LitAI, please log in at https://lightning.ai/sign-up "
|
|
146
|
+
"and re-run your script, or set environment variable LIGHTNING_TEAMSPACE=<your-teamspace>."
|
|
147
|
+
) from err
|
|
117
148
|
|
|
118
|
-
# TODO: when teamspace_name is given, we don't know the teamspace_id yet
|
|
119
149
|
# TODO: if LIGHTNING_CLOUD_PROJECT_ID does not exist, we have to get the id from the teamspace name
|
|
120
150
|
|
|
121
151
|
LLM._cached_auth_info = {
|
|
@@ -35,15 +35,15 @@ PUBLIC_MODELS = {
|
|
|
35
35
|
"id": "ast_01k1z7ajxbz7wq62xj5bc0mrcs",
|
|
36
36
|
"context_length": 128000,
|
|
37
37
|
},
|
|
38
|
-
"openai/gpt-5
|
|
38
|
+
"openai/gpt-5": {
|
|
39
39
|
"id": "ast_01jdjds71fs8gt47jexzed4cza",
|
|
40
40
|
"context_length": 400000
|
|
41
41
|
},
|
|
42
|
-
"openai/gpt-5-mini
|
|
42
|
+
"openai/gpt-5-mini": {
|
|
43
43
|
"id": "ast_01jdjds71fs8gt47jexzed4czb",
|
|
44
44
|
"context_length": 400000
|
|
45
45
|
},
|
|
46
|
-
"openai/gpt-5-nano
|
|
46
|
+
"openai/gpt-5-nano": {
|
|
47
47
|
"id": "ast_01jdjds71fs8gt47jexzed4czc",
|
|
48
48
|
"context_length": 400000
|
|
49
49
|
},
|
lightning_sdk/studio.py
CHANGED
|
@@ -57,6 +57,7 @@ class Studio:
|
|
|
57
57
|
|
|
58
58
|
# skips init of studio, only set when using this as a shell for names, ids etc.
|
|
59
59
|
_skip_init = False
|
|
60
|
+
_skip_setup = False
|
|
60
61
|
|
|
61
62
|
def __init__(
|
|
62
63
|
self,
|
|
@@ -82,7 +83,7 @@ class Studio:
|
|
|
82
83
|
self._teamspace = _teamspace
|
|
83
84
|
self._cloud_account = _resolve_deprecated_cluster(cloud_account, cluster)
|
|
84
85
|
|
|
85
|
-
self._setup_done =
|
|
86
|
+
self._setup_done = self._skip_setup
|
|
86
87
|
self._disable_secrets = disable_secrets
|
|
87
88
|
|
|
88
89
|
self._plugins = {}
|
lightning_sdk/utils/resolve.py
CHANGED
|
@@ -206,6 +206,19 @@ def skip_studio_init() -> Generator[None, None, None]:
|
|
|
206
206
|
Studio._skip_init = prev_studio_init_state
|
|
207
207
|
|
|
208
208
|
|
|
209
|
+
@contextmanager
|
|
210
|
+
def skip_studio_setup() -> Generator[None, None, None]:
|
|
211
|
+
"""Skip studio setup based on current runtime."""
|
|
212
|
+
from lightning_sdk.studio import Studio
|
|
213
|
+
|
|
214
|
+
prev_studio_init_state = Studio._skip_setup
|
|
215
|
+
Studio._skip_setup = True
|
|
216
|
+
|
|
217
|
+
yield
|
|
218
|
+
|
|
219
|
+
Studio._skip_setup = prev_studio_init_state
|
|
220
|
+
|
|
221
|
+
|
|
209
222
|
def _parse_model_and_version(name: str) -> Tuple[str, Optional[str]]:
|
|
210
223
|
"""Parse the model name and version from the given string.
|
|
211
224
|
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
docs/source/conf.py,sha256=r8yX20eC-4mHhMTd0SbQb5TlSWHhO6wnJ0VJ_FBFpag,13249
|
|
2
|
-
lightning_sdk/__init__.py,sha256=
|
|
2
|
+
lightning_sdk/__init__.py,sha256=IIU8VWs4YQHIWb5A96dDCl6_GuKm0TmT_HMBaDe5e-0,1151
|
|
3
3
|
lightning_sdk/agents.py,sha256=ly6Ma1j0ZgGPFyvPvMN28JWiB9dATIstFa5XM8pMi6I,1577
|
|
4
4
|
lightning_sdk/ai_hub.py,sha256=iI1vNhgcz_Ff1c3rN1ogN7dK-r-HXRj6NMtS2cA14UA,6925
|
|
5
5
|
lightning_sdk/base_studio.py,sha256=_Pwwl37R9GRd7t-f2kO5aQXiLNrP4sUtUNht2ZkP8LE,3678
|
|
@@ -14,7 +14,7 @@ lightning_sdk/plugin.py,sha256=f3P5-xZY6x-MX0Fs2z_Q2erSxPSiHZARO0BVkCezHw4,15192
|
|
|
14
14
|
lightning_sdk/sandbox.py,sha256=_NvnWotEXW2rBiVFZZ4krKXxVjuAqfNh04qELSM0-Pg,5786
|
|
15
15
|
lightning_sdk/serve.py,sha256=uW7zLhQ3X90ifetpxzTb8FNxifv5vIs7qZlgfEjVKzk,11794
|
|
16
16
|
lightning_sdk/status.py,sha256=lLGAuSvXBoXQFEEsEYwdCi0RcSNatUn5OPjJVjDtoM0,386
|
|
17
|
-
lightning_sdk/studio.py,sha256=
|
|
17
|
+
lightning_sdk/studio.py,sha256=8oAVdEr1yW4nhkXlDZf-tI5PoG3WFAMuvi1Ow-bmnF0,26500
|
|
18
18
|
lightning_sdk/teamspace.py,sha256=4KLSCxkOIpkOXwvdFMeOgGjX8Ak41NpLkLkdLz7Wu2A,20099
|
|
19
19
|
lightning_sdk/user.py,sha256=vdn8pZqkAZO0-LoRsBdg0TckRKtd_H3QF4gpiZcl4iY,1130
|
|
20
20
|
lightning_sdk/api/__init__.py,sha256=Qn2VVRvir_gO7w4yxGLkZY-R3T7kdiTPKgQ57BhIA9k,413
|
|
@@ -67,7 +67,7 @@ lightning_sdk/cli/deploy/serve.py,sha256=-UzN3SWoMddfQu2Yu0viVDfj8woTTZuMW5Mddkd
|
|
|
67
67
|
lightning_sdk/deployment/__init__.py,sha256=dXsa4psDzFYFklsq3JC-2V_L4FQjGZnQAf-ZiVlqG9c,545
|
|
68
68
|
lightning_sdk/deployment/deployment.py,sha256=7Sk4ORKmgMDk7Owpk_q-89ws8-Y9orX0jRZF99tNv1E,21775
|
|
69
69
|
lightning_sdk/job/__init__.py,sha256=1MxjQ6rHkyUHCypSW9RuXuVMVH11WiqhIXcU2LCFMwE,64
|
|
70
|
-
lightning_sdk/job/base.py,sha256=
|
|
70
|
+
lightning_sdk/job/base.py,sha256=BJULMWcRPxjOQ0RuNpfDUhH2S5YntouYgrxBx3OGljk,21100
|
|
71
71
|
lightning_sdk/job/job.py,sha256=jPlW3u34lJ6tpszm-Q6EHzWrfMIpQfM7-z8UCFFVyaE,14780
|
|
72
72
|
lightning_sdk/job/v1.py,sha256=WISVvPs_j_g1oaNcbEOAua_JpaNO_9_BueJoPgeul6E,9618
|
|
73
73
|
lightning_sdk/job/v2.py,sha256=TiRkTO41VqcV-RhARG93U3182kbcqlrNnsvQ0rdXKPI,11168
|
|
@@ -1041,7 +1041,7 @@ lightning_sdk/lightning_cloud/openapi/models/v1_upstream_open_ai.py,sha256=jt1qQ
|
|
|
1041
1041
|
lightning_sdk/lightning_cloud/openapi/models/v1_usage.py,sha256=ozMzoGD9mfZGYy4J5j50Dps19Y6o8cn-aYW_oRMZMy8,16865
|
|
1042
1042
|
lightning_sdk/lightning_cloud/openapi/models/v1_usage_details.py,sha256=U7qC698Xj5tb3D93ZskG6sDf3lTXE13UTlGeDTvtRU4,14062
|
|
1043
1043
|
lightning_sdk/lightning_cloud/openapi/models/v1_usage_report.py,sha256=k9pDp9UIaOEEWz6bTNWF_KMfcNCOp-F67N-IZ9MO2Rs,8304
|
|
1044
|
-
lightning_sdk/lightning_cloud/openapi/models/v1_user_features.py,sha256=
|
|
1044
|
+
lightning_sdk/lightning_cloud/openapi/models/v1_user_features.py,sha256=Xan5L3rBXqqYn_EIrS6PcxwYAqpPODQf55ZiV4YO4nY,78129
|
|
1045
1045
|
lightning_sdk/lightning_cloud/openapi/models/v1_user_requested_compute_config.py,sha256=0fnZpdhxNRXGNyILHtfm3rVztfHpSF4kXGc5kTt4zls,13960
|
|
1046
1046
|
lightning_sdk/lightning_cloud/openapi/models/v1_user_requested_flow_compute_config.py,sha256=3WpZ-lf7xPwuYyQDMdP7Uc6-dh3vf5TaaUlcMfesfMk,5208
|
|
1047
1047
|
lightning_sdk/lightning_cloud/openapi/models/v1_user_slurm_job_action_response.py,sha256=BdNzXH8Vsf5PHjl9Rd-TVkpAgx1YC9rf8LD0js-ba20,3058
|
|
@@ -1084,8 +1084,8 @@ lightning_sdk/lightning_cloud/utils/dataset.py,sha256=4nUspe8iAaRPgSYpXA2uAQCgyd
|
|
|
1084
1084
|
lightning_sdk/lightning_cloud/utils/name_generator.py,sha256=MkciuA10332V0mcE2PxLIiwWomWE0Fm_gNGK01vwRr4,58046
|
|
1085
1085
|
lightning_sdk/lightning_cloud/utils/network.py,sha256=axPgl8rhyPcPjxiztDxyksfxax3VNg2OXL5F5Uc81b4,406
|
|
1086
1086
|
lightning_sdk/llm/__init__.py,sha256=ErZva0HqN2iPtK_6hI6GN7A_HPGNrHo3wYh7vyFdO3Q,57
|
|
1087
|
-
lightning_sdk/llm/llm.py,sha256=
|
|
1088
|
-
lightning_sdk/llm/public_assistants.py,sha256=
|
|
1087
|
+
lightning_sdk/llm/llm.py,sha256=an7VstxZdP50q4-W8bmvb624uz2MnSTnk93UYlIxopg,17305
|
|
1088
|
+
lightning_sdk/llm/public_assistants.py,sha256=4Gxbz5SD4mBKeSBSbay25XRhZ74Iq4ZF-kNUwl294aE,1449
|
|
1089
1089
|
lightning_sdk/mmt/__init__.py,sha256=ExMu90-96bGBnyp5h0CErQszUGB1-PcjC4-R8_NYbeY,117
|
|
1090
1090
|
lightning_sdk/mmt/base.py,sha256=iqVudKDxazomuezj6l7pa-m9I1EQnM82OKs4ZQbo4Ck,16434
|
|
1091
1091
|
lightning_sdk/mmt/mmt.py,sha256=CZK0KopnW8j-oez464bYMxc0UbqzsYazsNTq1vBtdlg,14982
|
|
@@ -1105,10 +1105,10 @@ lightning_sdk/services/utilities.py,sha256=WlzKDGqUrQFcT85lnLgHvexf7AB1ppxS4_RBk
|
|
|
1105
1105
|
lightning_sdk/utils/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
1106
1106
|
lightning_sdk/utils/dynamic.py,sha256=glUTO1JC9APtQ6Gr9SO02a3zr56-sPAXM5C3NrTpgyQ,1959
|
|
1107
1107
|
lightning_sdk/utils/enum.py,sha256=h2JRzqoBcSlUdanFHmkj_j5DleBHAu1esQYUsdNI-hU,4106
|
|
1108
|
-
lightning_sdk/utils/resolve.py,sha256=
|
|
1109
|
-
lightning_sdk-2025.8.8.dist-info/LICENSE,sha256=uFIuZwj5z-4TeF2UuacPZ1o17HkvKObT8fY50qN84sg,1064
|
|
1110
|
-
lightning_sdk-2025.8.8.dist-info/METADATA,sha256=
|
|
1111
|
-
lightning_sdk-2025.8.8.dist-info/WHEEL,sha256=iAkIy5fosb7FzIOwONchHf19Qu7_1wCWyFNR5gu9nU0,91
|
|
1112
|
-
lightning_sdk-2025.8.8.dist-info/entry_points.txt,sha256=msB9PJWIJ784dX-OP8by51d4IbKYH3Fj1vCuA9oXjHY,68
|
|
1113
|
-
lightning_sdk-2025.8.8.dist-info/top_level.txt,sha256=ps8doKILFXmN7F1mHncShmnQoTxKBRPIcchC8TpoBw4,19
|
|
1114
|
-
lightning_sdk-2025.8.8.dist-info/RECORD,,
|
|
1108
|
+
lightning_sdk/utils/resolve.py,sha256=9BHOxGtDMptkrooRZwu1FkXbYQe5VAIumWGQlz2WIy8,8405
|
|
1109
|
+
lightning_sdk-2025.8.8.post1.dist-info/LICENSE,sha256=uFIuZwj5z-4TeF2UuacPZ1o17HkvKObT8fY50qN84sg,1064
|
|
1110
|
+
lightning_sdk-2025.8.8.post1.dist-info/METADATA,sha256=I5VArnccdkREQ3S6am1i3GRZi4T50N6HHQ79nF_hk_I,4113
|
|
1111
|
+
lightning_sdk-2025.8.8.post1.dist-info/WHEEL,sha256=iAkIy5fosb7FzIOwONchHf19Qu7_1wCWyFNR5gu9nU0,91
|
|
1112
|
+
lightning_sdk-2025.8.8.post1.dist-info/entry_points.txt,sha256=msB9PJWIJ784dX-OP8by51d4IbKYH3Fj1vCuA9oXjHY,68
|
|
1113
|
+
lightning_sdk-2025.8.8.post1.dist-info/top_level.txt,sha256=ps8doKILFXmN7F1mHncShmnQoTxKBRPIcchC8TpoBw4,19
|
|
1114
|
+
lightning_sdk-2025.8.8.post1.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|
{lightning_sdk-2025.8.8.dist-info → lightning_sdk-2025.8.8.post1.dist-info}/entry_points.txt
RENAMED
|
File without changes
|
|
File without changes
|