feat(mcp): AI-oriented MCP tools and Claude Code plugin - #14
Merged
Conversation
Add comprehensive AI-oriented tools following the spec in dev-docs/ai-oriented-mcp-design.md: Phase 0 - Protocol Foundation: - Revision tracking system with optimistic concurrency control - Idempotency cache for request deduplication (5-min TTL) - get_capabilities and get_document_revision tools Phase 1 - Structure Layer: - get_document_ast with projections and filtering - get_document_digest for quick document overview - list_blocks for querying blocks by type/content - resolve_targets for pre-flight disambiguation - get_section for section-level access Phase 2 - Declarative Mutations: - batch_edit for atomic multi-operation edits - apply_diff for smart find/replace with match policies - replace_text_anchored for drift-tolerant replacements Phase 3 - Higher Abstractions: - Section operations (update, insert, move) - Table batch operations (add/delete rows/columns, update cells) - List batch operations (add/delete items, reorder, toggle checks) All tools support three modes: apply, suggest, dryRun. Integrates with existing suggestion system for user approval workflow.
Remove 5 AI-powered tools that required external AI service integration: - fix_grammar - improve_writing - translate - summarize - expand These were stubbed but never implemented.
- Fix apply_diff to use proper ProseMirror positions instead of textContent offsets, which caused wrong replacements in multi-block documents - Fix batch_edit to resolve nodeId to PM positions instead of using cursor, making operations deterministic and matching the API contract - Add validation for nth parameter: must be non-negative integer when matchPolicy="nth" - Add findTextMatches(), resolveNodeId(), getTextRange() helpers in utils.ts
- Add --version flag to print version and exit - Add --health-check flag to validate binary functionality: - Imports server module successfully - Lists all registered tools and resources - Validates tool schema structure - Update release workflow to run health checks after building sidecar for macOS, Windows, and Linux - Health check runs on native architecture, skips cross-builds This ensures corrupted or misconfigured binaries fail the release.
Three ways for users to check MCP server health: 1. **Status bar indicator** - Shows green/red dot with "MCP" label - Click to open detailed status dialog - Pulses when server is starting 2. **Settings panel** - Enhanced MCP section showing: - Version (0.2.0) - Tool count (76) - Resource count (4) - Last checked time - "Test Connection" button - "View Details" button 3. **Menu item** - Help → MCP Server Status... - Opens detailed diagnostic dialog - Shows all available tools - Copy tool list button New files: - src/stores/mcpHealthStore.ts - Shared health state - src/hooks/useMcpHealthCheck.ts - Health check logic - src/hooks/useMcpStatusMenuEvent.ts - Menu event handler - src/components/Dialogs/McpStatusDialog.tsx/css - Status dialog
- Sync vmark-mcp-server version from 0.2.0 to 0.3.10 - Update VERSION constant in cli.ts - Update MCP_VERSION in useMcpHealthCheck.ts Version bump procedure now includes: 1. package.json 2. src-tauri/tauri.conf.json 3. src-tauri/Cargo.toml 4. vmark-mcp-server/package.json 5. vmark-mcp-server/src/cli.ts
- Add "Checking MCP Status" section to mcp-setup.md documenting:
- Status bar indicator
- Status dialog
- Settings panel integration
- Add new AI-oriented tools to mcp-tools.md:
- Document inspection: get_capabilities, get_document_revision,
get_document_ast, get_document_digest, list_blocks, resolve_targets
- Section operations: get_section, update_section, insert_section, move_section
- Batch operations: batch_edit, apply_diff, replace_text_anchored
- Structure manipulation: table_modify, list_modify
- Merge latest website updates from main branch
Frontend handlers: - Remove duplicate isAutoApproveEnabled, import from utils - Fix TypeScript any casts with proper typed assertions MCP server tools: - Move TableTarget, ListTarget, SectionTarget types to bridge/types.ts - Replace `as any` casts with properly typed BridgeRequest - Use NewHeading type for heading parameters
Provides a comprehensive AI writing assistant skill that teaches Claude Code
how to effectively use VMark's MCP tools. Includes:
- Main SKILL.md with core principles and quick reference
- tools-by-intent.md: Maps writer intents to appropriate tools
- workflows.md: 9 detailed step-by-step patterns
- examples.md: Real tool calls with parameters and responses
Key design decisions:
- Writer-centric organization ("continue this thought" not "call batch_edit")
- Suggestion-first approach for content changes
- Read-before-write workflow
- Honest about limitations (no real-time, no alternatives)
Plugin structure enables distribution via Claude Code marketplace while
keeping source in the vmark repository.
- Add marketplace.json to make vmark a self-hosted marketplace - Add GitHub Action to auto-PR plugin updates to external marketplaces Users can now: 1. Add vmark directly as a marketplace source 2. Or install from every-marketplace after the sync PR is merged
- Fix repo name: EveryInc/compound-engineering-plugin (not every-marketplace) - Use fork (xiaolai/compound-engineering-plugin) for PRs - Sync fork with upstream before making changes - Create proper directory structure before copying - Add author and homepage to marketplace.json entry
Complete release automation: - Build app on v* tag - Publish release - Update homebrew tap - Sync Claude skill to marketplace All steps now triggered automatically on version tag.
- New page: claude-code-skill.md with installation and usage guide - Add to sidebar under AI Integration - Link from mcp-setup.md next steps
Transform README from developer-focused to user-friendly: - New headline: "The Markdown Editor That Gets It Right" - Lead with benefits, not tech stack - Add screenshot at top - Organize by user value: AI-Native, CJK, Two Modes, Design, Privacy - Simple installation instructions upfront - AI integration section with quick setup - Essential shortcuts table - Links to full documentation - Development guide moved to bottom (still present for contributors) Target audience: Writers, not just developers.
xiaolai
commented
Jan 28, 2026
xiaolai
left a comment
Owner
Author
There was a problem hiding this comment.
Code Review
Verdict: Ready to merge ✓
What's Good
- Solid AI-oriented MCP design with revision tracking + idempotency
- Structured tools follow read-before-write pattern
- Suggestion mode lets writers approve content changes
- Claude Code skill is comprehensive with 9 workflows
- Tests included for cache and protocol handlers
- UI additions follow design tokens
Minor Notes
- Table/list batch ops in suggest mode return warnings (expected limitation)
- Large PR (8979 lines) - future features could be smaller increments
Recommendation
CI should pass before merge. Otherwise looks good to ship.
- Fix suggestionHandlers.test.ts to properly mock isAutoApproveEnabled - Add --success-color-dark token for dark mode success indicators - Replace hardcoded #4ade80 with var(--success-color-dark) token
xiaolai
added a commit
that referenced
this pull request
Feb 19, 2026
Issues fixed: - #6: Add StatusBar warning when auto-save paused (file missing) - #15: Use Documents folder instead of Home for default save location - #19: Fix race condition in recent files menu by storing snapshot in Rust - #30: Fix dock icon drop when no document windows exist - #35: Show toast notification when file auto-reloads - #37: Add "Restore to Disk" context menu for missing files Additional improvements: - Add toast on pinned tab close attempt (#7) - Add toast on save failure (#5/#14) - Add toasts for drag-drop failures (#25, #26, #27) - Improve cold start file open reliability (#9, #34) - Fix no-window menu operations (#17, #18, #21)
xiaolai
added a commit
that referenced
this pull request
Feb 19, 2026
feat(mcp): AI-oriented MCP tools and Claude Code plugin
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Major overhaul of the VMark MCP server to be AI-oriented, plus a comprehensive Claude Code skill for interacting with VMark.
What's Changed
MCP Server Enhancements
get_capabilities,get_document_revisionfor discovery and concurrencyget_document_ast,get_document_digest,list_blocks,get_section,resolve_targetsbatch_edit,apply_diff,replace_text_anchoredwith suggestion/dryRun modesupdate_section,insert_section,move_sectiontable_modify,list_modifyfor atomic multi-operation supportClaude Code Plugin
New plugin structure for distribution via Claude Code marketplace:
CI/CD Automation
every-marketplaceon releaseOther Changes
Key Design Decisions
Test Plan
claude marketplace add github:xiaolai/vmark