fast-agent-mcp 0.2.21__tar.gz → 0.2.23__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.
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/.gitignore +7 -1
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/PKG-INFO +10 -8
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/README.md +6 -5
- fast_agent_mcp-0.2.23/examples/tensorzero/README.md +55 -0
- fast_agent_mcp-0.2.23/examples/tensorzero/agent.py +36 -0
- fast_agent_mcp-0.2.23/examples/tensorzero/docker-compose.yml +104 -0
- fast_agent_mcp-0.2.23/examples/tensorzero/fastagent.config.yaml +18 -0
- fast_agent_mcp-0.2.23/examples/tensorzero/image_demo.py +67 -0
- fast_agent_mcp-0.2.23/examples/tensorzero/mcp_server/mcp_server.py +31 -0
- fast_agent_mcp-0.2.23/examples/tensorzero/simple_agent.py +25 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/pyproject.toml +4 -3
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/agents/workflow/orchestrator_agent.py +2 -2
- fast_agent_mcp-0.2.23/src/mcp_agent/cli/commands/go.py +236 -0
- fast_agent_mcp-0.2.23/src/mcp_agent/cli/commands/url_parser.py +185 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/config.py +16 -1
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/core/fastagent.py +2 -2
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/core/request_params.py +11 -7
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/event_progress.py +1 -1
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/augmented_llm.py +3 -9
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/model_factory.py +8 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/provider_types.py +1 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/providers/augmented_llm_anthropic.py +1 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/providers/augmented_llm_openai.py +14 -1
- fast_agent_mcp-0.2.23/src/mcp_agent/llm/providers/augmented_llm_tensorzero.py +442 -0
- fast_agent_mcp-0.2.23/src/mcp_agent/llm/providers/multipart_converter_tensorzero.py +200 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp/mcp_connection_manager.py +78 -10
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp/prompts/prompt_server.py +12 -4
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp_server/agent_server.py +13 -10
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp_server_registry.py +51 -9
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/mcp/state-transfer/fastagent.config.yaml +2 -2
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/ui/console_display.py +7 -6
- fast_agent_mcp-0.2.21/src/mcp_agent/cli/commands/go.py +0 -133
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/LICENSE +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/data-analysis/analysis-campaign.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/data-analysis/analysis.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/data-analysis/fastagent.config.yaml +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/data-analysis/mount-point/WA_Fn-UseC_-HR-Employee-Attrition.csv +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/mcp/state-transfer/agent_one.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/mcp/state-transfer/agent_two.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/mcp/state-transfer/fastagent.config.yaml +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/mcp/vision-examples/example1.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/mcp/vision-examples/example2.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/mcp/vision-examples/example3.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/mcp/vision-examples/fastagent.config.yaml +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/otel/agent.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/otel/agent2.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/otel/docker-compose.yaml +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/otel/fastagent.config.yaml +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/researcher/fastagent.config.yaml +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/researcher/researcher-eval.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/researcher/researcher-imp.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/researcher/researcher.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/workflows/chaining.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/workflows/evaluator.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/workflows/fastagent.config.yaml +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/workflows/graded_report.md +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/workflows/human_input.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/workflows/orchestrator.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/workflows/parallel.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/workflows/router.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/workflows/short_story.md +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/examples/workflows/short_story.txt +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/__init__.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/agents/__init__.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/agents/agent.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/agents/base_agent.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/agents/workflow/__init__.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/agents/workflow/chain_agent.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/agents/workflow/evaluator_optimizer.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/agents/workflow/orchestrator_models.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/agents/workflow/orchestrator_prompts.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/agents/workflow/parallel_agent.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/agents/workflow/router_agent.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/app.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/cli/__init__.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/cli/__main__.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/cli/commands/check_config.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/cli/commands/quickstart.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/cli/commands/setup.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/cli/main.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/cli/terminal.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/console.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/context.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/context_dependent.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/core/__init__.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/core/agent_app.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/core/agent_types.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/core/direct_decorators.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/core/direct_factory.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/core/enhanced_prompt.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/core/error_handling.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/core/exceptions.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/core/interactive_prompt.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/core/mcp_content.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/core/prompt.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/core/validation.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/executor/__init__.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/executor/executor.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/executor/task_registry.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/executor/workflow_signal.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/human_input/__init__.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/human_input/handler.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/human_input/types.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/__init__.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/augmented_llm_passthrough.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/augmented_llm_playback.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/memory.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/prompt_utils.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/provider_key_manager.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/providers/__init__.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/providers/anthropic_utils.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/providers/augmented_llm_deepseek.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/providers/augmented_llm_generic.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/providers/augmented_llm_google.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/providers/augmented_llm_openrouter.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/providers/multipart_converter_anthropic.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/providers/multipart_converter_openai.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/providers/openai_multipart.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/providers/openai_utils.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/providers/sampling_converter_anthropic.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/providers/sampling_converter_openai.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/sampling_converter.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/llm/sampling_format_converter.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/logging/__init__.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/logging/events.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/logging/json_serializer.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/logging/listeners.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/logging/logger.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/logging/rich_progress.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/logging/transport.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp/__init__.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp/gen_client.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp/helpers/__init__.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp/helpers/content_helpers.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp/interfaces.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp/logger_textio.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp/mcp_agent_client_session.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp/mcp_aggregator.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp/mime_utils.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp/prompt_message_multipart.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp/prompt_render.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp/prompt_serialization.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp/prompts/__init__.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp/prompts/__main__.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp/prompts/prompt_constants.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp/prompts/prompt_helpers.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp/prompts/prompt_load.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp/prompts/prompt_template.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp/resource_utils.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp/sampling.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/mcp_server/__init__.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/progress_display.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/data-analysis/analysis-campaign.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/data-analysis/analysis.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/data-analysis/fastagent.config.yaml +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/data-analysis/mount-point/WA_Fn-UseC_-HR-Employee-Attrition.csv +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/in_dev/agent_build.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/in_dev/css-LICENSE.txt +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/in_dev/slides.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/internal/agent.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/internal/fastagent.config.yaml +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/internal/history_transfer.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/internal/job.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/internal/prompt_category.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/internal/prompt_sizing.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/internal/simple.txt +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/internal/sizer.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/internal/social.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/mcp/state-transfer/agent_one.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/mcp/state-transfer/agent_two.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/mcp/state-transfer/fastagent.secrets.yaml.example +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/prompting/__init__.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/prompting/agent.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/prompting/delimited_prompt.txt +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/prompting/fastagent.config.yaml +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/prompting/image_server.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/prompting/prompt1.txt +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/prompting/work_with_image.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/researcher/fastagent.config.yaml +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/researcher/researcher-eval.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/researcher/researcher-imp.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/researcher/researcher.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/workflows/chaining.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/workflows/evaluator.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/workflows/fastagent.config.yaml +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/workflows/human_input.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/workflows/orchestrator.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/workflows/parallel.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/workflows/router.py +0 -0
- {fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/resources/examples/workflows/short_story.txt +0 -0
@@ -1,4 +1,4 @@
|
|
1
|
-
# Byte-compiled / optimized / DLL files
|
1
|
+
s# Byte-compiled / optimized / DLL files
|
2
2
|
__pycache__/
|
3
3
|
*.py[cod]
|
4
4
|
*$py.class
|
@@ -182,6 +182,7 @@ fastagent.secrets.yaml
|
|
182
182
|
CLAUDE.md
|
183
183
|
example-outputs/
|
184
184
|
|
185
|
+
tests/integration/api/weather_location.txt
|
185
186
|
tests/integration/prompt-state/simple.txt
|
186
187
|
tests/integration/workflow/router/fastagent.jsonl
|
187
188
|
tests/e2e/smoke/weather_location.txt
|
@@ -195,3 +196,8 @@ tests/integration/prompt-state/multipart.json
|
|
195
196
|
tests/integration/prompt-state/history.json
|
196
197
|
!tests/integration/api/fastagent.secrets.yaml
|
197
198
|
fastagent.jsonl
|
199
|
+
|
200
|
+
# JetBrains IDEs
|
201
|
+
.idea/
|
202
|
+
tests/e2e/smoke/base/weather_location.txt
|
203
|
+
tests/integration/roots/fastagent.jsonl
|
@@ -1,8 +1,8 @@
|
|
1
1
|
Metadata-Version: 2.4
|
2
2
|
Name: fast-agent-mcp
|
3
|
-
Version: 0.2.
|
3
|
+
Version: 0.2.23
|
4
4
|
Summary: Define, Prompt and Test MCP enabled Agents and Workflows
|
5
|
-
Author-email: Shaun Smith <fastagent@llmindset.co.uk
|
5
|
+
Author-email: Shaun Smith <fastagent@llmindset.co.uk>
|
6
6
|
License: Apache License
|
7
7
|
Version 2.0, January 2004
|
8
8
|
http://www.apache.org/licenses/
|
@@ -213,7 +213,7 @@ Requires-Dist: a2a-types>=0.1.0
|
|
213
213
|
Requires-Dist: aiohttp>=3.11.13
|
214
214
|
Requires-Dist: anthropic>=0.49.0
|
215
215
|
Requires-Dist: fastapi>=0.115.6
|
216
|
-
Requires-Dist: mcp
|
216
|
+
Requires-Dist: mcp>=1.8.0
|
217
217
|
Requires-Dist: openai>=1.63.2
|
218
218
|
Requires-Dist: opentelemetry-distro>=0.50b0
|
219
219
|
Requires-Dist: opentelemetry-exporter-otlp-proto-http>=1.29.0
|
@@ -224,6 +224,7 @@ Requires-Dist: pydantic-settings>=2.7.0
|
|
224
224
|
Requires-Dist: pydantic>=2.10.4
|
225
225
|
Requires-Dist: pyyaml>=6.0.2
|
226
226
|
Requires-Dist: rich>=13.9.4
|
227
|
+
Requires-Dist: tensorzero>=2025.4.7
|
227
228
|
Requires-Dist: typer>=0.15.1
|
228
229
|
Provides-Extra: dev
|
229
230
|
Requires-Dist: anthropic>=0.42.0; extra == 'dev'
|
@@ -260,6 +261,7 @@ The simple declarative syntax lets you concentrate on composing your Prompts and
|
|
260
261
|
`fast-agent` is multi-modal, supporting Images and PDFs for both Anthropic and OpenAI endpoints via Prompts, Resources and MCP Tool Call results. The inclusion of passthrough and playback LLMs enable rapid development and test of Python glue-code for your applications.
|
261
262
|
|
262
263
|
> [!IMPORTANT]
|
264
|
+
>
|
263
265
|
> `fast-agent` The fast-agent documentation repo is here: https://github.com/evalstate/fast-agent-docs. Please feel free to submit PRs for documentation, experience reports or other content you think others may find helpful. All help and feedback warmly received.
|
264
266
|
|
265
267
|
### Agent Application Development
|
@@ -277,12 +279,12 @@ Simple model selection makes testing Model <-> MCP Server interaction painless.
|
|
277
279
|
Start by installing the [uv package manager](https://docs.astral.sh/uv/) for Python. Then:
|
278
280
|
|
279
281
|
```bash
|
280
|
-
uv pip install fast-agent-mcp
|
282
|
+
uv pip install fast-agent-mcp # install fast-agent!
|
281
283
|
|
282
|
-
fast-agent setup
|
283
|
-
uv run agent.py
|
284
|
-
uv run agent.py --model=o3-mini.low
|
285
|
-
fast-agent quickstart workflow
|
284
|
+
uv run fast-agent setup # create an example agent and config files
|
285
|
+
uv run agent.py # run your first agent
|
286
|
+
uv run agent.py --model=o3-mini.low # specify a model
|
287
|
+
uv run fast-agent quickstart workflow # create "building effective agents" examples
|
286
288
|
```
|
287
289
|
|
288
290
|
Other quickstart examples include a Researcher Agent (with Evaluator-Optimizer workflow) and Data Analysis Agent (similar to the ChatGPT experience), demonstrating MCP Roots support.
|
@@ -19,6 +19,7 @@ The simple declarative syntax lets you concentrate on composing your Prompts and
|
|
19
19
|
`fast-agent` is multi-modal, supporting Images and PDFs for both Anthropic and OpenAI endpoints via Prompts, Resources and MCP Tool Call results. The inclusion of passthrough and playback LLMs enable rapid development and test of Python glue-code for your applications.
|
20
20
|
|
21
21
|
> [!IMPORTANT]
|
22
|
+
>
|
22
23
|
> `fast-agent` The fast-agent documentation repo is here: https://github.com/evalstate/fast-agent-docs. Please feel free to submit PRs for documentation, experience reports or other content you think others may find helpful. All help and feedback warmly received.
|
23
24
|
|
24
25
|
### Agent Application Development
|
@@ -36,12 +37,12 @@ Simple model selection makes testing Model <-> MCP Server interaction painless.
|
|
36
37
|
Start by installing the [uv package manager](https://docs.astral.sh/uv/) for Python. Then:
|
37
38
|
|
38
39
|
```bash
|
39
|
-
uv pip install fast-agent-mcp
|
40
|
+
uv pip install fast-agent-mcp # install fast-agent!
|
40
41
|
|
41
|
-
fast-agent setup
|
42
|
-
uv run agent.py
|
43
|
-
uv run agent.py --model=o3-mini.low
|
44
|
-
fast-agent quickstart workflow
|
42
|
+
uv run fast-agent setup # create an example agent and config files
|
43
|
+
uv run agent.py # run your first agent
|
44
|
+
uv run agent.py --model=o3-mini.low # specify a model
|
45
|
+
uv run fast-agent quickstart workflow # create "building effective agents" examples
|
45
46
|
```
|
46
47
|
|
47
48
|
Other quickstart examples include a Researcher Agent (with Evaluator-Optimizer workflow) and Data Analysis Agent (similar to the ChatGPT experience), demonstrating MCP Roots support.
|
@@ -0,0 +1,55 @@
|
|
1
|
+
# About the tensorzero / fast-agent integration
|
2
|
+
|
3
|
+
[TensorZero](https://www.tensorzero.com/) is an open source project designed to help LLM application developers rapidly improve their inference calls. Its core features include:
|
4
|
+
|
5
|
+
- A uniform inference interface to all leading LLM platforms.
|
6
|
+
- The ability to dynamic route to different platforms and program failovers.
|
7
|
+
- Automated parameter tuning and training
|
8
|
+
- Advance templating features for your system prompts
|
9
|
+
- Organization of LLM inference data into a Clickhouse DB allowing for sophisticated downstream analytics
|
10
|
+
- A bunch of other good stuff is always in development
|
11
|
+
|
12
|
+
`tensorzero` is powerful heavy, so we provide here a quickstart example that combines the basic components of `fast-agent`, an MCP server, `tensorzero`, and other supporting services into a cohesive whole.
|
13
|
+
|
14
|
+
## Quickstart guide
|
15
|
+
|
16
|
+
- Build and activate the `uv` `fast-agent` environment
|
17
|
+
- Ensure that ports `3000`, `4000`, `8000`, `9000`, and `9001` are unallocated before running this demo.
|
18
|
+
- Run `cp .env.sample .env` and then drop in at least one of `OPENAI_API_KEY` or `ANTHROPIC_API_KEY`. Make sure the accounts are funded.
|
19
|
+
- `make up`
|
20
|
+
- `make agent`
|
21
|
+
|
22
|
+
The demo test's our implementation's ability to:
|
23
|
+
|
24
|
+
- Implement the T0 model gateway as an inference backend
|
25
|
+
- Implement T0's dynamic templating feature
|
26
|
+
- Have in-conversation memory
|
27
|
+
- Describe and execute tool calls
|
28
|
+
- Remember previous tool calls
|
29
|
+
|
30
|
+
A version of a conversation to test all of this could be:
|
31
|
+
|
32
|
+
```
|
33
|
+
Hi.
|
34
|
+
|
35
|
+
Tell me a poem.
|
36
|
+
|
37
|
+
Do you have any tools that you can use?
|
38
|
+
|
39
|
+
Please demonstrate the use of that tool on your last response.
|
40
|
+
|
41
|
+
Please summarize the conversation so far.
|
42
|
+
|
43
|
+
What tool calls have you executed in this session, and what were their results?
|
44
|
+
```
|
45
|
+
|
46
|
+
## Multimodal support
|
47
|
+
|
48
|
+
Run `make image-test` to test the gateway's ability to handle base64-encoded image data
|
49
|
+
|
50
|
+
## Development notes:
|
51
|
+
|
52
|
+
- `make stop` will stop the MCP server and the tensorzero server
|
53
|
+
- `make tenzorzero-logs` will tail the tensorzero server logs
|
54
|
+
- `make mcp-logs` will tail the MCP server logs
|
55
|
+
- Generic `make logs` dumps all log output from all services to terminal
|
@@ -0,0 +1,36 @@
|
|
1
|
+
import asyncio
|
2
|
+
|
3
|
+
from mcp_agent.core.fastagent import FastAgent
|
4
|
+
from mcp_agent.core.request_params import RequestParams
|
5
|
+
|
6
|
+
# Explicitly provide the path to the config file in the current directory
|
7
|
+
CONFIG_FILE = "fastagent.config.yaml"
|
8
|
+
fast = FastAgent("fast-agent example", config_path=CONFIG_FILE, ignore_unknown_args=True)
|
9
|
+
|
10
|
+
# Define T0 system variables here
|
11
|
+
my_t0_system_vars = {
|
12
|
+
"TEST_VARIABLE_1": "Roses are red",
|
13
|
+
"TEST_VARIABLE_2": "Violets are blue",
|
14
|
+
"TEST_VARIABLE_3": "Sugar is sweet",
|
15
|
+
"TEST_VARIABLE_4": "Vibe code responsibly 👍",
|
16
|
+
}
|
17
|
+
|
18
|
+
|
19
|
+
@fast.agent(
|
20
|
+
name="default",
|
21
|
+
instruction="""
|
22
|
+
You are an agent dedicated to helping developers understand the relationship between TensoZero and fast-agent. If the user makes a request
|
23
|
+
that requires you to invoke the test tools, please do so. When you use the tool, describe your rationale for doing so.
|
24
|
+
""",
|
25
|
+
servers=["tester"],
|
26
|
+
request_params=RequestParams(template_vars=my_t0_system_vars),
|
27
|
+
)
|
28
|
+
async def main():
|
29
|
+
async with fast.run() as agent_app: # Get the AgentApp wrapper
|
30
|
+
agent_name = "default"
|
31
|
+
print("\nStarting interactive session with template_vars set via decorator...")
|
32
|
+
await agent_app.interactive(agent=agent_name)
|
33
|
+
|
34
|
+
|
35
|
+
if __name__ == "__main__":
|
36
|
+
asyncio.run(main()) # type: ignore
|
@@ -0,0 +1,104 @@
|
|
1
|
+
# This is a simplified example for learning purposes. Do not use this in production.
|
2
|
+
# For production-ready deployments, see: https://www.tensorzero.com/docs/gateway/deployment
|
3
|
+
|
4
|
+
# Top-level volumes definition
|
5
|
+
volumes:
|
6
|
+
minio_data: {}
|
7
|
+
|
8
|
+
services:
|
9
|
+
clickhouse:
|
10
|
+
image: clickhouse/clickhouse-server:24.12-alpine
|
11
|
+
environment:
|
12
|
+
CLICKHOUSE_USER: chuser
|
13
|
+
CLICKHOUSE_DEFAULT_ACCESS_MANAGEMENT: 1
|
14
|
+
CLICKHOUSE_PASSWORD: chpassword
|
15
|
+
ports:
|
16
|
+
- "8123:8123"
|
17
|
+
healthcheck:
|
18
|
+
test: wget --spider --tries 1 http://chuser:chpassword@clickhouse:8123/ping
|
19
|
+
start_period: 30s
|
20
|
+
start_interval: 1s
|
21
|
+
timeout: 1s
|
22
|
+
|
23
|
+
gateway:
|
24
|
+
image: tensorzero/gateway
|
25
|
+
volumes:
|
26
|
+
- ./tensorzero_config:/app/config:ro
|
27
|
+
env_file:
|
28
|
+
- ./.env
|
29
|
+
command: --config-file /app/config/tensorzero.toml
|
30
|
+
environment: # WARNING: Insecure default credentials for local testing ONLY. Don't send this to production.
|
31
|
+
TENSORZERO_CLICKHOUSE_URL: http://chuser:chpassword@clickhouse:8123/tensorzero
|
32
|
+
S3_ACCESS_KEY_ID: user
|
33
|
+
S3_SECRET_ACCESS_KEY: password
|
34
|
+
ports:
|
35
|
+
- "3000:3000"
|
36
|
+
extra_hosts:
|
37
|
+
- "host.docker.internal:host-gateway"
|
38
|
+
depends_on:
|
39
|
+
clickhouse:
|
40
|
+
condition: service_healthy
|
41
|
+
minio:
|
42
|
+
condition: service_healthy
|
43
|
+
mcp-server:
|
44
|
+
condition: service_healthy
|
45
|
+
|
46
|
+
gateway-ui:
|
47
|
+
image: tensorzero/ui
|
48
|
+
volumes:
|
49
|
+
- ./tensorzero_config:/app/config:ro
|
50
|
+
env_file:
|
51
|
+
- ./.env
|
52
|
+
command: --config-file /app/config/tensorzero.toml
|
53
|
+
environment:
|
54
|
+
TENSORZERO_CLICKHOUSE_URL: http://chuser:chpassword@clickhouse:8123/tensorzero
|
55
|
+
TENSORZERO_GATEWAY_URL: http://gateway:3000
|
56
|
+
S3_ACCESS_KEY_ID: user
|
57
|
+
S3_SECRET_ACCESS_KEY: password
|
58
|
+
ports:
|
59
|
+
- "4000:4000"
|
60
|
+
depends_on:
|
61
|
+
clickhouse:
|
62
|
+
condition: service_healthy
|
63
|
+
|
64
|
+
mcp-server:
|
65
|
+
build:
|
66
|
+
context: ../..
|
67
|
+
dockerfile: examples/tensorzero/mcp_server/Dockerfile
|
68
|
+
volumes:
|
69
|
+
- ./mcp_server:/app
|
70
|
+
ports:
|
71
|
+
- "8000:8000"
|
72
|
+
depends_on:
|
73
|
+
minio:
|
74
|
+
condition: service_healthy
|
75
|
+
healthcheck:
|
76
|
+
test:
|
77
|
+
[
|
78
|
+
"CMD",
|
79
|
+
"wget",
|
80
|
+
"--spider",
|
81
|
+
"--tries=1",
|
82
|
+
"http://localhost:8000/t0-example-server/sse",
|
83
|
+
]
|
84
|
+
interval: 10s
|
85
|
+
timeout: 5s
|
86
|
+
retries: 12
|
87
|
+
start_period: 20s
|
88
|
+
|
89
|
+
minio:
|
90
|
+
image: minio/minio:latest
|
91
|
+
ports:
|
92
|
+
- "9000:9000" # API port
|
93
|
+
- "9001:9001" # Console port
|
94
|
+
volumes:
|
95
|
+
- minio_data:/data
|
96
|
+
environment: # WARNING: Insecure default credentials for local testing ONLY.
|
97
|
+
MINIO_ROOT_USER: user
|
98
|
+
MINIO_ROOT_PASSWORD: password
|
99
|
+
command: server /data --console-address :9001
|
100
|
+
healthcheck:
|
101
|
+
test: ["CMD", "curl", "-f", "http://localhost:9000/minio/health/live"]
|
102
|
+
interval: 30s
|
103
|
+
timeout: 20s
|
104
|
+
retries: 3
|
@@ -0,0 +1,18 @@
|
|
1
|
+
default_model: haiku
|
2
|
+
|
3
|
+
tensorzero:
|
4
|
+
base_url: http://localhost:3000
|
5
|
+
|
6
|
+
logger:
|
7
|
+
level: "info"
|
8
|
+
progress_display: true
|
9
|
+
show_chat: true
|
10
|
+
show_tools: true
|
11
|
+
truncate_tools: true
|
12
|
+
|
13
|
+
mcp:
|
14
|
+
servers:
|
15
|
+
tester:
|
16
|
+
transport: "sse"
|
17
|
+
url: "http://localhost:8000/t0-example-server/sse"
|
18
|
+
read_transport_sse_timeout_seconds: 300
|
@@ -0,0 +1,67 @@
|
|
1
|
+
import asyncio
|
2
|
+
import base64
|
3
|
+
import mimetypes
|
4
|
+
from pathlib import Path
|
5
|
+
from typing import List, Union
|
6
|
+
|
7
|
+
from mcp.types import ImageContent, TextContent
|
8
|
+
|
9
|
+
from mcp_agent.core.fastagent import FastAgent
|
10
|
+
from mcp_agent.core.prompt import Prompt
|
11
|
+
from mcp_agent.core.request_params import RequestParams
|
12
|
+
|
13
|
+
AGENT_NAME = "tensorzero_image_tester"
|
14
|
+
TENSORZERO_MODEL = "tensorzero.test_chat"
|
15
|
+
TEXT_PROMPT = (
|
16
|
+
"Provide a description of the similarities and differences between these three images."
|
17
|
+
)
|
18
|
+
LOCAL_IMAGE_FILES = [
|
19
|
+
Path("./demo_images/clam.jpg"),
|
20
|
+
Path("./demo_images/shrimp.png"),
|
21
|
+
Path("./demo_images/crab.png"),
|
22
|
+
]
|
23
|
+
|
24
|
+
MY_T0_SYSTEM_VARS = {
|
25
|
+
"TEST_VARIABLE_1": "Roses are red",
|
26
|
+
"TEST_VARIABLE_2": "Violets are blue",
|
27
|
+
"TEST_VARIABLE_3": "Sugar is sweet",
|
28
|
+
"TEST_VARIABLE_4": "Vibe code responsibly 👍",
|
29
|
+
}
|
30
|
+
|
31
|
+
fast = FastAgent("TensorZero Image Demo - Base64 Only")
|
32
|
+
|
33
|
+
|
34
|
+
@fast.agent(
|
35
|
+
name=AGENT_NAME,
|
36
|
+
model=TENSORZERO_MODEL,
|
37
|
+
request_params=RequestParams(template_vars=MY_T0_SYSTEM_VARS),
|
38
|
+
)
|
39
|
+
async def main():
|
40
|
+
content_parts: List[Union[TextContent, ImageContent]] = []
|
41
|
+
content_parts.append(TextContent(type="text", text=TEXT_PROMPT))
|
42
|
+
|
43
|
+
for file_path in LOCAL_IMAGE_FILES:
|
44
|
+
mime_type, _ = mimetypes.guess_type(file_path)
|
45
|
+
if not mime_type or not mime_type.startswith("image/"):
|
46
|
+
ext = file_path.suffix.lower()
|
47
|
+
if ext == ".jpg" or ext == ".jpeg":
|
48
|
+
mime_type = "image/jpeg"
|
49
|
+
elif ext == ".png":
|
50
|
+
mime_type = "image/png"
|
51
|
+
if mime_type is None:
|
52
|
+
mime_type = "image/png" # Default fallback if still None
|
53
|
+
|
54
|
+
with open(file_path, "rb") as image_file:
|
55
|
+
image_bytes = image_file.read()
|
56
|
+
|
57
|
+
encoded_data = base64.b64encode(image_bytes).decode("utf-8")
|
58
|
+
content_parts.append(ImageContent(type="image", mimeType=mime_type, data=encoded_data))
|
59
|
+
|
60
|
+
message = Prompt.user(*content_parts)
|
61
|
+
async with fast.run() as agent_app:
|
62
|
+
agent = getattr(agent_app, AGENT_NAME)
|
63
|
+
await agent.send(message)
|
64
|
+
|
65
|
+
|
66
|
+
if __name__ == "__main__":
|
67
|
+
asyncio.run(main()) # type: ignore
|
@@ -0,0 +1,31 @@
|
|
1
|
+
import uvicorn
|
2
|
+
from mcp.server.fastmcp.server import FastMCP
|
3
|
+
from starlette.applications import Starlette
|
4
|
+
from starlette.routing import Mount
|
5
|
+
|
6
|
+
SERVER_PATH = "t0-example-server"
|
7
|
+
|
8
|
+
|
9
|
+
mcp_instance = FastMCP(name="t0-example-server")
|
10
|
+
mcp_instance.settings.message_path = f"/{SERVER_PATH}/messages/"
|
11
|
+
mcp_instance.settings.sse_path = f"/{SERVER_PATH}/sse"
|
12
|
+
|
13
|
+
|
14
|
+
@mcp_instance.tool()
|
15
|
+
def example_tool(input_text: str) -> str:
|
16
|
+
"""Example tool that reverses the text of a given string."""
|
17
|
+
reversed_text = input_text[::-1]
|
18
|
+
return reversed_text
|
19
|
+
|
20
|
+
|
21
|
+
app = Starlette(
|
22
|
+
routes=[
|
23
|
+
Mount("/", app=mcp_instance.sse_app()),
|
24
|
+
]
|
25
|
+
)
|
26
|
+
|
27
|
+
if __name__ == "__main__":
|
28
|
+
print(f"Starting minimal MCP server ({mcp_instance.name}) on http://127.0.0.1:8000")
|
29
|
+
print(f" -> SSE endpoint: {mcp_instance.settings.sse_path}")
|
30
|
+
print(f" -> Message endpoint: {mcp_instance.settings.message_path}")
|
31
|
+
uvicorn.run(app, host="127.0.0.1", port=8000)
|
@@ -0,0 +1,25 @@
|
|
1
|
+
import asyncio
|
2
|
+
|
3
|
+
from mcp_agent.core.fastagent import FastAgent
|
4
|
+
|
5
|
+
CONFIG_FILE = "fastagent.config.yaml"
|
6
|
+
fast = FastAgent("fast-agent example", config_path=CONFIG_FILE, ignore_unknown_args=True)
|
7
|
+
|
8
|
+
|
9
|
+
@fast.agent(
|
10
|
+
name="default",
|
11
|
+
instruction="""
|
12
|
+
You are an agent dedicated to helping developers understand the relationship between TensoZero and fast-agent. If the user makes a request
|
13
|
+
that requires you to invoke the test tools, please do so. When you use the tool, describe your rationale for doing so.
|
14
|
+
""",
|
15
|
+
servers=["tester"],
|
16
|
+
)
|
17
|
+
async def main():
|
18
|
+
async with fast.run() as agent_app:
|
19
|
+
agent_name = "default"
|
20
|
+
print("\nStarting interactive session with template_vars set via decorator...")
|
21
|
+
await agent_app.interactive(agent=agent_name)
|
22
|
+
|
23
|
+
|
24
|
+
if __name__ == "__main__":
|
25
|
+
asyncio.run(main()) # type: ignore
|
@@ -1,12 +1,11 @@
|
|
1
1
|
[project]
|
2
2
|
name = "fast-agent-mcp"
|
3
|
-
version = "0.2.
|
3
|
+
version = "0.2.23"
|
4
4
|
description = "Define, Prompt and Test MCP enabled Agents and Workflows"
|
5
5
|
readme = "README.md"
|
6
6
|
license = { file = "LICENSE" }
|
7
7
|
authors = [
|
8
8
|
{ name = "Shaun Smith", email = "fastagent@llmindset.co.uk"},
|
9
|
-
{ name = "Sarmad Qadri", email = "sarmad@lastmileai.dev" }
|
10
9
|
]
|
11
10
|
classifiers = [
|
12
11
|
"Programming Language :: Python :: 3",
|
@@ -16,7 +15,7 @@ classifiers = [
|
|
16
15
|
requires-python = ">=3.10"
|
17
16
|
dependencies = [
|
18
17
|
"fastapi>=0.115.6",
|
19
|
-
"mcp
|
18
|
+
"mcp>=1.8.0",
|
20
19
|
"opentelemetry-distro>=0.50b0",
|
21
20
|
"opentelemetry-exporter-otlp-proto-http>=1.29.0",
|
22
21
|
"pydantic-settings>=2.7.0",
|
@@ -31,6 +30,7 @@ dependencies = [
|
|
31
30
|
"a2a-types>=0.1.0",
|
32
31
|
"opentelemetry-instrumentation-openai>=0.39.3",
|
33
32
|
"opentelemetry-instrumentation-anthropic>=0.39.3",
|
33
|
+
"tensorzero>=2025.4.7",
|
34
34
|
]
|
35
35
|
|
36
36
|
[project.optional-dependencies]
|
@@ -100,6 +100,7 @@ dev = [
|
|
100
100
|
"pytest>=7.4.0",
|
101
101
|
"pytest-asyncio>=0.21.1",
|
102
102
|
"pytest-cov>=6.1.1",
|
103
|
+
"ipdb>=0.13.13",
|
103
104
|
]
|
104
105
|
|
105
106
|
[project.scripts]
|
{fast_agent_mcp-0.2.21 → fast_agent_mcp-0.2.23}/src/mcp_agent/agents/workflow/orchestrator_agent.py
RENAMED
@@ -229,7 +229,7 @@ class OrchestratorAgent(BaseAgent):
|
|
229
229
|
self.logger.warning(
|
230
230
|
f"Reached maximum step limit ({max_steps}) without completing objective"
|
231
231
|
)
|
232
|
-
plan_result.
|
232
|
+
plan_result.max_iterations_reached = True
|
233
233
|
break
|
234
234
|
|
235
235
|
# Execute the step and collect results
|
@@ -239,7 +239,7 @@ class OrchestratorAgent(BaseAgent):
|
|
239
239
|
total_steps_executed += 1
|
240
240
|
|
241
241
|
# Check if we need to break due to hitting max steps
|
242
|
-
if getattr(plan_result, "
|
242
|
+
if getattr(plan_result, "max_iterations_reached", False):
|
243
243
|
break
|
244
244
|
|
245
245
|
# If the plan is marked complete, finalize the result
|