GW

givhvy/word-mcp

Developer tools

このページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。 原文を見る

0 stars 0 forks 品質 70 トレンド 14

Windows PC上で実行されるMicrosoft Word用のMCPサーバー:完全なドキュメントのコンテキストを読み込み、画像とページ、編集、フォーマット、コメント、および応答を参照してください.

概要

ローカルファイルやSharePoint / OneDrive文書でAIエージェントが、Wordデスクトップで開くようにするMCPサーバー。 あなたが見ている間、エージェントは、あなたの開いた文書にまっすぐなタイプ:クローズ、再オープンなし、あなたの背中の後ろに保存しません。 エージェントで技術的な文書を書くために構築: - エージェントは、コードベースを読み込み、セクション全体(ヘッディング、リスト、コードブロック、テーブル、スクリーンショット、数字のキャプションを持つ図)をword insert markdownで書きます。 - それはあなたが自分自身をタイプし、保存されていないものを含む、その画像とコメント(word context)を読み込み、Wordがそれらをレンダリングするページを正確に表示します。 - それは最後に見たので、それは通知します(単語をコピーして、テキストをコピーし、テキストをコピーし、テキストをコピーして、テキストをコピーして、テキストをコピーします.

概要(AI 翻訳)

Windows PCで開くMicrosoft Wordの内部でAIエージェントが動作させるMCPサーバー ローカルファイルとSharePoint / OneDrive文書がWordデスクトップで開きます。 エージェントはストレートタイプ あなたが見ている間あなたの開いた文書に:閉鎖無し、再開し、あなたの背部の後ろの保存無し。

代理人と技術的な文書を書くために造られる:

  • エージェントは、コードベースを読み、セクション全体(見出し、リスト、コードブロック、テーブル、 [word_insert_markdownで** 1つの呼び出しで、数えられたキャプションを持つスクリーンショットと図。
  • それはあなたが自分自身をタイプし、保存されていないものを含む、**Wholeライブ文書を読む その画像とコメント(word_context])は、Wordがそれらをレンダリングするページを正確に表示します。
  • 最後の検索([[word_changes])から**あなたの編集に気づくし、テキストを見出して場所をターゲットに、 自分の文章や文章を安全に混在させることができます。
  • ドキュメントのハウススタイルに従う書き込みはすべて:テンプレートの見出し、ボディ、 リスト、テーブル、コード、キャプションスタイル(ドキュメントから検出、またはテンプレートファイルからコピー)。
  • 保存はあなたの決定(Ctrl + S):あなたが尋ねない限り、エージェントは保存しません.

このページは AI により自動翻訳されています。技術的な詳細は原文をご確認ください。

README

以下は原文 README の抜粋です。原文を見る。

word-mcp

An MCP server that lets an AI agent work inside the Microsoft Word that is open on your Windows PC, on local files and on SharePoint / OneDrive documents opened in Word desktop. The agent types straight into your open document while you watch: no closing, no reopening, no saving behind your back.

Built for writing technical documents with an agent:

  • the agent reads your codebase and writes whole sections (headings, lists, code blocks, tables, screenshots and diagrams with numbered captions) in one call with word_insert_markdown;
  • it reads the whole live document, including what you typed yourself and have not saved, with its images and comments (word_context), and sees pages exactly as Word renders them;
  • it notices your edits since it last looked (word_changes) and targets places by heading text, so your own writing and its writing can be mixed safely;
  • everything it writes follows the document’s house style: your template’s own heading, body, list, table, code and caption styles (detected from the document, or copied from a template file);
  • saving stays your decision (Ctrl+S): the agent never saves unless you ask.

It uses Word’s own COM automation API, so everything happens in the real Word window, and every agent edit is a single Ctrl+Z step.

Requirements

  • Windows 10 or 11
  • Microsoft Word desktop (Microsoft 365, 2021, 2019 or 2016). Word on the web and Word for Mac do not work.
  • Python 3.10 or newer

Install

1. Get the code and install dependencies

A virtual environment keeps the dependencies away from your other Python projects, and gives the MCP client one fixed python.exe to launch.

git clone https://github.com/givhvy/word-mcp.git
cd word-mcp
python -m venv .venv
.\.venv\Scripts\python.exe -m pip install -r requirements.txt

Check Python can reach Word (prints its version, changes nothing). Word must be installed; it does not need to be open.

.\.venv\Scripts\python.exe -c "import win32com.client as c; print('Word', c.Dispatch('Word.Application').Version)"

2. Register it with your agent

Rules that apply to every client:

  • The command is the full path to the venv’s python.exe, followed by the full path to word_mcp_server.py. Relative paths break because the client starts the server from its own working directory.
  • The server talks over stdio. Do not run it by hand to “start” it: the client launches it.
  • Below, replace C:\path\to\word-mcp with the folder you cloned into.
  • The default name is word-huy. It is the key in each config below (and the name after claude mcp add). You can use any other name. The name only sets the tool prefix, for example mcp__word-huy__... in Claude Code or word-huy_... in OpenCode. If you rename it, use your name wherever this README says word-huy.
  • The -I flag runs Python isolated from the current directory. It is optional but recommended.
GitHub で README 全文を見る

インストール

This server does not publish a one-line install command.

Open the repository installation guide MCP 初心者?mcpskill.org のガイドから始めましょう →

設定

{ "mcpServers": { "word-huy": { "command": "C:\\path\\to\\word-mcp\\.venv\\Scripts\\python.exe", "args": ["-I", "C:\\path\\to\\word-mcp\\word_mcp_server.py"] } } }