Vignette: Connect a coding assistant to R through MCP

Open
#232 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
4/5
Estimated time
3-5 days
Newbie friendliness
52/100
Issue type
Documentation
Clarity
Mostly clear
Activity status
Active
Tech stack
r
Domain
ai, documentation

Research direction

Start by reviewing the existing documentation, btw_mcp_server(), btw_mcp_session(), and the CLI vignette, then verify one MCP-capable client against the current upstream instructions. Draft one end-to-end setup with a concrete documentation or package-development request, explaining process and session boundaries, working-directory assumptions, tool risks, and when CLI or session access is appropriate. Done means readers can establish the connection and understand its R-session and capability boundaries.

Written by the indexing model from the issue text.

Description

documentation

Goal and audience

Help users of an existing MCP-capable coding assistant connect to btw's R capabilities. Begin with R documentation and package tools, then optionally connect the assistant to an existing interactive R session.

The destination is a working connection whose R-session and capability boundaries the reader understands.

Proposed coverage — reassess before drafting

This is a starting proposal, not a fixed outline or required section order. Before writing, reassess the scope, example, and teaching sequence against the current implementation, existing documentation, and reader needs. Adjust, combine, or drop items as appropriate.

  • Configure one representative MCP client end to end using btw_mcp_server(). Select and verify that client before drafting.
  • Start with a focused tool set rather than duplicating the coding assistant's existing capabilities.
  • Demonstrate a concrete documentation or package-development request.
  • Explain the server's R process versus the reader's interactive R session.
  • Connect an existing session with btw_mcp_session() and demonstrate the difference.
  • Cover working-directory assumptions, tool selection, and risks of granting code execution or write capabilities.
  • Briefly distinguish when the CLI suffices from when session access makes MCP useful.

Suggested boundaries

Avoid MCP protocol internals and exhaustive client-configuration instructions. Teach one working setup and link to the broader reference/client documentation. Keep the CLI comparison short and cross-link the CLI vignette.

Writing guidance

Verify external client configuration against current upstream documentation as well as btw source. Be explicit about which process/session runs each operation and which setup is interactive versus blocking. Do not imply that restricted tool groups create a sandbox.

Dominant language
R
Stars
150
Forks
13
PR merge metrics
No merged PRs in 30d

Getting set up

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from posit-dev/btw

All issues in posit-dev/btw

Similar issues

More R issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.