pygeai 0.6.0b13__py3-none-any.whl → 0.6.1__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 (217) hide show
  1. pygeai/__init__.py +1 -2
  2. pygeai/_docs/source/content/api_reference/project.rst +392 -0
  3. pygeai/_docs/source/content/authentication.rst +130 -1
  4. pygeai/_docs/source/content/debugger.rst +327 -157
  5. pygeai/_docs/source/content/migration.rst +391 -7
  6. pygeai/_docs/source/pygeai.core.common.rst +8 -0
  7. pygeai/_docs/source/pygeai.tests.auth.rst +56 -0
  8. pygeai/_docs/source/pygeai.tests.cli.rst +8 -0
  9. pygeai/admin/clients.py +1 -3
  10. pygeai/analytics/clients.py +1 -1
  11. pygeai/assistant/clients.py +2 -7
  12. pygeai/assistant/data/clients.py +0 -8
  13. pygeai/assistant/data_analyst/clients.py +0 -2
  14. pygeai/assistant/managers.py +1 -1
  15. pygeai/assistant/rag/clients.py +0 -2
  16. pygeai/assistant/rag/mappers.py +9 -11
  17. pygeai/auth/clients.py +26 -7
  18. pygeai/auth/endpoints.py +2 -1
  19. pygeai/chat/clients.py +2 -2
  20. pygeai/chat/managers.py +1 -1
  21. pygeai/cli/commands/admin.py +13 -25
  22. pygeai/cli/commands/analytics.py +56 -88
  23. pygeai/cli/commands/assistant.py +84 -138
  24. pygeai/cli/commands/auth.py +23 -46
  25. pygeai/cli/commands/base.py +0 -1
  26. pygeai/cli/commands/chat.py +218 -209
  27. pygeai/cli/commands/common.py +5 -5
  28. pygeai/cli/commands/configuration.py +79 -29
  29. pygeai/cli/commands/docs.py +3 -4
  30. pygeai/cli/commands/embeddings.py +13 -19
  31. pygeai/cli/commands/evaluation.py +133 -344
  32. pygeai/cli/commands/feedback.py +7 -15
  33. pygeai/cli/commands/files.py +26 -53
  34. pygeai/cli/commands/gam.py +28 -69
  35. pygeai/cli/commands/lab/ai_lab.py +96 -142
  36. pygeai/cli/commands/lab/common.py +1 -1
  37. pygeai/cli/commands/lab/spec.py +12 -32
  38. pygeai/cli/commands/llm.py +9 -18
  39. pygeai/cli/commands/migrate.py +43 -99
  40. pygeai/cli/commands/organization.py +223 -196
  41. pygeai/cli/commands/rag.py +35 -58
  42. pygeai/cli/commands/rerank.py +21 -25
  43. pygeai/cli/commands/secrets.py +39 -67
  44. pygeai/cli/commands/usage_limits.py +50 -136
  45. pygeai/cli/commands/validators.py +1 -1
  46. pygeai/cli/geai.py +32 -3
  47. pygeai/cli/geai_proxy.py +6 -2
  48. pygeai/cli/install_man.py +1 -1
  49. pygeai/cli/parsers.py +1 -1
  50. pygeai/core/base/clients.py +90 -21
  51. pygeai/core/base/mappers.py +39 -55
  52. pygeai/core/base/session.py +134 -22
  53. pygeai/core/common/config.py +50 -13
  54. pygeai/core/common/constants.py +8 -0
  55. pygeai/core/common/exceptions.py +6 -0
  56. pygeai/core/embeddings/clients.py +0 -1
  57. pygeai/core/embeddings/managers.py +0 -1
  58. pygeai/core/feedback/clients.py +0 -2
  59. pygeai/core/feedback/models.py +1 -1
  60. pygeai/core/files/clients.py +0 -3
  61. pygeai/core/files/managers.py +1 -1
  62. pygeai/core/files/mappers.py +4 -5
  63. pygeai/core/llm/clients.py +0 -1
  64. pygeai/core/models.py +4 -4
  65. pygeai/core/plugins/clients.py +0 -3
  66. pygeai/core/plugins/models.py +2 -2
  67. pygeai/core/rerank/clients.py +0 -2
  68. pygeai/core/secrets/clients.py +0 -2
  69. pygeai/core/services/rest.py +80 -14
  70. pygeai/core/singleton.py +24 -0
  71. pygeai/dbg/__init__.py +2 -2
  72. pygeai/dbg/debugger.py +276 -38
  73. pygeai/evaluation/clients.py +2 -4
  74. pygeai/evaluation/dataset/clients.py +0 -1
  75. pygeai/evaluation/plan/clients.py +0 -2
  76. pygeai/evaluation/result/clients.py +0 -2
  77. pygeai/gam/clients.py +1 -3
  78. pygeai/health/clients.py +1 -3
  79. pygeai/lab/clients.py +0 -1
  80. pygeai/lab/managers.py +0 -1
  81. pygeai/lab/models.py +0 -1
  82. pygeai/lab/strategies/clients.py +1 -2
  83. pygeai/lab/tools/clients.py +2 -2
  84. pygeai/lab/tools/mappers.py +1 -1
  85. pygeai/migration/strategies.py +5 -6
  86. pygeai/migration/tools.py +1 -1
  87. pygeai/organization/clients.py +118 -12
  88. pygeai/organization/endpoints.py +1 -0
  89. pygeai/organization/limits/clients.py +4 -6
  90. pygeai/organization/limits/managers.py +1 -4
  91. pygeai/organization/managers.py +2 -2
  92. pygeai/proxy/config.py +1 -0
  93. pygeai/proxy/managers.py +6 -5
  94. pygeai/tests/admin/test_clients.py +11 -11
  95. pygeai/tests/assistants/rag/test_clients.py +1 -1
  96. pygeai/tests/assistants/rag/test_models.py +1 -2
  97. pygeai/tests/assistants/test_clients.py +1 -1
  98. pygeai/tests/assistants/test_managers.py +1 -3
  99. pygeai/tests/auth/test_cli_configuration.py +252 -0
  100. pygeai/tests/auth/test_client_initialization.py +411 -0
  101. pygeai/tests/auth/test_clients.py +29 -27
  102. pygeai/tests/auth/test_config_manager.py +305 -0
  103. pygeai/tests/auth/test_header_injection.py +294 -0
  104. pygeai/tests/auth/test_oauth.py +3 -1
  105. pygeai/tests/auth/test_session_logging.py +119 -0
  106. pygeai/tests/auth/test_session_validation.py +408 -0
  107. pygeai/tests/auth/test_singleton_reset.py +201 -0
  108. pygeai/tests/chat/test_clients.py +1 -1
  109. pygeai/tests/chat/test_iris.py +1 -1
  110. pygeai/tests/chat/test_ui.py +0 -2
  111. pygeai/tests/cli/commands/lab/test_ai_lab.py +1 -3
  112. pygeai/tests/cli/commands/lab/test_common.py +0 -1
  113. pygeai/tests/cli/commands/test_chat.py +1 -1
  114. pygeai/tests/cli/commands/test_common.py +0 -1
  115. pygeai/tests/cli/commands/test_embeddings.py +2 -2
  116. pygeai/tests/cli/commands/test_evaluation.py +1 -9
  117. pygeai/tests/cli/commands/test_llm.py +1 -1
  118. pygeai/tests/cli/commands/test_migrate.py +1 -1
  119. pygeai/tests/cli/commands/test_rerank.py +0 -1
  120. pygeai/tests/cli/commands/test_secrets.py +1 -1
  121. pygeai/tests/cli/commands/test_show_help.py +0 -1
  122. pygeai/tests/cli/commands/test_validators.py +0 -1
  123. pygeai/tests/cli/test_credentials_flag.py +312 -0
  124. pygeai/tests/cli/test_error_handler.py +0 -1
  125. pygeai/tests/core/base/test_mappers.py +2 -2
  126. pygeai/tests/core/base/test_models.py +4 -4
  127. pygeai/tests/core/common/test_config.py +2 -7
  128. pygeai/tests/core/common/test_decorators.py +0 -1
  129. pygeai/tests/core/embeddings/test_managers.py +1 -1
  130. pygeai/tests/core/feedback/test_clients.py +2 -2
  131. pygeai/tests/core/files/test_clients.py +6 -6
  132. pygeai/tests/core/files/test_models.py +0 -1
  133. pygeai/tests/core/files/test_responses.py +0 -1
  134. pygeai/tests/core/llm/test_clients.py +1 -1
  135. pygeai/tests/core/plugins/test_clients.py +4 -4
  136. pygeai/tests/core/rerank/test_mappers.py +1 -3
  137. pygeai/tests/core/secrets/test_clients.py +2 -3
  138. pygeai/tests/core/services/test_rest.py +10 -10
  139. pygeai/tests/core/utils/test_console.py +0 -1
  140. pygeai/tests/dbg/test_debugger.py +95 -8
  141. pygeai/tests/evaluation/dataset/test_clients.py +24 -27
  142. pygeai/tests/evaluation/plan/test_clients.py +16 -18
  143. pygeai/tests/evaluation/result/test_clients.py +4 -5
  144. pygeai/tests/health/test_clients.py +2 -2
  145. pygeai/tests/integration/lab/agents/test_create_agent.py +1 -3
  146. pygeai/tests/integration/lab/agents/test_get_agent.py +1 -1
  147. pygeai/tests/integration/lab/processes/test_create_process.py +2 -2
  148. pygeai/tests/integration/lab/processes/test_create_task.py +2 -3
  149. pygeai/tests/integration/lab/processes/test_delete_process.py +0 -1
  150. pygeai/tests/integration/lab/processes/test_get_process.py +2 -4
  151. pygeai/tests/integration/lab/processes/test_list_process_instances.py +1 -3
  152. pygeai/tests/integration/lab/processes/test_update_process.py +3 -9
  153. pygeai/tests/integration/lab/reasoning_strategies/test_update_reasoning_strategy.py +1 -2
  154. pygeai/tests/integration/lab/tools/test_delete_tool.py +1 -1
  155. pygeai/tests/integration/lab/tools/test_list_tools.py +1 -1
  156. pygeai/tests/integration/lab/tools/test_update_tool.py +1 -1
  157. pygeai/tests/lab/agents/test_clients.py +17 -17
  158. pygeai/tests/lab/processes/test_clients.py +67 -67
  159. pygeai/tests/lab/processes/test_mappers.py +23 -23
  160. pygeai/tests/lab/spec/test_loader.py +0 -2
  161. pygeai/tests/lab/spec/test_parsers.py +1 -2
  162. pygeai/tests/lab/strategies/test_clients.py +10 -10
  163. pygeai/tests/lab/test_managers.py +3 -5
  164. pygeai/tests/lab/test_mappers.py +1 -4
  165. pygeai/tests/lab/tools/test_clients.py +21 -21
  166. pygeai/tests/lab/tools/test_mappers.py +0 -1
  167. pygeai/tests/organization/limits/test_clients.py +33 -33
  168. pygeai/tests/organization/limits/test_managers.py +7 -7
  169. pygeai/tests/organization/test_clients.py +78 -60
  170. pygeai/tests/proxy/test_clients.py +1 -1
  171. pygeai/tests/proxy/test_integration.py +1 -4
  172. pygeai/tests/proxy/test_managers.py +1 -2
  173. pygeai/tests/proxy/test_servers.py +1 -2
  174. pygeai/tests/snippets/assistants/rag/delete_rag_assistant.py +0 -1
  175. pygeai/tests/snippets/assistants/rag/get_documents.py +0 -1
  176. pygeai/tests/snippets/assistants/rag/get_rag_assistant_data.py +0 -1
  177. pygeai/tests/snippets/chat/get_request_status.py +0 -1
  178. pygeai/tests/snippets/dbg/file_debugging.py +72 -0
  179. pygeai/tests/snippets/dbg/module_debugging.py +60 -0
  180. pygeai/tests/snippets/embeddings/cohere_example.py +2 -2
  181. pygeai/tests/snippets/embeddings/openai_base64_example.py +1 -1
  182. pygeai/tests/snippets/evaluation/dataset/complete_workflow_example.py +8 -8
  183. pygeai/tests/snippets/evaluation/plan/complete_workflow_example.py +5 -5
  184. pygeai/tests/snippets/evaluation/result/complete_workflow_example.py +3 -3
  185. pygeai/tests/snippets/lab/agentic_flow_example_1.py +1 -1
  186. pygeai/tests/snippets/lab/agentic_flow_example_2.py +3 -4
  187. pygeai/tests/snippets/lab/agents/create_agent_with_permissions.py +2 -2
  188. pygeai/tests/snippets/lab/agents/delete_agent.py +1 -2
  189. pygeai/tests/snippets/lab/agents/get_agent.py +1 -1
  190. pygeai/tests/snippets/lab/agents/get_agent_with_new_fields.py +10 -10
  191. pygeai/tests/snippets/lab/agents/get_sharing_link.py +0 -1
  192. pygeai/tests/snippets/lab/agents/list_agents.py +1 -1
  193. pygeai/tests/snippets/lab/agents/publish_agent_revision.py +0 -1
  194. pygeai/tests/snippets/lab/agents/update_agent_properties.py +1 -1
  195. pygeai/tests/snippets/lab/crud_ui.py +3 -5
  196. pygeai/tests/snippets/lab/processes/kbs/get_kb.py +0 -1
  197. pygeai/tests/snippets/lab/processes/kbs/list_kbs.py +0 -1
  198. pygeai/tests/snippets/lab/processes/list_processes.py +1 -1
  199. pygeai/tests/snippets/lab/samples/summarize_files.py +0 -3
  200. pygeai/tests/snippets/lab/strategies/get_reasoning_strategy.py +0 -1
  201. pygeai/tests/snippets/lab/strategies/list_reasoning_strategies.py +1 -1
  202. pygeai/tests/snippets/lab/tools/get_tool.py +1 -1
  203. pygeai/tests/snippets/lab/tools/publish_tool_revision.py +0 -1
  204. pygeai/tests/snippets/lab/tools/set_parameters.py +1 -2
  205. pygeai/tests/snippets/lab/use_cases/c_code_fixer_agent_flow.py +2 -3
  206. pygeai/tests/snippets/lab/use_cases/file_summarizer_example_2.py +1 -1
  207. pygeai/tests/snippets/lab/use_cases/update_cli_expert.py +0 -1
  208. pygeai/tests/snippets/lab/use_cases/update_lab_expert.py +0 -1
  209. pygeai/tests/snippets/lab/use_cases/update_web_designer.py +0 -1
  210. pygeai/tests/snippets/lab/use_cases/update_web_reader.py +0 -1
  211. pygeai/tests/snippets/migrate/orchestrator_examples.py +1 -1
  212. {pygeai-0.6.0b13.dist-info → pygeai-0.6.1.dist-info}/METADATA +32 -7
  213. {pygeai-0.6.0b13.dist-info → pygeai-0.6.1.dist-info}/RECORD +217 -206
  214. {pygeai-0.6.0b13.dist-info → pygeai-0.6.1.dist-info}/WHEEL +0 -0
  215. {pygeai-0.6.0b13.dist-info → pygeai-0.6.1.dist-info}/entry_points.txt +0 -0
  216. {pygeai-0.6.0b13.dist-info → pygeai-0.6.1.dist-info}/licenses/LICENSE +0 -0
  217. {pygeai-0.6.0b13.dist-info → pygeai-0.6.1.dist-info}/top_level.txt +0 -0
