ibm-watsonx-orchestrate 1.9.0b0__py3-none-any.whl → 1.9.0b2__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 (28) hide show
  1. ibm_watsonx_orchestrate/__init__.py +1 -1
  2. ibm_watsonx_orchestrate/agent_builder/knowledge_bases/types.py +2 -2
  3. ibm_watsonx_orchestrate/agent_builder/models/types.py +5 -0
  4. ibm_watsonx_orchestrate/agent_builder/tools/types.py +5 -3
  5. ibm_watsonx_orchestrate/cli/commands/agents/agents_controller.py +15 -3
  6. ibm_watsonx_orchestrate/cli/commands/connections/connections_controller.py +6 -3
  7. ibm_watsonx_orchestrate/cli/commands/copilot/copilot_controller.py +103 -23
  8. ibm_watsonx_orchestrate/cli/commands/models/model_provider_mapper.py +17 -13
  9. ibm_watsonx_orchestrate/cli/commands/server/server_command.py +146 -36
  10. ibm_watsonx_orchestrate/cli/commands/toolkit/toolkit_command.py +4 -2
  11. ibm_watsonx_orchestrate/cli/commands/toolkit/toolkit_controller.py +9 -1
  12. ibm_watsonx_orchestrate/cli/commands/tools/tools_controller.py +1 -1
  13. ibm_watsonx_orchestrate/client/connections/connections_client.py +14 -2
  14. ibm_watsonx_orchestrate/client/copilot/cpe/copilot_cpe_client.py +5 -3
  15. ibm_watsonx_orchestrate/docker/compose-lite.yml +123 -9
  16. ibm_watsonx_orchestrate/docker/default.env +22 -17
  17. ibm_watsonx_orchestrate/flow_builder/flows/__init__.py +2 -2
  18. ibm_watsonx_orchestrate/flow_builder/flows/constants.py +2 -0
  19. ibm_watsonx_orchestrate/flow_builder/flows/flow.py +52 -10
  20. ibm_watsonx_orchestrate/flow_builder/node.py +34 -3
  21. ibm_watsonx_orchestrate/flow_builder/types.py +144 -26
  22. ibm_watsonx_orchestrate/flow_builder/utils.py +7 -5
  23. {ibm_watsonx_orchestrate-1.9.0b0.dist-info → ibm_watsonx_orchestrate-1.9.0b2.dist-info}/METADATA +1 -3
  24. {ibm_watsonx_orchestrate-1.9.0b0.dist-info → ibm_watsonx_orchestrate-1.9.0b2.dist-info}/RECORD +27 -28
  25. ibm_watsonx_orchestrate/agent_builder/utils/pydantic_utils.py +0 -149
  26. {ibm_watsonx_orchestrate-1.9.0b0.dist-info → ibm_watsonx_orchestrate-1.9.0b2.dist-info}/WHEEL +0 -0
  27. {ibm_watsonx_orchestrate-1.9.0b0.dist-info → ibm_watsonx_orchestrate-1.9.0b2.dist-info}/entry_points.txt +0 -0
  28. {ibm_watsonx_orchestrate-1.9.0b0.dist-info → ibm_watsonx_orchestrate-1.9.0b2.dist-info}/licenses/LICENSE +0 -0
@@ -4,11 +4,13 @@ import os
4
4
  import platform
5
5
  import subprocess
6
6
  import sys
7
+ import shutil
7
8
  import tempfile
8
9
  import time
9
10
  from pathlib import Path
10
11
  from urllib.parse import urlparse
11
12
 
13
+ import re
12
14
  import jwt
13
15
  import requests
14
16
  import typer
@@ -32,6 +34,13 @@ logger = logging.getLogger(__name__)
32
34
 
33
35
  server_app = typer.Typer(no_args_is_help=True)
34
36
 
37
+ _EXPORT_FILE_TYPES: set[str] = {
38
+ 'py',
39
+ 'yaml',
40
+ 'yml',
41
+ 'json',
42
+ 'env'
43
+ }
35
44
 
