Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Community: Marqo Index Setting GET Request Updated according to 2.x API version while keep backward compatability for 1.5.x #28342

Merged
merged 3 commits into from
Nov 26, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 6 additions & 3 deletions libs/community/langchain_community/vectorstores/marqo.py
Original file line number Diff line number Diff line change
Expand Up @@ -109,9 +109,12 @@ def add_texts(
List[str]: The list of ids that were added.
"""

if self._client.index(self._index_name).get_settings()["index_defaults"][
"treat_urls_and_pointers_as_images"
]:
settings = self._client.index(self._index_name).get_settings()
if (
"index_defaults" in settings
and settings["index_defaults"]["treat_urls_and_pointers_as_images"]
or settings.get("treat_urls_and_pointers_as_images")
):
raise ValueError(
"Marqo.add_texts is disabled for multimodal indexes. To add documents "
"with a multimodal index use the Python client for Marqo directly."
Expand Down
Loading