Skip to content

feat: word plugin using inline LLM#27

Open
valdo404 wants to merge 4 commits intoclaude/mcp-server-ui-design-VvKe5from
claude/word-llm-plugin-Sh67w
Open

feat: word plugin using inline LLM#27
valdo404 wants to merge 4 commits intoclaude/mcp-server-ui-design-VvKe5from
claude/word-llm-plugin-Sh67w

Conversation

@valdo404
Copy link
Copy Markdown
Owner

@valdo404 valdo404 commented Feb 3, 2026

Architecture plan for a read-only session browser UI (docx-ui binary):

  • Back-end: Kestrel Minimal API with CreateSlimBuilder (NativeAOT, zero
    reflection, source-generated JSON)
  • Front-end: vanilla JS SPA with Fluent UI Web Components (Microsoft
    design system) and docx-preview.js for native DOCX rendering
  • Real-time: SSE (Server-Sent Events) via FileSystemWatcher + polling
    fallback for live session/patch notifications
  • 5 REST endpoints: sessions list, detail, DOCX bytes at position,
    history, and SSE event stream
  • LRU cache for reconstructed documents (slider scrubbing performance)
  • CLI integration: docx-cli server [--port N] launches docx-ui
  • No npm/webpack/vite: vendorized JS libs, ES modules, zero build step

https://claude.ai/code/session_01AVZcLrhY6w4QujyzEAnLUJ

Closes #8

@valdo404 valdo404 changed the title docs: add UI design plan — NativeAOT Minimal API + Fluent UI Web Components feat: word plugin using inline LLM Feb 3, 2026
@valdo404 valdo404 force-pushed the claude/word-llm-plugin-Sh67w branch from e072bc6 to bffb8c1 Compare February 4, 2026 12:42
claude and others added 4 commits February 4, 2026 14:06
## Backend (DocxMcp.WordAddin)
- ASP.NET Minimal API with SSE streaming endpoint
- ClaudeService for streaming Claude API responses
- UserChangeService for tracking user changes as logical patches
- CORS support for Office.js add-in

## Frontend (word-addin)
- Office.js add-in with TypeScript + React + Fluent UI
- WordService: wrapper around Word JavaScript API
- ChangeTracker: detects user changes, sends to backend as logical patches
- LlmClient: receives streaming patches via SSE, applies to Word
- Task Pane UI with chat interface and patch visualization

## Architecture
- User changes → logical patches (semantic: added/removed/modified/moved)
- LLM changes → normal patches (JSON RFC 6902: add/replace/remove)
- Real-time streaming via Server-Sent Events (SSE)

https://claude.ai/code/session_01LUhRKQAbk9v2pT25K6LSke
…sistant

- Like Clippy, but actually helpful!
- Updated manifest with new branding and Clippy-style welcome message
- Added paperclip emoji throughout UI
- Renamed package and assembly to 'doccy'

"It looks like you're writing a document. Would you like help with that?"

https://claude.ai/code/session_01LUhRKQAbk9v2pT25K6LSke
- PowerShell script with full options (path, pull, interactive mode)
- Batch script for simple usage
- OneDrive "Files On-Demand" warning included

Usage:
  .\run-docker-windows.ps1 -Pull
  .\run-docker-windows.bat pull

https://claude.ai/code/session_01LUhRKQAbk9v2pT25K6LSke
- Upgrade Anthropic.SDK from 3.7.0 to 5.9.0 (fixes MessageParameters.System API)
- Migrate streaming from type-based pattern matching to property-based (SDK 5.x API)
- Convert LlmEditRequest and LlmPatch to records (fixes CS8858 'with' expression)
- Fix InternalsVisibleTo to use assembly name 'docx-ui' instead of 'DocxMcp.Ui'

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
@valdo404 valdo404 force-pushed the claude/word-llm-plugin-Sh67w branch from bffb8c1 to b82f873 Compare February 4, 2026 13:07
@valdo404 valdo404 changed the base branch from main to claude/mcp-server-ui-design-VvKe5 February 4, 2026 13:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Build a microsoft word plugin

2 participants