36
45
  _ALWAYS_UNSET: set[str] = {
37
46
  "WO_API_KEY",
@@ -43,11 +52,34 @@ _ALWAYS_UNSET: set[str] = {
43
52
  "WO_USERNAME",
44
53
  "WO_PASSWORD",
45
54
  }
55
+
56
+ NON_SECRET_ENV_ITEMS: set[str] = {
57
+ "WO_DEVELOPER_EDITION_SOURCE",
58
+ "WO_INSTANCE",
59
+ "USE_SAAS_ML_TOOLS_RUNTIME",
60
+ "AUTHORIZATION_URL",
61
+ "OPENSOURCE_REGISTRY_PROXY",
62
+ "SAAS_WDU_RUNTIME",
63
+ "LATEST_ENV_FILE",
64
+ }
46
65
 
47
66
  def define_saas_wdu_runtime(value: str = "none") -> None:
48
67
  cfg = Config()
49
68
  cfg.write(USER_ENV_CACHE_HEADER,"SAAS_WDU_RUNTIME",value)
50
69
 
70
+ def set_compose_file_path_in_env(path: str = None) -> None:
71
+ Config().save(
72
+ {
73
+ USER_ENV_CACHE_HEADER: {
74
+ "DOCKER_COMPOSE_FILE_PATH" : path
75
+ }
76
+ }
77
+ )
78
+
79
+ def get_compose_file_path_from_env() -> str:
80
+ return Config().read(USER_ENV_CACHE_HEADER,"DOCKER_COMPOSE_FILE_PATH")
81
+
82
+
51
83
  def ensure_docker_installed() -> None:
52
84
  try:
53
85
  subprocess.run(["docker", "--version"], check=True, capture_output=True)
@@ -106,6 +138,11 @@ def docker_login_by_dev_edition_source(env_dict: dict, source: str) -> None:
106
138
 
107
139
 
108
140
  def get_compose_file() -> Path:
141
+ custom_compose_path = get_compose_file_path_from_env()
142
+ return Path(custom_compose_path) if custom_compose_path else get_default_compose_file()
143
+
144
+
145
+ def get_default_compose_file() -> Path:
109
146
  with resources.as_file(
110
147
  resources.files("ibm_watsonx_orchestrate.docker").joinpath("compose-lite.yml")
111
148
  ) as compose_file:
@@ -283,12 +320,17 @@ def _prepare_clean_env(env_file: Path) -> None:
283
320
  for key in keys_to_unset:
284
321
  os.environ.pop(key, None)
285
322
 
286
- def write_merged_env_file(merged_env: dict) -> Path:
287
- tmp = tempfile.NamedTemporaryFile(mode="w", delete=False, suffix=".env")
288
- with tmp:
323
+ def write_merged_env_file(merged_env: dict, target_path: str = None) -> Path:
324
+
325
+ if target_path:
326
+ file = open(target_path,"w")
327
+ else:
328
+ file = tempfile.NamedTemporaryFile(mode="w", delete=False, suffix=".env")
329
+
330
+ with file:
289
331
  for key, val in merged_env.items():
290
- tmp.write(f"{key}={val}\n")
291
- return Path(tmp.name)
332
+ file.write(f"{key}={val}\n")
333
+ return Path(file.name)
292
334
 
293
335
 
294
336
  def get_dbtag_from_architecture(merged_env_dict: dict) -> str:
@@ -310,14 +352,6 @@ def refresh_local_credentials() -> None:
310
352
  clear_protected_env_credentials_token()
311
353
  _login(name=PROTECTED_ENV_NAME, apikey=None)
312
354
 
313
- NON_SECRET_ENV_ITEMS = {
314
- "WO_DEVELOPER_EDITION_SOURCE",
315
- "WO_INSTANCE",
316
- "USE_SAAS_ML_TOOLS_RUNTIME",
317
- "AUTHORIZATION_URL",
318
- "OPENSOURCE_REGISTRY_PROXY",
319
- "SAAS_WDU_RUNTIME"
320
- }
321
355
  def persist_user_env(env: dict, include_secrets: bool = False) -> None:
322
356
  if include_secrets:
323
357
  persistable_env = env
@@ -337,7 +371,10 @@ def get_persisted_user_env() -> dict | None:
337
371
  return user_env
338
372
 
339
373
  def run_compose_lite(final_env_file: Path, experimental_with_langfuse=False, experimental_with_ibm_telemetry=False, with_doc_processing=False) -> None:
374
+
375
+
340
376
  compose_path = get_compose_file()
377
+
341
378
  compose_command = ensure_docker_compose_installed()
342
379
  _prepare_clean_env(final_env_file)
343
380
  db_tag = read_env_file(final_env_file).get('DBTAG', None)
@@ -754,6 +791,32 @@ def auto_configure_callback_ip(merged_env_dict: dict) -> dict:
754
791
 
755
792
  return merged_env_dict
756
793
 
794
+ def prepare_server_env_vars(user_env: dict = {}):
795
+
796
+ default_env = read_env_file(get_default_env_file())
797
+ dev_edition_source = get_dev_edition_source(user_env)
798
+ default_registry_vars = get_default_registry_env_vars_by_dev_edition_source(default_env, user_env, source=dev_edition_source)
799
+
800
+ # Update the default environment with the default registry variables only if they are not already set
801
+ for key in default_registry_vars:
802
+ if key not in default_env or not default_env[key]:
803
+ default_env[key] = default_registry_vars[key]
804
+
805
+ # Merge the default environment with the user environment
806
+ merged_env_dict = {
807
+ **default_env,
808
+ **user_env,
809
+ }
810
+
811
+ merged_env_dict = apply_server_env_dict_defaults(merged_env_dict)
812
+
813
+ # Auto-configure callback IP for async tools
814
+ merged_env_dict = auto_configure_callback_ip(merged_env_dict)
815
+
816
+ apply_llm_api_key_defaults(merged_env_dict)
817
+
818
+ return merged_env_dict
819
+
757
820
  @server_app.command(name="start")
758
821
  def server_start(
759
822
  user_env_file: str = typer.Option(
@@ -787,38 +850,37 @@ def server_start(
787
850
  '--with-doc-processing', '-d',
788
851
  help='Enable IBM Document Processing to extract information from your business documents. Enabling this activates the Watson Document Understanding service.'
789
852
  ),
853
+ custom_compose_file: str = typer.Option(
854
+ None,
855
+ '--compose-file', '-f',
856
+ help='Provide the path to a custom docker-compose file to use instead of the default compose file'
857
+ ),
790
858
  ):
791
859
  confirm_accepts_license_agreement(accept_terms_and_conditions)
792
860
 
793
861
  define_saas_wdu_runtime()
794
862
 
863
+ ensure_docker_installed()
864
+
795
865
  if user_env_file and not Path(user_env_file).exists():
796
- logger.error(f"Error: The specified environment file '{user_env_file}' does not exist.")
866
+ logger.error(f"The specified environment file '{user_env_file}' does not exist.")
797
867
  sys.exit(1)
798
- ensure_docker_installed()
799
868
 
800
- default_env = read_env_file(get_default_env_file())
869
+ if custom_compose_file:
870
+ if Path(custom_compose_file).exists():
871
+ logger.warning("You are using a custom docker compose file, official support will not be available for this configuration")
872
+ else:
873
+ logger.error(f"The specified docker-compose file '{custom_compose_file}' does not exist.")
874
+ sys.exit(1)
875
+
876
+ #Run regardless, to allow this to set compose as 'None' when not in use
877
+ set_compose_file_path_in_env(custom_compose_file)
878
+
801
879
  user_env = read_env_file(user_env_file) if user_env_file else {}
802
880
  persist_user_env(user_env, include_secrets=persist_env_secrets)
803
881
 
804
- dev_edition_source = get_dev_edition_source(user_env)
805
- default_registry_vars = get_default_registry_env_vars_by_dev_edition_source(default_env, user_env, source=dev_edition_source)
806
-
807
- # Update the default environment with the default registry variables only if they are not already set
808
- for key in default_registry_vars:
809
- if key not in default_env or not default_env[key]:
810
- default_env[key] = default_registry_vars[key]
882
+ merged_env_dict = prepare_server_env_vars(user_env)
811
883
 
812
- # Merge the default environment with the user environment
813
- merged_env_dict = {
814
- **default_env,
815
- **user_env,
816
- }
817
-
818
- merged_env_dict = apply_server_env_dict_defaults(merged_env_dict)
819
-
820
- # Auto-configure callback IP for async tools
821
- merged_env_dict = auto_configure_callback_ip(merged_env_dict)
822
884
  if not _check_exclusive_observibility(experimental_with_langfuse, experimental_with_ibm_telemetry):
823
885
  logger.error("Please select either langfuse or ibm telemetry for observability not both")
824
886
  sys.exit(1)
@@ -835,14 +897,12 @@ def server_start(
835
897
  merged_env_dict['USE_IBM_TELEMETRY'] = 'true'
836
898
 
837
899
  try:
900
+ dev_edition_source = get_dev_edition_source(merged_env_dict)
838
901
  docker_login_by_dev_edition_source(merged_env_dict, dev_edition_source)
839
902
  except ValueError as e:
840
903
  logger.error(f"Error: {e}")
841
904
  sys.exit(1)
842
905
 
843
- apply_llm_api_key_defaults(merged_env_dict)
844
-
845
-
846
906
  final_env_file = write_merged_env_file(merged_env_dict)
847
907
 
848
908
  run_compose_lite(final_env_file=final_env_file,
@@ -1000,5 +1060,55 @@ def run_db_migration() -> None:
1000
1060
  )
1001
1061
  sys.exit(1)
1002
1062
 
1063
+
1064
+ def bump_file_iteration(filename: str) -> str:
1065
+ regex = re.compile(f"^(?P<name>[^\\(\\s\\.\\)]+)(\\((?P<num>\\d+)\\))?(?P<type>\\.(?:{'|'.join(_EXPORT_FILE_TYPES)}))?$")
1066
+ _m = regex.match(filename)
1067
+ iter = int(_m['num']) + 1 if (_m and _m['num']) else 1
1068
+ return f"{_m['name']}({iter}){_m['type'] or ''}"
1069
+
1070
+ def get_next_free_file_iteration(filename: str) -> str:
1071
+ while Path(filename).exists():
1072
+ filename = bump_file_iteration(filename)
1073
+ return filename
1074
+
1075
+ @server_app.command(name="eject", help="output the docker-compose file and associated env file used to run the server")
1076
+ def server_eject(
1077
+ user_env_file: str = typer.Option(
1078
+ None,
1079
+ "--env-file",
1080
+ "-e",
1081
+ help="Path to a .env file that overrides default.env. Then environment variables override both."
1082
+ )
1083
+ ):
1084
+
1085
+ if not user_env_file:
1086
+ logger.error(f"To use 'server eject' you need to specify an env file with '--env-file' or '-e'")
1087
+ sys.exit(1)
1088
+
1089
+ if not Path(user_env_file).exists():
1090
+ logger.error(f"The specified environment file '{user_env_file}' does not exist.")
1091
+ sys.exit(1)
1092
+
1093
+ logger.warning("Changes to your docker compose file are not supported")
1094
+
1095
+ compose_file_path = get_compose_file()
1096
+
1097
+ compose_output_file = get_next_free_file_iteration('docker-compose.yml')
1098
+ logger.info(f"Exporting docker compose file to '{compose_output_file}'")
1099
+
1100
+ shutil.copyfile(compose_file_path,compose_output_file)
1101
+
1102
+
1103
+ user_env = read_env_file(user_env_file)
1104
+ merged_env_dict = prepare_server_env_vars(user_env)
1105
+
1106
+ env_output_file = get_next_free_file_iteration('server.env')
1107
+ logger.info(f"Exporting env file to '{env_output_file}'")
1108
+
1109
+ write_merged_env_file(merged_env=merged_env_dict,target_path=env_output_file)
1110
+
1111
+ logger.info(f"To make use of the exported configuration file run \"orchestrate server start -e {env_output_file} -f {compose_output_file}\"")
1112
+
1003
1113
  if __name__ == "__main__":
1004
1114
  server_app()
@@ -64,8 +64,8 @@ def import_toolkit(
64
64
  else:
65
65
  tool_list = None
66
66
 
67
- if not package and not package_root:
68
- logger.error("You must provide either '--package' or '--package-root'.")
67
+ if not package and not package_root and not command:
68
+ logger.error("You must provide either '--package', '--package-root' or '--command'.")
69
69
  sys.exit(1)
70
70
 
71
71
  if package_root and not command:
@@ -85,6 +85,8 @@ def import_toolkit(
85
85
  else:
86
86
  logger.error("Unable to infer start up command: '--language' flag must be either 'node' or 'python' when using the '--package' flag without '--command' flag.")
87
87
  sys.exit(1)
88
+ else:
89
+ logger.warning(f"Default package installation command for package '{package}' overridden by '--command {command}'.")
88
90
 
89
91
 
90
92
  toolkit_controller = ToolkitController(
@@ -70,7 +70,7 @@ class ToolkitController:
70
70
  self.client = None
71
71
 
72
72
  self.source: ToolkitSource = (
73
- ToolkitSource.PUBLIC_REGISTRY if package else ToolkitSource.FILES
73
+ ToolkitSource.FILES if package_root else ToolkitSource.PUBLIC_REGISTRY
74
74
  )
75
75
 
76
76
  def get_client(self) -> ToolKitClient:
@@ -105,6 +105,14 @@ class ToolkitController:
105
105
  command = command_parts[0]
106
106
  args = command_parts[1:]
107
107
 
108
+ if self.package_root:
109
+ is_folder = os.path.isdir(self.package_root)
110
+ is_zip_file = os.path.isfile(self.package_root) and zipfile.is_zipfile(self.package_root)
111
+
112
+ if not is_folder and not is_zip_file:
113
+ logger.error(f"Unable to find a valid directory or zip file at location '{self.package_root}'")
114
+ sys.exit(1)
115
+
108
116
  console = Console()
109
117
 
110
118
  with tempfile.TemporaryDirectory() as tmpdir:
@@ -590,7 +590,7 @@ class ToolsController:
590
590
  for tool in tools:
591
591
  tools_list.append(json.loads(tool.dumps_spec()))
592
592
 
593
- rich.print(JSON(json.dumps(tools_list, indent=4)))
593
+ rich.print_json(json.dumps(tools_list, indent=4))
594
594
  else:
595
595
  table = rich.table.Table(show_header=True, header_style="bold white", show_lines=True)
596
596
  column_args = {
@@ -3,6 +3,7 @@ from typing import List
3
3
  from ibm_cloud_sdk_core.authenticators import MCSPAuthenticator
4
4
  from pydantic import BaseModel, ValidationError
5
5
  from typing import Optional
6
+ from enum import Enum
6
7
 
7
8
  from ibm_watsonx_orchestrate.client.base_api_client import BaseAPIClient, ClientAPIException
8
9
  from ibm_watsonx_orchestrate.agent_builder.connections.types import ConnectionEnvironment, ConnectionPreference, ConnectionAuthType, ConnectionSecurityScheme, IdpConfigData, AppConfigData, ConnectionType
@@ -12,12 +13,23 @@ import logging
12
13
  logger = logging.getLogger(__name__)
13
14
 
14
15
 
16
+ class FetchConfigAuthTypes(str, Enum):
17
+ BASIC_AUTH = ConnectionType.BASIC_AUTH.value
18
+ BEARER_TOKEN = ConnectionType.BEARER_TOKEN.value
19
+ API_KEY_AUTH = ConnectionType.API_KEY_AUTH.value
20
+ OAUTH2_AUTH_CODE = ConnectionType.OAUTH2_AUTH_CODE.value
21
+ OAUTH2_IMPLICIT = 'oauth2_implicit'
22
+ OAUTH2_PASSWORD = 'oauth2_password'
23
+ OAUTH2_CLIENT_CREDS = ConnectionType.OAUTH2_CLIENT_CREDS.value
24
+ OAUTH_ON_BEHALF_OF_FLOW = ConnectionType.OAUTH_ON_BEHALF_OF_FLOW.value
25
+ KEY_VALUE = ConnectionType.KEY_VALUE.value
26
+
15
27
  class ListConfigsResponse(BaseModel):
16
28
  connection_id: str = None,
17
29
  app_id: str = None
18
30
  name: str = None
19
31
  security_scheme: ConnectionSecurityScheme | None = None,
20
- auth_type: ConnectionAuthType | None = None,
32
+ auth_type: FetchConfigAuthTypes | None = None,
21
33
  environment: ConnectionEnvironment | None = None,
22
34
  preference: ConnectionPreference | None = None,
23
35
  credentials_entered: bool | None = False
@@ -28,7 +40,7 @@ class GetConfigResponse(BaseModel):
28
40
  app_id: str = None
29
41
  environment: ConnectionEnvironment = None
30
42
  preference: ConnectionPreference = None
31
- auth_type: ConnectionAuthType | None = None
43
+ auth_type: FetchConfigAuthTypes | None = None
32
44
  sso: bool = None
33
45
  security_scheme: ConnectionSecurityScheme = None
34
46
  server_url: str | None = None
@@ -21,13 +21,15 @@ class CPEClient(BaseAPIClient):
21
21
  }
22
22
 
23
23
 
24
- def submit_pre_cpe_chat(self, user_message: str | None =None, tools: Dict[str, Any] = None, agents: Dict[str, Any] = None) -> dict:
24
+ def submit_pre_cpe_chat(self, user_message: str | None =None, tools: Dict[str, Any] = None, collaborators: Dict[str, Any] = None, knowledge_bases: Dict[str, Any] = None, selected:bool=False) -> dict:
25
25
  payload = {
26
26
  "message": user_message,
27
27
  "tools": tools,
28
- "agents": agents,
28
+ "collaborators": collaborators,
29
+ "knowledge_bases": knowledge_bases,
29
30
  "chat_id": self.chat_id,
30
- "chat_model_name": self.chat_model_name
31
+ "chat_model_name": self.chat_model_name,
32
+ 'selected':selected
31
33
  }
32
34
 
33
35
  response = self._post_nd_json("/wxo-cpe/create-agent", data=payload)
@@ -1,3 +1,4 @@
1
+ name: docker
1
2
  services:
2
3
  ########################
3
4
  # Orchestrate Lite dependencies
@@ -121,6 +122,11 @@ services:
121
122
  CONNECTIONS_MANAGER_ENDPOINT: http://wxo-server-connection-manager:3001
122
123
  AGENT_OPS_API_KEY: ${AGENTOPS_API_KEY}
123
124
  AGENTS_OPS_RUNTIME_ENDPOINT: https://frontend-server:443
125
+ DPI_WO_WDU_SERVER_ENDPOINT: https://wxo-doc-processing-service:8080
126
+ DPI_RAG_SERVER_ENDPOINT: https://wxo-doc-processing-llm-service:8083
127
+ IBM_DPS_CACHE_SERVICE: https://wxo-doc-processing-cache:8080
128
+ DOCPROC_BASE_URL: http://wxo-doc-processing-infra-standalone:9080
129
+ BUILDER_ASYNC_CALLBACK_ENDPOINT: http://wxo-builder:4025
124
130
  IS_OBSERVABILITY_FEATURE_ENABLED: "true"
125
131
  ALLOW_INSECURE_TLS: "true"
126
132
  command: 'npm start'
@@ -164,7 +170,7 @@ services:
164
170
  "
165
171
 
166
172
  wxo-milvus-standalone:
167
- image: ${OPENSOURCE_REGISTRY_PROXY:-docker.io}/milvusdb/milvus:v2.5.6
173
+ image: ${OPENSOURCE_REGISTRY_PROXY:-docker.io}/milvusdb/milvus:v2.5.15
168
174
  command: ["milvus", "run", "standalone"]
169
175
  security_opt:
170
176
  - seccomp:unconfined
@@ -548,6 +554,7 @@ services:
548
554
  - TENANT_DEFAULT_PASSWORD=${ES_PASSWORD}
549
555
  - TENANT_DEFAULT_HOSTNAME=http://elasticsearch:9200
550
556
  - DEFAULT_TENANT_ID=${DEFAULT_TENANT_ID}
557
+ - FORCE_SINGLE_TENANT=${FORCE_SINGLE_TENANT:-true}
551
558
  ports:
552
559
  - "9202:9201" # Expose proxy on host port 9202
553
560
  networks:
@@ -643,6 +650,7 @@ services:
643
650
  - INBOUND_API_KEY=${AGENTOPS_API_KEY}
644
651
  - DEFAULT_TENANT_ID=${DEFAULT_TENANT_ID}
645
652
  - TENANT_DEFAULT_HOSTNAME=http://elasticsearch:9200
653
+ - FORCE_SINGLE_TENANT=${FORCE_SINGLE_TENANT:-true}
646
654
  ports:
647
655
  - "8765:443"
648
656
  networks:
@@ -780,7 +788,6 @@ services:
780
788
  LANGFUSE_PUBLIC_KEY: ${LANGFUSE_PUBLIC_KEY:-pk-lf-7417757e-d6df-421b-957e-683b76acb5df}
781
789
  LANGFUSE_SECRET_KEY: ${LANGFUSE_PRIVATE_KEY:-sk-lf-7bc4da63-7b2b-40c0-b5eb-1e0cf64f9af2}
782
790
  LOG_LEVEL: info
783
- DISABLE_FLOW_BINDING: true
784
791
  DOCPROC_ENABLED: ${DOCPROC_ENABLED:-false}
785
792
  DOCPROC_BASE_URL: http://wxo-doc-processing-infra-standalone:9080
786
793
  WO_API_KEY: ${WO_API_KEY}
@@ -825,7 +832,7 @@ services:
825
832
  ########################
826
833
 
827
834
  wxo-doc-processing-service:
828
- image: ${DOCPROC_REGISTRY:-us.icr.io/watson-orchestrate-private}/document-processing/wo_doc_processing_service:${DOCPROC_DPS_TAG:-20250606-172035-246-4191121}
835
+ image: ${DOCPROC_REGISTRY:-us.icr.io/watson-orchestrate-private}/document-processing/wo_doc_processing_service:${DOCPROC_DPS_TAG:-20250721-164412-250-503756a}
829
836
  platform: linux/amd64
830
837
  restart: unless-stopped
831
838
  environment:
@@ -841,9 +848,9 @@ services:
841
848
  IBM_DPS_CACHE_SERVICE: https://wxo-doc-processing-cache:8080
842
849
  profiles:
843
850
  - docproc
844
- # depends_on:
845
- # wxo-doc-processing-cache:
846
- # condition: service_healthy
851
+ depends_on:
852
+ wxo-doc-processing-cache:
853
+ condition: service_healthy
847
854
  ports:
848
855
  - "18081:8080"
849
856
  healthcheck:
@@ -855,6 +862,7 @@ services:
855
862
  wdu-runtime:
856
863
  image: ${WDU_REGISTRY:-us.icr.io/watson-orchestrate-private}/document-processing/wdu-runtime:${WDU_TAG:-2.4.0}
857
864
  platform: linux/amd64
865
+ user: app
858
866
  restart: unless-stopped
859
867
  environment:
860
868
  MEMORY_MINIMAL: "true"
@@ -894,6 +902,48 @@ services:
894
902
  tmpfs:
895
903
  - "/dev/shm"
896
904
 
905
+ wxo-doc-processing-cache:
906
+ image: ${DOCPROC_REGISTRY:-us.icr.io/watson-orchestrate-private}/document-processing/wo_doc_processing_cache:${DOCPROC_CACHE_TAG:-20250723-100852-70-9edc1ab}
907
+ platform: linux/amd64
908
+ restart: unless-stopped
909
+ environment:
910
+ SERVICE_NAME: wxo-doc-processing-cache
911
+ LOG_LEVEL: info
912
+ RATE_LIMITING_ENABLED: "false"
913
+ USE_DUMMY_CACHE: "false"
914
+ CACHE_ENFORCE_STRICT_JWT: "false"
915
+ PGHOST: wxo-server-db
916
+ PGPORT: "5432"
917
+ PGUSER: ${POSTGRES_USER:-postgres}
918
+ PGPASSWORD: ${POSTGRES_PASSWORD:-postgres}
919
+ PGDATABASE: wxo-document-processing-cache
920
+ PG_DB_SCHEMA: dpschema
921
+ # PG_USE_SSL: false
922
+ S3_ENDPOINT_URL: http://wxo-server-minio:9000
923
+ S3_ACCESS_KEY: ${MINIO_ROOT_USER:-minioadmin}
924
+ S3_SECRET_KEY: ${MINIO_ROOT_PASSWORD:-watsonxorchestrate}
925
+ S3_REGION: us-east-1
926
+ S3_BUCKET_NAME: wxo-document-processing-cache
927
+ VERIFY_CLIENT_CERT: 1
928
+ # S3_USE_SSL: false
929
+ # S3_VERIFY_CERT: false
930
+ profiles:
931
+ - docproc
932
+ depends_on:
933
+ wxo-doc-processing-pg-init:
934
+ condition: service_completed_successfully
935
+ wxo-doc-processing-cache-minio-init:
936
+ condition: service_completed_successfully
937
+ ports:
938
+ - "18083:8080"
939
+ # volumes:
940
+ # - ./docker/wo_doc_processing_rag_base/etc/certs:/etc/certs
941
+ healthcheck:
942
+ test: ["CMD-SHELL", "curl -fk https://localhost:8080/ping"]
943
+ interval: 30s
944
+ timeout: 30s
945
+ retries: 10
946
+
897
947
  wxo-doc-processing-infra-standalone:
898
948
  image: ${DOCPROC_REGISTRY:-us.icr.io/watson-orchestrate-private}/document-processing/wo-doc-processing-infra-standalone:${DOCPROC_DPI_TAG:-2025-06-13-dev-1}
899
949
  platform: linux/amd64
@@ -918,7 +968,7 @@ services:
918
968
  SIDECAR_METERED_ENABLED: "false"
919
969
  DPI_DEBUG: "false"
920
970
  DPI_WO_WDU_SERVER_ENDPOINT: https://wxo-doc-processing-service:8080
921
- # DPI_RAG_SERVER_ENDPOINT: https://wxo-doc-processing-llm-service:8083
971
+ DPI_RAG_SERVER_ENDPOINT: https://wxo-doc-processing-llm-service:8083
922
972
  DISABLE_TLS: true
923
973
  STANDALONE_DPI: "true"
924
974
  depends_on:
@@ -928,8 +978,8 @@ services:
928
978
  condition: service_completed_successfully
929
979
  wxo-doc-processing-service:
930
980
  condition: service_healthy
931
- # wxo-doc-processing-llm-service:
932
- # condition: service_healthy
981
+ wxo-doc-processing-llm-service:
982
+ condition: service_healthy
933
983
  ports:
934
984
  - 19080:9080
935
985
  - 19443:9443
@@ -939,6 +989,33 @@ services:
939
989
  timeout: 30s
940
990
  retries: 10
941
991
 
992
+ wxo-doc-processing-llm-service:
993
+ image: ${DOCPROC_REGISTRY:-us.icr.io/watson-orchestrate-private}/document-processing/wo_doc_processing_rag:${DOCPROC_LLMSERVICE_TAG:-20250725-100249-111-51d3e51}
994
+ platform: linux/amd64
995
+ restart: unless-stopped
996
+ environment:
997
+ SERVICE_NAME: wxo-doc-processing-llm-service
998
+ LOG_LEVEL: info
999
+ WATSONX_API_ENDPOINT: ${WATSONX_URL:-https://us-south.ml.cloud.ibm.com}
1000
+ WATSONX_API_KEY: ${WATSONX_APIKEY}
1001
+ WATSONX_PROJECT_ID: ${WATSONX_PROJECT_ID}
1002
+ WATSONX_SPACE_ID: ${WATSONX_SPACE_ID}
1003
+ IBM_DPS_CACHE_SERVICE: 'wxo-doc-processing-cache:8080'
1004
+ profiles:
1005
+ - docproc
1006
+ depends_on:
1007
+ wxo-doc-processing-cache:
1008
+ condition: service_healthy
1009
+ ports:
1010
+ - "18084:8083"
1011
+ # volumes:
1012
+ # - ./conf/rag/certs:/etc/certs
1013
+ healthcheck:
1014
+ test: ["CMD-SHELL", "curl -fk https://localhost:8083/ping"]
1015
+ interval: 30s
1016
+ timeout: 30s
1017
+ retries: 10
1018
+
942
1019
  wxo-doc-processing-infra-pg-init:
943
1020
  image: ${DOCPROC_REGISTRY:-us.icr.io/watson-orchestrate-private}/document-processing/wo-doc-processing-infra-pg-init:${DOCPROC_DPI_TAG:-2025-06-13-dev-1}
944
1021
  platform: linux/amd64
@@ -963,6 +1040,28 @@ services:
963
1040
  timeout: 5s
964
1041
  retries: 50
965
1042
 
1043
+ wxo-doc-processing-pg-init:
1044
+ image: ${DOCPROC_REGISTRY:-us.icr.io/watson-orchestrate-private}/document-processing/wo_doc_processing_cache_rds_init:${DOCPROC_CACHE_TAG:-20250723-100852-70-9edc1ab}
1045
+ platform: linux/amd64
1046
+ environment:
1047
+ PGHOST: wxo-server-db
1048
+ PGPORT: "5432"
1049
+ PGUSER: ${POSTGRES_USER:-postgres}
1050
+ PGPASSWORD: ${POSTGRES_PASSWORD:-postgres}
1051
+ PGDATABASE: wxo-document-processing-cache
1052
+ PG_DB_SCHEMA: dpschema
1053
+ # PG_USE_SSL: false
1054
+ profiles:
1055
+ - docproc
1056
+ depends_on:
1057
+ wxo-server-db:
1058
+ condition: service_started
1059
+ healthcheck:
1060
+ test: ["CMD-SHELL", "psql -h localhost -U ${POSTGRES_USER:-postgres} -d ${POSTGRES_PASSWORD:-postgres}"]
1061
+ interval: 1s
1062
+ timeout: 5s
1063
+ retries: 50
1064
+
966
1065
  wxo-doc-processing-dpi-minio-init:
967
1066
  image: ${OPENSOURCE_REGISTRY_PROXY:-docker.io}/minio/mc:latest
968
1067
  platform: linux/amd64
@@ -978,6 +1077,21 @@ services:
978
1077
  exit 0;
979
1078
  "
980
1079
 
1080
+ wxo-doc-processing-cache-minio-init:
1081
+ image: ${OPENSOURCE_REGISTRY_PROXY:-docker.io}/minio/mc:latest
1082
+ platform: linux/amd64
1083
+ profiles:
1084
+ - docproc
1085
+ depends_on:
1086
+ wxo-server-minio:
1087
+ condition: service_healthy
1088
+ entrypoint: >
1089
+ /bin/sh -c "
1090
+ /usr/bin/mc alias set wxo-server-minio http://wxo-server-minio:9000 ${MINIO_ROOT_USER:-minioadmin} ${MINIO_ROOT_PASSWORD:-watsonxorchestrate};
1091
+ /usr/bin/mc mb wxo-server-minio/wxo-document-processing-cache;
1092
+ exit 0;
1093
+ "
1094
+
981
1095
  volumes:
982
1096
  tools:
983
1097
  driver: local