@@ -6,57 +6,66 @@ from pygeai.core.utils.console import Console
6
6
  def configure(option_list: list[str, str] = None):
7
7
  if not any(option_list):
8
8
  Console.write_stdout("# Configuring GEAI credentials...")
9
- alias = str(input("-> Select an alias (Leave empty to use 'default'): "))
9
+ alias = str(input("-> Select an alias for this profile (Leave empty to use 'default'): ")).strip()
10
10
  if not alias:
11
11
  alias = "default"
12
12
 
13
- api_key = str(input("-> Insert your GEAI API KEY (Leave empty to keep current value): "))
14
- if api_key:
15
- configure_api_key(api_key, alias)
13
+ auth_type = str(input("-> Which type of authentication will this profile use? \n1.API key \n2. Oauth2 \n(Type 'enter' for default (1): ")).strip()
14
+ if not auth_type or auth_type == "1":
15
+ api_key = str(input("-> Insert your GEAI API KEY (Leave empty to keep current value): ")).strip()
16
+ if api_key:
17
+ configure_api_key(api_key, alias)
18
+
19
+ elif auth_type == "2":
20
+ access_token = str(input("-> Insert your GEAI OAUTH2 ACCESS TOKEN (Leave empty to keep current value): ")).strip()
21
+ if access_token:
22
+ configure_access_token(access_token, alias)
16
23
 
