DocScribe is a RubyMine plugin that auto-generates inline YARD documentation for Ruby methods using docscribe — a Ruby gem that analyzes AST and suggests YARD-compatible documentation. Compatible with docscribe >= 1.4.0 (daemon mode requires >= 1.5.1; validate-types, source routing and file-scoped update require >= 1.6.2).
Also, available for VS Code on the VS Code Marketplace.
- Fast daemon mode — persistent Ruby server via Unix socket JSON-RPC, eliminating CLI startup overhead on repeated operations
- Inline diagnostics — undocumented methods highlighted in the editor on file open and save
- Quick-fix intention — lightbulb action to generate YARD documentation with one click
- RBS type inference — uses RBS signatures for accurate
@paramand@returntypes (whengem "rbs"is in your Gemfile) - Workspace-wide check — scan all Ruby files in the project
- Flexible strategies — safe (document missing methods only) and aggressive (replace existing docs, preserve manual descriptions)
- Update types from RBS — refresh YARD docs from RBS signatures
- Invalid YARD type validation — highlights malformed YARD types like
Sym boleven without RBS (toggle in settings) - File-scoped Update Types — intention fixes current file only
- Collapsible YARD docs — fold all YARD comment blocks automatically on file open (configurable in settings)
- Configurable — hide comments by default
.rakeandRakefilesupport — diagnostics and actions work on Rake files and bare Rakefiles- Automatic backend selection — detects docscribe version on first use, chooses daemon (>= 1.5.1) or CLI fallback
- JSON output — uses
docscribe --format jsonfor reliable diagnostics parsing
- RubyMine 2026.1+ (also works in IntelliJ IDEA with Ruby plugin)
- Ruby with Bundler
- docscribe gem >= 1.4.0
| Mode | docscribe version | Ruby version |
|---|---|---|
| Daemon (Unix socket RPC) | >= 1.5.1 | >= 3.0 |
| CLI fallback | >= 1.4.0 | >= 2.7 |
| Validate-types / source / file-scoped | >= 1.6.2 | >= 2.7 |
The plugin automatically selects the backend based on the detected docscribe version: daemon mode for >= 1.5.1, CLI fallback for older versions. If the Ruby SDK is unavailable, it falls back to system PATH Ruby.
gem install docscribeOr add to your Gemfile:
gem "docscribe", group: :developmentFor RBS type inference:
gem "rbs", group: :developmentDocscribe infers @param / @return types from the Ruby AST and falls back to Object when uncertain. When RBS is
enabled, signatures from sig/*.rbs (and the RBS collection, if present) override that heuristic and produce accurate
types.
- Enabled via
docscribe.yml:rbs.enabled: true(orfalseto force inference). - Otherwise auto-detected: enabled if
sig/contains*.rbsorrbsis inGemfile.lock/Gemfile; disabled otherwise.rbs_collection.lock.yamlautomatically adds--rbs-collection.
Since v0.1.7 the plugin forwards this decision to both the daemon (cli_overrides) and the CLI fallback (--rbs).
Install directly from the IDE: Settings -> Plugins -> Marketplace -> search "DocScribe".
Or download from the JetBrains Marketplace.
Download the latest release from GitHub Releases and install via Settings -> Plugins -> ⚙ -> Install Plugin from Disk.
| Action | Shortcut | Description |
|---|---|---|
| DocScribe -> Check Current File | Ctrl+Shift+D then C |
Analyze the active Ruby file for undocumented methods |
| DocScribe -> Check Entire Workspace | Ctrl+Shift+D then W |
Scan all Ruby files in the project |
| DocScribe -> Apply Safe Fixes | Ctrl+Shift+D then S |
Add docs to undocumented methods only |
| DocScribe -> Apply Aggressive Fixes | Ctrl+Shift+D then A |
Replace all existing YARD docs |
| DocScribe -> Update Types from RBS | — | Refresh YARD docs from RBS signatures |
All actions are available in the editor right-click menu under the DocScribe group.
Open a Ruby file — undocumented methods are underlined with a warning. Hover to see what's missing. Diagnostics update automatically on file save and open.
Invalid InvalidType warnings highlight the YARD line (# @param / # @return), not the def line. Fatal errors stay
red ERROR.
Click the lightbulb or press Alt+Enter on an annotated diagnostic and select "Apply docscribe fix" to
auto-generate documentation for that method.
If the gem is not installed, the plugin shows a BALLOON WARNING with an Add to Gemfile button (writes
gem "docscribe" to the Gemfile root) instead of a red squiggle.
Navigate to Settings -> Tools -> DocScribe:
| Setting | Description | Default |
|---|---|---|
| Hide comments by default | Auto-fold YARD comment blocks on file open | Off |
| Warn on invalid YARD types | Highlight malformed YARD types even without RBS | On |
# Build the plugin
./gradlew buildPlugin
# Run in development IDE
./gradlew runIde
# Run tests
./gradlew test
# Check formatting and static analysis
./gradlew spotlessCheck detekt
# Verify compatibility
./gradlew verifyPluginOutput: build/distributions/docscribe-rubymine-*.zip
- docscribe-rubymine — IntelliJ Platform plugin (Kotlin)
- docscribe — Ruby gem (gem + CLI) — GitHub
The plugin runs a persistent Ruby daemon (Docscribe::Server) over a Unix domain socket using JSON-RPC 2.0 for all
check/fix operations. If the daemon is unavailable, it falls back to spawning the docscribe CLI directly via
GeneralCommandLine/CapturingProcessHandler. Output is parsed from the RuboCop-compatible JSON format for inline
diagnostics.