kodexa 7.4.413640242188__tar.gz → 7.4.413698503885__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.
Files changed (50) hide show
  1. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/PKG-INFO +1 -1
  2. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/model/objects.py +73 -0
  3. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/platform/client.py +61 -7
  4. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/pyproject.toml +1 -1
  5. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/LICENSE +0 -0
  6. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/README.md +0 -0
  7. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/__init__.py +0 -0
  8. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/assistant/__init__.py +0 -0
  9. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/assistant/assistant.py +0 -0
  10. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/connectors/__init__.py +0 -0
  11. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/connectors/connectors.py +0 -0
  12. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/dataclasses/__init__.py +0 -0
  13. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/dataclasses/templates/llm_data_class.j2 +0 -0
  14. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/model/__init__.py +0 -0
  15. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/model/base.py +0 -0
  16. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/model/entities/__init__.py +0 -0
  17. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/model/entities/check_response.py +0 -0
  18. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/model/entities/product.py +0 -0
  19. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/model/entities/product_group.py +0 -0
  20. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/model/entities/product_subscription.py +0 -0
  21. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/model/model.py +0 -0
  22. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/model/persistence.py +0 -0
  23. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/model/utils.py +0 -0
  24. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/pipeline/__init__.py +0 -0
  25. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/pipeline/pipeline.py +0 -0
  26. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/platform/__init__.py +0 -0
  27. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/platform/interaction.py +0 -0
  28. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/platform/kodexa.py +0 -0
  29. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/selectors/__init__.py +0 -0
  30. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/selectors/ast.py +0 -0
  31. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/selectors/core.py +0 -0
  32. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/selectors/lexrules.py +0 -0
  33. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/selectors/lextab.py +0 -0
  34. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/selectors/lextab.pyi +0 -0
  35. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/selectors/parserules.py +0 -0
  36. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/selectors/parserules.pyi +0 -0
  37. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/selectors/parsetab.py +0 -0
  38. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/selectors/parsetab.pyi +0 -0
  39. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/spatial/__init__.py +0 -0
  40. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/spatial/azure_models.py +0 -0
  41. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/spatial/bbox_common.py +0 -0
  42. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/spatial/table_form_common.py +0 -0
  43. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/steps/__init__.py +0 -0
  44. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/steps/common.py +0 -0
  45. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/testing/__init__.py +0 -0
  46. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/testing/test_components.py +0 -0
  47. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/testing/test_utils.py +0 -0
  48. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/training/__init__.py +0 -0
  49. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/training/train_utils.py +0 -0
  50. {kodexa-7.4.413640242188 → kodexa-7.4.413698503885}/kodexa/utils/__init__.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: kodexa
3
- Version: 7.4.413640242188
3
+ Version: 7.4.413698503885
4
4
  Summary: Python SDK for the Kodexa Platform
5
5
  Author: Austin Redenbaugh
6
6
  Author-email: austin@kodexa.com
@@ -2900,6 +2900,79 @@ class ProjectOptions(BaseModel):
2900
2900
  )
2901
2901
 
2902
2902
 