17
- base_url = str(input("-> Insert your GEAI API BASE URL (Leave empty to keep current value): "))
24
+ base_url = str(input("-> Insert your GEAI API BASE URL (Leave empty to keep current value): ")).strip()
18
25
  if base_url:
19
26
  configure_base_url(base_url, alias)
20
27
 
21
- eval_url = str(input("-> Insert your GEAI API EVAL URL (Leave empty to keep current value): "))
28
+ eval_url = str(input("-> Insert your GEAI API EVAL URL (Leave empty to keep current value): ")).strip()
22
29
  if eval_url:
23
30
  configure_eval_url(eval_url, alias)
24
31
 
25
32
  else:
26
- list_alias = False
27
- remove_alias = False
28
- api_key = None
29
- base_url = None
30
- eval_url = None
31
- alias = "default"
32
-
33
- for option_flag, option_arg in option_list:
34
- if option_flag.name == "list":
35
- list_alias = True
36
- if option_flag.name == "profile_alias":
37
- alias = option_arg
38
- if option_flag.name == "api_key":
39
- api_key = option_arg
40
- if option_flag.name == "base_url":
41
- base_url = option_arg
42
- if option_flag.name == "eval_url":
43
- eval_url = option_arg
44
- if option_flag.name == "remove_alias":
45
- alias = option_arg
46
- remove_alias = True
47
-
33
+ opts = {opt.name: arg for opt, arg in option_list}
34
+
35
+ list_alias = 'list' in opts
36
+ remove_alias = 'remove_alias' in opts
37
+ alias = opts.get('remove_alias') if remove_alias else opts.get('profile_alias', 'default')
38
+ api_key = opts.get('api_key')
39
+ base_url = opts.get('base_url')
40
+ eval_url = opts.get('eval_url')
41
+ access_token = opts.get('access_token')
42
+ project_id = opts.get('project_id')
43
+ organization_id = opts.get('organization_id')
48
44
 
