MCPcopy Create free account
hub / github.com/UsefulSoftwareCo/executor / tokenizeSearchText

Function tokenizeSearchText

packages/core/execution/src/tool-invoker.ts:493–497  ·  view source on GitHub ↗
(value: string)

Source from the content-addressed store, hash-verified

491 .trim();
492
493const tokenizeSearchText = (value: string): string[] =>
494 normalizeSearchText(value)
495 .split(/[^a-z0-9]+/)
496 .map((token) => token.trim())
497 .filter(Boolean);
498
499const prepareField = (value?: string): PreparedField => ({
500 raw: normalizeSearchText(value ?? ""),

Callers 4

prepareFieldFunction · 0.85
matchesNamespaceFunction · 0.85
scoreToolMatchFunction · 0.85
tool-invoker.tsFile · 0.85

Calls 1

normalizeSearchTextFunction · 0.85

Tested by

no test coverage detected