Vignette: Gather useful context with btw()

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

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
72/100
Issue type
Documentation
Clarity
Mostly clear
Activity status
Active
Tech stack
r
Domain
documentation

Research direction

Start by reading the existing btw-md and custom-agents vignettes, then inspect the current source to verify the btw() and btw_this() APIs and behavior. Build a focused, task-first vignette around a concrete analysis or debugging question, run its executable examples in a fresh session, and render it successfully.

Written by the indexing model from the issue text.

Description

documentation

Goal and audience

Introduce the context-gathering workflow to R users who want help from any LLM, including a browser-based chat. Start with an analysis question and incrementally assemble enough context for the model to answer without guessing about the data or code.

The destination is a focused context bundle the reader can paste into their preferred chat. Most examples should work without an LLM provider.

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.

  • Start with an R object and a question using btw().
  • Add a relevant function, help page, package description, or project file.
  • Explain the assembled output and clipboard workflow.
  • Use btw_this() to inspect a description without assembling a clipboard bundle.
  • Explain what summaries preserve and omit, especially for data frames.
  • Demonstrate selecting relevant context rather than sending the whole workspace.

Suggested boundaries

Avoid an exhaustive command-alias catalog, custom description-method development, or a tool-enabled chat tutorial. Link to reference documentation for the broader surface.

Writing guidance

Use the task-first, incremental teaching approach of the btw-md and custom-agents vignettes. Verify APIs and described behavior against source; run executable examples and render in a fresh session. Prefer a concrete analysis or debugging question over a tour of input types.

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.