2903
+ class NodePosition(BaseModel):
2904
+ model_config = ConfigDict(
2905
+ populate_by_name=True,
2906
+ use_enum_values=True,
2907
+ arbitrary_types_allowed=True,
2908
+ protected_namespaces=("model_config",),
2909
+ )
2910
+ x: float = 0
2911
+ y: float = 0
2912
+
2913
+
2914
+ class NodeDimensions(BaseModel):
2915
+ model_config = ConfigDict(
2916
+ populate_by_name=True,
2917
+ use_enum_values=True,
2918
+ arbitrary_types_allowed=True,
2919
+ protected_namespaces=("model_config",),
2920
+ )
2921
+ width: float = 0
2922
+ height: float = 0
2923
+
2924
+
2925
+ class FlowViewPort(BaseModel):
2926
+ model_config = ConfigDict(
2927
+ populate_by_name=True,
2928
+ use_enum_values=True,
2929
+ arbitrary_types_allowed=True,
2930
+ protected_namespaces=("model_config",),
2931
+ )
2932
+ x: float = 0
2933
+ y: float = 0
2934
+ zoom: float = 1
2935
+
2936
+
2937
+ class DataFlowNode(BaseModel):
2938
+ model_config = ConfigDict(
2939
+ populate_by_name=True,
2940
+ use_enum_values=True,
2941
+ arbitrary_types_allowed=True,
2942
+ protected_namespaces=("model_config",),
2943
+ )
2944
+ id: Optional[str] = None
2945
+ parent_id: Optional[str] = Field(None, alias="parentId")
2946
+ type: Optional[str] = None
2947
+ position: Optional[NodePosition] = None
2948
+ dimensions: Optional[NodeDimensions] = None
2949
+ properties: Dict[str, Any] = Field(default_factory=dict)
2950
+
2951
+
2952
+ class DataFlowEdge(BaseModel):
2953
+ model_config = ConfigDict(
2954
+ populate_by_name=True,
2955
+ use_enum_values=True,
2956
+ arbitrary_types_allowed=True,
2957
+ protected_namespaces=("model_config",),
2958
+ )
2959
+ id: Optional[str] = None
2960
+ source: Optional[str] = None
2961
+ target: Optional[str] = None
2962
+ properties: Dict[str, Any] = Field(default_factory=dict)
2963
+
2964
+
2965
+ class ProjectDataFlow(BaseModel):
2966
+ model_config = ConfigDict(
2967
+ populate_by_name=True,
2968
+ use_enum_values=True,
2969
+ arbitrary_types_allowed=True,
2970
+ protected_namespaces=("model_config",),
2971
+ )
2972
+ view_port: Optional[FlowViewPort] = Field(None, alias="viewPort")
2973
+ nodes: List[DataFlowNode] = Field(default_factory=list)
2974
+ edges: List[DataFlowEdge] = Field(default_factory=list)
2975
+
2903
2976
  class Project(BaseModel):
