aixtools 0.2.9__tar.gz → 0.2.11__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.
Potentially problematic release.
This version of aixtools might be problematic. Click here for more details.
- {aixtools-0.2.9 → aixtools-0.2.11}/PKG-INFO +2 -2
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/_version.py +3 -3
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/auth/auth.py +30 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/utils/config.py +4 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/pyproject.toml +1 -1
- {aixtools-0.2.9 → aixtools-0.2.11}/README.md +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/.chainlit/config.toml +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/.chainlit/translations/bn.json +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/.chainlit/translations/en-US.json +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/.chainlit/translations/gu.json +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/.chainlit/translations/he-IL.json +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/.chainlit/translations/hi.json +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/.chainlit/translations/ja.json +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/.chainlit/translations/kn.json +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/.chainlit/translations/ml.json +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/.chainlit/translations/mr.json +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/.chainlit/translations/nl.json +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/.chainlit/translations/ta.json +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/.chainlit/translations/te.json +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/.chainlit/translations/zh-CN.json +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/__init__.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/a2a/app.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/a2a/google_sdk/__init__.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/a2a/google_sdk/pydantic_ai_adapter/agent_executor.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/a2a/google_sdk/pydantic_ai_adapter/storage.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/a2a/google_sdk/remote_agent_connection.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/a2a/google_sdk/utils.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/a2a/utils.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/agents/__init__.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/agents/agent.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/agents/agent_batch.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/agents/print_nodes.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/agents/prompt.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/app.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/auth/__init__.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/chainlit.md +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/compliance/__init__.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/compliance/private_data.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/context.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/db/__init__.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/db/database.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/db/vector_db.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/evals/__init__.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/evals/__main__.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/evals/dataset.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/evals/discovery.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/evals/run_evals.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/google/client.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/log_view/__init__.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/log_view/app.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/log_view/display.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/log_view/export.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/log_view/filters.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/log_view/log_utils.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/log_view/node_summary.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/logfilters/__init__.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/logfilters/context_filter.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/logging/__init__.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/logging/log_objects.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/logging/logging_config.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/logging/mcp_log_models.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/logging/mcp_logger.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/logging/model_patch_logging.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/logging/open_telemetry.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/mcp/__init__.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/mcp/client.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/mcp/example_client.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/mcp/example_server.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/mcp/fast_mcp_log.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/mcp/faulty_mcp.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/model_patch/model_patch.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/server/__init__.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/server/app_mounter.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/server/path.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/server/utils.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/testing/__init__.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/testing/aix_test_model.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/testing/mock_tool.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/testing/model_patch_cache.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/tools/doctor/__init__.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/tools/doctor/mcp_tool_doctor.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/tools/doctor/tool_doctor.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/tools/doctor/tool_recommendation.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/utils/__init__.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/utils/chainlit/cl_agent_show.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/utils/chainlit/cl_utils.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/utils/config_util.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/utils/enum_with_description.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/utils/files.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/utils/persisted_dict.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/utils/utils.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/vault/__init__.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools/vault/vault.py +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/aixtools.egg-info/SOURCES.txt +0 -0
- {aixtools-0.2.9 → aixtools-0.2.11}/setup.cfg +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: aixtools
|
|
3
|
-
Version: 0.2.
|
|
3
|
+
Version: 0.2.11
|
|
4
4
|
Summary: Tools for AI exploration and debugging
|
|
5
5
|
Requires-Python: >=3.11.2
|
|
6
6
|
Description-Content-Type: text/markdown
|
|
@@ -9,7 +9,7 @@ Requires-Dist: cachebox>=5.0.1
|
|
|
9
9
|
Requires-Dist: chainlit>=2.5.5
|
|
10
10
|
Requires-Dist: colorlog>=6.9.0
|
|
11
11
|
Requires-Dist: fasta2a>=0.5.0
|
|
12
|
-
Requires-Dist: fastmcp>=2.
|
|
12
|
+
Requires-Dist: fastmcp>=2.11.0
|
|
13
13
|
Requires-Dist: hvac>=2.3.0
|
|
14
14
|
Requires-Dist: ipykernel>=6.29.5
|
|
15
15
|
Requires-Dist: langchain-chroma>=0.2.3
|
|
@@ -28,7 +28,7 @@ version_tuple: VERSION_TUPLE
|
|
|
28
28
|
commit_id: COMMIT_ID
|
|
29
29
|
__commit_id__: COMMIT_ID
|
|
30
30
|
|
|
31
|
-
__version__ = version = '0.2.
|
|
32
|
-
__version_tuple__ = version_tuple = (0, 2,
|
|
31
|
+
__version__ = version = '0.2.11'
|
|
32
|
+
__version_tuple__ = version_tuple = (0, 2, 11)
|
|
33
33
|
|
|
34
|
-
__commit_id__ = commit_id = '
|
|
34
|
+
__commit_id__ = commit_id = 'g66be32dcf'
|
|
@@ -7,7 +7,11 @@ import logging
|
|
|
7
7
|
|
|
8
8
|
import jwt
|
|
9
9
|
from fastapi import HTTPException
|
|
10
|
+
from fastmcp.server.auth.auth import AuthProvider
|
|
10
11
|
from jwt import ExpiredSignatureError, InvalidAudienceError, InvalidIssuerError, InvalidSignatureError, PyJWKClient
|
|
12
|
+
from mcp.server.auth.provider import (
|
|
13
|
+
AccessToken,
|
|
14
|
+
)
|
|
11
15
|
|
|
12
16
|
from aixtools.utils import config
|
|
13
17
|
|
|
@@ -147,3 +151,29 @@ class AccessTokenVerifier:
|
|
|
147
151
|
AuthTokenErrorCode.MISSING_GROUPS_ERROR,
|
|
148
152
|
f"Could not find any group in JWT token, matching: {self.authorized_groups}",
|
|
149
153
|
)
|
|
154
|
+
|
|
155
|
+
|
|
156
|
+
class AccessTokenAuthProvider(AuthProvider):
|
|
157
|
+
"""Authentication provider for MCP servers for validating, authorizing and extracting access tokens."""
|
|
158
|
+
|
|
159
|
+
def __init__(self) -> None:
|
|
160
|
+
super().__init__()
|
|
161
|
+
self.token_verifier = AccessTokenVerifier()
|
|
162
|
+
self.app_scope = config.APP_DEFAULT_SCOPE
|
|
163
|
+
|
|
164
|
+
async def verify_token(self, token: str) -> AccessToken:
|
|
165
|
+
"""Verify the access token and return an AccessToken object."""
|
|
166
|
+
|
|
167
|
+
logger.info("Received verify token request")
|
|
168
|
+
claims = self.token_verifier.verify(token)
|
|
169
|
+
scopes = claims.get("scp", "")
|
|
170
|
+
self.token_verifier.authorize_claims(claims, self.app_scope)
|
|
171
|
+
|
|
172
|
+
scopes_arr = []
|
|
173
|
+
if scopes:
|
|
174
|
+
scopes_arr = scopes.split(" ")
|
|
175
|
+
|
|
176
|
+
logger.info("Authorized the token")
|
|
177
|
+
return AccessToken(
|
|
178
|
+
token=token, client_id=self.token_verifier.api_id, scopes=scopes_arr, expires_at=claims.get("exp", None)
|
|
179
|
+
)
|
|
@@ -138,3 +138,7 @@ APP_TENANT_ID = get_variable_env("APP_TENANT_ID")
|
|
|
138
138
|
|
|
139
139
|
# used for token authorization check
|
|
140
140
|
APP_AUTHORIZED_GROUPS = get_variable_env("APP_AUTHORIZED_GROUPS", allow_empty=True)
|
|
141
|
+
|
|
142
|
+
# used to skip authorization in local tests if required.
|
|
143
|
+
SKIP_MCP_AUTHORIZATION = str2bool(get_variable_env("SKIP_MCP_AUTHORIZATION", True, False))
|
|
144
|
+
APP_DEFAULT_SCOPE = get_variable_env("APP_DEFAULT_SCOPE", allow_empty=True)
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{aixtools-0.2.9 → aixtools-0.2.11}/aixtools/a2a/google_sdk/pydantic_ai_adapter/agent_executor.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|