deepset-mcp 0.0.3rc1__py3-none-any.whl → 0.0.4__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.
- deepset_mcp/__init__.py +10 -0
- deepset_mcp/api/__init__.py +4 -0
- deepset_mcp/api/client.py +4 -0
- deepset_mcp/api/custom_components/__init__.py +4 -0
- deepset_mcp/api/custom_components/models.py +4 -0
- deepset_mcp/api/custom_components/protocols.py +4 -0
- deepset_mcp/api/custom_components/resource.py +4 -0
- deepset_mcp/api/exceptions.py +4 -0
- deepset_mcp/api/haystack_service/__init__.py +4 -0
- deepset_mcp/api/haystack_service/protocols.py +4 -0
- deepset_mcp/api/haystack_service/resource.py +4 -0
- deepset_mcp/api/indexes/__init__.py +4 -0
- deepset_mcp/api/indexes/models.py +4 -0
- deepset_mcp/api/indexes/protocols.py +4 -0
- deepset_mcp/api/indexes/resource.py +4 -0
- deepset_mcp/api/integrations/__init__.py +4 -0
- deepset_mcp/api/integrations/models.py +4 -0
- deepset_mcp/api/integrations/protocols.py +4 -0
- deepset_mcp/api/integrations/resource.py +4 -0
- deepset_mcp/api/pipeline/__init__.py +4 -0
- deepset_mcp/api/pipeline/log_level.py +4 -0
- deepset_mcp/api/pipeline/models.py +4 -0
- deepset_mcp/api/pipeline/protocols.py +8 -0
- deepset_mcp/api/pipeline/resource.py +4 -0
- deepset_mcp/api/pipeline_template/__init__.py +4 -0
- deepset_mcp/api/pipeline_template/models.py +4 -0
- deepset_mcp/api/pipeline_template/protocols.py +4 -0
- deepset_mcp/api/pipeline_template/resource.py +4 -0
- deepset_mcp/api/protocols.py +4 -0
- deepset_mcp/api/secrets/__init__.py +4 -0
- deepset_mcp/api/secrets/models.py +4 -0
- deepset_mcp/api/secrets/protocols.py +4 -0
- deepset_mcp/api/secrets/resource.py +4 -0
- deepset_mcp/api/shared_models.py +4 -0
- deepset_mcp/api/transport.py +4 -0
- deepset_mcp/api/user/__init__.py +4 -0
- deepset_mcp/api/user/protocols.py +4 -0
- deepset_mcp/api/user/resource.py +4 -0
- deepset_mcp/api/workspace/__init__.py +4 -0
- deepset_mcp/api/workspace/models.py +4 -0
- deepset_mcp/api/workspace/protocols.py +4 -0
- deepset_mcp/api/workspace/resource.py +4 -0
- deepset_mcp/config.py +8 -0
- deepset_mcp/initialize_embedding_model.py +4 -0
- deepset_mcp/main.py +8 -0
- deepset_mcp/store.py +4 -0
- deepset_mcp/tool_factory.py +11 -4
- deepset_mcp/tools/__init__.py +4 -0
- deepset_mcp/tools/custom_components.py +4 -0
- deepset_mcp/tools/doc_search.py +4 -0
- deepset_mcp/tools/haystack_service.py +4 -0
- deepset_mcp/tools/haystack_service_models.py +4 -0
- deepset_mcp/tools/indexes.py +4 -0
- deepset_mcp/tools/model_protocol.py +4 -0
- deepset_mcp/tools/pipeline.py +4 -0
- deepset_mcp/tools/pipeline_template.py +4 -0
- deepset_mcp/tools/secrets.py +4 -0
- deepset_mcp/tools/tokonomics/__init__.py +4 -0
- deepset_mcp/tools/tokonomics/decorators.py +4 -0
- deepset_mcp/tools/tokonomics/explorer.py +4 -0
- deepset_mcp/tools/tokonomics/object_store.py +4 -0
- deepset_mcp/tools/workspace.py +4 -0
- deepset_mcp-0.0.4.dist-info/METADATA +761 -0
- deepset_mcp-0.0.4.dist-info/RECORD +70 -0
- {deepset_mcp-0.0.3rc1.dist-info → deepset_mcp-0.0.4.dist-info}/entry_points.txt +0 -1
- deepset_mcp-0.0.4.dist-info/licenses/LICENSE +202 -0
- deepset_mcp/agents/__init__.py +0 -0
- deepset_mcp/agents/debugging/__init__.py +0 -0
- deepset_mcp/agents/debugging/debugging_agent.py +0 -37
- deepset_mcp/agents/debugging/system_prompt.md +0 -214
- deepset_mcp/agents/generalist/__init__.py +0 -0
- deepset_mcp/agents/generalist/generalist_agent.py +0 -38
- deepset_mcp/agents/generalist/system_prompt.md +0 -241
- deepset_mcp/benchmark/README.md +0 -425
- deepset_mcp/benchmark/__init__.py +0 -1
- deepset_mcp/benchmark/agent_configs/debugging_agent.yml +0 -10
- deepset_mcp/benchmark/agent_configs/generalist_agent.yml +0 -6
- deepset_mcp/benchmark/dp_validation_error_analysis/__init__.py +0 -0
- deepset_mcp/benchmark/dp_validation_error_analysis/eda.ipynb +0 -757
- deepset_mcp/benchmark/dp_validation_error_analysis/prepare_interaction_data.ipynb +0 -167
- deepset_mcp/benchmark/dp_validation_error_analysis/preprocessing_utils.py +0 -213
- deepset_mcp/benchmark/runner/__init__.py +0 -0
- deepset_mcp/benchmark/runner/agent_benchmark_runner.py +0 -561
- deepset_mcp/benchmark/runner/agent_loader.py +0 -110
- deepset_mcp/benchmark/runner/cli.py +0 -39
- deepset_mcp/benchmark/runner/cli_agent.py +0 -373
- deepset_mcp/benchmark/runner/cli_index.py +0 -71
- deepset_mcp/benchmark/runner/cli_pipeline.py +0 -73
- deepset_mcp/benchmark/runner/cli_tests.py +0 -226
- deepset_mcp/benchmark/runner/cli_utils.py +0 -61
- deepset_mcp/benchmark/runner/config.py +0 -73
- deepset_mcp/benchmark/runner/config_loader.py +0 -64
- deepset_mcp/benchmark/runner/interactive.py +0 -140
- deepset_mcp/benchmark/runner/models.py +0 -203
- deepset_mcp/benchmark/runner/repl.py +0 -67
- deepset_mcp/benchmark/runner/setup_actions.py +0 -238
- deepset_mcp/benchmark/runner/streaming.py +0 -360
- deepset_mcp/benchmark/runner/teardown_actions.py +0 -196
- deepset_mcp/benchmark/runner/tracing.py +0 -21
- deepset_mcp/benchmark/tasks/chat_rag_answers_wrong_format.yml +0 -16
- deepset_mcp/benchmark/tasks/documents_output_wrong.yml +0 -13
- deepset_mcp/benchmark/tasks/jinja_str_instead_of_complex_type.yml +0 -11
- deepset_mcp/benchmark/tasks/jinja_syntax_error.yml +0 -11
- deepset_mcp/benchmark/tasks/missing_output_mapping.yml +0 -14
- deepset_mcp/benchmark/tasks/no_query_input.yml +0 -13
- deepset_mcp/benchmark/tasks/pipelines/chat_agent_jinja_str.yml +0 -141
- deepset_mcp/benchmark/tasks/pipelines/chat_agent_jinja_syntax.yml +0 -141
- deepset_mcp/benchmark/tasks/pipelines/chat_rag_answers_wrong_format.yml +0 -181
- deepset_mcp/benchmark/tasks/pipelines/chat_rag_missing_output_mapping.yml +0 -189
- deepset_mcp/benchmark/tasks/pipelines/rag_documents_wrong_format.yml +0 -193
- deepset_mcp/benchmark/tasks/pipelines/rag_no_query_input.yml +0 -191
- deepset_mcp/benchmark/tasks/pipelines/standard_index.yml +0 -167
- deepset_mcp-0.0.3rc1.dist-info/METADATA +0 -289
- deepset_mcp-0.0.3rc1.dist-info/RECORD +0 -115
- {deepset_mcp-0.0.3rc1.dist-info → deepset_mcp-0.0.4.dist-info}/WHEEL +0 -0
deepset_mcp/__init__.py
CHANGED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
# SPDX-FileCopyrightText: 2025-present deepset GmbH <info@deepset.ai>
|
|
2
|
+
#
|
|
3
|
+
# SPDX-License-Identifier: Apache-2.0
|
|
4
|
+
|
|
5
|
+
import importlib.metadata
|
|
6
|
+
|
|
7
|
+
try:
|
|
8
|
+
__version__ = importlib.metadata.version(__name__)
|
|
9
|
+
except importlib.metadata.PackageNotFoundError:
|
|
10
|
+
__version__ = "0.0.0" # Fallback for development mode
|
deepset_mcp/api/__init__.py
CHANGED
deepset_mcp/api/client.py
CHANGED
deepset_mcp/api/exceptions.py
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
# SPDX-FileCopyrightText: 2025-present deepset GmbH <info@deepset.ai>
|
|
2
|
+
#
|
|
3
|
+
# SPDX-License-Identifier: Apache-2.0
|
|
4
|
+
|
|
1
5
|
from deepset_mcp.api.exceptions import UnexpectedAPIError
|
|
2
6
|
from deepset_mcp.api.indexes.models import Index, IndexList
|
|
3
7
|
from deepset_mcp.api.indexes.protocols import IndexResourceProtocol
|
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
# SPDX-FileCopyrightText: 2025-present deepset GmbH <info@deepset.ai>
|
|
2
|
+
#
|
|
3
|
+
# SPDX-License-Identifier: Apache-2.0
|
|
4
|
+
|
|
1
5
|
from collections.abc import AsyncIterator
|
|
2
6
|
from typing import Any, Protocol
|
|
3
7
|
|
|
@@ -81,3 +85,7 @@ class PipelineResourceProtocol(Protocol):
|
|
|
81
85
|
) -> AsyncIterator[DeepsetStreamEvent]:
|
|
82
86
|
"""Search using a pipeline with response streaming."""
|
|
83
87
|
...
|
|
88
|
+
|
|
89
|
+
async def delete(self, pipeline_name: str) -> NoContentResponse:
|
|
90
|
+
"""Delete a pipeline."""
|
|
91
|
+
...
|
deepset_mcp/api/protocols.py
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
# SPDX-FileCopyrightText: 2025-present deepset GmbH <info@deepset.ai>
|
|
2
|
+
#
|
|
3
|
+
# SPDX-License-Identifier: Apache-2.0
|
|
4
|
+
|
|
1
5
|
from contextlib import AbstractAsyncContextManager
|
|
2
6
|
from types import TracebackType
|
|
3
7
|
from typing import Any, Literal, Protocol, Self, TypeVar, overload
|
deepset_mcp/api/shared_models.py
CHANGED
deepset_mcp/api/transport.py
CHANGED
deepset_mcp/api/user/__init__.py
CHANGED
deepset_mcp/api/user/resource.py
CHANGED
deepset_mcp/config.py
CHANGED
|
@@ -1,5 +1,11 @@
|
|
|
1
|
+
# SPDX-FileCopyrightText: 2025-present deepset GmbH <info@deepset.ai>
|
|
2
|
+
#
|
|
3
|
+
# SPDX-License-Identifier: Apache-2.0
|
|
4
|
+
|
|
1
5
|
"""This module contains static configuration for the deepset MCP server."""
|
|
2
6
|
|
|
7
|
+
from deepset_mcp import __version__
|
|
8
|
+
|
|
3
9
|
# We need this mapping to which environment variables integrations are mapped to
|
|
4
10
|
# The mapping is maintained in the pipeline operator:
|
|
5
11
|
# https://github.com/deepset-ai/dc-pipeline-operator/blob/main/dc_operators/config.py#L279
|
|
@@ -23,3 +29,5 @@ TOKEN_DOMAIN_MAPPING = {
|
|
|
23
29
|
}
|
|
24
30
|
|
|
25
31
|
DEEPSET_DOCS_DEFAULT_SHARE_URL = "https://cloud.deepset.ai/shared_prototypes?share_token=prototype_eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJleHAiOjE3ODM0MjE0OTguNTk5LCJhdWQiOiJleHRlcm5hbCB1c2VyIiwiaXNzIjoiZEMiLCJ3b3Jrc3BhY2VfaWQiOiI4YzI0ZjExMi1iMjljLTQ5MWMtOTkzOS1hZTkxMDRhNTQyMWMiLCJ3b3Jrc3BhY2VfbmFtZSI6ImRjLWRvY3MtY29udGVudCIsIm9yZ2FuaXphdGlvbl9pZCI6ImNhOWYxNGQ0LWMyYzktNDYwZC04ZDI2LWY4Y2IwYWNhMDI0ZiIsInNoYXJlX2lkIjoiY2Y3MTA3ODAtOThmNi00MzlmLThiNzYtMmMwNDkyODNiMDZhIiwibG9naW5fcmVxdWlyZWQiOmZhbHNlfQ.5j6DCNRQ1_KB8lhIJqHyw2hBIleEW1_Y_UBuH6MTYY0"
|
|
32
|
+
|
|
33
|
+
DEFAULT_CLIENT_HEADER = {"headers": {"User-Agent": f"deepset-mcp/{__version__}"}}
|
deepset_mcp/main.py
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
# SPDX-FileCopyrightText: 2025-present deepset GmbH <info@deepset.ai>
|
|
2
|
+
#
|
|
3
|
+
# SPDX-License-Identifier: Apache-2.0
|
|
4
|
+
|
|
1
5
|
import argparse
|
|
2
6
|
import asyncio
|
|
3
7
|
import logging
|
|
@@ -106,11 +110,13 @@ def main() -> None:
|
|
|
106
110
|
)
|
|
107
111
|
parser.add_argument(
|
|
108
112
|
"--docs-share-url",
|
|
113
|
+
"-d",
|
|
109
114
|
default=DEEPSET_DOCS_DEFAULT_SHARE_URL,
|
|
110
115
|
help="Deepset docs search share URL (env DEEPSET_DOCS_SHARE_URL)",
|
|
111
116
|
)
|
|
112
117
|
parser.add_argument(
|
|
113
118
|
"--workspace-mode",
|
|
119
|
+
"-m",
|
|
114
120
|
choices=[WorkspaceMode.STATIC, WorkspaceMode.DYNAMIC],
|
|
115
121
|
default=WorkspaceMode.STATIC,
|
|
116
122
|
help=(
|
|
@@ -120,11 +126,13 @@ def main() -> None:
|
|
|
120
126
|
)
|
|
121
127
|
parser.add_argument(
|
|
122
128
|
"--tools",
|
|
129
|
+
"-t",
|
|
123
130
|
nargs="*",
|
|
124
131
|
help="Space-separated list of tools to register (default: all)",
|
|
125
132
|
)
|
|
126
133
|
parser.add_argument(
|
|
127
134
|
"--list-tools",
|
|
135
|
+
"-l",
|
|
128
136
|
action="store_true",
|
|
129
137
|
help="List all available tools and exit",
|
|
130
138
|
)
|
deepset_mcp/store.py
CHANGED
deepset_mcp/tool_factory.py
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
# SPDX-FileCopyrightText: 2025-present deepset GmbH <info@deepset.ai>
|
|
2
|
+
#
|
|
3
|
+
# SPDX-License-Identifier: Apache-2.0
|
|
4
|
+
|
|
1
5
|
"""Factory for creating workspace-aware MCP tools."""
|
|
2
6
|
|
|
3
7
|
import functools
|
|
@@ -12,6 +16,7 @@ from typing import Any
|
|
|
12
16
|
from mcp.server.fastmcp import FastMCP
|
|
13
17
|
|
|
14
18
|
from deepset_mcp.api.client import AsyncDeepsetClient
|
|
19
|
+
from deepset_mcp.config import DEFAULT_CLIENT_HEADER
|
|
15
20
|
from deepset_mcp.initialize_embedding_model import get_initialized_model
|
|
16
21
|
from deepset_mcp.store import STORE
|
|
17
22
|
from deepset_mcp.tools.custom_components import (
|
|
@@ -117,7 +122,9 @@ async def search_docs(query: str) -> str:
|
|
|
117
122
|
:param query: The search query to execute against the documentation.
|
|
118
123
|
:returns: The formatted search results from the documentation.
|
|
119
124
|
"""
|
|
120
|
-
async with AsyncDeepsetClient(
|
|
125
|
+
async with AsyncDeepsetClient(
|
|
126
|
+
api_key=os.environ["DEEPSET_DOCS_API_KEY"], transport_config=DEFAULT_CLIENT_HEADER
|
|
127
|
+
) as client:
|
|
121
128
|
response = await search_docs_tool(
|
|
122
129
|
client=client,
|
|
123
130
|
workspace=os.environ["DEEPSET_DOCS_WORKSPACE"],
|
|
@@ -373,14 +380,14 @@ def create_enhanced_tool(
|
|
|
373
380
|
|
|
374
381
|
async def workspace_environment_wrapper(**kwargs: Any) -> Any:
|
|
375
382
|
ws = workspace or get_workspace_from_env()
|
|
376
|
-
async with AsyncDeepsetClient() as client:
|
|
383
|
+
async with AsyncDeepsetClient(transport_config=DEFAULT_CLIENT_HEADER) as client:
|
|
377
384
|
return await decorated_func(client=client, workspace=ws, **kwargs)
|
|
378
385
|
|
|
379
386
|
wrapper = workspace_environment_wrapper
|
|
380
387
|
else: # DYNAMIC mode
|
|
381
388
|
|
|
382
389
|
async def workspace_explicit_wrapper(**kwargs: Any) -> Any:
|
|
383
|
-
async with AsyncDeepsetClient() as client:
|
|
390
|
+
async with AsyncDeepsetClient(transport_config=DEFAULT_CLIENT_HEADER) as client:
|
|
384
391
|
# The first argument is the workspace, which must be passed by keyword.
|
|
385
392
|
return await decorated_func(client=client, **kwargs)
|
|
386
393
|
|
|
@@ -388,7 +395,7 @@ def create_enhanced_tool(
|
|
|
388
395
|
else: # Client-only tools
|
|
389
396
|
|
|
390
397
|
async def client_only_wrapper(**kwargs: Any) -> Any:
|
|
391
|
-
async with AsyncDeepsetClient() as client:
|
|
398
|
+
async with AsyncDeepsetClient(transport_config=DEFAULT_CLIENT_HEADER) as client:
|
|
392
399
|
return await decorated_func(client=client, **kwargs)
|
|
393
400
|
|
|
394
401
|
wrapper = client_only_wrapper
|
deepset_mcp/tools/__init__.py
CHANGED
deepset_mcp/tools/doc_search.py
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
# SPDX-FileCopyrightText: 2025-present deepset GmbH <info@deepset.ai>
|
|
2
|
+
#
|
|
3
|
+
# SPDX-License-Identifier: Apache-2.0
|
|
4
|
+
|
|
1
5
|
from deepset_mcp.api.exceptions import BadRequestError, ResourceNotFoundError, UnexpectedAPIError
|
|
2
6
|
from deepset_mcp.api.pipeline.models import DeepsetSearchResponse
|
|
3
7
|
from deepset_mcp.api.protocols import AsyncClientProtocol
|
deepset_mcp/tools/indexes.py
CHANGED
|
@@ -1,3 +1,7 @@
|
|
|
1
|
+
# SPDX-FileCopyrightText: 2025-present deepset GmbH <info@deepset.ai>
|
|
2
|
+
#
|
|
3
|
+
# SPDX-License-Identifier: Apache-2.0
|
|
4
|
+
|
|
1
5
|
from deepset_mcp.api.exceptions import BadRequestError, ResourceNotFoundError, UnexpectedAPIError
|
|
2
6
|
from deepset_mcp.api.indexes.models import Index, IndexList
|
|
3
7
|
from deepset_mcp.api.pipeline import PipelineValidationResult
|
deepset_mcp/tools/pipeline.py
CHANGED
deepset_mcp/tools/secrets.py
CHANGED
deepset_mcp/tools/workspace.py
CHANGED