orchestrator-core 4.4.0rc1__py3-none-any.whl → 5.0.0a1__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.
Files changed (65) hide show
  1. orchestrator/__init__.py +1 -1
  2. orchestrator/api/api_v1/api.py +7 -0
  3. orchestrator/api/api_v1/endpoints/agent.py +62 -0
  4. orchestrator/api/api_v1/endpoints/processes.py +6 -12
  5. orchestrator/api/api_v1/endpoints/search.py +197 -0
  6. orchestrator/app.py +4 -0
  7. orchestrator/cli/index_llm.py +73 -0
  8. orchestrator/cli/main.py +8 -1
  9. orchestrator/cli/resize_embedding.py +136 -0
  10. orchestrator/cli/scheduler.py +29 -39
  11. orchestrator/cli/search_explore.py +203 -0
  12. orchestrator/db/models.py +37 -1
  13. orchestrator/graphql/schema.py +0 -5
  14. orchestrator/graphql/schemas/process.py +2 -2
  15. orchestrator/graphql/utils/create_resolver_error_handler.py +1 -1
  16. orchestrator/migrations/versions/schema/2025-08-12_52b37b5b2714_search_index_model_for_llm_integration.py +95 -0
  17. orchestrator/schedules/__init__.py +2 -1
  18. orchestrator/schedules/resume_workflows.py +2 -2
  19. orchestrator/schedules/scheduling.py +24 -64
  20. orchestrator/schedules/task_vacuum.py +2 -2
  21. orchestrator/schedules/validate_products.py +2 -8
  22. orchestrator/schedules/validate_subscriptions.py +2 -2
  23. orchestrator/schemas/search.py +101 -0
  24. orchestrator/search/__init__.py +0 -0
  25. orchestrator/search/agent/__init__.py +1 -0
  26. orchestrator/search/agent/prompts.py +62 -0
  27. orchestrator/search/agent/state.py +8 -0
  28. orchestrator/search/agent/tools.py +122 -0
  29. orchestrator/search/core/__init__.py +0 -0
  30. orchestrator/search/core/embedding.py +64 -0
  31. orchestrator/search/core/exceptions.py +16 -0
  32. orchestrator/search/core/types.py +162 -0
  33. orchestrator/search/core/validators.py +27 -0
  34. orchestrator/search/docs/index.md +37 -0
  35. orchestrator/search/docs/running_local_text_embedding_inference.md +45 -0
  36. orchestrator/search/filters/__init__.py +27 -0
  37. orchestrator/search/filters/base.py +236 -0
  38. orchestrator/search/filters/date_filters.py +75 -0
  39. orchestrator/search/filters/definitions.py +76 -0
  40. orchestrator/search/filters/ltree_filters.py +31 -0
  41. orchestrator/search/filters/numeric_filter.py +60 -0
  42. orchestrator/search/indexing/__init__.py +3 -0
  43. orchestrator/search/indexing/indexer.py +316 -0
  44. orchestrator/search/indexing/registry.py +88 -0
  45. orchestrator/search/indexing/tasks.py +53 -0
  46. orchestrator/search/indexing/traverse.py +209 -0
  47. orchestrator/search/retrieval/__init__.py +3 -0
  48. orchestrator/search/retrieval/builder.py +64 -0
  49. orchestrator/search/retrieval/engine.py +96 -0
  50. orchestrator/search/retrieval/ranker.py +202 -0
  51. orchestrator/search/retrieval/utils.py +88 -0
  52. orchestrator/search/retrieval/validation.py +174 -0
  53. orchestrator/search/schemas/__init__.py +0 -0
  54. orchestrator/search/schemas/parameters.py +114 -0
  55. orchestrator/search/schemas/results.py +47 -0
  56. orchestrator/services/processes.py +11 -16
  57. orchestrator/settings.py +29 -1
  58. orchestrator/workflow.py +1 -8
  59. {orchestrator_core-4.4.0rc1.dist-info → orchestrator_core-5.0.0a1.dist-info}/METADATA +6 -3
  60. {orchestrator_core-4.4.0rc1.dist-info → orchestrator_core-5.0.0a1.dist-info}/RECORD +62 -26
  61. orchestrator/graphql/resolvers/scheduled_tasks.py +0 -36
  62. orchestrator/graphql/schemas/scheduled_task.py +0 -8
  63. orchestrator/schedules/scheduler.py +0 -153
  64. {orchestrator_core-4.4.0rc1.dist-info → orchestrator_core-5.0.0a1.dist-info}/WHEEL +0 -0
  65. {orchestrator_core-4.4.0rc1.dist-info → orchestrator_core-5.0.0a1.dist-info}/licenses/LICENSE +0 -0
