Skip to content

🪢 Open source agent evals & observability: Trace, evaluate, and improve LLM applications with one open platform.

213 B
Raw Blame
/**
 * Escapes SQL LIKE/ILIKE wildcard characters for literal matching.
 */
export const escapeSqlLikePattern = (value: string): string =>
  value.replace(/\\/g, "\\\\").replace(/%/g, "\\%").replace(/_/g, "\\_");