suse-documentation-mcp-server 0.14.0__tar.gz → 0.17.0__tar.gz
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.
- {suse_documentation_mcp_server-0.14.0 → suse_documentation_mcp_server-0.17.0}/PKG-INFO +3 -3
- {suse_documentation_mcp_server-0.14.0 → suse_documentation_mcp_server-0.17.0}/pyproject.toml +3 -3
- {suse_documentation_mcp_server-0.14.0 → suse_documentation_mcp_server-0.17.0}/server/search_suse_documentation.py +20 -13
- {suse_documentation_mcp_server-0.14.0 → suse_documentation_mcp_server-0.17.0}/suse_documentation_mcp_server.egg-info/PKG-INFO +3 -3
- {suse_documentation_mcp_server-0.14.0 → suse_documentation_mcp_server-0.17.0}/suse_documentation_mcp_server.egg-info/requires.txt +2 -2
- {suse_documentation_mcp_server-0.14.0 → suse_documentation_mcp_server-0.17.0}/README.md +0 -0
- {suse_documentation_mcp_server-0.14.0 → suse_documentation_mcp_server-0.17.0}/setup.cfg +0 -0
- {suse_documentation_mcp_server-0.14.0 → suse_documentation_mcp_server-0.17.0}/suse_documentation_mcp_server.egg-info/SOURCES.txt +0 -0
- {suse_documentation_mcp_server-0.14.0 → suse_documentation_mcp_server-0.17.0}/suse_documentation_mcp_server.egg-info/dependency_links.txt +0 -0
- {suse_documentation_mcp_server-0.14.0 → suse_documentation_mcp_server-0.17.0}/suse_documentation_mcp_server.egg-info/entry_points.txt +0 -0
- {suse_documentation_mcp_server-0.14.0 → suse_documentation_mcp_server-0.17.0}/suse_documentation_mcp_server.egg-info/top_level.txt +0 -0
@@ -1,11 +1,11 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: suse-documentation-mcp-server
|
3
|
-
Version: 0.
|
3
|
+
Version: 0.17.0
|
4
4
|
Summary: Add your description here
|
5
5
|
Requires-Python: >=3.12
|
6
6
|
Description-Content-Type: text/markdown
|
7
7
|
Requires-Dist: httpx>=0.28.1
|
8
|
-
Requires-Dist: mcp[cli]
|
9
|
-
Requires-Dist: pydantic>=2.
|
8
|
+
Requires-Dist: mcp[cli]~=1.6.0
|
9
|
+
Requires-Dist: pydantic>=2.10.3
|
10
10
|
Requires-Dist: python-dotenv>=1.1.0
|
11
11
|
Requires-Dist: requests>=2.32.3
|
{suse_documentation_mcp_server-0.14.0 → suse_documentation_mcp_server-0.17.0}/pyproject.toml
RENAMED
@@ -1,13 +1,13 @@
|
|
1
1
|
[project]
|
2
2
|
name = "suse-documentation-mcp-server"
|
3
|
-
version = "0.
|
3
|
+
version = "0.17.0"
|
4
4
|
description = "Add your description here"
|
5
5
|
readme = "README.md"
|
6
6
|
requires-python = ">=3.12"
|
7
7
|
dependencies = [
|
8
8
|
"httpx>=0.28.1",
|
9
|
-
"mcp[cli]
|
10
|
-
"pydantic>=2.
|
9
|
+
"mcp[cli]~=1.6.0",
|
10
|
+
"pydantic>=2.10.3",
|
11
11
|
"python-dotenv>=1.1.0",
|
12
12
|
"requests>=2.32.3",
|
13
13
|
]
|
@@ -4,6 +4,8 @@ import os
|
|
4
4
|
from dotenv import load_dotenv
|
5
5
|
from typing import Any
|
6
6
|
from mcp.server.fastmcp import FastMCP
|
7
|
+
from pydantic import Field
|
8
|
+
from concurrent.futures import ThreadPoolExecutor
|
7
9
|
|
8
10
|
load_dotenv()
|
9
11
|
|
@@ -74,14 +76,16 @@ def get_web_search_results_from_oi(query):
|
|
74
76
|
return combined_response
|
75
77
|
|
76
78
|
@mcp.tool()
|
77
|
-
async def get_web_search_results(
|
79
|
+
async def get_web_search_results(
|
80
|
+
queries: list[str] = Field(
|
81
|
+
description="One or more concise, keyword-focused search queries. Use keywords relevant to SUSE documentation.",
|
82
|
+
),
|
83
|
+
) -> str:
|
78
84
|
"""
|
79
85
|
Search SUSE documentation using web search and return results.
|
80
86
|
|
81
87
|
This function is designed to perform a web search on the SUSE documentation
|
82
|
-
for a given query and return the results.
|
83
|
-
a string, JSON object, or dictionary, normalizes it, performs the web search,
|
84
|
-
and returns a formatted string containing the content from the search results.
|
88
|
+
for a given query and return the results.
|
85
89
|
|
86
90
|
Parameters:
|
87
91
|
- query (str): The search query string to be used for the web search.
|
@@ -89,23 +93,26 @@ async def get_web_search_results(query: str) -> str:
|
|
89
93
|
Returns:
|
90
94
|
str: Combined content from the search results, cleaned and formatted
|
91
95
|
"""
|
92
|
-
print("Entered get_web_search_results:",
|
96
|
+
print("Entered get_web_search_results:", queries)
|
97
|
+
|
93
98
|
try:
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
|
98
|
-
|
99
|
+
if not queries:
|
100
|
+
raise ValueError("Search called with no queries.")
|
101
|
+
|
102
|
+
with ThreadPoolExecutor() as executor:
|
103
|
+
results = list(executor.map(get_web_search_results_from_oi, queries, timeout=10))
|
104
|
+
|
105
|
+
return results
|
99
106
|
except Exception as e:
|
100
|
-
return f"Error performing web search: {str(e)}\n\n{
|
107
|
+
return f"Error performing web search: {str(e)}\n\n{queries}"
|
101
108
|
|
102
109
|
|
103
110
|
def main():
|
104
111
|
"""Main entry point for the script."""
|
105
112
|
# Initialize and run the server
|
106
|
-
mcp.run(
|
113
|
+
mcp.run()
|
107
114
|
|
108
115
|
if __name__ == "__main__":
|
109
116
|
# Initialize and run the server
|
110
|
-
|
117
|
+
main()
|
111
118
|
|
@@ -1,11 +1,11 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: suse-documentation-mcp-server
|
3
|
-
Version: 0.
|
3
|
+
Version: 0.17.0
|
4
4
|
Summary: Add your description here
|
5
5
|
Requires-Python: >=3.12
|
6
6
|
Description-Content-Type: text/markdown
|
7
7
|
Requires-Dist: httpx>=0.28.1
|
8
|
-
Requires-Dist: mcp[cli]
|
9
|
-
Requires-Dist: pydantic>=2.
|
8
|
+
Requires-Dist: mcp[cli]~=1.6.0
|
9
|
+
Requires-Dist: pydantic>=2.10.3
|
10
10
|
Requires-Dist: python-dotenv>=1.1.0
|
11
11
|
Requires-Dist: requests>=2.32.3
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|