fyi

Get Complete Package Information for LLMs

Description

The main function - returns everything an LLM needs to understand a package, including exports, internals, options, and optionally full documentation.

Usage

 1fyi(
 2  package,
 3  src_dir = NULL,
 4  internals = TRUE,
 5  options = TRUE,
 6  exports = TRUE,
 7  docs = FALSE,
 8  pattern = NULL,
 9  max_exports = NULL,
10  max_internals = NULL,
11  max_topics = NULL
12)

Arguments

  • package: Character. Package name.
  • src_dir: Optional path to source directory for options extraction.
  • internals: Logical. Include internal functions? Default TRUE.
  • options: Logical. Include option names? Default TRUE.
  • exports: Logical. Include exported functions? Default TRUE.
  • docs: Logical. Include full documentation? Default FALSE (can be verbose).
  • pattern: Optional regex to filter exports/internals/topics.
  • max_exports: Maximum number of exports to show. Default NULL (all).
  • max_internals: Maximum number of internals to show. Default NULL (all).
  • max_topics: Maximum number of doc topics to list. Default NULL (all).

Value

Character string of markdown, invisibly. Also prints to console.

Examples

1fyi("sttapi")
2fyi("llamaR", internals = TRUE, options = FALSE)
3fyi("sttapi", docs = TRUE)  # Include full help docs
4
5# For large packages like torch, filter to reduce size
6fyi("torch", pattern = "^nn_", internals = FALSE)
7fyi("torch", max_exports = 50, max_internals = 0, max_topics = 50)