2904
2977
  model_config = ConfigDict(
2905
2978
  populate_by_name=True,
@@ -306,7 +306,7 @@ class ProjectResourceEndpoint(ClientEndpoint):
306
306
  page += 1
307
307
 
308
308
  def list(
309
- self, query: str = "*", page: int = 1, page_size: int = 10, sort: Optional[str] = None,
309
+ self, query: str = "*", page: int = 1, page_size: int = 10, sort: Optional[str] = None,
310
310
  filters: Optional[List[str]] = None
311
311
  ):
312
312
  """
@@ -502,7 +502,7 @@ class ComponentEndpoint(ClientEndpoint, OrganizationOwned):
502
502
  params["page"] += 1
503
503
 
504
504
  def list(
505
- self, query: str = "*", page: int = 1, page_size: int = 10, sort: Optional[str] = None,
505
+ self, query: str = "*", page: int = 1, page_size: int = 10, sort: Optional[str] = None,
506
506
  filters: Optional[List[str]] = None
507
507
  ):
508
508
  """
@@ -730,7 +730,7 @@ class EntitiesEndpoint:
730
730
  page += 1
731
731
 
732
732
  def list(
733
- self, query: str = "*", page: int = 1, page_size: int = 10, sort: Optional[str] = None,
733
+ self, query: str = "*", page: int = 1, page_size: int = 10, sort: Optional[str] = None,
734
734
  filters: Optional[List[str]] = None
735
735
  ):
736
736
  """List the resources.
@@ -1164,34 +1164,43 @@ class PageTaskEndpoint(PageTask, PageEndpoint):
1164
1164
  """
1165
1165
  Represents a page of tasks.
1166
1166
  """
1167
+
1167
1168
  def get_type(self) -> Optional[str]:
1168
1169
  return "task"
1169
1170
 
1171
+
1170
1172
  class PageTaskActivityEndpoint(PageEndpoint):
1171
1173
  """
1172
1174
  Represents a page of task activities.
1173
1175
  """
1176
+
1174
1177
  def get_type(self) -> Optional[str]:
1175
1178
  return "taskActivities"
1176
1179
 
1180
+
1177
1181
  class PageTaskDocumentFamilyEndpoint(PageEndpoint):
1178
1182
  """
1179
1183
  Represents a page of task document families.
1180
1184
  """
1185
+
1181
1186
  def get_type(self) -> Optional[str]:
1182
1187
  return "taskDocumentFamilies"
1183
1188
 
1189
+
1184
1190
  class PageTaskTagEndpoint(PageEndpoint):
1185
1191
  """
1186
1192
  Represents a page of task tags.
1187
1193
  """
1194
+
1188
1195
  def get_type(self) -> Optional[str]:
1189
1196
  return "taskTags"
1190
1197
 
1198
+
1191
1199
  class TaskEndpoint(EntityEndpoint, Task):
1192
1200
  """
1193
1201
  Represents a task endpoint.
1194
1202
  """
1203
+
1195
1204
  def get_type(self) -> str:
1196
1205
  return "tasks"
1197
1206
 
@@ -1219,10 +1228,12 @@ class TaskEndpoint(EntityEndpoint, Task):
1219
1228
  response = self.client.delete(url)
1220
1229
  return TaskEndpoint.model_validate(response.json()).set_client(self.client)
1221
1230
 
1231
+
1222
1232
  class TasksEndpoint(EntitiesEndpoint):
1223
1233
  """
1224
1234
  Represents tasks endpoints.
1225
1235
  """
1236
+
1226
1237
  def get_type(self) -> str:
1227
1238
  return "tasks"
1228
1239
 
@@ -1232,28 +1243,34 @@ class TasksEndpoint(EntitiesEndpoint):
1232
1243
  def get_page_class(self, object_dict=None):
1233
1244
  return PageTaskEndpoint
1234
1245
 
1235
- def create_with_template(self, task: Task, task_template: Optional[TaskTemplate] = None, document_families: Optional[List[DocumentFamily]] = None) -> TaskEndpoint:
1246
+ def create_with_template(self, task: Task, task_template: Optional[TaskTemplate] = None,
1247
+ document_families: Optional[List[DocumentFamily]] = None) -> TaskEndpoint:
1236
1248
  """Create a task with the given template."""
1237
1249
  url = "/api/tasks/createTaskWithRequest"
1238
1250
  create_body = {
1239
1251
  "task": task.model_dump(mode="json", by_alias=True),
1240
1252
  "taskTemplate": task_template.model_dump(mode="json", by_alias=True) if task_template else None,
1241
- "documentFamilies": [df.model_dump(mode="json", by_alias=True) for df in document_families] if document_families else None
1253
+ "documentFamilies": [df.model_dump(mode="json", by_alias=True) for df in
1254
+ document_families] if document_families else None
1242
1255
  }
1243
1256
  response = self.client.post(url, create_body)
1244
1257
  return TaskEndpoint.model_validate(response.json()).set_client(self.client)
1245
1258
 
1259
+
1246
1260
  class TaskTemplateEndpoint(EntityEndpoint, TaskTemplate):
1247
1261
  """
1248
1262
  Represents a task template endpoint.
1249
1263
  """
1264
+
1250
1265
  def get_type(self) -> str:
1251
1266
  return "taskTemplates"
1252
1267
 
1268
+
1253
1269
  class TaskTemplatesEndpoint(EntitiesEndpoint):
1254
1270
  """
1255
1271
  Represents task templates endpoints.
1256
1272
  """
1273
+
1257
1274
  def get_type(self) -> str:
1258
1275
  return "taskTemplates"
1259
1276
 
@@ -1263,17 +1280,21 @@ class TaskTemplatesEndpoint(EntitiesEndpoint):
1263
1280
  def get_page_class(self, object_dict=None):
1264
1281
  return PageTaskTemplateEndpoint
1265
1282
 
1283
+
1266
1284
  class TaskActivityEndpoint(EntityEndpoint, TaskActivity):
1267
1285
  """
1268
1286
  Represents a task activity endpoint.
1269
1287
  """
1288
+
1270
1289
  def get_type(self) -> str:
1271
1290
  return "taskActivities"
1272
1291
 
1292
+
1273
1293
  class TaskActivitiesEndpoint(EntitiesEndpoint):
1274
1294
  """
1275
1295
  Represents task activities endpoints.
1276
1296
  """
1297
+
1277
1298
  def get_type(self) -> str:
1278
1299
  return "taskActivities"
1279
1300
 
@@ -1283,17 +1304,21 @@ class TaskActivitiesEndpoint(EntitiesEndpoint):
1283
1304
  def get_page_class(self, object_dict=None):
1284
1305
  return PageTaskActivityEndpoint
1285
1306
 
1307
+
1286
1308
  class TaskDocumentFamilyEndpoint(EntityEndpoint, TaskDocumentFamily):
1287
1309
  """
1288
1310
  Represents a task document family endpoint.
1289
1311
  """
1312
+
1290
1313
  def get_type(self) -> str:
1291
1314
  return "taskDocumentFamilies"
1292
1315
 
1316
+
1293
1317
  class TaskDocumentFamiliesEndpoint(EntitiesEndpoint):
1294
1318
  """
1295
1319
  Represents task document families endpoints.
1296
1320
  """
1321
+
1297
1322
  def get_type(self) -> str:
1298
1323
  return "taskDocumentFamilies"
1299
1324
 
@@ -1303,17 +1328,21 @@ class TaskDocumentFamiliesEndpoint(EntitiesEndpoint):
1303
1328
  def get_page_class(self, object_dict=None):
1304
1329
  return PageTaskDocumentFamilyEndpoint
1305
1330
 
1331
+
1306
1332
  class TaskTagEndpoint(EntityEndpoint, TaskTag):
1307
1333
  """
1308
1334
  Represents a task tag endpoint.
1309
1335
  """
1336
+
1310
1337
  def get_type(self) -> str:
1311
1338
  return "taskTags"
1312
1339
 
1340
+
1313
1341
  class TaskTagsEndpoint(EntitiesEndpoint):
1314
1342
  """
1315
1343
  Represents task tags endpoints.
1316
1344
  """
1345
+
1317
1346
  def get_type(self) -> str:
1318
1347
  return "taskTags"
1319
1348
 
@@ -2857,6 +2886,30 @@ class ProjectEndpoint(EntityEndpoint, Project):
2857
2886
  )
2858
2887
  return [ProjectTag.model_validate(tag) for tag in response.json()]
2859
2888
 
2889
+ def get_data_flow(self) -> "ProjectDataFlow":
2890
+ """Get the data flow of the project.
2891
+
2892
+ Returns:
2893
+ ProjectDataFlow: The data flow of the project.
2894
+ """
2895
+ response = self.client.get(f"/api/projects/{self.id}/dataFlow")
2896
+ return ProjectDataFlow.model_validate(response.json()).set_client(self.client)
2897
+
2898
+ def update_data_flow(self, data_flow: "ProjectDataFlow") -> "ProjectDataFlow":
2899
+ """Update the data flow of the project.
2900
+
2901
+ Args:
2902
+ data_flow (ProjectDataFlow): The new data flow to associate with the project.
2903
+
2904
+ Returns:
2905
+ ProjectDataFlow: The updated data flow associated with the project.
2906
+ """
2907
+ response = self.client.put(
2908
+ f"/api/projects/{self.id}/dataFlow",
2909
+ body=data_flow.model_dump(mode="json", by_alias=True),
2910
+ )
2911
+ return ProjectDataFlow.model_validate(response.json()).set_client(self.client)
2912
+
2860
2913
 
2861
2914
  class MessagesEndpoint(EntitiesEndpoint):
2862
2915
  """Represents a message endpoint"""
@@ -3477,6 +3530,7 @@ class ProjectTemplatesEndpoint(ComponentEndpoint, ClientEndpoint, OrganizationOw
3477
3530
  """
3478
3531
  return ProjectTemplateEndpoint
3479
3532
 
3533
+
3480
3534
  class DataFormsEndpoint(ComponentEndpoint, ClientEndpoint, OrganizationOwned):
3481
3535
  """
3482
3536
  A class used to represent the DataFormsEndpoint.
@@ -4637,7 +4691,7 @@ class DocumentFamilyEndpoint(DocumentFamily, ClientEndpoint):
4637
4691
  project_id: Optional[str] = None,
4638
4692
  friendly_names=False,
4639
4693
  include_ids=True,
4640
- include_exceptions=False,
4694
+ include_exceptions=False,
4641
4695
  ) -> str:
4642
4696
  """Get the JSON export for the document family
4643
4697
 
@@ -5106,7 +5160,7 @@ class DataStoreExceptionsEndpoint(EntitiesEndpoint):
5106
5160
  super().__init__(client)
5107
5161
 
5108
5162
  def list(
5109
- self, query: str = "*", page: int = 1, page_size: int = 10, sort: Optional[str] = None,
5163
+ self, query: str = "*", page: int = 1, page_size: int = 10, sort: Optional[str] = None,
5110
5164
  filters: Optional[List[str]] = None
5111
5165
  ):
5112
5166
  """
@@ -1,6 +1,6 @@
1
1
  [tool.poetry]
2
2
  name = "kodexa"
3
- version = "7.4.413640242188"
3
+ version = "7.4.413698503885"
4
4
  description = "Python SDK for the Kodexa Platform"
5
5
  authors = ["Austin Redenbaugh <austin@kodexa.com>", "Philip Dodds <philip@kodexa.com>", "Romar Cablao <rcablao@kodexa.com>", "Amadea Paula Dodds <amadeapaula@kodexa.com>"]
6
6
  readme = "README.md"