# Text Find

> Find a substring or pattern in a text document. Returns position with surrounding context. Deterministic — use this instead of asking the LLM to find substrings.

- Skill: `bdambrosio/text-find` (Agent Skill, multi-file: 3 files)
- Install (CLI): `npx skillmds@latest add bdambrosio/text-find`
- Raw SKILL.md: https://api.skillmd.com/api/skills/bdambrosio/text-find/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: AI & ML
- Author: bdambrosio (https://skillmd.com/u/bdambrosio)
- Updated: 2026-09-17
- Page: https://skillmd.com/skills/bdambrosio/text-find

---


# text-find

Locate patterns or substrings in text and return all matches with context.

## Behavior

- Case-sensitive by default.
- Supports standard Python regex syntax in `pattern`.
- Returns every match (not just the first), with line/character position and the surrounding lines.
- Returns an empty result if no matches — not an error.

## When to use vs `assess` / `process_text`

- `text-find` — exact substring or regex match. Deterministic. No LLM cost.
- `assess` — natural-language predicate (semantic match). LLM-backed.
- `process_text` — open-ended transformation with an instruction.

If you want "does this contain the literal string X?" → `text-find`. If you want "does this contain mention of X?" (paraphrases count) → `assess`.

## Examples

```json
{"thought": "find every TODO in the document", "tool": "text-find", "source": "$step1", "pattern": "TODO"}
```

```json
{"thought": "locate error lines mentioning a timeout", "tool": "text-find", "source": "$step1", "pattern": "ERROR.*timeout", "context_lines": 3}
```

