MCP.so
ログイン

Gemini API with MCP Tool Integration

@hitechdk

基本情報

カテゴリ

AI とエージェント

ライセンス

MIT license

トランスポート

stdio

作者

hitechdk

Gemini API with MCP Tool Integration について

AI agent that retrieves weather data from the MCP server to provide automated forecasts. Ideal for integration into weather-related applications.

Gemini API with MCP Tool Integration の設定

以下の設定を使って、このサーバーを MCP 対応クライアントに追加してください。

{
  "mcpServers": {
    "weather-ai-agent": {
      "command": "python3",
      "args": [
        "-m",
        "venv",
        "venv"
      ]
    }
  }
}

Gemini API with MCP Tool Integration のツール

ツール一覧はまだありません

この掲載には表示できるツール一覧がまだありません。サーバーにツールがないという意味ではありません。対応機能はプロジェクトのドキュメントをご確認ください。

ツールは README から自動的に抽出されます。メンテナーは ## Tools という見出しの下に記載することで、このタブに反映できます。

概要

What is Gemini API with MCP Tool Integration?

This project integrates the Google Gemini API with custom tools managed by the MCP (Multi-Cloud Platform) framework. It processes natural language queries via Gemini and executes specific actions based on query intent using MCP tools.

How to use Gemini API with MCP Tool Integration?

Install Python 3.7+, set up a Google Cloud project with Gemini API enabled, configure a .env file with GEMINI_API_KEY, GEMINI_MODEL, MCP_RUNNER, and MCP_SCRIPT, then run python main.py. Customize prompt, get_contents(), and process_response() as needed.

Key features of Gemini API with MCP Tool Integration

  • Integrates Google Gemini API with MCP custom tools
  • Uses environment variables for configuration
  • Processes tool calls made by the model
  • Supports customizable prompt and response handling
  • Automates actions based on natural language queries

Use cases of Gemini API with MCP Tool Integration

  • Automating cloud tasks through natural language commands
  • Building AI assistants that trigger external tools
  • Prototyping applications combining Gemini with MCP-based services
  • Enabling conversational interfaces with backend action execution

よくある質問

1

What is the purpose of this integration?

It demonstrates how to combine the Gemini API with MCP framework tools to interpret natural language and perform corresponding actions.

2

What are the prerequisites?

Python 3.7+, a Google Cloud project with the Gemini API enabled, an API key, and an MCP environment with the necessary tools.

3

How do I install the required dependencies?

Use `uv` to install `dotenv`, `google-generativeai`, `mcp`, and other packages as listed in the README.

4

How do I run the application?

After setting up the `.env` file, execute `python main.py` from the project root.

コメント

「AI とエージェント」の他のコンテンツ