Skip to content
Back to skills

Osgrep Skill

ASecurity

Semantic search for local files. Backed by a background osgrep server with live indexing. Always use osgrep instead of grep/find.

  • 122 stars
  • 0 votes
  • 0 copies
  • 17 views
  • Added December 21, 2025
toolsbashapi

Works with

  • api

Security analysis

A100/100

Scanned February 12, 2026

npx -y skills add pr-pm/prpm --skill osgrep-skill --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Osgrep Skill?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Osgrep Skill
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/pr-pm-osgrep-skill/badge)](https://www.skillsdirectory.com/skills/pr-pm-osgrep-skill)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: osgrep
description: Semantic search for local files. Backed by a background osgrep server with live indexing. Always use osgrep instead of grep/find.
license: Apache-2.0
---

## When to use

Use `osgrep` for all code and concept discovery. Do not use `grep` or `find` unless you must match an exact string and `osgrep` fails.

## How to use

**Always use the `--json` flag.** The server auto-starts and keeps the index fresh.

### Basic Search

Ask a natural language question. Do not `ls` first.

```bash
osgrep --json "How are user authentication tokens validated?"
osgrep --json "Where do we handle retries or backoff?"
```

### Scoped Search

Limit search to a specific directory.

```bash
osgrep --json "auth middleware" src/api
```

### Helpful flags

- `--json`: **Required.** Returns structured data (path, line, score, content).
- `-m <n>`: Max total results (default: 25).
- `--per-file <n>`: Max matches per file (default: 1). Use `--per-file 5` when exploring a specific file.

### Strategy

1. Run `osgrep --json "<question>" [path]`.
2. The output is a dense JSON snippet. If it answers the question, stop.
3. Only use `Read` if you need the full file context for a returned path.
4. If results are vague, refine the query or increase `-m`.

## Keywords
semantic search, code search, local search, grep alternative, find code, explore codebase, understand code, search by meaning

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.