49
45
  if list_alias:
50
46
  display_alias_list()
51
47
  elif remove_alias:
52
48
  remove_alias_from_config(alias)
53
49
  else:
50
+ if api_key and access_token:
51
+ Console.write_stdout(
52
+ "WARNING: You're setting 2 different types of authentication for the same profile. "
53
+ "This may cause unknown behaviors. Consider using separate profiles for different "
54
+ "authentication types."
55
+ )
56
+
54
57
  if api_key:
55
58
  configure_api_key(api_key=api_key, alias=alias)
56
59
  if base_url:
57
60
  configure_base_url(base_url=base_url, alias=alias)
58
61
  if eval_url:
59
62
  configure_eval_url(eval_url=eval_url, alias=alias)
63
+ if access_token:
64
+ configure_access_token(access_token=access_token, alias=alias)
65
+ if project_id:
66
+ configure_project_id(project_id=project_id, alias=alias)
67
+ if organization_id:
68
+ configure_organization_id(organization_id=organization_id, alias=alias)
60
69
 
61
70
 
62
71
  def configure_api_key(api_key: str, alias: str = "default"):
@@ -77,6 +86,24 @@ def configure_eval_url(eval_url: str, alias: str = "default"):
77
86
  Console.write_stdout(f"GEAI API EVAL URL for alias '{alias}' saved successfully!")
