apache / apache/fesod

[Enhancement] Implement a Model Context Protocol (MCP) based agent for Fesod

Open
#613 4 comments 1 reaction 0 assignees View on GitHub
discussion welcome enhancement
Dominant language
Java
Stars
6.2k
Forks
532
Avg merge
1d 3h
Merged PRs (30d)
42

Description

### Search before asking

- [x] I searched in the [issues](https://github.com/apache/fesod/issues) and found nothing similar.

### Motivation

We would like to build an MCP (Model Context Protocol) based agent around Fesod so that its high‑performance spreadsheet (Excel) processing capabilities can be exposed as structured tools via an MCP server. This enables AI / LLM agents to perform spreadsheet analysis, automated data completion, querying, difference comparison, and workflow automation.

### Solution

1. Design and implement an MCP server adapter for Fesod supporting JSON-RPC over stdio (and optionally WebSocket/HTTP).
2. Register typical spreadsheet operation tools, e.g. `list_sheets`, `read_sheet_range`, `analyze`, `update`, `diff`, `export`, etc.
3. Support resource handles (workbook resourceId) to avoid repeated file loading.
4. Return structured JSON outputs optimized for LLM / agent consumption, including truncation indicators and metadata.
5. (Optional) Provide a declarative `transform_pipeline` tool for multi-step data processing (read → filter → derive → aggregate → export).
6. Establish unified error codes and JSON Schemas for tool inputs/outputs for better LLM alignment.
7. Introduce caching (LRU) and range limiting for performance and safety.

### Alternatives

1. Expose only a REST API wrapper around Fesod (less portable for emerging agent runtimes).
2. Provide only language-specific SDKs (Java/Python), which increases integration friction for heterogeneous AI toolchains.

### Anything else?

Recommend starting from a minimal viable set: `open_workbook`, `list_sheets`, `read_sheet_range`, `analyze`, then iteratively add `query`, `diff`, `update`, `export`, and finally `transform_pipeline`.

### Are you willing to submit a PR?

- [ ] I'm willing to submit a PR!

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.