@@ -0,0 +1,114 @@
1
+ import uuid
2
+ from typing import Any, Literal
3
+
4
+ from pydantic import BaseModel, ConfigDict, Field
5
+
6
+ from orchestrator.search.core.types import ActionType, EntityType
7
+ from orchestrator.search.filters import FilterTree
8
+
9
+
10
+ class BaseSearchParameters(BaseModel):
11
+ """Base model with common search parameters."""
12
+
13
+ action: ActionType = Field(default=ActionType.SELECT, description="The action to perform.")
14
+ entity_type: EntityType
15
+
16
+ filters: FilterTree | None = Field(default=None, description="A list of structured filters to apply to the search.")
17
+
18
+ query: str | None = Field(
19
+ default=None, description="Unified search query - will be processed into vector_query and/or fuzzy_term"
20
+ )
21
+
22
+ model_config = ConfigDict(extra="forbid")
23
+
24
+ @classmethod
25
+ def create(cls, entity_type: EntityType, **kwargs: Any) -> "BaseSearchParameters":
26
+ try:
27
+ return PARAMETER_REGISTRY[entity_type](entity_type=entity_type, **kwargs)
28
+ except KeyError:
29
+ raise ValueError(f"No search parameter class found for entity type: {entity_type.value}")
30
+
31
+ @property
32
+ def vector_query(self) -> str | None:
33
+ """Extract vector query from unified query field."""
34
+ if not self.query:
35
+ return None
36
+ try:
37
+ uuid.UUID(self.query)
38
+ return None # It's a UUID, so disable vector search.
39
+ except ValueError:
40
+ return self.query
41
+
42
+ @property
43
+ def fuzzy_term(self) -> str | None:
44
+ """Extract fuzzy term from unified query field."""
45
+ if not self.query:
46
+ return None
47
+
48
+ words = self.query.split()
49
+ # Only use fuzzy for single words
50
+ return self.query if len(words) == 1 else None
51
+
52
+
53
+ class SubscriptionSearchParameters(BaseSearchParameters):
54
+ entity_type: Literal[EntityType.SUBSCRIPTION] = Field(
55
+ default=EntityType.SUBSCRIPTION, description="The type of entity to search."
56
+ )
57
+ model_config = ConfigDict(
58
+ json_schema_extra={
59
+ "title": "SearchSubscriptions",
60
+ "description": "Search subscriptions based on specific criteria.",
61
+ "examples": [
62
+ {
63
+ "filters": {
64
+ "op": "AND",
65
+ "children": [
66
+ {"path": "subscription.status", "condition": {"op": "eq", "value": "provisioning"}},
67
+ {"path": "subscription.end_date", "condition": {"op": "gte", "value": "2025-01-01"}},
68
+ ],
69
+ }
70
+ }
71
+ ],
72
+ }
73
+ )
74
+
75
+
76
+ class ProductSearchParameters(BaseSearchParameters):
77
+ entity_type: Literal[EntityType.PRODUCT] = Field(
78
+ default=EntityType.PRODUCT, description="The type of entity to search."
79
+ )
80
+ model_config = ConfigDict(
81
+ json_schema_extra={
82
+ "title": "SearchProducts",
83
+ "description": "Search products based on specific criteria.",
84
+ "examples": [
85
+ {
86
+ "filters": [
87
+ {"path": "product.product_type", "condition": {"op": "eq", "value": "Shop"}},
88
+ ]
89
+ }
90
+ ],
91
+ }
92
+ )
93
+
94
+
95
+ class WorkflowSearchParameters(BaseSearchParameters):
96
+ entity_type: Literal[EntityType.WORKFLOW] = Field(
97
+ default=EntityType.WORKFLOW, description="The type of entity to search."
98
+ )
99
+
100
+
101
+ class ProcessSearchParameters(BaseSearchParameters):
102
+ """Search parameters specifically for PROCESS entities."""
103
+
104
+ entity_type: Literal[EntityType.PROCESS] = Field(
105
+ default=EntityType.PROCESS, description="The type of entity to search."
106
+ )
107
+
108
+
109
+ PARAMETER_REGISTRY: dict[EntityType, type[BaseSearchParameters]] = {
110
+ EntityType.SUBSCRIPTION: SubscriptionSearchParameters,
111
+ EntityType.PRODUCT: ProductSearchParameters,
112
+ EntityType.WORKFLOW: WorkflowSearchParameters,
113
+ EntityType.PROCESS: ProcessSearchParameters,
114
+ }
@@ -0,0 +1,47 @@
1
+ from typing import Literal
2
+
3
+ from pydantic import BaseModel, ConfigDict
4
+
5
+ from orchestrator.search.core.types import FilterOp, UIType
6
+
7
+
8
+ class Highlight(BaseModel):
9
+ """Contains the text and the indices of the matched term."""
10
+
11
+ text: str
12
+ indices: list[tuple[int, int]]
13
+
14
+
15
+ class SearchResult(BaseModel):
16
+ """Represents a single search result item."""
17
+
18
+ entity_id: str
19
+ score: float
20
+ highlight: Highlight | None = None
21
+
22
+
23
+ SearchResponse = list[SearchResult]
24
+
25
+
26
+ class ValueSchema(BaseModel):
27
+ kind: UIType | Literal["none", "object"] = UIType.STRING
28
+ fields: dict[str, "ValueSchema"] | None = None
29
+
30
+ model_config = ConfigDict(extra="forbid")
31
+
32
+
33
+ class PathInfo(BaseModel):
34
+ path: str
35
+ type: UIType
36
+
37
+ model_config = ConfigDict(
38
+ extra="forbid",
39
+ use_enum_values=True,
40
+ )
41
+
42
+
43
+ class TypeDefinition(BaseModel):
44
+ operators: list[FilterOp]
45
+ valueSchema: dict[FilterOp, ValueSchema]
46
+
47
+ model_config = ConfigDict(use_enum_values=True)
@@ -733,17 +733,11 @@ def abort_process(process: ProcessTable, user: str, broadcast_func: Callable | N
733
733
 
734
734
 
735
735
  def _recoverwf(wf: Workflow, log: list[WFProcess]) -> tuple[WFProcess, StepList]:
736
- """Recover workflow state and remaining steps from the given 'Process step' objects.
736
+ # Remove all extra steps (Failed, Suspended and (A)waiting steps in db). Only keep cleared steps.
737
737
 
738
- Returns:
739
- - The state accumulated up until the last cleared (completed) step\
740
- - The remaining steps to execute (including Failed, Suspended and (A)waiting steps)
741
- """
742
-
743
- def is_cleared(p: WFProcess) -> bool:
744
- return not (p.isfailed() or p.issuspend() or p.iswaiting() or p.isawaitingcallback())
745
-
746
- persistent = [p for p in log if is_cleared(p)]
738
+ persistent = list(
739
+ filter(lambda p: not (p.isfailed() or p.issuspend() or p.iswaiting() or p.isawaitingcallback()), log)
740
+ )
747
741
  stepcount = len(persistent)
748
742
 
749
743
  if log and (log[-1].issuspend() or log[-1].isawaitingcallback()):
@@ -766,14 +760,15 @@ def _recoverwf(wf: Workflow, log: list[WFProcess]) -> tuple[WFProcess, StepList]
766
760
 
767
761
 
768
762
  def _restore_log(steps: list[ProcessStepTable]) -> list[WFProcess]:
769
- """Deserialize ProcessStepTable objects into foldable 'Process step' objects."""
763
+ result = []
764
+ for step in steps:
765
+ process = WFProcess.from_status(step.status, step.state)
770
766
 
771
- def deserialize(step: ProcessStepTable) -> WFProcess:
772
- if not (wf_process := WFProcess.from_status(step.status, step.state)):
773
- raise ValueError(f"Unable to deserialize step from it's status {step.status}")
774
- return wf_process
767
+ if not process:
768
+ raise ValueError(step.status)
775
769
 
776
- return [deserialize(step) for step in steps]
770
+ result.append(process)
771
+ return result
777
772
 
778
773
 
779
774
  def load_process(process: ProcessTable) -> ProcessStat:
orchestrator/settings.py CHANGED
@@ -16,7 +16,7 @@ import string
16
16
  from pathlib import Path
17
17
  from typing import Literal
18
18
 
19
- from pydantic import Field, NonNegativeInt, PostgresDsn, RedisDsn
19
+ from pydantic import Field, NonNegativeInt, PostgresDsn, RedisDsn, field_validator
20
20
  from pydantic_settings import BaseSettings
21
21
 
22
22
  from oauth2_lib.settings import oauth2lib_settings
@@ -92,6 +92,34 @@ class AppSettings(BaseSettings):
92
92
  EXPOSE_SETTINGS: bool = False
93
93
  EXPOSE_OAUTH_SETTINGS: bool = False
94
94
 
95
+ # Pydantic-ai Agent settings
96
+ AGENT_MODEL: str = "openai:gpt-4o-mini" # See pydantic-ai docs for supported models.
97
+ OPENAI_API_KEY: str = "OPENAI_API_KEY" # Change per provider (Azure, etc).
98
+
99
+ # Embedding settings
100
+ EMBEDDING_DIMENSION: int = 1536
101
+ EMBEDDING_MODEL: str = "openai/text-embedding-3-small" # See litellm docs for supported models.
102
+ EMBEDDING_SAFE_MARGIN_PERCENT: float = Field(
103
+ 0.1, description="Safety margin as a percentage (e.g., 0.1 for 10%) for token budgeting.", ge=0, le=1
104
+ )
105
+
106
+ # The following settings are only needed for local models.
107
+ # By default, they are set conservative assuming a small model like All-MiniLM-L6-V2.
108
+ OPENAI_BASE_URL: str | None = None
109
+ EMBEDDING_FALLBACK_MAX_TOKENS: int | None = 512
110
+ EMBEDDING_MAX_BATCH_SIZE: int | None = 32
111
+
112
+ # General LiteLLM settings
113
+ LLM_MAX_RETRIES: int = 3
114
+ LLM_TIMEOUT: int = 30
115
+
116
+ @field_validator("EMBEDDING_MODEL")
117
+ def validate_embedding_model_format(cls, v: str) -> str:
118
+ """Validate that embedding model is in 'vendor/model' format."""
119
+ if "/" not in v:
120
+ raise ValueError("EMBEDDING_MODEL must be in format 'vendor/model'")
121
+ return v
122
+
95
123
 
96
124
  app_settings = AppSettings()
97
125
 
orchestrator/workflow.py CHANGED
@@ -552,7 +552,7 @@ class ProcessStat:
552
552
  process_id: UUID
553
553
  workflow: Workflow
554
554
  state: Process
555
- log: StepList # Remaining steps to execute
555
+ log: StepList
556
556
  current_user: str
557
557
  user_model: OIDCUserModel | None = None
558
558
 
@@ -597,13 +597,6 @@ class StepStatus(strEnum):
597
597
 
598
598
 
599
599
  class Process(Generic[S]):
600
- """ADT base class.
601
-
602
- This class defines an Algebraic Data Type - specifically a "sum type" - that defines the possible
603
- variants of a Process. It encapsulates the state and allows to fold _instances_ of a process into
604
- a single value. These instances correspond to subsequent steps of the process.
605
- """
606
-
607
600
  def __init__(self, s: S):
608
601
  self.s = s
609
602
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: orchestrator-core
3
- Version: 4.4.0rc1
3
+ Version: 5.0.0a1
4
4
  Summary: This is the orchestrator workflow engine.
5
5
  Author-email: SURF <automation-beheer@surf.nl>
6
6
  Requires-Python: >=3.11,<3.14
@@ -32,7 +32,6 @@ Classifier: Typing :: Typed
32
32
  License-File: LICENSE
33
33
  Requires-Dist: alembic==1.16.1
34
34
  Requires-Dist: anyio>=3.7.0
35
- Requires-Dist: apscheduler>=3.11.0
36
35
  Requires-Dist: click==8.*
37
36
  Requires-Dist: deepmerge==2.0
38
37
  Requires-Dist: deprecated>=1.2.18
@@ -40,10 +39,13 @@ Requires-Dist: fastapi~=0.115.2
40
39
  Requires-Dist: fastapi-etag==0.4.0
41
40
  Requires-Dist: itsdangerous>=2.2.0
42
41
  Requires-Dist: jinja2==3.1.6
42
+ Requires-Dist: litellm>=1.75.7
43
43
  Requires-Dist: more-itertools~=10.7.0
44
44
  Requires-Dist: nwa-stdlib~=1.9.0
45
- Requires-Dist: oauth2-lib~=2.4.0
45
+ Requires-Dist: oauth2-lib>=2.4.1
46
+ Requires-Dist: openai>=1.99.9
46
47
  Requires-Dist: orjson==3.10.18
48
+ Requires-Dist: pgvector>=0.4.1
47
49
  Requires-Dist: prometheus-client==0.22.1
48
50
  Requires-Dist: psycopg2-binary==2.9.10
49
51
  Requires-Dist: pydantic-forms>=1.4.0,<=2.1.0
@@ -53,6 +55,7 @@ Requires-Dist: python-dateutil==2.8.2
53
55
  Requires-Dist: python-rapidjson>=1.18,<1.21
54
56
  Requires-Dist: pytz==2025.2
55
57
  Requires-Dist: redis==5.1.1
58
+ Requires-Dist: schedule==1.1.0
56
59
  Requires-Dist: semver==3.0.4
57
60
  Requires-Dist: sentry-sdk[fastapi]~=2.29.1
58
61
  Requires-Dist: sqlalchemy==2.0.41
@@ -1,26 +1,28 @@
1
- orchestrator/__init__.py,sha256=2VCmBMCQvlduTSR0AOWiSAcfGIGfm7kGJxYEKzqiXew,1066
2
- orchestrator/app.py,sha256=7UrXKjBKNSEaSSXAd5ww_RdMFhFqE4yvfj8faS2MzAA,12089
1
+ orchestrator/__init__.py,sha256=KbwuYV9k3chNd6QgFkndWPoVs4f7C22-or0hnZdIPcs,1065
2
+ orchestrator/app.py,sha256=X2vAwsOe6_7_vyHfcGMUSZSYl3JVgevbOPUS6uPJCys,12236
3
3
  orchestrator/exception_handlers.py,sha256=UsW3dw8q0QQlNLcV359bIotah8DYjMsj2Ts1LfX4ClY,1268
4
4
  orchestrator/log_config.py,sha256=1tPRX5q65e57a6a_zEii_PFK8SzWT0mnA5w2sKg4hh8,1853
5
5
  orchestrator/py.typed,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
6
6
  orchestrator/security.py,sha256=iXFxGxab54aav7oHEKLAVkTgrQMJGHy6IYLojEnD7gI,2422
7
- orchestrator/settings.py,sha256=2Kgc6m3qUCcSM3Z_IVUeehfgO0QphMFkLrS0RC3sU-U,4365
7
+ orchestrator/settings.py,sha256=BM0U2D36T9pqZpJpgnqd5Bs6L6P4pQf-4oLYN_nx14I,5591
8
8
  orchestrator/targets.py,sha256=WizBgnp8hWX9YLFUIju7ewSubiwQqinCvyiYNcXHbHI,802
9
9
  orchestrator/types.py,sha256=qzs7xx5AYRmKbpYRyJJP3wuDb0W0bcAzefCN0RWLAco,15459
10
10
  orchestrator/version.py,sha256=b58e08lxs47wUNXv0jXFO_ykpksmytuzEXD4La4W-NQ,1366
11
- orchestrator/workflow.py,sha256=meDCPnyyX_n5PsMUaFy2wWb5EKNm1_ff7zRDBYrbcDg,45901
11
+ orchestrator/workflow.py,sha256=PVHe6vnnkswzqw2UoY-j6NMSEhL6rLHXRnO7yLOyDC8,45551
12
12
  orchestrator/api/__init__.py,sha256=GyHNfEFCGKQwRiN6rQmvSRH2iYX7npjMZn97n8XzmLU,571
13
13
  orchestrator/api/error_handling.py,sha256=YrPCxSa-DSa9KwqIMlXI-KGBGnbGIW5ukOPiikUH9E4,1502
14
14
  orchestrator/api/helpers.py,sha256=s0QRHYw8AvEmlkmRhuEzz9xixaZKUF3YuPzUVHkcoXk,6933
15
15
  orchestrator/api/models.py,sha256=z9BDBx7uI4KBHWbD_LVrLsqNQ0_w-Mg9Qiy7PR_rZhk,5996
16
16
  orchestrator/api/api_v1/__init__.py,sha256=GyHNfEFCGKQwRiN6rQmvSRH2iYX7npjMZn97n8XzmLU,571
17
- orchestrator/api/api_v1/api.py,sha256=m4iDktsSpzxUDaudkdgXeZ83a6B4wfc3pczQsa-Pb-8,2866
17
+ orchestrator/api/api_v1/api.py,sha256=o6Jhnn92ME8Mw-n_AMZtlB_B6R5k_gZe_jj0yTFUeKg,2978
18
18
  orchestrator/api/api_v1/endpoints/__init__.py,sha256=GyHNfEFCGKQwRiN6rQmvSRH2iYX7npjMZn97n8XzmLU,571
19
+ orchestrator/api/api_v1/endpoints/agent.py,sha256=KSBlkd-g4C9bRIfZcmIYQMm9ND-FniUykWBpKifg5l0,2487
19
20
  orchestrator/api/api_v1/endpoints/health.py,sha256=iaxs1XX1_250_gKNsspuULCV2GEMBjbtjsmfQTOvMAI,1284
20
- orchestrator/api/api_v1/endpoints/processes.py,sha256=238Bydgj4ILNyMU_7j_Q7a0WGlfIvKv5ypP7lESU32w,16188
21
+ orchestrator/api/api_v1/endpoints/processes.py,sha256=kWz_jL8_sTNwl44tU17VwkwZGjBIw1IIW5pYCCSHwgs,15891
21
22
  orchestrator/api/api_v1/endpoints/product_blocks.py,sha256=kZ6ywIOsS_S2qGq7RvZ4KzjvaS1LmwbGWR37AKRvWOw,2146
22
23
  orchestrator/api/api_v1/endpoints/products.py,sha256=BfFtwu9dZXEQbtKxYj9icc73GKGvAGMR5ytyf41nQlQ,3081
23
24
  orchestrator/api/api_v1/endpoints/resource_types.py,sha256=gGyuaDyOD0TAVoeFGaGmjDGnQ8eQQArOxKrrk4MaDzA,2145
25
+ orchestrator/api/api_v1/endpoints/search.py,sha256=QOx9JReVL_cWUGhU94Zab8Y3mIqJnb_4qbpBOXUiO4k,7035
24
26
  orchestrator/api/api_v1/endpoints/settings.py,sha256=5s-k169podZjgGHUbVDmSQwpY_3Cs_Bbf2PPtZIkBcw,6184
25
27
  orchestrator/api/api_v1/endpoints/subscription_customer_descriptions.py,sha256=1_6LtgQleoq3M6z_W-Qz__Bj3OFUweoPrUqHMwSH6AM,3288
26
28
  orchestrator/api/api_v1/endpoints/subscriptions.py,sha256=zn_LeVfmp2uw7CszK4BvQ5n37hZccy3K2htkoDgF1sI,9809
@@ -31,12 +33,15 @@ orchestrator/api/api_v1/endpoints/ws.py,sha256=1l7E0ag_sZ6UMfQPHlmew7ENwxjm6fflB
31
33
  orchestrator/cli/__init__.py,sha256=GyHNfEFCGKQwRiN6rQmvSRH2iYX7npjMZn97n8XzmLU,571
32
34
  orchestrator/cli/database.py,sha256=YkYAbCY2VPAa6mDW0PpNKG5wL4FuAQYD2CGl1_DQtEk,19595
33
35
  orchestrator/cli/generate.py,sha256=SBaYfRijXPF9r3VxarPKTiDzDcB6GBMMQvecQIb_ZLQ,7377
34
- orchestrator/cli/main.py,sha256=GC_kxa9OZ-Y0ig_klfWc6ysOQuPVTUmTmDRj3m8cJHA,983
36
+ orchestrator/cli/index_llm.py,sha256=RWPkFz5bxiznjpN1vMsSWeqcvYKB90DLL4pXQ92QJNI,2239
37
+ orchestrator/cli/main.py,sha256=IwnUQD4bOBHHNp9v78DPPn50I7dCoxL7kwp2zJAMssk,1347
35
38
  orchestrator/cli/migrate_domain_models.py,sha256=WRXy_1OnziQwpsCFZXvjB30nDJtjj0ikVXy8YNLque4,20928
36
39
  orchestrator/cli/migrate_tasks.py,sha256=bju8XColjSZD0v3rS4kl-24dLr8En_H4-6enBmqd494,7255
37
40
  orchestrator/cli/migrate_workflows.py,sha256=nxUpx0vgEIc_8aJrjAyrw3E9Dt8JmaamTts8oiQ4vHY,8923
38
41
  orchestrator/cli/migration_helpers.py,sha256=C5tpkP5WEBr7G9S-1k1hgSI8ili6xd9Z5ygc9notaK0,4110
39
- orchestrator/cli/scheduler.py,sha256=jdBbgqE7bNUOevFe6gZS5C-SyDTOow8baNJKEBTkS0A,2293
42
+ orchestrator/cli/resize_embedding.py,sha256=dOcd6UUe0ObplrClqdPJqlLSTlKevePRzMpx1CR0MT4,4213
43
+ orchestrator/cli/scheduler.py,sha256=iCKBWYUwQIYTDqKQ9rMVvs2sNiAzE-J2SkV170TPP2g,1896
44
+ orchestrator/cli/search_explore.py,sha256=fo_uVKWsM74K81pZnb-D8b8CUylxix_RsZPsVS1krWs,8096
40
45
  orchestrator/cli/domain_gen_helpers/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
41
46
  orchestrator/cli/domain_gen_helpers/fixed_input_helpers.py,sha256=uzpwsaau81hHSxNMOS9-o7kF-9_78R0f_UE0AvWooZQ,6775
42
47
  orchestrator/cli/domain_gen_helpers/helpers.py,sha256=tIPxn8ezED_xYZxH7ZAtQLwkDc6RNmLZVxWAoJ3a9lw,4203
@@ -106,7 +111,7 @@ orchestrator/db/database.py,sha256=MU_w_e95ho2dVb2JDnt_KFYholx___XDkiQXbc8wCkI,1
106
111
  orchestrator/db/helpers.py,sha256=L8kEdnSSNGnUpZhdeGx2arCodakWN8vSpKdfjoLuHdY,831
107
112
  orchestrator/db/listeners.py,sha256=UBPYcH0FE3a7aZQu_D0O_JMXpXIRYXC0gjSAvlv5GZo,1142
108
113
  orchestrator/db/loaders.py,sha256=ez6JzQ3IKVkC_oLAkVlIIiI8Do7hXbdcPKCvUSLxRog,7962
109
- orchestrator/db/models.py,sha256=9XOppPkXlbILM3M87wgaItsE8BKLNdnyyfeiSfYuYQ8,27502
114
+ orchestrator/db/models.py,sha256=ZkmLL_6QJQCEctnGIvzHYa1p5gfMlfYuyVabWcKbaGg,28526
110
115
  orchestrator/db/filters/__init__.py,sha256=RUj6P0XxEBhYj0SN5wH5-Vf_Wt_ilZR_n9DSar5m9oM,371
111
116
  orchestrator/db/filters/filters.py,sha256=55RtpQwM2rhrk4A6CCSeSXoo-BT9GnQoNTryA8CtLEg,5020
112
117
  orchestrator/db/filters/process.py,sha256=xvGhyfo_MZ1xhLvFC6yULjcT4mJk0fKc1glJIYgsWLE,4018
@@ -158,7 +163,7 @@ orchestrator/forms/validators/product_id.py,sha256=u5mURLT0pOhbFLdwvYcy2_2fXMt35
158
163
  orchestrator/graphql/__init__.py,sha256=avq8Yg3Jr_9pJqh7ClyIAOX7YSg1eM_AWmt5C3FRYUY,1440
159
164
  orchestrator/graphql/autoregistration.py,sha256=pF2jbMKG26MvYoMSa6ZpqpHjVks7_NvSRFymHTgmfjs,6342
160
165
  orchestrator/graphql/pagination.py,sha256=iqVDn3GPZpiQhEydfwkBJLURY-X8wwUphS8Lkeg0BOc,2413
161
- orchestrator/graphql/schema.py,sha256=dw4m4sM1ek2DscB8vINN6L8vVDE0h5GXclHGa8CiUJo,9537
166
+ orchestrator/graphql/schema.py,sha256=gwZ3nAgKL0zlpc-aK58hSUAGPVD11Tb3aRSSK9hC39I,9204
162
167
  orchestrator/graphql/types.py,sha256=_kHKMusrRPuRtF4wm42NsBzoFZ4egbu3ibMmhd2D6Fs,5432
163
168
  orchestrator/graphql/extensions/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
164
169
  orchestrator/graphql/extensions/model_cache.py,sha256=1uhMRjBs9eK7zJ1Y6P6BopX06822w2Yh9jliwYvG6yQ,1085
@@ -174,7 +179,6 @@ orchestrator/graphql/resolvers/process.py,sha256=Hqs1F7-gw0yO_ioHjh2eLAyxrK2WSuL
174
179
  orchestrator/graphql/resolvers/product.py,sha256=uPBmYwMdau-zUqNjoDl-LDn927u3aCFW5JQ4A_it8q0,2772
175
180
  orchestrator/graphql/resolvers/product_block.py,sha256=Ker1CpxGab5h2BZujOHHwRUj8W4uphRr3WSpQGk2PnI,2939
176
181
  orchestrator/graphql/resolvers/resource_type.py,sha256=SREZXjkLYpuo4nCM8DqVeImIrZcP3xDiWr_gq4wWaxQ,2956
177
- orchestrator/graphql/resolvers/scheduled_tasks.py,sha256=QsnesRrj8ESuS9vPKG9DXYcG2Wfj9m5LWGeZgmc6hu8,1640
178
182
  orchestrator/graphql/resolvers/settings.py,sha256=xVYqxo-EWQ24F4hUHm9OZeN9vsqQXJzIJ1_HF4Ci9Cs,3777
179
183
  orchestrator/graphql/resolvers/subscription.py,sha256=57niFv-JCro_wm0peJ5Ne04F2WIPuJ-Lx2h8yd9qubA,6541
180
184
  orchestrator/graphql/resolvers/version.py,sha256=qgwe1msPOexeg3RHCscJ8s45vNfMhYh9ZKyCZ3MNw30,809
@@ -185,18 +189,17 @@ orchestrator/graphql/schemas/customer_description.py,sha256=fize71IMpkvk_rTzcqCY
185
189
  orchestrator/graphql/schemas/errors.py,sha256=VRl-Zd1FHMnscyozhfxzqeEUZ0ERAWum_Y8YwjGxwmA,203
186
190
  orchestrator/graphql/schemas/fixed_input.py,sha256=1yqYHADQRgHz8OIP7ObYsPFS-gmzfkCvEO0a-KKf7zI,513
187
191
  orchestrator/graphql/schemas/helpers.py,sha256=Kpj4kIbmoKKN35bdgUSwQvGUIbeg7VJAVMEq65YS_ik,346
188
- orchestrator/graphql/schemas/process.py,sha256=g3noYh_USfnaK59fnoX2DI5tAf1PhdLMJGI_lA2xX1M,4966
192
+ orchestrator/graphql/schemas/process.py,sha256=nvD6Rvr0hnrMINdXF_rQuLF8szKJ7E-SywCFMuZsnlg,4940
189
193
  orchestrator/graphql/schemas/product.py,sha256=vUCqcjrKBJj-VKSrMYPKzjmmxLMXL7alKTJ8UdUkhTg,4342
190
194
  orchestrator/graphql/schemas/product_block.py,sha256=Qk9cbA6vm7ZPrhdgPHatKRuy6TytBmxSr97McEOxAu8,2860
191
195
  orchestrator/graphql/schemas/resource_type.py,sha256=s5d_FwQXL2-Sc-IDUxTJun5qFQ4zOP4-XcHF9ql-t1g,898
192
- orchestrator/graphql/schemas/scheduled_task.py,sha256=22Kb7r2pUoefz9AeiTYQ1t6YBYCmAs_zVp7FqNdN5HQ,194
193
196
  orchestrator/graphql/schemas/settings.py,sha256=drhm5VcLmUbiYAk6WUSJcyJqjNM96E6GvpxVdPAobnA,999
194
197
  orchestrator/graphql/schemas/strawberry_pydantic_patch.py,sha256=CjNUhTKdYmLiaem-WY_mzw4HASIeaZitxGF8pPocqVw,1602
195
198
  orchestrator/graphql/schemas/subscription.py,sha256=hTA34C27kgLguH9V53173CxMKIWiQKh3vFzyJ2yBfE0,9918
196
199
  orchestrator/graphql/schemas/version.py,sha256=HSzVg_y4Sjd5_H5rRUtu3FJKOG_8ifhvBNt_qjOtC-E,92
197
200
  orchestrator/graphql/schemas/workflow.py,sha256=WLbegRNxOfvXg4kPYrO5KPBwtHmUofAr2pvZT2JsW1c,1761
198
201
  orchestrator/graphql/utils/__init__.py,sha256=1JvenzEVW1CBa1sGVI9I8IWnnoXIkb1hneDqph9EEZY,524
199
- orchestrator/graphql/utils/create_resolver_error_handler.py,sha256=XzCnL482M4wz3fg5fUdGUwCAuzSZQ9Ufu1mscLyeoWU,1227
202
+ orchestrator/graphql/utils/create_resolver_error_handler.py,sha256=PpQMVwGrE9t0nZ12TwoxPxksXxEwQM7lSNPeh7qW3vk,1233
200
203
  orchestrator/graphql/utils/get_query_loaders.py,sha256=abS_HJ7K9een78gMiGq3IhwGwxQXHvZygExe0h_t9ns,815
201
204
  orchestrator/graphql/utils/get_selected_fields.py,sha256=0hBcQkU-7TNVO_KG-MmLItKm0O3gmbqoxXNkLHO-wHo,1002
202
205
  orchestrator/graphql/utils/get_selected_paths.py,sha256=H0btESeOr3_VB7zy5Cx25OS0uzBcg2Y1I-arAmSOnsQ,1382
@@ -247,13 +250,13 @@ orchestrator/migrations/versions/schema/2025-05-08_161918133bec_add_is_task_to_w
247
250
  orchestrator/migrations/versions/schema/2025-07-01_93fc5834c7e5_changed_timestamping_fields_in_process_steps.py,sha256=Oezd8b2qaI1Kyq-sZFVFmdzd4d9NjXrf6HtJGk11fy0,1914
248
251
  orchestrator/migrations/versions/schema/2025-07-04_4b58e336d1bf_deprecating_workflow_target_in_.py,sha256=xnD6w-97R4ClS7rbmXQEXc36K3fdcXKhCy7ZZNy_FX4,742
249
252
  orchestrator/migrations/versions/schema/2025-07-28_850dccac3b02_update_description_of_resume_workflows_.py,sha256=R6Qoga83DJ1IL0WYPu0u5u2ZvAmqGlDmUMv_KtJyOhQ,812
250
- orchestrator/schedules/__init__.py,sha256=Zy0fTOBMGIRFoh5iVFDLF9_PRAFaONYDThGK9EsysWo,981
251
- orchestrator/schedules/resume_workflows.py,sha256=jRnVRWDy687pQu-gtk80ecwiLSdrvtL15tG3U2zWA6I,891
252
- orchestrator/schedules/scheduler.py,sha256=vze3xaZhUL5maKQB6a1gCvc9AcGw3jX-BHT3d5xvy6A,5430
253
- orchestrator/schedules/scheduling.py,sha256=_mbpHMhijey8Y56ebtJ4wVkrp_kPVRm8hoByzlQF4SE,2821
254
- orchestrator/schedules/task_vacuum.py,sha256=mxb7fsy1GphRwvUWi_lvwNaj51YAXUdIDlkOJd90AFI,874
255
- orchestrator/schedules/validate_products.py,sha256=zWFQeVn3F8LP3joExLiKdmHs008pZsO-RolcIXHjFyE,1322
256
- orchestrator/schedules/validate_subscriptions.py,sha256=bUBV45aEuqVdtqYBAXh1lX4O5vuNTeTfds4J_zq35dI,2113
253
+ orchestrator/migrations/versions/schema/2025-08-12_52b37b5b2714_search_index_model_for_llm_integration.py,sha256=6lRbUd1hJBjG8KM4Ow_J4pk2qwlRVhTKczS7XmoW-q4,3304
254
+ orchestrator/schedules/__init__.py,sha256=JnnaglfK1qYUBKI6Dd9taV-tCZIPlAdAkHtnkJDMXxY,1066
255
+ orchestrator/schedules/resume_workflows.py,sha256=kSotzTAXjX7p9fpSYiGOpuxuTQfv54eRFAe0YSG0DHc,832
256
+ orchestrator/schedules/scheduling.py,sha256=ehtwgpbvMOk1jhn-hHgVzg_9wLJkI6l3mRY3DcO9ZVY,1526
257
+ orchestrator/schedules/task_vacuum.py,sha256=eovnuKimU8SFRw1IF62MsAVFSdgeeV1u57kapUbz8As,821
258
+ orchestrator/schedules/validate_products.py,sha256=YMr7ASSqdXM6pd6oZu0kr8mfmH8If16MzprrsHdN_ZU,1234
259
+ orchestrator/schedules/validate_subscriptions.py,sha256=9SYvsn4BJ5yo_1nu555hWjl5XffTx7QMaRhH5oOjM9E,2042
257
260
  orchestrator/schemas/__init__.py,sha256=YDyZ0YBvzB4ML9oDBCBPGnBvf680zFFgUzg7X0tYBRY,2326
258
261
  orchestrator/schemas/base.py,sha256=Vc444LetsINLRhG2SxW9Bq01hOzChPOhQWCImQTr-As,930
259
262
  orchestrator/schemas/engine_settings.py,sha256=LF8al7tJssiilb5A4emPtUYo0tVDSaT1Lvo_DN_ttrY,1296
@@ -263,14 +266,47 @@ orchestrator/schemas/process.py,sha256=UACBNt-4g4v9Y528u-gZ-Wk7YxwJHhnI4cEu5CtQm
263
266
  orchestrator/schemas/product.py,sha256=MhMCh058ZuS2RJq-wSmxIPUNlhQexxXIx3DSz2OmOh4,1570
264
267
  orchestrator/schemas/product_block.py,sha256=kCqvm6qadHpegMr9aWI_fYX-T7mS-5S-ldPxnGQZg7M,1519
265
268
  orchestrator/schemas/resource_type.py,sha256=VDju4XywcDDLxdpbWU62RTvR9QF8x_GRrpTlN_NE8uI,1064
269
+ orchestrator/schemas/search.py,sha256=wIPEyBo1SQlg0s1Qu-hSsjt1bgryOxdVW4nlVtX8Lp8,3249
266
270
  orchestrator/schemas/subscription.py,sha256=-jXyHZIed9Xlia18ksSDyenblNN6Q2yM2FlGELyJ458,3423
267
271
  orchestrator/schemas/subscription_descriptions.py,sha256=Ft_jw1U0bf9Z0U8O4OWfLlcl0mXCVT_qYVagBP3GbIQ,1262
268
272
  orchestrator/schemas/workflow.py,sha256=VqQ9XfV4fVd6MjY0LRRQzWBJHmlPsAamWfTwDx1cZkg,2102
273
+ orchestrator/search/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
274
+ orchestrator/search/agent/__init__.py,sha256=oUXG24eWRXisBZTodxf-FmNTjAphNIC6JbVlpkPzsEU,66
275
+ orchestrator/search/agent/prompts.py,sha256=LiiPExn4pFaj0jpsYmuSPmrGF3Iui41ShMqHPKX5T0c,2069
276
+ orchestrator/search/agent/state.py,sha256=DPCbvp6_WCxXwuJq1IU9glfKNZ1mRODoFcLjb9AOke0,203
277
+ orchestrator/search/agent/tools.py,sha256=HnLwqKDxH-t173UwMTWAfVJNfs4n-JYiY0XAbBDklbE,4733
278
+ orchestrator/search/core/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
279
+ orchestrator/search/core/embedding.py,sha256=YZqbOiPxaYg0qSEQ9avc1RQ0A19JTlTRDnyLuobnpAM,2308
280
+ orchestrator/search/core/exceptions.py,sha256=wBAWEIkpU8tjmqIO7d8H9s1QFwMBcA9ikHaeJ-GfBfw,344
281
+ orchestrator/search/core/types.py,sha256=MyxeJSnhpMaRQwytb54ouOAgizFznHqwirLSnbw72Tc,4379
282
+ orchestrator/search/core/validators.py,sha256=Ny80tH3SHuM64yZCi-9kfX-66NKGjsp_0oG7uJ21JVk,624
283
+ orchestrator/search/docs/index.md,sha256=zKzE2fbtHDfYTKaHg628wAsqCTOJ5yFUWV0ucFH3pAg,863
284
+ orchestrator/search/docs/running_local_text_embedding_inference.md,sha256=KlFxyAjHfLyCeV9fXAFVUqZOFWYwGPH-_oBjWx2Vgng,1255
285
+ orchestrator/search/filters/__init__.py,sha256=h9wjnKLcIfG1TwiuwtnlDvv9XMWLxkjCBD9D8qCOoQU,642
286
+ orchestrator/search/filters/base.py,sha256=h2EUck53pI6M0yZmkgdpY9_5Dpzfv-CogeiFHWCu45E,8887
287
+ orchestrator/search/filters/date_filters.py,sha256=dDbTPI-badVnaKM404waQ3yzTOHJNn59kYoqHvW3XFE,2460
288
+ orchestrator/search/filters/definitions.py,sha256=GmKXOLerYuOqLeShfyZAGp2qdQQcIVO3hoL7pBTJL8A,2764
289
+ orchestrator/search/filters/ltree_filters.py,sha256=BPA-vn3SYRiwL2MVldST0ey6qpvcDbfXXrdNjV26eL4,1292
290
+ orchestrator/search/filters/numeric_filter.py,sha256=GPBcZgrip2ruxsBx2AHZqxS16zkQG3C6zLJAGC2s2VU,2194
291
+ orchestrator/search/indexing/__init__.py,sha256=7IVylH0S5FPUh6jb9H9vNLb61gQQIk_sNrSHc8WoSD0,82
292
+ orchestrator/search/indexing/indexer.py,sha256=Wnwp-lB4ut3L7zZIez2dII7QyhdT23ooyQ4vuu6DSTs,13710
293
+ orchestrator/search/indexing/registry.py,sha256=cSeZe6aq3XME-RRz4AMD8BHXzx7dvU6tBa05ecjTzfk,2468
294
+ orchestrator/search/indexing/tasks.py,sha256=AQJDCb3kH5k1glIFvTquSrUinPwyG3ekTmlNQqPARc8,1783
295
+ orchestrator/search/indexing/traverse.py,sha256=7nc7N1TPfhFAw9sHNb5XulOo5YHZzk9g3uVdwojNGMw,8094
296
+ orchestrator/search/retrieval/__init__.py,sha256=EixZVzUzP3FOC-hWwf3pqvz0XHZe1HyHBsmJlTEU0Cw,65
297
+ orchestrator/search/retrieval/builder.py,sha256=HdR89BCoh8m02dh-B1CZ64ZaG_zpleoOLy1Yd1ALaBE,2394
298
+ orchestrator/search/retrieval/engine.py,sha256=Ws5hNWfLVOwnDNTOgZxywxHSPJV4gzPLI70-Cttgt-4,3409
299
+ orchestrator/search/retrieval/ranker.py,sha256=EPpy5znq-YcO2vz7QPgp__DkB0s1hioqVWR6h2srMnA,7170
300
+ orchestrator/search/retrieval/utils.py,sha256=KzUwpUe8axcJanyGsz7tRs2RAeu6avJAsHRIaoE6aSg,3042
301
+ orchestrator/search/retrieval/validation.py,sha256=KvPjvnl67mq2iMbjBc3YLMZ_XMiK3AygRDxrWKAPP_Y,5829
302
+ orchestrator/search/schemas/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
303
+ orchestrator/search/schemas/parameters.py,sha256=aV1BM9JXpYbZKrPIlIcOqhyM-gHfF-lDffSZwM3dtUg,3943
304
+ orchestrator/search/schemas/results.py,sha256=Mr0_02-B9QK_JaUe6s5QG94S6A587MMLiQno5f_Lr6g,980
269
305
  orchestrator/services/__init__.py,sha256=GyHNfEFCGKQwRiN6rQmvSRH2iYX7npjMZn97n8XzmLU,571
270
306
  orchestrator/services/fixed_inputs.py,sha256=kyz7s2HLzyDulvcq-ZqefTw1om86COvyvTjz0_5CmgI,876
271
307
  orchestrator/services/input_state.py,sha256=6BZOpb3cHpO18K-XG-3QUIV9pIM25_ufdODrp5CmXG4,2390
272
308
  orchestrator/services/process_broadcast_thread.py,sha256=D44YbjF8mRqGuznkRUV4SoRn1J0lfy_x1H508GnSVlU,4649
273
- orchestrator/services/processes.py,sha256=NfzdtH4eZK_wYuSmFtUX69qDvoeI8J7sJ2fFyY_VYaM,30544
309
+ orchestrator/services/processes.py,sha256=JGM9vWbUjvEpy-IpTIgaYaqcTBKMI-CWTY8SJKBf3eI,30153
274
310
  orchestrator/services/products.py,sha256=BP4KyE8zO-8z7Trrs5T6zKBOw53S9BfBJnHWI3p6u5Y,1943
275
311
  orchestrator/services/resource_types.py,sha256=_QBy_JOW_X3aSTqH0CuLrq4zBJL0p7Q-UDJUcuK2_qc,884
276
312
  orchestrator/services/settings.py,sha256=HEWfFulgoEDwgfxGEO__QTr5fDiwNBEj1UhAeTAdbLQ,3159
@@ -319,7 +355,7 @@ orchestrator/workflows/tasks/resume_workflows.py,sha256=T3iobSJjVgiupe0rClD34kUZ
319
355
  orchestrator/workflows/tasks/validate_product_type.py,sha256=paG-NAY1bdde3Adt8zItkcBKf5Pxw6f5ngGW6an6dYU,3192
320
356
  orchestrator/workflows/tasks/validate_products.py,sha256=GZJBoFF-WMphS7ghMs2-gqvV2iL1F0POhk0uSNt93n0,8510
321
357
  orchestrator/workflows/translations/en-GB.json,sha256=ST53HxkphFLTMjFHonykDBOZ7-P_KxksktZU3GbxLt0,846
322
- orchestrator_core-4.4.0rc1.dist-info/licenses/LICENSE,sha256=b-aA5OZQuuBATmLKo_mln8CQrDPPhg3ghLzjPjLn4Tg,11409
323
- orchestrator_core-4.4.0rc1.dist-info/WHEEL,sha256=G2gURzTEtmeR8nrdXUJfNiB3VYVxigPQ-bEQujpNiNs,82
324
- orchestrator_core-4.4.0rc1.dist-info/METADATA,sha256=as5RXg0Y5DUGPcpT-6raY0HmvEeDJfEMsg1dIQfqoqU,5967
325
- orchestrator_core-4.4.0rc1.dist-info/RECORD,,
358
+ orchestrator_core-5.0.0a1.dist-info/licenses/LICENSE,sha256=b-aA5OZQuuBATmLKo_mln8CQrDPPhg3ghLzjPjLn4Tg,11409
359
+ orchestrator_core-5.0.0a1.dist-info/WHEEL,sha256=G2gURzTEtmeR8nrdXUJfNiB3VYVxigPQ-bEQujpNiNs,82
360
+ orchestrator_core-5.0.0a1.dist-info/METADATA,sha256=O08JzKILxDGjxchb-FX1p1DnZQSVbCfxLCwGqTb2OO0,6054
361
+ orchestrator_core-5.0.0a1.dist-info/RECORD,,
@@ -1,36 +0,0 @@
1
- import structlog
2
-
3
- from orchestrator.db.filters import Filter
4
- from orchestrator.db.sorting import Sort
5
- from orchestrator.graphql.pagination import Connection
6
- from orchestrator.graphql.schemas.scheduled_task import ScheduledTaskGraphql
7
- from orchestrator.graphql.types import GraphqlFilter, GraphqlSort, OrchestratorInfo
8
- from orchestrator.graphql.utils import create_resolver_error_handler, to_graphql_result_page
9
- from orchestrator.graphql.utils.is_query_detailed import is_querying_page_data
10
- from orchestrator.schedules.scheduler import get_scheduler_tasks, scheduled_task_filter_keys, scheduled_task_sort_keys
11
-
12
- logger = structlog.get_logger(__name__)
13
-
14
-
15
- async def resolve_scheduled_tasks(
16
- info: OrchestratorInfo,
17
- filter_by: list[GraphqlFilter] | None = None,
18
- sort_by: list[GraphqlSort] | None = None,
19
- first: int = 10,
20
- after: int = 0,
21
- ) -> Connection[ScheduledTaskGraphql]:
22
- _error_handler = create_resolver_error_handler(info)
23
-
24
- pydantic_filter_by: list[Filter] = [item.to_pydantic() for item in filter_by] if filter_by else []
25
- pydantic_sort_by: list[Sort] = [item.to_pydantic() for item in sort_by] if sort_by else []
26
- scheduled_tasks, total = get_scheduler_tasks(
27
- first=first, after=after, filter_by=pydantic_filter_by, sort_by=pydantic_sort_by, error_handler=_error_handler
28
- )
29
-
30
- graphql_scheduled_tasks = []
31
- if is_querying_page_data(info):
32
- graphql_scheduled_tasks = [ScheduledTaskGraphql.from_pydantic(p) for p in scheduled_tasks]
33
-
34
- return to_graphql_result_page(
35
- graphql_scheduled_tasks, first, after, total, scheduled_task_filter_keys, scheduled_task_sort_keys
36
- )
@@ -1,8 +0,0 @@
1
- import strawberry
2
-
3
- from orchestrator.schedules.scheduler import ScheduledTask
4
-
5
-
6
- @strawberry.experimental.pydantic.type(model=ScheduledTask, all_fields=True)
7
- class ScheduledTaskGraphql:
8
- pass