Skip to main content
Glama
jenstangen1

PowerPoint MCP Server

by jenstangen1

PowerPoint MCP サーバー

AIの支援を受けてPowerPointプレゼンテーションを作成・操作するためのモデルコンテキストプロトコル(MCP)サーバー。このサーバーは、AIモデルがPowerPointファイルを操作するための包括的なAPIを提供し、高度な書式設定、財務チャート、データ統合をサポートします。

特徴

プレゼンテーション管理

  • PowerPoint プレゼンテーションの作成と変更

  • スライドの追加、削除、変更

  • ワークスペースからプレゼンテーションを保存および読み込む

  • テンプレート管理システム

要素操作

  • スライドの要素(テキスト、図形、画像、グラフ)を細かく制御します

  • 高度なシェイプの作成とスタイリング

  • 要素の配置とグループ化

  • 図形間のコネクタ線

金融統合

  • 財務チャート(折れ線グラフ、棒グラフ、縦棒グラフ、円グラフ、ウォーターフォールグラフなど)を作成します

  • 比較表を生成する

  • さまざまな財務指標のサポート:

    • 収益

    • EBITDA

    • 利益

    • 資産

    • 公平性

    • 成長率

    • マージン

  • 現在はダミーデータを使用していますが、ノルウェーの企業データ用にProff APIを統合する予定です。

  • APIカスタマイズにより他の金融データプロバイダーにも適応可能

スタイルとフォーマット

  • リッチテキストフォーマット

  • 図形のスタイル設定(塗りつぶし、グラデーション、アウトライン)

  • チャートのカスタマイズ

  • 背景色と効果

Related MCP server: MCP Server for Cappt

インストール

  1. リポジトリをクローンします。

git clone https://github.com/jenstangen1/pptx-mcp.git cd pptx-mcp
  1. 依存関係をインストールします:

pip install -r requirements.txt

クロードとのセットアップ

Claude のインターフェースに MCP をインストールする

この PowerPoint MCP を Claude と統合するには、次の JSON 構成を Claude MCP ファイルに追加します。

{ "mcpServers": { "powerpoint_mcp": { "command": "uv", "args": [ "--directory", "your directory here", "run", "mcp_powerpoint_server.py" ] } } }

注: インストール場所に合わせてディレクトリ パスを変更する必要がある場合があります。

利用可能なMCPツール

プレゼンテーション管理

  • list_presentations : ワークスペース内のすべての PowerPoint ファイルを一覧表示します

  • upload_presentation : 新しいプレゼンテーションをワークスペースにアップロードします

  • save_presentation : 現在のプレゼンテーションを保存する

スライド操作

  • add_slide : プレゼンテーションに新しいスライドを追加する

  • delete_slide : プレゼンテーションからスライドを削除する

  • get_slide_count : プレゼンテーション内のスライドの総数を取得する

  • analyze_slide : スライドの内容を分析する

  • set_background_color : スライドの背景色を設定する

要素操作

  • add_text : スライドにテキストを追加する

  • add_shape : スライドに図形を追加する

  • edit_element : 要素のプロパティを編集する

  • style_element : 要素にスタイルを適用する

  • connect_shapes : 2つの図形をコネクタで接続する

  • find_element : 条件に基づいてスライド上の要素を検索する

金融ツール

  • get_company_financials : 企業の財務データを取得します(現在はダミーデータを返します)

  • create_financial_chart : スライド上に財務チャートを作成する

  • create_comparison_table : 企業の比較表を作成する

**注:**金融ツールは現在ダミーデータを使用しています。将来のバージョンでは、ノルウェーの企業データを自動取得するためにProff APIとの統合を予定しています。ユーザーはコードを変更することで、ローカルまたは好みの金融データプロバイダーに接続できます。

テンプレート操作

  • list_templates : 利用可能なすべてのテンプレートを一覧表示する

  • apply_template : プレゼンテーションにテンプレートを適用する

  • create_slide_from_template : テンプレートから新しいスライドを作成する

  • save_as_template : スライドをテンプレートとして保存する

デバッグツール

  • debug_element_mappings : スライドの要素マッピングを検査するためのデバッグツール

使用法

サーバーの起動

サーバーを実行します。

python mcp_powerpoint_server.py

プレゼンテーションとテンプレートが存在しない場合は、サーバーによってワークスペース ディレクトリが作成されます。

基本操作

# List presentations presentations = mcp.list_presentations() # Create a new slide slide_index = mcp.add_slide(presentation_path, layout_name="Title and Content") # Add text to a slide element_id = mcp.add_text( presentation_path=presentation_path, slide_index=slide_index, text="Hello World", position=[1.0, 1.0], font_size=24 ) # Add a shape shape_id = mcp.add_shape( presentation_path=presentation_path, slide_index=slide_index, shape_type="rectangle", position={"x": 2.0, "y": 2.0}, size={"width": 2.0, "height": 1.0} )

財務チャート

# Create a financial chart chart_id = mcp.create_financial_chart( presentation_path=presentation_path, slide_index=slide_index, chart_type="column", data={ "categories": ["2020", "2021", "2022"], "series": [{ "name": "Revenue", "values": [1000000, 1200000, 1500000] }] }, position={"x": 1.0, "y": 1.0}, size={"width": 6.0, "height": 4.0}, title="Revenue Growth" ) # Create a comparison table table_id = mcp.create_comparison_table( presentation_path=presentation_path, slide_index=slide_index, companies=["Company A", "Company B"], metrics=["revenue", "ebitda", "margin"], position={"x": 1.0, "y": 1.0}, title="Company Comparison" )

テンプレート管理

# List available templates templates = mcp.list_templates() # Apply a template mcp.apply_template( presentation_path=presentation_path, template_name="financial_report", options={ "apply_master": True, "apply_theme": True, "apply_layouts": True } ) # Create a slide from template mcp.create_slide_from_template( presentation_path=presentation_path, template_name="comparison_slide", content={ "title": "Market Analysis", "subtitle": "Q3 2023" } )

ディレクトリ構造

pptx-mcp/ ├── mcp_powerpoint_server.py # Main server implementation ├── requirements.txt # Python dependencies ├── presentations/ # Workspace for presentations │ └── templates/ # Template storage └── README.md # This file

依存関係

  • python-pptx: PowerPoint ファイルの操作

  • 枕:画像処理

  • numpy: 数値演算

  • MCP SDK: モデルコンテキストプロトコルの実装

貢献

貢献を歓迎します!お気軽にプルリクエストを送信してください。

ライセンス

このプロジェクトは MIT ライセンスに基づいてライセンスされています - 詳細については LICENSE ファイルを参照してください。

-
security - not tested
F
license - not found
-
quality - not tested

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/jenstangen1/pptx-xlsx-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server