Conversation
6256d8e to
b3db2d7
Compare
|
@juliasilge @eitsupi, I have an optional It is a draft PR in my fork, targeting I also benchmarked the current R-only implementation (
Method: Linux laptop (Core Ultra 9 285H), R 4.6.1, 340 installed package entries; optimized build, median of 15 samples per implementation/scenario. Suggestions used The result is a tradeoff: about 29% faster first-use suggestions, but slower initial searches. The baseline prepares R’s native search database while constructing suggestions; the prototype reads aliases separately, so the first submitted search pays the deferred native-database build. A fresh submitted search pays for both paths. Cached suggestions and repeated searches were essentially unchanged. These are measurements of this prototype on one machine, not a general performance claim about the library. The benchmark verified identical bounded suggestions and that the Rust reader succeeded without taking the fallback. The prototype also passed 25 targeted Help tests and Clippy. Indexing still runs synchronously; this draft does not yet implement the background worker discussed earlier. I would welcome feedback on the reader adapter and index lifecycle before taking that further. The existing upstream PRs remain independent of this experiment. |
Escape invalid regular expressions for literal R Help search while preserving valid regex and native fuzzy matching. Add coverage for query edge cases and navigation correlation.
R backend support for the Help search and autocomplete UI in posit-dev/positron#15923, addressing posit-dev/positron#422.
Changes
search_help(query, search_id)while preserving nativeutils::help.search()matching and result rendering across installed packages.get_help_topics(query, limit)responses, bounded to 1–50 suggestions, with package-qualified topic targets.show_helpso the frontend can ignore obsolete results. Scope the ID to the request and restore it on exit, including errors; ordinary console help remains untagged.Scope and integration
posit-dev/positron#4484 (reloading search results at the same URL) is acknowledged but deliberately left to the Positron team.
After this merges, Positron needs to adopt the resulting upstream Ark version through its normal update process. The companion Positron PR intentionally contains no Ark submodule pointer change.
Validation
cargo checkpassed locally.The earlier local
KEYWORDS.dbblocker was resolved by supplying the correct R documentation/share/include paths; it is no longer blocking integration tests.