Skip to content

nlgrep

CLI that searches code, docs and logs by natural-language condition, asking Jev a yes/no question per candidate with a threshold.

CLIbeta

Overview

nlgrep is a TypeScript CLI for searching code, documentation, logs and text by meaning rather than exact words. Every match is decided by a Jev Noul judgment on whether the candidate satisfies your natural-language condition, with a configurable probability threshold, and results are ranked by file and linked to source lines. It also handles text, case and format conditions and describes code behaviour without writing rules.

The README compares it with grep and Semgrep CE in demo videos, and links an evaluation and limits document noting that judgments depend on supplied context and are probabilistic. A dry-run mode previews the search plan without API calls, a max-requests flag caps spending (retries count toward it), and results are cached. It needs Node.js 22+ and a TypeSafe key set as JEV_KEY.

What the decision model decides

TypeQuestionAnswers
Yes / noDoes this code or text satisfy the condition (e.g. retry logic after a failed request)?yes · no

How it works

  1. Run nlgrep with a condition and a path; use --dry-run to preview.
  2. Candidates are sent to Jev as Noul questions within the request limit.
  3. Keep those above the probability threshold.
  4. Print ranked results linked to source lines; cache answers.

Strengths

  • Finds paraphrases and behaviours grep cannot.
  • Request caps and dry-run control cost.
  • Cached results avoid repeat calls.

Caveats

  • Probabilistic; may miss or over-match.
  • Sends code or text to TypeSafe.
  • Requires a TypeSafe key.

Getting started

npm install --global nlgrep, set JEV_KEY in .env, then nlgrep "Retry logic after a failed request" ./src --max-requests 30.

At a glance

Type
CLI
Status
beta
Language
TypeScript
Runtime
Node CLI
Has code
yes

Use cases and integrations

How curated lists describe it

  • Developer tooling: uses Jev `Noul` judgments to find code, docs, logs, and text satisfying natural-language conditions, with a configurable probability threshold and ranked file results linked to source lines.

    yibie/awesome-jev
  • TypeScript CLI that finds code, docs, logs, and text by natural-language conditions using Jev Noul judgments, with probability thresholds, source lines, and cached results.

    hellogumbo/awesome-jev

Frequently asked questions

How does nlgrep decide a match?

It asks Jev a yes/no question per candidate and keeps those above a probability threshold.

How do I limit cost?

Use --dry-run to preview and --max-requests to cap API calls.

What does it need?

Node.js 22+ and a TypeSafe API key in JEV_KEY or TYPESAFE_API_KEY.

Related projects

  • Unix filters (grev, tagv, rank, sortv, cutv, uniqv and more) that select, label and rank lines by meaning with Jev.

    CLIbetaGo
  • grep where the pattern is a description: each line, record, function or diff hunk becomes a streamed Jev yes/no question.

    LibrarybetaPython
  • Semantic grep that asks Jev a yes/no about every function for questions no regex can express, with cost reporting.

    Projectbeta
  • Deterministic code-graph context for coding agents on Postgres, AGE and pgvector, with optional Jev or local re-selection of symbols.

    MCP serverbetaPython
  • Claude Code plugin that adds Jev as an independent judge for review findings, debugging hypotheses, design options and search hits.

    Pluginbeta
  • Retrieval layer for Codex that finds evidence locally, optionally ranks sanitized excerpts with Jev, and returns bounded, cited evidence.

    Projectbeta