sapiopycommons 2025.7.1a575__py3-none-any.whl → 2025.7.2a578__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.
Potentially problematic release.
This version of sapiopycommons might be problematic. Click here for more details.
- sapiopycommons/ai/api/fielddefinitions/proto/fields_pb2.py +43 -0
- sapiopycommons/ai/api/fielddefinitions/proto/fields_pb2.pyi +31 -0
- sapiopycommons/ai/api/fielddefinitions/proto/fields_pb2_grpc.py +24 -0
- sapiopycommons/ai/api/fielddefinitions/proto/velox_field_def_pb2.py +123 -0
- sapiopycommons/ai/api/fielddefinitions/proto/velox_field_def_pb2.pyi +598 -0
- sapiopycommons/ai/api/fielddefinitions/proto/velox_field_def_pb2_grpc.py +24 -0
- sapiopycommons/ai/api/plan/proto/step_output_pb2.py +45 -0
- sapiopycommons/ai/api/plan/proto/step_output_pb2.pyi +42 -0
- sapiopycommons/ai/api/plan/proto/step_output_pb2_grpc.py +24 -0
- sapiopycommons/ai/api/plan/proto/step_pb2.py +43 -0
- sapiopycommons/ai/api/plan/proto/step_pb2.pyi +43 -0
- sapiopycommons/ai/api/plan/proto/step_pb2_grpc.py +24 -0
- sapiopycommons/ai/api/plan/script/proto/script_pb2.py +53 -0
- sapiopycommons/ai/api/plan/script/proto/script_pb2.pyi +99 -0
- sapiopycommons/ai/api/plan/script/proto/script_pb2_grpc.py +153 -0
- sapiopycommons/ai/api/plan/tool/proto/entry_pb2.py +57 -0
- sapiopycommons/ai/api/plan/tool/proto/entry_pb2.pyi +96 -0
- sapiopycommons/ai/api/plan/tool/proto/entry_pb2_grpc.py +24 -0
- sapiopycommons/ai/api/plan/tool/proto/tool_pb2.py +67 -0
- sapiopycommons/ai/api/plan/tool/proto/tool_pb2.pyi +220 -0
- sapiopycommons/ai/api/plan/tool/proto/tool_pb2_grpc.py +154 -0
- sapiopycommons/ai/api/session/proto/sapio_conn_info_pb2.py +39 -0
- sapiopycommons/ai/api/session/proto/sapio_conn_info_pb2.pyi +32 -0
- sapiopycommons/ai/api/session/proto/sapio_conn_info_pb2_grpc.py +24 -0
- sapiopycommons/ai/protobuf_utils.py +508 -0
- sapiopycommons/ai/test_client.py +251 -0
- sapiopycommons/ai/tool_service_base.py +798 -0
- sapiopycommons/callbacks/callback_util.py +332 -665
- sapiopycommons/callbacks/field_builder.py +0 -2
- sapiopycommons/chem/IndigoMolecules.py +1 -29
- sapiopycommons/chem/Molecules.py +3 -3
- sapiopycommons/customreport/auto_pagers.py +1 -26
- sapiopycommons/customreport/term_builder.py +1 -1
- sapiopycommons/datatype/pseudo_data_types.py +326 -349
- sapiopycommons/eln/experiment_handler.py +767 -408
- sapiopycommons/eln/experiment_report_util.py +6 -11
- sapiopycommons/eln/plate_designer.py +2 -7
- sapiopycommons/files/file_util.py +5 -7
- sapiopycommons/general/accession_service.py +2 -2
- sapiopycommons/general/aliases.py +1 -3
- sapiopycommons/general/audit_log.py +0 -7
- sapiopycommons/general/custom_report_util.py +0 -12
- sapiopycommons/processtracking/custom_workflow_handler.py +1 -11
- sapiopycommons/processtracking/endpoints.py +0 -27
- sapiopycommons/recordmodel/record_handler.py +317 -657
- sapiopycommons/rules/eln_rule_handler.py +1 -8
- sapiopycommons/rules/on_save_rule_handler.py +1 -8
- sapiopycommons/webhook/webhook_handlers.py +0 -3
- sapiopycommons/webhook/webservice_handlers.py +2 -2
- {sapiopycommons-2025.7.1a575.dist-info → sapiopycommons-2025.7.2a578.dist-info}/METADATA +2 -2
- sapiopycommons-2025.7.2a578.dist-info/RECORD +92 -0
- sapiopycommons/ai/tool_of_tools.py +0 -917
- sapiopycommons/eln/experiment_cache.py +0 -188
- sapiopycommons/eln/experiment_step_factory.py +0 -476
- sapiopycommons/eln/step_creation.py +0 -236
- sapiopycommons/general/data_structure_util.py +0 -115
- sapiopycommons-2025.7.1a575.dist-info/RECORD +0 -70
- {sapiopycommons-2025.7.1a575.dist-info → sapiopycommons-2025.7.2a578.dist-info}/WHEEL +0 -0
- {sapiopycommons-2025.7.1a575.dist-info → sapiopycommons-2025.7.2a578.dist-info}/licenses/LICENSE +0 -0
|
@@ -1,236 +0,0 @@
|
|
|
1
|
-
from typing import Iterable
|
|
2
|
-
|
|
3
|
-
from sapiopycommons.general.aliases import DataTypeIdentifier, FieldIdentifier, ExperimentEntryIdentifier
|
|
4
|
-
from sapiopylib.rest.pojo.TableColumn import TableColumn
|
|
5
|
-
from sapiopylib.rest.pojo.datatype.FieldDefinition import AbstractVeloxFieldDefinition
|
|
6
|
-
from sapiopylib.rest.pojo.eln.SapioELNEnums import ExperimentEntryStatus, ElnEntryType
|
|
7
|
-
from sapiopylib.rest.pojo.eln.field_set import ElnFieldSetInfo
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
# CR-47564: Created these classes to streamline entry creation using the ExperimentEntryFactory.
|
|
11
|
-
class StepCreation:
|
|
12
|
-
"""
|
|
13
|
-
An object that contains the criteria for creating a new entry in the experiment.
|
|
14
|
-
"""
|
|
15
|
-
_entry_type: ElnEntryType
|
|
16
|
-
"""The type of the entry to be created."""
|
|
17
|
-
is_shown_in_template: bool | None
|
|
18
|
-
"""Whether the entry will appear in the template if the experiment this entry is in is saved to a new template."""
|
|
19
|
-
is_removable: bool | None
|
|
20
|
-
"""Whether the entry can be removed by users."""
|
|
21
|
-
is_renamable: bool | None
|
|
22
|
-
"""Whether the entry can be renamed by users."""
|
|
23
|
-
is_static_view: bool | None
|
|
24
|
-
"""Whether the entry's attachment is static. For attachment entries only. Static attachment entries will store
|
|
25
|
-
their attachment data in the template."""
|
|
26
|
-
related_entry_set: Iterable[ExperimentEntryIdentifier | str] | None
|
|
27
|
-
"""The IDs of the entries this entry is implicitly dependent on. If any of the entries are deleted then this entry
|
|
28
|
-
is also deleted."""
|
|
29
|
-
dependency_set: Iterable[ExperimentEntryIdentifier | str] | None
|
|
30
|
-
"""The IDs of the entries this entry is dependent on. Requires the entries to be completed before this entry will
|
|
31
|
-
be enabled."""
|
|
32
|
-
requires_grabber_plugin: bool
|
|
33
|
-
"""Whether to run a grabber plugin when this entry is initialized."""
|
|
34
|
-
entry_singleton_id: str | None
|
|
35
|
-
"""When this field is present (i.e. not null or blank) it will enforce that only one entry with this singleton
|
|
36
|
-
value is present in the experiment. If you attempt to create an entry with the singletonId of an entry already
|
|
37
|
-
present in the experiment it will return the existing entry instead of creating a new one. If an entry isn't
|
|
38
|
-
present in the Notebook Experiment with a matching singletonId it will create a new entry like normal."""
|
|
39
|
-
is_hidden: bool | None
|
|
40
|
-
"""Whether the user is able to visibly see this entry within the experiment."""
|
|
41
|
-
entry_height: int | None
|
|
42
|
-
"""The height of this entry in pixels. Setting the height to 0 will cause the entry to auto-size to its contents."""
|
|
43
|
-
description: str | None
|
|
44
|
-
"""The description of the entry."""
|
|
45
|
-
is_initialization_required: bool | None
|
|
46
|
-
"""Whether the user must manually initialize this entry by clicking on it."""
|
|
47
|
-
collapse_entry: bool | None
|
|
48
|
-
"""Whether the entry should be collapsed by default."""
|
|
49
|
-
entry_status: ExperimentEntryStatus | None
|
|
50
|
-
"""The current status of the entry."""
|
|
51
|
-
template_item_fulfilled_timestamp: int | None
|
|
52
|
-
"""The time in milliseconds since the epoch that this entry became initialized."""
|
|
53
|
-
entry_options: dict[str, str] | None
|
|
54
|
-
"""The entry options of the entry."""
|
|
55
|
-
|
|
56
|
-
def __init__(self, entry_type: ElnEntryType):
|
|
57
|
-
self._entry_type = entry_type
|
|
58
|
-
self.is_shown_in_template = None
|
|
59
|
-
self.is_removable = None
|
|
60
|
-
self.is_renamable = None
|
|
61
|
-
self.is_static_view = None
|
|
62
|
-
self.related_entry_set = None
|
|
63
|
-
self.dependency_set = None
|
|
64
|
-
self.requires_grabber_plugin = False
|
|
65
|
-
self.entry_singleton_id = None
|
|
66
|
-
self.is_hidden = None
|
|
67
|
-
self.entry_height = None
|
|
68
|
-
self.description = None
|
|
69
|
-
self.is_initialization_required = None
|
|
70
|
-
self.collapse_entry = None
|
|
71
|
-
self.entry_status = None
|
|
72
|
-
self.template_item_fulfilled_timestamp = None
|
|
73
|
-
self.entry_options = None
|
|
74
|
-
|
|
75
|
-
@property
|
|
76
|
-
def entry_type(self) -> ElnEntryType:
|
|
77
|
-
return self._entry_type
|
|
78
|
-
|
|
79
|
-
class AttachmentStepCreation(StepCreation):
|
|
80
|
-
"""
|
|
81
|
-
An object that contains criteria for creating a new attachment entry in an experiment.
|
|
82
|
-
"""
|
|
83
|
-
def __init__(self):
|
|
84
|
-
super().__init__(ElnEntryType.Attachment)
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
class DashboardStepCreation(StepCreation):
|
|
88
|
-
"""
|
|
89
|
-
An object that contains criteria for creating a new dashboard entry in an experiment.
|
|
90
|
-
"""
|
|
91
|
-
source_entry: ExperimentEntryIdentifier | str | None
|
|
92
|
-
"""The entry that contains the source data for this entry's dashboard(s)."""
|
|
93
|
-
dashboard_guids: Iterable[str] | None
|
|
94
|
-
"""The GUIDs of the dashboards to display in this entry."""
|
|
95
|
-
|
|
96
|
-
def __init__(self):
|
|
97
|
-
super().__init__(ElnEntryType.Dashboard)
|
|
98
|
-
self.source_entry = None
|
|
99
|
-
self.dashboard_guids = None
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
class GlobalDtFormStepCreation(StepCreation):
|
|
103
|
-
"""
|
|
104
|
-
An object that contains criteria for creating a new global data type form entry in an experiment.
|
|
105
|
-
"""
|
|
106
|
-
layout_name: str | None
|
|
107
|
-
"""The name of the data type layout to be displayed in this form. The layout must be for the data type for this
|
|
108
|
-
entry."""
|
|
109
|
-
form_names: Iterable[str] | None
|
|
110
|
-
"""The names of the components in the chosen data type layout to display in this form."""
|
|
111
|
-
extension_types: Iterable[DataTypeIdentifier] | None
|
|
112
|
-
"""The names of the extension data types to display fields from within the form."""
|
|
113
|
-
field_names: Iterable[FieldIdentifier] | None
|
|
114
|
-
"""A list of data field names for the fields to be displayed in the form."""
|
|
115
|
-
|
|
116
|
-
def __init__(self):
|
|
117
|
-
super().__init__(ElnEntryType.Form)
|
|
118
|
-
self.form_names = None
|
|
119
|
-
self.layout_name = None
|
|
120
|
-
self.extension_types = None
|
|
121
|
-
self.field_names = None
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
class ELnDtFormStepCreation(StepCreation):
|
|
125
|
-
"""
|
|
126
|
-
An object that contains criteria for creating a new ELN data type form entry in an experiment.
|
|
127
|
-
"""
|
|
128
|
-
is_field_addable: bool | None
|
|
129
|
-
"""Whether new fields can be added to the entry by users."""
|
|
130
|
-
is_existing_field_removable: bool | None
|
|
131
|
-
"""Whether existing fields on the entry can be removed by users."""
|
|
132
|
-
field_sets: Iterable[int | str | ElnFieldSetInfo] | None
|
|
133
|
-
"""The predefined field sets to display in this form."""
|
|
134
|
-
field_definitions: Iterable[AbstractVeloxFieldDefinition] | None
|
|
135
|
-
"""New field definitions to be created for this entry."""
|
|
136
|
-
predefined_field_names: Iterable[str] | None
|
|
137
|
-
"""The names of the predefined fields to display in this form."""
|
|
138
|
-
|
|
139
|
-
def __init__(self):
|
|
140
|
-
super().__init__(ElnEntryType.Form)
|
|
141
|
-
self.is_field_addable = None
|
|
142
|
-
self.is_existing_field_removable = None
|
|
143
|
-
self.field_sets = None
|
|
144
|
-
self.field_definitions = None
|
|
145
|
-
self.predefined_field_names = None
|
|
146
|
-
self.table_columns = None
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
class PluginStepCreation(StepCreation):
|
|
150
|
-
"""
|
|
151
|
-
An object that contains criteria for creating a new plugin entry in an experiment.
|
|
152
|
-
"""
|
|
153
|
-
plugin_name: str | None
|
|
154
|
-
"""The client side plugin name to render this entry with."""
|
|
155
|
-
using_template_data: bool | None
|
|
156
|
-
"""Whether this entry will use the data from the template."""
|
|
157
|
-
provides_template_data: bool | None
|
|
158
|
-
"""Whether this entry can provide data to copy into a new template."""
|
|
159
|
-
|
|
160
|
-
def __init__(self):
|
|
161
|
-
super().__init__(ElnEntryType.Plugin)
|
|
162
|
-
self.plugin_name = None
|
|
163
|
-
self.using_template_data = None
|
|
164
|
-
self.provides_template_data = None
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
class GlobalDtTableStepCreation(StepCreation):
|
|
168
|
-
"""
|
|
169
|
-
An object that contains criteria for creating a new global data type table entry in an experiment.
|
|
170
|
-
"""
|
|
171
|
-
layout_name: str | None
|
|
172
|
-
"""The name of the data type layout to display in this table."""
|
|
173
|
-
extension_types: Iterable[str] | None
|
|
174
|
-
"""The names of the extension data types to display fields from within the table."""
|
|
175
|
-
table_columns: Iterable[TableColumn] | None
|
|
176
|
-
"""The columns to display in the table. This can be used to change the sort order and direction of columns."""
|
|
177
|
-
field_names: Iterable[FieldIdentifier] | None
|
|
178
|
-
"""A list of data field names for the fields to be displayed in the table. These will be added as TableColumns and
|
|
179
|
-
placed after any of the existing columns specified in the table_columns parameter without any sorting."""
|
|
180
|
-
show_key_fields: bool | None
|
|
181
|
-
"""Whether the key fields of the data type should be shown in the entry."""
|
|
182
|
-
|
|
183
|
-
def __init__(self):
|
|
184
|
-
super().__init__(ElnEntryType.Table)
|
|
185
|
-
self.layout_name = None
|
|
186
|
-
self.extension_types = None
|
|
187
|
-
self.table_columns = None
|
|
188
|
-
self.field_names = None
|
|
189
|
-
self.show_key_fields = None
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
class ELnDtTableStepCreation(StepCreation):
|
|
193
|
-
"""
|
|
194
|
-
An object that contains criteria for creating a new ELN data type table entry in an experiment.
|
|
195
|
-
"""
|
|
196
|
-
is_field_addable: bool | None
|
|
197
|
-
"""Whether new fields can be added to the entry by users."""
|
|
198
|
-
is_existing_field_removable: bool | None
|
|
199
|
-
"""Whether existing fields on the entry can be removed by users."""
|
|
200
|
-
field_sets: Iterable[int | str | ElnFieldSetInfo] | None
|
|
201
|
-
"""The predefined field sets to display in this form."""
|
|
202
|
-
field_definitions: Iterable[AbstractVeloxFieldDefinition] | None
|
|
203
|
-
"""New field definitions to be created for this entry."""
|
|
204
|
-
predefined_field_names: Iterable[str] | None
|
|
205
|
-
"""The names of the predefined fields to display in this form."""
|
|
206
|
-
table_columns: Iterable[TableColumn] | None
|
|
207
|
-
"""The columns to display in the table."""
|
|
208
|
-
|
|
209
|
-
def __init__(self):
|
|
210
|
-
super().__init__(ElnEntryType.Table)
|
|
211
|
-
self.is_field_addable = None
|
|
212
|
-
self.is_existing_field_removable = None
|
|
213
|
-
self.field_sets = None
|
|
214
|
-
self.field_definitions = None
|
|
215
|
-
self.predefined_field_names = None
|
|
216
|
-
self.table_columns = None
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
class TempDataStepCreation(StepCreation):
|
|
220
|
-
"""
|
|
221
|
-
An object that contains criteria for creating a new temp data entry in an experiment.
|
|
222
|
-
"""
|
|
223
|
-
plugin_path: str | None
|
|
224
|
-
"""The temp data plugin path to run to populate the entry."""
|
|
225
|
-
|
|
226
|
-
def __init__(self):
|
|
227
|
-
super().__init__(ElnEntryType.TempData)
|
|
228
|
-
self.plugin_path = None
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
class TextStepCreation(StepCreation):
|
|
232
|
-
"""
|
|
233
|
-
An object that contains criteria for creating a new text entry in an experiment.
|
|
234
|
-
"""
|
|
235
|
-
def __init__(self):
|
|
236
|
-
super().__init__(ElnEntryType.Text)
|
|
@@ -1,115 +0,0 @@
|
|
|
1
|
-
from enum import Enum
|
|
2
|
-
from typing import Iterable, Any, Collection
|
|
3
|
-
|
|
4
|
-
from sapiopycommons.general.exceptions import SapioException
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
class ArrayTransformation(Enum):
|
|
8
|
-
"""
|
|
9
|
-
An enumeration of the different transformations that can be applied to a 2D array.
|
|
10
|
-
"""
|
|
11
|
-
ROTATE_CLOCKWISE = 0
|
|
12
|
-
ROTATE_COUNTER_CLOCKWISE = 1
|
|
13
|
-
ROTATE_180_DEGREES = 2
|
|
14
|
-
MIRROR_HORIZONTAL = 3
|
|
15
|
-
MIRROR_VERTICAL = 4
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
# FR-47524: Create a DataStructureUtils class that implements various collection utility functions from our Java
|
|
19
|
-
# libraries.
|
|
20
|
-
class DataStructureUtil:
|
|
21
|
-
"""
|
|
22
|
-
Utility class for working with data structures. Copies from ListUtil, SetUtil, and various other classes in
|
|
23
|
-
our Java library.
|
|
24
|
-
"""
|
|
25
|
-
@staticmethod
|
|
26
|
-
def find_first_or_none(values: Iterable[Any]) -> Any | None:
|
|
27
|
-
"""
|
|
28
|
-
Get the first value from an iterable, or None if the iterable is empty.
|
|
29
|
-
|
|
30
|
-
:param values: An iterable of values.
|
|
31
|
-
:return: The first value from the input, or None if the input is empty.
|
|
32
|
-
"""
|
|
33
|
-
return next(iter(values), None)
|
|
34
|
-
|
|
35
|
-
@staticmethod
|
|
36
|
-
def remove_null_values(values: Iterable[Any]) -> list[Any]:
|
|
37
|
-
"""
|
|
38
|
-
Remove null values from a list.
|
|
39
|
-
|
|
40
|
-
:param values: An iterable of values.
|
|
41
|
-
:return: A list containing all the non-null values from the input.
|
|
42
|
-
"""
|
|
43
|
-
return [value for value in values if value is not None]
|
|
44
|
-
|
|
45
|
-
@staticmethod
|
|
46
|
-
def transform_2d_array(values: Collection[Collection[Any]], transformation: ArrayTransformation) \
|
|
47
|
-
-> Collection[Collection[Any]]:
|
|
48
|
-
"""
|
|
49
|
-
Perform a transformation on a 2D list.
|
|
50
|
-
|
|
51
|
-
:param values: An iterable of iterables. The iterables should all be of the same size.
|
|
52
|
-
:param transformation: The transformation to apply to the input.
|
|
53
|
-
:return: A new 2D list containing the input transformed according to the specified transformation.
|
|
54
|
-
"""
|
|
55
|
-
x: int = len(values)
|
|
56
|
-
for row in values:
|
|
57
|
-
y = len(row)
|
|
58
|
-
if y != x:
|
|
59
|
-
raise SapioException(f"Input must be a square 2D array. The provided array has a length of {x} but "
|
|
60
|
-
f"at least one row has a length of {y}.")
|
|
61
|
-
|
|
62
|
-
match transformation:
|
|
63
|
-
case ArrayTransformation.ROTATE_CLOCKWISE:
|
|
64
|
-
return [list(row) for row in zip(*values[::-1])]
|
|
65
|
-
case ArrayTransformation.ROTATE_COUNTER_CLOCKWISE:
|
|
66
|
-
return [list(row) for row in zip(*values)][::-1]
|
|
67
|
-
case ArrayTransformation.ROTATE_180_DEGREES:
|
|
68
|
-
return [row[::-1] for row in values[::-1]]
|
|
69
|
-
case ArrayTransformation.MIRROR_HORIZONTAL:
|
|
70
|
-
return [list(row[::-1]) for row in values]
|
|
71
|
-
case ArrayTransformation.MIRROR_VERTICAL:
|
|
72
|
-
return values[::-1]
|
|
73
|
-
|
|
74
|
-
raise SapioException(f"Invalid transformation: {transformation}")
|
|
75
|
-
|
|
76
|
-
@staticmethod
|
|
77
|
-
def flatten_to_list(values: Iterable[Iterable[Any]]) -> list[Any]:
|
|
78
|
-
"""
|
|
79
|
-
Flatten a list of lists into a single list.
|
|
80
|
-
|
|
81
|
-
:param values: An iterable of iterables.
|
|
82
|
-
:return: A single list containing all the values from the input. Elements are in the order they appear in the
|
|
83
|
-
input.
|
|
84
|
-
"""
|
|
85
|
-
return [item for sublist in values for item in sublist]
|
|
86
|
-
|
|
87
|
-
@staticmethod
|
|
88
|
-
def flatten_to_set(values: Iterable[Iterable[Any]]) -> set[Any]:
|
|
89
|
-
"""
|
|
90
|
-
Flatten a list of lists into a single set.
|
|
91
|
-
|
|
92
|
-
:param values: An iterable of iterables.
|
|
93
|
-
:return: A single set containing all the values from the input. Elements are in the order they appear in the
|
|
94
|
-
input.
|
|
95
|
-
"""
|
|
96
|
-
return {item for subset in values for item in subset}
|
|
97
|
-
|
|
98
|
-
@staticmethod
|
|
99
|
-
def invert_dictionary(dictionary: dict[Any, Any], list_values: bool = False) \
|
|
100
|
-
-> dict[Any, Any] | dict[Any, list[Any]]:
|
|
101
|
-
"""
|
|
102
|
-
Invert a dictionary, swapping keys and values. Note that the values of the input dictionary must be hashable.
|
|
103
|
-
|
|
104
|
-
:param dictionary: A dictionary to invert.
|
|
105
|
-
:param list_values: If false, keys that share the same value in the input dictionary will be overwritten in
|
|
106
|
-
the output dictionary so that only the last key remains. If true, the values of the output dictionary will
|
|
107
|
-
be lists where input keys that share the same value will be stored together.
|
|
108
|
-
:return: A new dictionary with the keys and values swapped.
|
|
109
|
-
"""
|
|
110
|
-
if list_values:
|
|
111
|
-
inverted = {}
|
|
112
|
-
for key, value in dictionary.items():
|
|
113
|
-
inverted.setdefault(value, []).append(key)
|
|
114
|
-
return inverted
|
|
115
|
-
return {value: key for key, value in dictionary.items()}
|
|
@@ -1,70 +0,0 @@
|
|
|
1
|
-
sapiopycommons/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
2
|
-
sapiopycommons/ai/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
3
|
-
sapiopycommons/ai/tool_of_tools.py,sha256=zYmQ4rNX-qYQnc-vNDnYZjtv9JgmQAmVVuHfVOdBF3w,46984
|
|
4
|
-
sapiopycommons/callbacks/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
5
|
-
sapiopycommons/callbacks/callback_util.py,sha256=OuPJ1o6jcDQ7qV-dxrjAkJerGbVI9_9P-xu0r3ODaMM,153008
|
|
6
|
-
sapiopycommons/callbacks/field_builder.py,sha256=rnIP-RJafk3mZlAx1eJ8a0eSW9Ps_L6_WadCmusnENw,38772
|
|
7
|
-
sapiopycommons/chem/IndigoMolecules.py,sha256=7ucCaRMLu1zfH2uPIvXwRTSdpNcS03O1P9p_O-5B4xQ,5110
|
|
8
|
-
sapiopycommons/chem/Molecules.py,sha256=mVqPn32MPMjF0iZas-5MFkS-upIdoW5OB72KKZmJRJA,12523
|
|
9
|
-
sapiopycommons/chem/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
10
|
-
sapiopycommons/customreport/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
11
|
-
sapiopycommons/customreport/auto_pagers.py,sha256=89p-tik0MhsOplYje6LbAW4WClldpAmb8YXFDoXhIlY,17144
|
|
12
|
-
sapiopycommons/customreport/column_builder.py,sha256=0RO53e9rKPZ07C--KcepN6_tpRw_FxF3O9vdG0ilKG8,3014
|
|
13
|
-
sapiopycommons/customreport/custom_report_builder.py,sha256=BlTxZ4t1sfZA2Ciur1EfYvkZxHxJ7ADwYNAe2zwiN0c,7176
|
|
14
|
-
sapiopycommons/customreport/term_builder.py,sha256=1_PGjxNUy5YWim8WJ_HJfiTq6i0D3gLPDxLySlFt30o,18573
|
|
15
|
-
sapiopycommons/datatype/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
16
|
-
sapiopycommons/datatype/attachment_util.py,sha256=N-nhsJ0oxa_Ft6Y6VWeNFYLzfuQqsjhHA6_-yIt2wVw,3596
|
|
17
|
-
sapiopycommons/datatype/data_fields.py,sha256=pczUlEcE0TeHEDU0Gkvu7voacSLPXCB7l9UbI1Tb6V0,5656
|
|
18
|
-
sapiopycommons/datatype/pseudo_data_types.py,sha256=lAJDnFuStrUP0mK5AuYlFvLerwjEB-ABd6Z4qlCrwJA,40637
|
|
19
|
-
sapiopycommons/eln/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
20
|
-
sapiopycommons/eln/experiment_cache.py,sha256=Zv4IcsAl95ftO2ul3DRc_Hyno0AfC3OvFV7RYb72ITo,9560
|
|
21
|
-
sapiopycommons/eln/experiment_handler.py,sha256=kMQuccmGyPzc8wYKsds6AZ_VjH9WLjtUY6hsSWXJx6s,98786
|
|
22
|
-
sapiopycommons/eln/experiment_report_util.py,sha256=GLpgwSEPuUqnY1v4oJ1ao60Va-YcgXh7E-cH9YnVeAg,37256
|
|
23
|
-
sapiopycommons/eln/experiment_step_factory.py,sha256=qw9UfLslVzB6dEIZPOZ85XHKpld81RhD4-csM6TgQNg,26099
|
|
24
|
-
sapiopycommons/eln/experiment_tags.py,sha256=7-fpOiSqrjbXmWIJhEhaxMgLsVCPAtKqH8xRzpDVKoE,356
|
|
25
|
-
sapiopycommons/eln/plate_designer.py,sha256=XFazSvhTbSy47t80-jc2tyx_-fQ_IUjKd18JQKEFcsY,13939
|
|
26
|
-
sapiopycommons/eln/step_creation.py,sha256=CFkGC-SxwAQpQlcs_obqLAVgmsNxKSGMqMtO_E6IVmw,10171
|
|
27
|
-
sapiopycommons/files/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
28
|
-
sapiopycommons/files/complex_data_loader.py,sha256=T39veNhvYl6j_uZjIIJ8Mk5Aa7otR5RB-g8XlAdkksA,1421
|
|
29
|
-
sapiopycommons/files/file_bridge.py,sha256=vKbqxPexi15epr_-_qLrEfYoxNxB031mXN92iVtOMqE,9511
|
|
30
|
-
sapiopycommons/files/file_bridge_handler.py,sha256=SEYDIQhSCmjI6qyLdDJE8JVKSd0WYvF7JvAq_Ahp9Do,25503
|
|
31
|
-
sapiopycommons/files/file_data_handler.py,sha256=f96MlkMuQhUCi4oLnzJK5AiuElCp5jLI8_sJkZVwpws,36779
|
|
32
|
-
sapiopycommons/files/file_util.py,sha256=djouyGjsYgWzjz2OBRnSeMDgj6NrsJUm1a2J93J8Wco,31915
|
|
33
|
-
sapiopycommons/files/file_validator.py,sha256=ryg22-93csmRO_Pv0ZpWphNkB74xWZnHyJ23K56qLj0,28761
|
|
34
|
-
sapiopycommons/files/file_writer.py,sha256=hACVl0duCjP28gJ1NPljkjagNCLod0ygUlPbvUmRDNM,17605
|
|
35
|
-
sapiopycommons/flowcyto/flow_cyto.py,sha256=vs9WhXXKz3urpjL8QKSk56B-NSmQR3O3x_WFBKoeO10,3227
|
|
36
|
-
sapiopycommons/flowcyto/flowcyto_data.py,sha256=mYKFuLbtpJ-EsQxLGtu4tNHVlygTxKixgJxJqD68F58,2596
|
|
37
|
-
sapiopycommons/general/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
38
|
-
sapiopycommons/general/accession_service.py,sha256=3e__bVs7CYZ1CduLlGA9plnK7nCtdy7GXjCrNObPFgo,13484
|
|
39
|
-
sapiopycommons/general/aliases.py,sha256=VwnWf_P803pcteoAIs0DkLScVChCS5XNgryTp8FzaNc,14696
|
|
40
|
-
sapiopycommons/general/audit_log.py,sha256=sQAMcJx0cNkgZm7nTZSaGPxWvHG0_x6dBtU0jESavb4,9131
|
|
41
|
-
sapiopycommons/general/custom_report_util.py,sha256=9elLEUSgfM0gli8nRPz1uYkhaXN4Vnx3piSiNHv5IBs,19156
|
|
42
|
-
sapiopycommons/general/data_structure_util.py,sha256=fbQR_Fh4Scg67IpFPbQW9wVLw1oxlYxqp4LjBRTpjgU,4702
|
|
43
|
-
sapiopycommons/general/directive_util.py,sha256=7SeQrd2Ye5JHlXZtJZaVGgtaSLdq_Vm9EObuxf44Pz8,3905
|
|
44
|
-
sapiopycommons/general/exceptions.py,sha256=aPlzK1cvxeMU5UsokYlLrIBGltUfJZ7LH8zvLh9DxpI,3233
|
|
45
|
-
sapiopycommons/general/html_formatter.py,sha256=HE3OeGgwOw6x53zGSc4-UzP4-JoOmQIz3pX-DzNVg94,17138
|
|
46
|
-
sapiopycommons/general/popup_util.py,sha256=HKILegU1uCL_6abNlNL0Wn3xgX2JNa_kJeq7e5CZu6Q,31923
|
|
47
|
-
sapiopycommons/general/sapio_links.py,sha256=YkcVKNLrSGoM7tCCXBAsIbIxylctwdcEyhePrRMODe0,2859
|
|
48
|
-
sapiopycommons/general/storage_util.py,sha256=ovmK_jN7v09BoX07XxwShpBUC5WYQOM7dbKV_VeLXJU,8892
|
|
49
|
-
sapiopycommons/general/time_util.py,sha256=jU1urPoZRv6evNucR0-288EyT4PrsDpCr-H1-7BKq9A,12363
|
|
50
|
-
sapiopycommons/multimodal/multimodal.py,sha256=PFaGJPbKvW__tnxb8KkgkJZOKjQdgxF_kGfD5chet1s,6779
|
|
51
|
-
sapiopycommons/multimodal/multimodal_data.py,sha256=0BeVPr9HaC0hNTF1v1phTIKGruvNnwerHsD994qJKBg,15099
|
|
52
|
-
sapiopycommons/processtracking/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
53
|
-
sapiopycommons/processtracking/custom_workflow_handler.py,sha256=eYKdYlwo8xx-6AkB_iPUBNV9yDoNvW2h_Sm3i8JpmRU,25844
|
|
54
|
-
sapiopycommons/processtracking/endpoints.py,sha256=5AJLbhRKQsOeeOdQa888xcCJZD5aavxD-DHZ36Qob_M,12548
|
|
55
|
-
sapiopycommons/recordmodel/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
56
|
-
sapiopycommons/recordmodel/record_handler.py,sha256=HfYOl_dDHFd0SEQS3g48_a4zsm36ODWkvZunwzCFDos,90666
|
|
57
|
-
sapiopycommons/rules/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
58
|
-
sapiopycommons/rules/eln_rule_handler.py,sha256=MnE-eSl1kNfaXWFi9elTOC9V2fdUzrwWTvCHUprC8_I,11388
|
|
59
|
-
sapiopycommons/rules/on_save_rule_handler.py,sha256=fkNIlslAZZ0BUrRiwecyvf42JBR8FpCCQ6DBNKXP2jE,11155
|
|
60
|
-
sapiopycommons/samples/aliquot.py,sha256=mWOJUqaQh0t3HklNuGdmuV7D5zzXs6fpLwtDdM6_XTo,3018
|
|
61
|
-
sapiopycommons/sftpconnect/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
62
|
-
sapiopycommons/sftpconnect/sftp_builder.py,sha256=lFK3FeXk-sFLefW0hqY8WGUQDeYiGaT6yDACzT_zFgQ,3015
|
|
63
|
-
sapiopycommons/webhook/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
64
|
-
sapiopycommons/webhook/webhook_context.py,sha256=D793uLsb1691SalaPnBUk3rOSxn_hYLhdvkaIxjNXss,1909
|
|
65
|
-
sapiopycommons/webhook/webhook_handlers.py,sha256=tUVNCw05CDGu1gFDm2g558hX_O203WVm_n__ojjoRRM,39841
|
|
66
|
-
sapiopycommons/webhook/webservice_handlers.py,sha256=tyaYGG1-v_JJrJHZ6cy5mGCxX9z1foLw7pM4MDJlFxs,14297
|
|
67
|
-
sapiopycommons-2025.7.1a575.dist-info/METADATA,sha256=A5xcFHxCQAm70feJ7Yp8pQU8-sTtAZQKgMYkkfweZHY,3142
|
|
68
|
-
sapiopycommons-2025.7.1a575.dist-info/WHEEL,sha256=C2FUgwZgiLbznR-k0b_5k3Ai_1aASOXDss3lzCUsUug,87
|
|
69
|
-
sapiopycommons-2025.7.1a575.dist-info/licenses/LICENSE,sha256=HyVuytGSiAUQ6ErWBHTqt1iSGHhLmlC8fO7jTCuR8dU,16725
|
|
70
|
-
sapiopycommons-2025.7.1a575.dist-info/RECORD,,
|
|
File without changes
|
{sapiopycommons-2025.7.1a575.dist-info → sapiopycommons-2025.7.2a578.dist-info}/licenses/LICENSE
RENAMED
|
File without changes
|