Given a task ("convert Markdown to HTML", "typeset a PDF"), discovers
existing community-maintained libraries/CLIs live (PyPI, npm, optionally
GitHub) and recommends which one(s) to reach for instead of reimplementing
— e.g. markdown-it-py/pandoc for document conversion. A build-vs-buy
check for MyThingsLab tools (and humans) to run before
writing new code.
Deterministic pre-work:
- Read the task issue (label
my-librarian) and build query terms (the same naive tokenizer MySearcher/MyResearcher use). - Retrieve candidates over LLM-free HTTP from the selected registries
(
--registries, defaultpypi,npm):- npm —
registry.npmjs.org/-/v1/search, keyless. - PyPI — no free-text search API exists anymore, so a small curated
seed table maps common task keywords to well-known package names,
enriched via
pypi.org/pypi/<name>/json(keyless). - GitHub — repo search via the existing
ghCLI Runner, opt-in.
- npm —
- Normalize + dedupe, score by query-term overlap + popularity + recency, with license permissiveness downranking (never dropping) copyleft candidates, and cap to the top N (default 10).
If at least one candidate is found, one Engine call recommends which to
use, with trade-offs, a usage snippet, and any to avoid — citing only
package names from the shortlist. Against NoopEngine, the reply is empty
and the shortlist is posted verbatim, sorted by the deterministic score.
Read-only: no Workspace, no PR, no code edits — MyLibrarian recommends, it
never adopts a dependency itself. The only side effect is an optional
--comment posting the survey to the issue, routed through Policy
(Guard default). Writes exactly one kind=library_survey ledger entry per
run.
mylibrarian survey --issue 12 --task "convert markdown to html" --source .
mylibrarian survey --issue 12 --task "..." --repo owner/name --comment
mylibrarian survey --issue 12 --task "..." --registries pypi,npm,github --engine claude-cliStandalone today — a build-vs-buy check any tool-build issue can consult before writing new code, per the design doc. See the org README for how the shipped tools chain together.
python -m venv .venv && source .venv/bin/activate
pip install -e ../my-things-core -e ".[dev]"
pytestMIT — see LICENSE.