78
87
 
79
88
 
89
+ def configure_access_token(access_token: str, alias: str = "default"):
90
+ settings = get_settings()
91
+ settings.set_access_token(access_token, alias)
92
+ Console.write_stdout(f"GEAI OAUTH2 ACCESS TOKEN for alias '{alias}' saved successfully!")
93
+
94
+
95
+ def configure_project_id(project_id: str, alias: str = "default"):
96
+ settings = get_settings()
97
+ settings.set_project_id(project_id, alias)
98
+ Console.write_stdout(f"GEAI PROJECT ID for alias '{alias}' saved successfully!")
99
+
100
+
101
+ def configure_organization_id(organization_id: str, alias: str = "default"):
102
+ settings = get_settings()
103
+ settings.set_organization_id(organization_id, alias)
104
+ Console.write_stdout(f"GEAI ORGANIZATION ID for alias '{alias}' saved successfully!")
105
+
106
+
80
107
  def display_alias_list():
81
108
  settings = get_settings()
82
109
  for alias, url in settings.list_aliases().items():
@@ -93,7 +120,6 @@ def remove_alias_from_config(alias: str):
93
120
  Console.write_stdout(f"Alias {alias} kept in configuration file.")
94
121
 
95
122
 
96
-
97
123
  configuration_options = (
98
124
  Option(
99
125
  "api_key",
@@ -113,6 +139,30 @@ configuration_options = (
113
139
  "Set GEAI API EVAL URL for the evaluation module",
114
140
  True
115
141
  ),
142
+ Option(
143
+ "eval_url",
144
+ ["--eval-url", "--eu"],
145
+ "Set GEAI API EVAL URL for the evaluation module",
146
+ True
147
+ ),
148
+ Option(
149
+ "access_token",
150
+ ["--access-token", "--at"],
151
+ "Set GEAI_OAUTH_ACCESS_TOKEN for Oauth2 authentication in requests",
152
+ True
153
+ ),
154
+ Option(
155
+ "project_id",
156
+ ["--project-id", "--pid"],
157
+ "Set GEAI_PROJECT_ID for header configuration in some requests",
158
+ True
159
+ ),
160
+ Option(
161
+ "organization_id",
162
+ ["--organization-id", "--oid"],
163
+ "Set GEAI_ORGANIZATION_ID for header configuration in some requests",
164
+ True
165
+ ),
116
166
  Option(
117
167
  "profile_alias",
118
168
  ["--profile-alias", "--pa"],
@@ -1,4 +1,3 @@
1
- import os
2
1
  import subprocess
3
2
  import webbrowser
4
3
  from pathlib import Path
@@ -8,6 +7,8 @@ from pygeai.cli.commands.builders import build_help_text
8
7
  from pygeai.cli.texts.help import DOCS_HELP_TEXT
9
8
  from pygeai.core.utils.console import Console
10
9
 
10
+ from importlib import util
11
+
11
12
 
12
13
  def show_help():
13
14
  help_text = build_help_text(docs_commands, DOCS_HELP_TEXT)
@@ -15,9 +16,7 @@ def show_help():
15
16
 
16
17
 
17
18
  def open_documentation():
18
- try:
19
- import sphinx
20
- except ImportError:
19
+ if not util.find_spec("sphinx"):
21
20
  Console.write_stdout(
22
21
  "Documentation dependencies (sphinx, sphinx-rtd-theme) are not installed.\n"
23
22
  "Would you like to install them now? [Y/n]: "
@@ -17,41 +17,35 @@ def show_help():
17
17
 
18
18
 
19
19
  def generate_embeddings(option_list: list):
20
- model = None
21
- encoding_format = None
20
+ input_list = []
22
21
  dimensions = None
23
- user = None
24
- input_type = None
25
22
  timeout = None
26
- cache = None
27
23
  preview = True
28
- input_list = list()
29
-
24
+ cache = None
25
+
30
26
  for option_flag, option_arg in option_list:
31
- if option_flag.name == "model":
32
- model = option_arg
33
27
  if option_flag.name == "input":
34
28
  input_list.append(option_arg)
35
- if option_flag.name == "encoding_format":
36
- encoding_format = option_arg
37
- if option_flag.name == "dimensions":
29
+ elif option_flag.name == "dimensions":
38
30
  try:
39
31
  dimensions = int(option_arg)
40
32
  except (ValueError, TypeError):
41
33
  raise WrongArgumentError("dimensions must be an integer")
42
- if option_flag.name == "user":
43
- user = option_arg
44
- if option_flag.name == "input_type":
45
- input_type = option_arg
46
- if option_flag.name == "timeout":
34
+ elif option_flag.name == "timeout":
47
35
  try:
48
36
  timeout = int(option_arg)
49
37
  except (ValueError, TypeError):
50
38
  raise WrongArgumentError("timeout must be an integer")
51
- if option_flag.name == "cache":
39
+ elif option_flag.name == "cache":
52
40
  cache = get_boolean_value(option_arg)
53
- if option_flag.name == "preview":
41
+ elif option_flag.name == "preview":
54
42
  preview = get_boolean_value(option_arg)
43
+
44
+ opts = {opt.name: arg for opt, arg in option_list}
45
+ model = opts.get('model')
46
+ encoding_format = opts.get('encoding_format')
47
+ user = opts.get('user')
48
+ input_type = opts.get('input_type')
55
49
 
56
50
  if not (model and any(input_list)):
57
51
  raise MissingRequirementException("Cannot generate embeddings without specifying model and at least one input")