关于
This skill installs and configures the `putior` R package for creating workflow visualizations from code annotations. It handles installation from CRAN or GitHub, manages optional dependencies, and verifies the complete annotation-to-diagram pipeline. Use it for initial setup, environment preparation, or when restoring an environment after upgrades.
快速安装
Claude Code
推荐npx skills add pjt222/agent-almanac -a claude-code/plugin add https://github.com/pjt222/agent-almanacgit clone https://github.com/pjt222/agent-almanac.git ~/.claude/skills/install-putior在 Claude Code 中复制并粘贴此命令以安装该技能
技能文档
裝 putior 套件
裝 putior R 套件及其選擇性依賴,使註解至圖之管線於專案中可用。本技能涵蓋核心裝、選擇性擴展之擇與管線之驗證。
適用時機
- 於專案或環境首次設 putior
- 為工作流程視覺化任務備機
- 下游技能(analyze-codebase-workflow、generate-workflow-diagram)需 putior 已裝
- R 版本升級或 renv 清除後恢復環境
輸入
- 必要:可存取之 R 安裝(>= 4.1.0)
- 選擇性:自 CRAN(預設)或 GitHub 開發版裝
- 選擇性:欲裝哪些選擇性依賴群:MCP(
mcptools、ellmer)、互動(shiny、shinyAce)、日誌(logger)、ACP(plumber2)
步驟
步驟一:驗 R 安裝
確 R 可用且合最低版本要求。
R.Version()$version.string
# Must be >= 4.1.0
# From WSL with Windows R
"/mnt/c/Program Files/R/R-4.5.2/bin/Rscript.exe" -e "cat(R.version.string)"
預期: R 版本字串印出,>= 4.1.0。
失敗時: 裝或升級 R。Windows 自 https://cran.r-project.org/bin/windows/base/ 下。Linux 用 sudo apt install r-base。
步驟二:裝 putior
自 CRAN(穩定)或 GitHub(開發)裝。
# CRAN (recommended)
install.packages("putior")
# GitHub dev version (if latest features needed)
remotes::install_github("pjt222/putior")
預期: 套件無錯裝。library(putior) 默載。
失敗時: 若 CRAN 裝失敗報「not available for this version of R」,用 GitHub 版。若 GitHub 失敗,核 remotes 已裝:install.packages("remotes")。
步驟三:裝選擇性依賴
依所需功能裝選擇性套件。
# MCP server integration (for AI assistant access)
remotes::install_github("posit-dev/mcptools")
install.packages("ellmer")
# Interactive sandbox
install.packages("shiny")
install.packages("shinyAce")
# Structured logging
install.packages("logger")
# ACP server (agent-to-agent communication)
install.packages("plumber2")
預期: 每套件無錯裝。 各套件之功能:
mcptools+ellmer:令 AI 助理可經 MCP 存取 putiorshiny+shinyAce:啟瀏覽器基之互動沙箱logger:結構化日誌以供除錯plumber2:建 ACP 伺服器供代理間通訊
失敗時: mcptools 須先裝 remotes。
Linux 系統依賴錯則裝所需函式庫。
如 sudo apt install libcurl4-openssl-dev 為 httr2 之依賴。
於 macOS 可能需 brew install openssl。
步驟四:驗安裝
執基本管線以確一切運作。
library(putior)
# Check package version
packageVersion("putior")
# Verify core functions are available
stopifnot(
is.function(put),
is.function(put_auto),
is.function(put_diagram),
is.function(put_generate),
is.function(put_merge),
is.function(put_theme)
)
# Test basic pipeline with a temp file
tmp <- tempfile(fileext = ".R")
writeLines("# put id:'test', label:'Hello putior'", tmp)
cat(put_diagram(put(tmp)))
預期: Mermaid 流程圖代碼印至主控台含 test 與 Hello putior。
關鍵預設:所有掃描函數(
put()、put_auto()、put_generate()、put_merge())預設recursive = TRUE,自動掃子目錄。此為自 0.2.0 前版本之破壞性變更,彼時預設為FALSE。所有掃描函數亦接受exclude參數以供正則為基之檔過濾(如put("./src/", exclude = "test_"))。
若選擇性 shiny 套件已裝,試互動沙箱:
putior::run_sandbox()
此啟基於瀏覽器之編輯器,可試驗 PUT 註解語法並即時見圖渲染。
失敗時: 若 put 未覓,套件未正確裝。以 install.packages("putior", dependencies = TRUE) 重裝。若圖空,驗暫存檔已建且註解語法用單引號於雙引號內。
驗證
-
library(putior)無錯載 -
packageVersion("putior")返有效版本 -
put()於含有效 PUT 註解之檔返一列資料框 -
put_diagram()產以flowchart始之 Mermaid 代碼 - 所有所請之選擇性依賴無錯載
常見陷阱
- 引號嵌套錯:PUT 註解於註解內用單引號:
id:'name',非id:"name"(某些情境下與註解字串定界符衝突)。 - 無 Pandoc 缺小品文:若計畫本地建 putior 之小品文,確
RSTUDIO_PANDOC於.Renviron中設。 - renv 隔離:若專案用 renv,須於 renv 函式庫內裝 putior。執
renv::install("putior")而非install.packages("putior")。 - GitHub 速率限:自 GitHub 裝
mcptools可能無GITHUB_PAT而失敗。經usethis::create_github_token()設之。
相關技能
analyze-codebase-workflow— 裝後調查代碼庫之下步configure-putior-mcp— 裝選擇性依賴後設 MCP 伺服器manage-renv-dependencies— 於 renv 環境內管 putiorconfigure-mcp-server— 通用 MCP 伺服器配置
GitHub 仓库
Frequently asked questions
What is the install-putior skill?
install-putior is a Claude Skill by pjt222. Skills package instructions and resources that Claude loads on demand, so Claude can perform install-putior-related tasks without extra prompting.
How do I install install-putior?
Use the install commands on this page: add install-putior to Claude Code as a plugin, or clone its repository into your skills directory, then restart Claude so it picks up the skill.
What category does install-putior belong to?
install-putior is in the Meta category, tagged ai, api, mcp, automation and design.
Is install-putior free to use?
Yes. install-putior is listed on AIMCP and free to install. It runs inside Claude, so no separate service account is required to use the skill itself.
相关推荐技能
Content Collections 是一个 TypeScript 优先的构建工具,可将本地 Markdown/MDX 文件转换为类型安全的数据集合。它专为构建博客、文档站和内容密集型 Vite+React 应用而设计,提供基于 Zod 的自动模式验证。该工具涵盖从 Vite 插件配置、MDX 编译到生产环境部署的完整工作流。
这个Claude Skill为开发者提供完整的Polymarket预测市场开发支持,涵盖API调用、交易执行和市场数据分析。关键特性包括实时WebSocket数据流,可监控实时交易、订单和市场动态。开发者可用它构建预测市场应用、实施交易策略并集成实时市场预测功能。
该Skill帮助开发者创建OpenCode插件,用于接入命令、文件、LSP等25+种事件。它提供了插件结构、事件API规范和JavaScript/TypeScript实现模式,适合需要拦截操作、扩展功能或自定义事件处理的场景。开发者可通过它快速构建响应式模块来增强OpenCode AI助手的能力。
SGLang是一个专为LLM设计的高性能推理框架,特别适用于需要结构化输出的场景。它通过RadixAttention前缀缓存技术,在处理JSON、正则表达式、工具调用等具有重复前缀的复杂工作流时,能实现极速生成。如果你正在构建智能体或多轮对话系统,并追求远超vLLM的推理性能,SGLang是理想选择。
