fast-agent-mcp 0.2.40__py3-none-any.whl → 0.2.42__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.
Potentially problematic release.
This version of fast-agent-mcp might be problematic. Click here for more details.
- {fast_agent_mcp-0.2.40.dist-info → fast_agent_mcp-0.2.42.dist-info}/METADATA +2 -1
- {fast_agent_mcp-0.2.40.dist-info → fast_agent_mcp-0.2.42.dist-info}/RECORD +45 -40
- {fast_agent_mcp-0.2.40.dist-info → fast_agent_mcp-0.2.42.dist-info}/entry_points.txt +2 -2
- mcp_agent/agents/base_agent.py +111 -1
- mcp_agent/cli/__main__.py +29 -3
- mcp_agent/cli/commands/check_config.py +140 -81
- mcp_agent/cli/commands/go.py +151 -38
- mcp_agent/cli/commands/quickstart.py +6 -2
- mcp_agent/cli/commands/server_helpers.py +106 -0
- mcp_agent/cli/constants.py +25 -0
- mcp_agent/cli/main.py +1 -1
- mcp_agent/config.py +111 -44
- mcp_agent/core/agent_app.py +104 -15
- mcp_agent/core/agent_types.py +5 -1
- mcp_agent/core/direct_decorators.py +38 -0
- mcp_agent/core/direct_factory.py +18 -4
- mcp_agent/core/enhanced_prompt.py +173 -13
- mcp_agent/core/fastagent.py +4 -0
- mcp_agent/core/interactive_prompt.py +37 -37
- mcp_agent/core/usage_display.py +11 -1
- mcp_agent/core/validation.py +21 -2
- mcp_agent/human_input/elicitation_form.py +53 -21
- mcp_agent/llm/augmented_llm.py +28 -9
- mcp_agent/llm/augmented_llm_silent.py +48 -0
- mcp_agent/llm/model_database.py +20 -0
- mcp_agent/llm/model_factory.py +21 -0
- mcp_agent/llm/provider_key_manager.py +22 -8
- mcp_agent/llm/provider_types.py +20 -12
- mcp_agent/llm/providers/augmented_llm_anthropic.py +7 -2
- mcp_agent/llm/providers/augmented_llm_azure.py +7 -1
- mcp_agent/llm/providers/augmented_llm_bedrock.py +1787 -0
- mcp_agent/llm/providers/augmented_llm_google_native.py +4 -1
- mcp_agent/llm/providers/augmented_llm_openai.py +12 -3
- mcp_agent/llm/providers/augmented_llm_xai.py +38 -0
- mcp_agent/llm/usage_tracking.py +28 -3
- mcp_agent/logging/logger.py +7 -0
- mcp_agent/mcp/hf_auth.py +32 -4
- mcp_agent/mcp/mcp_agent_client_session.py +2 -0
- mcp_agent/mcp/mcp_aggregator.py +38 -44
- mcp_agent/mcp/sampling.py +15 -11
- mcp_agent/resources/examples/mcp/elicitations/forms_demo.py +0 -6
- mcp_agent/resources/examples/workflows/router.py +9 -0
- mcp_agent/ui/console_display.py +125 -13
- {fast_agent_mcp-0.2.40.dist-info → fast_agent_mcp-0.2.42.dist-info}/WHEEL +0 -0
- {fast_agent_mcp-0.2.40.dist-info → fast_agent_mcp-0.2.42.dist-info}/licenses/LICENSE +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: fast-agent-mcp
|
|
3
|
-
Version: 0.2.
|
|
3
|
+
Version: 0.2.42
|
|
4
4
|
Summary: Define, Prompt and Test MCP enabled Agents and Workflows
|
|
5
5
|
Author-email: Shaun Smith <fastagent@llmindset.co.uk>
|
|
6
6
|
License: Apache License
|
|
@@ -213,6 +213,7 @@ Requires-Dist: a2a-sdk>=0.2.9
|
|
|
213
213
|
Requires-Dist: aiohttp>=3.11.13
|
|
214
214
|
Requires-Dist: anthropic>=0.55.0
|
|
215
215
|
Requires-Dist: azure-identity>=1.14.0
|
|
216
|
+
Requires-Dist: boto3>=1.35.0
|
|
216
217
|
Requires-Dist: deprecated>=1.2.18
|
|
217
218
|
Requires-Dist: email-validator>=2.2.0
|
|
218
219
|
Requires-Dist: fastapi>=0.115.6
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
mcp_agent/__init__.py,sha256=18T0AG0W9sJhTY38O9GFFOzliDhxx9p87CvRyti9zbw,1620
|
|
2
2
|
mcp_agent/app.py,sha256=3mtHP1nRQcRaKhhxgTmCOv00alh70nT7UxNA8bN47QE,5560
|
|
3
|
-
mcp_agent/config.py,sha256=
|
|
3
|
+
mcp_agent/config.py,sha256=ORid5f2YSkkNHIWHFgIWdcqyqr3g1TGV5ZTQMinuMi0,18869
|
|
4
4
|
mcp_agent/console.py,sha256=Gjf2QLFumwG1Lav__c07X_kZxxEUSkzV-1_-YbAwcwo,813
|
|
5
5
|
mcp_agent/context.py,sha256=9s1F1-UfcI8rz9Yxm6EXHZ4cInuE_cOl_HFu8N8k3yc,7497
|
|
6
6
|
mcp_agent/context_dependent.py,sha256=QXfhw3RaQCKfscEEBRGuZ3sdMWqkgShz2jJ1ivGGX1I,1455
|
|
@@ -9,7 +9,7 @@ mcp_agent/mcp_server_registry.py,sha256=lmz-aES-l7Gbg4itDF0iCmpso_KD8bVazVKSVzjw
|
|
|
9
9
|
mcp_agent/progress_display.py,sha256=GeJU9VUt6qKsFVymG688hCMVCsAygG9ifiiEb5IcbN4,361
|
|
10
10
|
mcp_agent/agents/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
11
11
|
mcp_agent/agents/agent.py,sha256=EAYlcP1qqI1D0_CS808I806z1048FBjZQxxpcCZPeIU,3154
|
|
12
|
-
mcp_agent/agents/base_agent.py,sha256=
|
|
12
|
+
mcp_agent/agents/base_agent.py,sha256=EpdwZKktelEVdQUYyMoohtVwGgwas-rdM9r1nuMQIQk,30597
|
|
13
13
|
mcp_agent/agents/workflow/__init__.py,sha256=HloteEW6kalvgR0XewpiFAqaQlMPlPJYg5p3K33IUzI,25
|
|
14
14
|
mcp_agent/agents/workflow/chain_agent.py,sha256=eIlImirrSXkqBJmPuAJgOKis81Cl6lZEGM0-6IyaUV8,6105
|
|
15
15
|
mcp_agent/agents/workflow/evaluator_optimizer.py,sha256=ysUMGM2NzeCIutgr_vXH6kUPpZMw0cX4J_Wl1r8eT84,13296
|
|
@@ -19,66 +19,71 @@ mcp_agent/agents/workflow/orchestrator_prompts.py,sha256=EXKEI174sshkZyPPEnWbwwN
|
|
|
19
19
|
mcp_agent/agents/workflow/parallel_agent.py,sha256=JaQFp35nmAdoBRLAwx8BfnK7kirVq9PMw24LQ3ZEzoc,7705
|
|
20
20
|
mcp_agent/agents/workflow/router_agent.py,sha256=6tvI5D_ssKNZ6-tNxYHmw6r6DAQMYgqz3PZKZz2rC44,9466
|
|
21
21
|
mcp_agent/cli/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
22
|
-
mcp_agent/cli/__main__.py,sha256=
|
|
23
|
-
mcp_agent/cli/
|
|
22
|
+
mcp_agent/cli/__main__.py,sha256=KyZnfXkml0KsOnfy8T9JDYNVNynKix9cslwuafmKNbc,1089
|
|
23
|
+
mcp_agent/cli/constants.py,sha256=KawdkaN289nVB02DKPB4IVUJ8-fohIUD0gLfOp0P7B8,551
|
|
24
|
+
mcp_agent/cli/main.py,sha256=Hfa6yn47gfx_d6TUEbzDz68k2gaIS9vvN0yDbVOUgnc,3181
|
|
24
25
|
mcp_agent/cli/terminal.py,sha256=GRwD-RGW7saIz2IOWZn5vD6JjiArscELBThm1GTFkuI,1065
|
|
25
|
-
mcp_agent/cli/commands/check_config.py,sha256=
|
|
26
|
-
mcp_agent/cli/commands/go.py,sha256=
|
|
27
|
-
mcp_agent/cli/commands/quickstart.py,sha256=
|
|
26
|
+
mcp_agent/cli/commands/check_config.py,sha256=15YK0mtDQbVopnMm3HBjOeY2-00FUHj6tt8RvaemKmI,21081
|
|
27
|
+
mcp_agent/cli/commands/go.py,sha256=mVNtupzDr-qb95cv2rp9JLC2_5-QQgv8x7uyTwYH7wY,13240
|
|
28
|
+
mcp_agent/cli/commands/quickstart.py,sha256=lcozUGP9RRO8xZaayJg4pQNeY5zDQs-eg-ABm0A15cI,16471
|
|
29
|
+
mcp_agent/cli/commands/server_helpers.py,sha256=x5tD_qhf1W4D2li09sfOyfRWCOCa6lmpumYAPsEfIQs,3649
|
|
28
30
|
mcp_agent/cli/commands/setup.py,sha256=eOEd4TL-b0DaDeSJMGOfNOsTEItoZ67W88eTP4aP-bo,6482
|
|
29
31
|
mcp_agent/cli/commands/url_parser.py,sha256=5VdtcHRHzi67YignStVbz7u-rcvNNErw9oJLAUFOtEY,5855
|
|
30
32
|
mcp_agent/core/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
31
|
-
mcp_agent/core/agent_app.py,sha256=
|
|
32
|
-
mcp_agent/core/agent_types.py,sha256=
|
|
33
|
-
mcp_agent/core/direct_decorators.py,sha256=
|
|
34
|
-
mcp_agent/core/direct_factory.py,sha256=
|
|
35
|
-
mcp_agent/core/enhanced_prompt.py,sha256=
|
|
33
|
+
mcp_agent/core/agent_app.py,sha256=mMWfScEylf1l-rKzmRdoA7WIIBRvSypfZONDBYdo1M8,15919
|
|
34
|
+
mcp_agent/core/agent_types.py,sha256=7zVzAFWjvh5dDV3TuDwmO9LAWmDjYnZd3eeLH-wvvIQ,1705
|
|
35
|
+
mcp_agent/core/direct_decorators.py,sha256=sYoEA1EmdyAxTpQwUDUjQYWY73VviM-fBnV1Zv7KfeU,19047
|
|
36
|
+
mcp_agent/core/direct_factory.py,sha256=d_HvbAxyv2WrM07zyCpLXFVn7eArXk1LZmLKS49hzJo,19537
|
|
37
|
+
mcp_agent/core/enhanced_prompt.py,sha256=wAsPu8GdKXFTArr2tW2k_wmKZE207gPen6s2ho8x2ZM,33363
|
|
36
38
|
mcp_agent/core/error_handling.py,sha256=xoyS2kLe0eG0bj2eSJCJ2odIhGUve2SbDR7jP-A-uRw,624
|
|
37
39
|
mcp_agent/core/exceptions.py,sha256=ENAD_qGG67foxy6vDkIvc-lgopIUQy6O7zvNPpPXaQg,2289
|
|
38
|
-
mcp_agent/core/fastagent.py,sha256=
|
|
39
|
-
mcp_agent/core/interactive_prompt.py,sha256=
|
|
40
|
+
mcp_agent/core/fastagent.py,sha256=tAxapB3sjNyK6FqsJdOZt-IN5uYAi8DL1B9RHcGu55g,24849
|
|
41
|
+
mcp_agent/core/interactive_prompt.py,sha256=1XXtX8HnBt04hqfkCjPiVQP4OZegfuDa6hEQEwCUQRY,30493
|
|
40
42
|
mcp_agent/core/mcp_content.py,sha256=2D7KHY9mG_vxoDwFLKvsPQV9VRIzHItM7V-jcEnACh8,8878
|
|
41
43
|
mcp_agent/core/prompt.py,sha256=qnintOUGEoDPYLI9bu9G2OlgVMCe5ZPUZilgMzydXhc,7919
|
|
42
44
|
mcp_agent/core/request_params.py,sha256=qmFWZXeYEJyYw2IwonyrTnZWxQG7qX6bKpOPcqETa60,1603
|
|
43
|
-
mcp_agent/core/usage_display.py,sha256=
|
|
44
|
-
mcp_agent/core/validation.py,sha256=
|
|
45
|
+
mcp_agent/core/usage_display.py,sha256=VeVhlNRoTH109Yv3tokfWUKgxD4s_a2cFuvoNUbVEGU,7338
|
|
46
|
+
mcp_agent/core/validation.py,sha256=8D6d3mQanvzC2dXx5yc8-5bkoWEh9cxuT6-YSthSGFk,12676
|
|
45
47
|
mcp_agent/executor/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
46
48
|
mcp_agent/executor/executor.py,sha256=E44p6d-o3OMRoP_dNs_cDnyti91LQ3P9eNU88mSi1kc,9462
|
|
47
49
|
mcp_agent/executor/task_registry.py,sha256=PCALFeYtkQrPBg4RBJnlA0aDI8nHclrNkHGUS4kV3W8,1242
|
|
48
50
|
mcp_agent/executor/workflow_signal.py,sha256=Cg1uZBk3fn8kXhPOg-wINNuVaf3v9pvLD6NbqWy5Z6E,11142
|
|
49
51
|
mcp_agent/human_input/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
50
|
-
mcp_agent/human_input/elicitation_form.py,sha256=
|
|
52
|
+
mcp_agent/human_input/elicitation_form.py,sha256=s9rrX-qKxKZ91Uf-wjmrRIKgqDP-gdn6_1xOwizyJno,28158
|
|
51
53
|
mcp_agent/human_input/elicitation_forms.py,sha256=w8XQ1GfZX8Jw-VB4jnDI0Im4mF-T9Ts8mT2zRZBtL6M,3824
|
|
52
54
|
mcp_agent/human_input/elicitation_handler.py,sha256=YfVhIhSBc9wuszPS4zoHho4n1pwmIoq13huN4MSRkIs,3305
|
|
53
55
|
mcp_agent/human_input/elicitation_state.py,sha256=Unl9uhEybUqACCUimnETdfUprJNpYDMq3DdbbHw5oAw,1175
|
|
54
56
|
mcp_agent/human_input/handler.py,sha256=s712Z5ssTCwjL9-VKoIdP5CtgMh43YvepynYisiWTTA,3144
|
|
55
57
|
mcp_agent/human_input/types.py,sha256=RtWBOVzy8vnYoQrc36jRLn8z8N3C4pDPMBN5vF6qM5Y,1476
|
|
56
58
|
mcp_agent/llm/__init__.py,sha256=d8zgwG-bRFuwiMNMYkywg_qytk4P8lawyld_meuUmHI,68
|
|
57
|
-
mcp_agent/llm/augmented_llm.py,sha256=
|
|
59
|
+
mcp_agent/llm/augmented_llm.py,sha256=QMrNcyP-D5yfdUEhuHKtSDDg-_YnYaw8krGbafu0QTI,27567
|
|
58
60
|
mcp_agent/llm/augmented_llm_passthrough.py,sha256=F8KifmTwoQ7zyncjmoRek8SBfGdgc9yc5LRXwMQH-bg,8640
|
|
59
61
|
mcp_agent/llm/augmented_llm_playback.py,sha256=BQeBXRpO-xGAY9wIJxyde6xpHmZEdQPLd32frF8t3QQ,4916
|
|
62
|
+
mcp_agent/llm/augmented_llm_silent.py,sha256=IUnK_1Byy4D9TG0Pj46LFeNezgSTQ8d6MQIHWAImBwE,1846
|
|
60
63
|
mcp_agent/llm/augmented_llm_slow.py,sha256=DDSD8bL2flmQrVHZm-UDs7sR8aHRWkDOcOW-mX_GPok,2067
|
|
61
64
|
mcp_agent/llm/memory.py,sha256=pTOaTDV3EA3X68yKwEtUAu7s0xGIQQ_cKBhfYUnfR0w,8614
|
|
62
|
-
mcp_agent/llm/model_database.py,sha256=
|
|
63
|
-
mcp_agent/llm/model_factory.py,sha256=
|
|
65
|
+
mcp_agent/llm/model_database.py,sha256=YgqltGMDcmuoVrx-jiRj7Z5NCzKz2bshk7Rgkng2tsM,9401
|
|
66
|
+
mcp_agent/llm/model_factory.py,sha256=Vr7Ypt2laE_gPPdLWOFAQSXZkD7p3D5KKSvH3ijDwWw,11616
|
|
64
67
|
mcp_agent/llm/prompt_utils.py,sha256=yWQHykoK13QRF7evHUKxVF0SpVLN-Bsft0Yixzvn0g0,4825
|
|
65
|
-
mcp_agent/llm/provider_key_manager.py,sha256=
|
|
66
|
-
mcp_agent/llm/provider_types.py,sha256=
|
|
68
|
+
mcp_agent/llm/provider_key_manager.py,sha256=LSWIgcXlrUS4sfBvQBCya82qC6NcXQPYLtDHwHNOXR4,3394
|
|
69
|
+
mcp_agent/llm/provider_types.py,sha256=XK9IwmJND7Gd-WvggRXKovBSV9tTwtLD2BSUs86epp4,1091
|
|
67
70
|
mcp_agent/llm/sampling_converter.py,sha256=C7wPBlmT0eD90XWabC22zkxsrVHKCrjwIwg6cG628cI,2926
|
|
68
71
|
mcp_agent/llm/sampling_format_converter.py,sha256=xGz4odHpOcP7--eFaJaFtUR8eR9jxZS7MnLH6J7n0EU,1263
|
|
69
|
-
mcp_agent/llm/usage_tracking.py,sha256=
|
|
72
|
+
mcp_agent/llm/usage_tracking.py,sha256=rF6v8QQDam8QbvlP4jzHljKqvuNHExeYDLkUMI86czY,16073
|
|
70
73
|
mcp_agent/llm/providers/__init__.py,sha256=heVxtmuqFJOnjjxHz4bWSqTAxXoN1E8twC_gQ_yJpHk,265
|
|
71
74
|
mcp_agent/llm/providers/anthropic_utils.py,sha256=vYDN5G5jKMhD2CQg8veJYab7tvvzYkDMq8M1g_hUAQg,3275
|
|
72
75
|
mcp_agent/llm/providers/augmented_llm_aliyun.py,sha256=XylkJKZ9theSVUxJKOZkf1244hgzng4Ng4Dr209Qb-w,1101
|
|
73
|
-
mcp_agent/llm/providers/augmented_llm_anthropic.py,sha256=
|
|
74
|
-
mcp_agent/llm/providers/augmented_llm_azure.py,sha256=
|
|
76
|
+
mcp_agent/llm/providers/augmented_llm_anthropic.py,sha256=dKXP8d36jzqThV8E404PUYbTuQbRz9x7uQScW4_BU6U,24060
|
|
77
|
+
mcp_agent/llm/providers/augmented_llm_azure.py,sha256=sBVWgY88F4OsdRSHl71BAT2p3XPvuZp844z1ubwcV7U,6098
|
|
78
|
+
mcp_agent/llm/providers/augmented_llm_bedrock.py,sha256=tcbMovzA4W1JMB-PrvxXlwea8if-tmYooq9ME2W6Leo,82327
|
|
75
79
|
mcp_agent/llm/providers/augmented_llm_deepseek.py,sha256=zI9a90dwT4r6E1f_xp4K50Cj9sD7y7kNRgjo0s1pd5w,3804
|
|
76
80
|
mcp_agent/llm/providers/augmented_llm_generic.py,sha256=5Uq8ZBhcFuQTt7koP_5ykolREh2iWu8zKhNbh3pM9lQ,1210
|
|
77
|
-
mcp_agent/llm/providers/augmented_llm_google_native.py,sha256=
|
|
81
|
+
mcp_agent/llm/providers/augmented_llm_google_native.py,sha256=meWvjiNny2T8Map_TuLl8gx9JX8Ly8orHMFUCx3gtFU,22389
|
|
78
82
|
mcp_agent/llm/providers/augmented_llm_google_oai.py,sha256=cO4dvjTl9ymqEurCOo5nP09ATfXVjgkuk1yZAlWpS1s,1137
|
|
79
|
-
mcp_agent/llm/providers/augmented_llm_openai.py,sha256=
|
|
83
|
+
mcp_agent/llm/providers/augmented_llm_openai.py,sha256=AP2ZXZhFXntZlhm50Bi2QwLfTybIX134Y6e_OktdhG8,24321
|
|
80
84
|
mcp_agent/llm/providers/augmented_llm_openrouter.py,sha256=V_TlVKm92GHBxYIo6gpvH_6cAaIdppS25Tz6x5T7LW0,2341
|
|
81
85
|
mcp_agent/llm/providers/augmented_llm_tensorzero.py,sha256=Mol_Wzj_ZtccW-LMw0oFwWUt1m1yfofloay9QYNP23c,20729
|
|
86
|
+
mcp_agent/llm/providers/augmented_llm_xai.py,sha256=fJiO9Vkgi32pEMijxMbqoKrPCCNJmR_3YEnX0UCqOVs,1332
|
|
82
87
|
mcp_agent/llm/providers/google_converter.py,sha256=zsqxJJ636WzCL2K6w-yB94O8bdNR6mo8f5mQEnUJFyg,16831
|
|
83
88
|
mcp_agent/llm/providers/multipart_converter_anthropic.py,sha256=t5lHYGfFUacJldnrVtMNW-8gEMoto8Y7hJkDrnyZR-Y,16650
|
|
84
89
|
mcp_agent/llm/providers/multipart_converter_openai.py,sha256=kCvtTFOcOejg2BVI3_-F9OCFxAoShSj2i0hdCajHCIw,15955
|
|
@@ -91,7 +96,7 @@ mcp_agent/logging/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU
|
|
|
91
96
|
mcp_agent/logging/events.py,sha256=dSJJfuCd59-ZyYTVcf0M4HQd6iXb5k50PSAeoq1CpH0,4278
|
|
92
97
|
mcp_agent/logging/json_serializer.py,sha256=qkfxnR9ka6OgvwSpM2CggELbEtzzkApm0s_KYz11RDY,5791
|
|
93
98
|
mcp_agent/logging/listeners.py,sha256=_S4Jp5_KWp0kUfrx4BxDdNCeQK3MNT3Zi9AaolPri7A,6648
|
|
94
|
-
mcp_agent/logging/logger.py,sha256=
|
|
99
|
+
mcp_agent/logging/logger.py,sha256=v2_D5kWLSS9u4ueSU7q6cWF1oSmTVeAAtgnwR0LrbXI,11056
|
|
95
100
|
mcp_agent/logging/rich_progress.py,sha256=NQbW010VxfzgJw8BRaqKVTIFlTNvDfmMcoOt7pxGvzQ,5362
|
|
96
101
|
mcp_agent/logging/transport.py,sha256=m8YsLLu5T8eof_ndpLQs4gHOzqqEL98xsVwBwDsBfxI,17335
|
|
97
102
|
mcp_agent/mcp/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
|
|
@@ -99,18 +104,18 @@ mcp_agent/mcp/common.py,sha256=MpSC0fLO21RcDz4VApah4C8_LisVGz7OXkR17Xw-9mY,431
|
|
|
99
104
|
mcp_agent/mcp/elicitation_factory.py,sha256=gY0gEsF8Jdg01nSsrVbbl62ZS1A725QgDRB6UDPCadc,3162
|
|
100
105
|
mcp_agent/mcp/elicitation_handlers.py,sha256=w2S4kBn05pIKdq2-X13MErinFg5jSElwFsoTuW3zFSs,6618
|
|
101
106
|
mcp_agent/mcp/gen_client.py,sha256=fAVwFVCgSamw4PwoWOV4wrK9TABx1S_zZv8BctRyF2k,3030
|
|
102
|
-
mcp_agent/mcp/hf_auth.py,sha256=
|
|
107
|
+
mcp_agent/mcp/hf_auth.py,sha256=7szw4rkwRyK3J-sUTcVZHdwoLIZqlYo8XolJnZdjOww,4571
|
|
103
108
|
mcp_agent/mcp/interfaces.py,sha256=NxUDi4eI-qWfaOS1QHWr3EjAweV-CX_CBJeBCwTwr7g,7102
|
|
104
109
|
mcp_agent/mcp/logger_textio.py,sha256=vljC1BtNTCxBAda9ExqNB-FwVNUZIuJT3h1nWmCjMws,3172
|
|
105
|
-
mcp_agent/mcp/mcp_agent_client_session.py,sha256=
|
|
106
|
-
mcp_agent/mcp/mcp_aggregator.py,sha256=
|
|
110
|
+
mcp_agent/mcp/mcp_agent_client_session.py,sha256=nEHrSalG5z47BKGwE9ooOmlSTc4Gb7qdEut071Dwepo,8987
|
|
111
|
+
mcp_agent/mcp/mcp_aggregator.py,sha256=Q2hHT_fcm6QIJ96si88AWaHxPh4NB50g3nr2lfGGZV0,48753
|
|
107
112
|
mcp_agent/mcp/mcp_connection_manager.py,sha256=dJxjnv2IRzlFIxrbPFl39-pmGcZHgyeMXVlMfqpREhE,17974
|
|
108
113
|
mcp_agent/mcp/mime_utils.py,sha256=difepNR_gpb4MpMLkBRAoyhDk-AjXUHTiqKvT_VwS1o,1805
|
|
109
114
|
mcp_agent/mcp/prompt_message_multipart.py,sha256=BDwRdNwyWHb2q2bccDb2iR2VlORqVvkvoG3xYzcMpCE,4403
|
|
110
115
|
mcp_agent/mcp/prompt_render.py,sha256=k3v4BZDThGE2gGiOYVQtA6x8WTEdOuXIEnRafANhN1U,2996
|
|
111
116
|
mcp_agent/mcp/prompt_serialization.py,sha256=MQY6QxnhQTiq0oBDsyRzFtX8sBiovUjzUFX78As8q60,17974
|
|
112
117
|
mcp_agent/mcp/resource_utils.py,sha256=K4XY8bihmBMleRTZ2viMPiD2Y2HWxFnlgIJi6dd_PYE,6588
|
|
113
|
-
mcp_agent/mcp/sampling.py,sha256=
|
|
118
|
+
mcp_agent/mcp/sampling.py,sha256=PpUtLDvu9K3U8445z6m_esHeKstdSr-JBTyn9d8ppJM,6665
|
|
114
119
|
mcp_agent/mcp/helpers/__init__.py,sha256=sKqwlUR3jSsd9PVJKjXtxHgZA1YOdzPtsSW4xVey77Q,52
|
|
115
120
|
mcp_agent/mcp/helpers/content_helpers.py,sha256=fOrRq6sIHR0Zn18k9GRRn9PWBB5WosPLhvK0yVXg2Vg,4191
|
|
116
121
|
mcp_agent/mcp/helpers/server_config_helpers.py,sha256=MkyZB2ZzfsBNsqyGd0LfUOoXxhAMS28VF-f747cJJpY,978
|
|
@@ -132,7 +137,7 @@ mcp_agent/resources/examples/mcp/elicitations/elicitation_forms_server.py,sha256
|
|
|
132
137
|
mcp_agent/resources/examples/mcp/elicitations/elicitation_game_server.py,sha256=z9kHdNc6XWjAWkvet7inVBIcYxfWoxU6n9iHrsEqU7A,6206
|
|
133
138
|
mcp_agent/resources/examples/mcp/elicitations/fastagent.config.yaml,sha256=HPe0cuFL4-rzS4hHNgZiLMPEv0jYXOp7iSsrUliAaqs,1080
|
|
134
139
|
mcp_agent/resources/examples/mcp/elicitations/fastagent.secrets.yaml.example,sha256=1vkBmh9f4mnQZm6-2B7vyU1OepImviPW5MNAJkvUIPE,394
|
|
135
|
-
mcp_agent/resources/examples/mcp/elicitations/forms_demo.py,sha256=
|
|
140
|
+
mcp_agent/resources/examples/mcp/elicitations/forms_demo.py,sha256=0msJAZ6Pha_y3hcUxn_QIkXhbMxA7sa_6kag7iqYu0U,4335
|
|
136
141
|
mcp_agent/resources/examples/mcp/elicitations/game_character.py,sha256=forNICa8SzrvrVuwzDa9HcpjauByQHbkryO2yavxqc4,2372
|
|
137
142
|
mcp_agent/resources/examples/mcp/elicitations/game_character_handler.py,sha256=tOp8rFJ0ZDrzR5siATZT_RUh7wyRpicGwcOcfTeCd2c,11211
|
|
138
143
|
mcp_agent/resources/examples/mcp/elicitations/tool_call.py,sha256=1JWeN5YnbsuASu5eQxY9yvur4KLWtUs7j0c5jSeiq9A,530
|
|
@@ -151,13 +156,13 @@ mcp_agent/resources/examples/workflows/graded_report.md,sha256=QVF38xEtDIO1a2P-x
|
|
|
151
156
|
mcp_agent/resources/examples/workflows/human_input.py,sha256=_I6nS6xYo8IHAmvzsUYOxqVGb4G6BTyJXPAmS3fNcBU,621
|
|
152
157
|
mcp_agent/resources/examples/workflows/orchestrator.py,sha256=5Jxfe0s3ai4qRpVXm3DaqtkDvjeWD2CcysW36J6JA-M,2521
|
|
153
158
|
mcp_agent/resources/examples/workflows/parallel.py,sha256=OTWhX33uum_rspAzrSf3uCTj7b67Kvw3UUU8nsosz4g,1839
|
|
154
|
-
mcp_agent/resources/examples/workflows/router.py,sha256=
|
|
159
|
+
mcp_agent/resources/examples/workflows/router.py,sha256=56FX7JhZ6ERafWGoVhspoalT1kkfkfbb5P-6MTFDamA,2032
|
|
155
160
|
mcp_agent/resources/examples/workflows/short_story.md,sha256=XN9I2kzCcMmke3dE5F2lyRH5iFUZUQ8Sy-hS3rm_Wlc,1153
|
|
156
161
|
mcp_agent/resources/examples/workflows/short_story.txt,sha256=X3y_1AyhLFN2AKzCKvucJtDgAFIJfnlbsbGZO5bBWu0,1187
|
|
157
162
|
mcp_agent/tools/tool_definition.py,sha256=L3Pxl-uLEXqlVoo-bYuFTFALeI-2pIU44YgFhsTKEtM,398
|
|
158
|
-
mcp_agent/ui/console_display.py,sha256=
|
|
159
|
-
fast_agent_mcp-0.2.
|
|
160
|
-
fast_agent_mcp-0.2.
|
|
161
|
-
fast_agent_mcp-0.2.
|
|
162
|
-
fast_agent_mcp-0.2.
|
|
163
|
-
fast_agent_mcp-0.2.
|
|
163
|
+
mcp_agent/ui/console_display.py,sha256=U9ZWzeu3dUGNCDcyFVSTqX_rpxXbn3uNmuvJ4SIlzi0,15730
|
|
164
|
+
fast_agent_mcp-0.2.42.dist-info/METADATA,sha256=Usid8c-xlf44Efu98pJSkr-CrDWdohM5GLrw9cpmgb8,31012
|
|
165
|
+
fast_agent_mcp-0.2.42.dist-info/WHEEL,sha256=qtCwoSJWgHk21S1Kb4ihdzI2rlJ1ZKaIurTj_ngOhyQ,87
|
|
166
|
+
fast_agent_mcp-0.2.42.dist-info/entry_points.txt,sha256=QaX5kLdI0VdMPRdPUF1nkG_WdLUTNjp_icW6e3EhNYU,232
|
|
167
|
+
fast_agent_mcp-0.2.42.dist-info/licenses/LICENSE,sha256=Gx1L3axA4PnuK4FxsbX87jQ1opoOkSFfHHSytW6wLUU,10935
|
|
168
|
+
fast_agent_mcp-0.2.42.dist-info/RECORD,,
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[console_scripts]
|
|
2
|
-
fast-agent = mcp_agent.cli.__main__:
|
|
3
|
-
fast-agent-mcp = mcp_agent.cli.__main__:
|
|
2
|
+
fast-agent = mcp_agent.cli.__main__:main
|
|
3
|
+
fast-agent-mcp = mcp_agent.cli.__main__:main
|
|
4
4
|
fastagent = mcp_agent.cli.__main__:app
|
|
5
5
|
prompt-server = mcp_agent.mcp.prompts.__main__:main
|
|
6
6
|
silsila = mcp_agent.cli.__main__:app
|
mcp_agent/agents/base_agent.py
CHANGED
|
@@ -6,6 +6,7 @@ and delegates operations to an attached AugmentedLLMProtocol instance.
|
|
|
6
6
|
"""
|
|
7
7
|
|
|
8
8
|
import asyncio
|
|
9
|
+
import fnmatch
|
|
9
10
|
import uuid
|
|
10
11
|
from typing import (
|
|
11
12
|
TYPE_CHECKING,
|
|
@@ -13,6 +14,7 @@ from typing import (
|
|
|
13
14
|
Callable,
|
|
14
15
|
Dict,
|
|
15
16
|
List,
|
|
17
|
+
Mapping,
|
|
16
18
|
Optional,
|
|
17
19
|
Tuple,
|
|
18
20
|
Type,
|
|
@@ -325,9 +327,29 @@ class BaseAgent(MCPAggregator, AgentProtocol):
|
|
|
325
327
|
self.logger.debug("Received human input signal", data=result)
|
|
326
328
|
return result
|
|
327
329
|
|
|
330
|
+
def _matches_pattern(self, name: str, pattern: str, server_name: str) -> bool:
|
|
331
|
+
"""
|
|
332
|
+
Check if a name matches a pattern for a specific server.
|
|
333
|
+
|
|
334
|
+
Args:
|
|
335
|
+
name: The name to match (could be tool name, resource URI, or prompt name)
|
|
336
|
+
pattern: The pattern to match against (e.g., "add", "math*", "resource://math/*")
|
|
337
|
+
server_name: The server name (used for tool name prefixing)
|
|
338
|
+
|
|
339
|
+
Returns:
|
|
340
|
+
True if the name matches the pattern
|
|
341
|
+
"""
|
|
342
|
+
# For tools, build the full pattern with server prefix: server_name-pattern
|
|
343
|
+
if name.startswith(f"{server_name}-"):
|
|
344
|
+
full_pattern = f"{server_name}-{pattern}"
|
|
345
|
+
return fnmatch.fnmatch(name, full_pattern)
|
|
346
|
+
|
|
347
|
+
# For resources and prompts, match directly against the pattern
|
|
348
|
+
return fnmatch.fnmatch(name, pattern)
|
|
349
|
+
|
|
328
350
|
async def list_tools(self) -> ListToolsResult:
|
|
329
351
|
"""
|
|
330
|
-
List all tools available to this agent.
|
|
352
|
+
List all tools available to this agent, filtered by configuration.
|
|
331
353
|
|
|
332
354
|
Returns:
|
|
333
355
|
ListToolsResult with available tools
|
|
@@ -335,8 +357,26 @@ class BaseAgent(MCPAggregator, AgentProtocol):
|
|
|
335
357
|
if not self.initialized:
|
|
336
358
|
await self.initialize()
|
|
337
359
|
|
|
360
|
+
# Get all tools from the parent class
|
|
338
361
|
result = await super().list_tools()
|
|
339
362
|
|
|
363
|
+
# Apply filtering if tools are specified in config
|
|
364
|
+
if self.config.tools is not None:
|
|
365
|
+
filtered_tools = []
|
|
366
|
+
for tool in result.tools:
|
|
367
|
+
# Extract server name from tool name (e.g., "mathematics-add" -> "mathematics")
|
|
368
|
+
if '-' in tool.name:
|
|
369
|
+
server_name = tool.name.split('-', 1)[0]
|
|
370
|
+
|
|
371
|
+
# Check if this server has tool filters
|
|
372
|
+
if server_name in self.config.tools:
|
|
373
|
+
# Check if tool matches any pattern for this server
|
|
374
|
+
for pattern in self.config.tools[server_name]:
|
|
375
|
+
if self._matches_pattern(tool.name, pattern, server_name):
|
|
376
|
+
filtered_tools.append(tool)
|
|
377
|
+
break
|
|
378
|
+
result.tools = filtered_tools
|
|
379
|
+
|
|
340
380
|
if not self.human_input_callback:
|
|
341
381
|
return result
|
|
342
382
|
|
|
@@ -635,6 +675,76 @@ class BaseAgent(MCPAggregator, AgentProtocol):
|
|
|
635
675
|
response = await self.generate(prompts, request_params)
|
|
636
676
|
return response.first_text()
|
|
637
677
|
|
|
678
|
+
async def list_prompts(self, server_name: str | None = None) -> Mapping[str, List[Prompt]]:
|
|
679
|
+
"""
|
|
680
|
+
List all prompts available to this agent, filtered by configuration.
|
|
681
|
+
|
|
682
|
+
Args:
|
|
683
|
+
server_name: Optional server name to list prompts from
|
|
684
|
+
|
|
685
|
+
Returns:
|
|
686
|
+
Dictionary mapping server names to lists of Prompt objects
|
|
687
|
+
"""
|
|
688
|
+
if not self.initialized:
|
|
689
|
+
await self.initialize()
|
|
690
|
+
|
|
691
|
+
# Get all prompts from the parent class
|
|
692
|
+
result = await super().list_prompts(server_name)
|
|
693
|
+
|
|
694
|
+
# Apply filtering if prompts are specified in config
|
|
695
|
+
if self.config.prompts is not None:
|
|
696
|
+
filtered_result = {}
|
|
697
|
+
for server, prompts in result.items():
|
|
698
|
+
# Check if this server has prompt filters
|
|
699
|
+
if server in self.config.prompts:
|
|
700
|
+
filtered_prompts = []
|
|
701
|
+
for prompt in prompts:
|
|
702
|
+
# Check if prompt matches any pattern for this server
|
|
703
|
+
for pattern in self.config.prompts[server]:
|
|
704
|
+
if self._matches_pattern(prompt.name, pattern, server):
|
|
705
|
+
filtered_prompts.append(prompt)
|
|
706
|
+
break
|
|
707
|
+
if filtered_prompts:
|
|
708
|
+
filtered_result[server] = filtered_prompts
|
|
709
|
+
result = filtered_result
|
|
710
|
+
|
|
711
|
+
return result
|
|
712
|
+
|
|
713
|
+
async def list_resources(self, server_name: str | None = None) -> Dict[str, List[str]]:
|
|
714
|
+
"""
|
|
715
|
+
List all resources available to this agent, filtered by configuration.
|
|
716
|
+
|
|
717
|
+
Args:
|
|
718
|
+
server_name: Optional server name to list resources from
|
|
719
|
+
|
|
720
|
+
Returns:
|
|
721
|
+
Dictionary mapping server names to lists of resource URIs
|
|
722
|
+
"""
|
|
723
|
+
if not self.initialized:
|
|
724
|
+
await self.initialize()
|
|
725
|
+
|
|
726
|
+
# Get all resources from the parent class
|
|
727
|
+
result = await super().list_resources(server_name)
|
|
728
|
+
|
|
729
|
+
# Apply filtering if resources are specified in config
|
|
730
|
+
if self.config.resources is not None:
|
|
731
|
+
filtered_result = {}
|
|
732
|
+
for server, resources in result.items():
|
|
733
|
+
# Check if this server has resource filters
|
|
734
|
+
if server in self.config.resources:
|
|
735
|
+
filtered_resources = []
|
|
736
|
+
for resource in resources:
|
|
737
|
+
# Check if resource matches any pattern for this server
|
|
738
|
+
for pattern in self.config.resources[server]:
|
|
739
|
+
if self._matches_pattern(resource, pattern, server):
|
|
740
|
+
filtered_resources.append(resource)
|
|
741
|
+
break
|
|
742
|
+
if filtered_resources:
|
|
743
|
+
filtered_result[server] = filtered_resources
|
|
744
|
+
result = filtered_result
|
|
745
|
+
|
|
746
|
+
return result
|
|
747
|
+
|
|
638
748
|
@property
|
|
639
749
|
def agent_type(self) -> AgentType:
|
|
640
750
|
"""
|
mcp_agent/cli/__main__.py
CHANGED
|
@@ -1,7 +1,33 @@
|
|
|
1
|
+
import sys
|
|
2
|
+
|
|
3
|
+
from mcp_agent.cli.constants import GO_SPECIFIC_OPTIONS, KNOWN_SUBCOMMANDS
|
|
1
4
|
from mcp_agent.cli.main import app
|
|
2
5
|
|
|
3
|
-
#
|
|
4
|
-
|
|
6
|
+
# if the arguments would work with "go" we'll just route to it
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
def main():
|
|
10
|
+
"""Main entry point that handles auto-routing to 'go' command."""
|
|
11
|
+
# Check if we should auto-route to 'go'
|
|
12
|
+
if len(sys.argv) > 1:
|
|
13
|
+
# Check if first arg is not already a subcommand
|
|
14
|
+
first_arg = sys.argv[1]
|
|
15
|
+
|
|
16
|
+
if first_arg not in KNOWN_SUBCOMMANDS and any(
|
|
17
|
+
arg in sys.argv or any(arg.startswith(opt + "=") for opt in GO_SPECIFIC_OPTIONS)
|
|
18
|
+
for arg in sys.argv
|
|
19
|
+
):
|
|
20
|
+
# Find where to insert 'go' - before the first go-specific option
|
|
21
|
+
insert_pos = 1
|
|
22
|
+
for i, arg in enumerate(sys.argv[1:], 1):
|
|
23
|
+
if arg in GO_SPECIFIC_OPTIONS or any(arg.startswith(opt + "=") for opt in GO_SPECIFIC_OPTIONS):
|
|
24
|
+
insert_pos = i
|
|
25
|
+
break
|
|
26
|
+
# Auto-route to go command
|
|
27
|
+
sys.argv.insert(insert_pos, "go")
|
|
5
28
|
|
|
6
|
-
if __name__ == "__main__":
|
|
7
29
|
app()
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
if __name__ == "__main__":
|
|
33
|
+
main()
|