pm-search-advanced
Enable semantic/hybrid search modes and reindex workflows.
Installieren
Mit installiertem pm
pm install search-advanced --projectMit npm, ohne pm zu installieren
npx -y @unbrained/pm-cli install search-advanced --projectMit Bun, ohne pm zu installieren
bunx @unbrained/pm-cli install search-advanced --projectREADME
Tracker: pm-wfskfn.
First-party package that restores optional advanced search surfaces in bare-core pm.
Commands and behavior
- Adds
pm search advancedwith:--mode keyword|semantic|hybrid--semantic,--hybrid--include-linked--title-exact--phrase-exact--type,--tag,--priority--deadline-before,--deadline-after--limit,--fields,--compact,--full
- Adds
pm ops reindexwith:--mode keyword|semantic|hybrid--progress--eval--eval-fixtures <path>
Install
pm install search-advanced --project
Verify
pm search advanced "vector cache" --mode hybrid --limit 5 --json
pm search advanced --hybrid "vector cache" --limit 5 --json
pm search advanced "calendar package" --mode keyword --fields id,title,score --compact --json
pm ops reindex --mode hybrid --progress --json
pm ops reindex --mode keyword --eval --eval-fixtures tests/search-eval/golden-queries.json --json
Without --mode, --semantic, or --hybrid, search advanced stays keyword-first for fast agent reads.
The command registers its shared search options from
SEARCH_EXTENSION_FLAG_DEFINITIONS, the public SDK authoring adapter over pm's
canonical search contracts. This keeps package aliases and value semantics in
lockstep with the core CLI without a copied flag table.
Reindex eval harness
pm ops reindex --eval runs a golden-query relevance harness after the reindex pass and appends a deterministic eval object to JSON output:
- per-fixture pass/fail verdicts
ndcg_at_5score for each fixture- aggregate
average_ndcg_at_5, pass/fail counts, and overall status
The default fixture file is tests/search-eval/golden-queries.json. Override with --eval-fixtures <path>.
Fixture schema
Fixtures can be either a top-level array or an object with a fixtures array:
{
"fixtures": [
{
"name": "search-eval-task",
"query": "pm-22x2 search relevance evaluation harness",
"mode": "keyword",
"expected_top_ids": ["pm-22x2", "pm-fhsg"],
"min_ndcg_at_5": 0.8
}
]
}
Rules:
queryis required and must be non-empty.modeis optional (keyword,semantic,hybrid), defaultkeyword.expected_top_idsis required and defines the ideal ranking for nDCG@5.min_ndcg_at_5is optional (0..1), default0.7.
pm reindex remains a compatibility alias for pm ops reindex.
pm search-advanced remains a hidden compatibility alias with the stable search-advanced SDK action. Use pm search -- advanced to search for the literal word advanced; place query options before --. The search provider remains configurable independently of the command facet.
Aus der README des Pakets auf GitHub. Auf GitHub ansehen