Search documentation

Boolean connectors

Every connector LawDiver understands, what it does to your search, and the rules the parser actually applies — including the places where our behaviour differs from Westlaw and Lexis.

Start here

You do not need connectors. Type a citation, a case name, or a sentence describing your issue and the default search runs citation lookup, case-name matching, boolean terms, and a meaning search together. Connectors are for the case where you know exactly which words must appear, and how close together.

Everything below is the boolean engine. Pin Boolean above the search box when you want that engine alone: every term required, no meaning hits, no case-name hits, and an empty page stays empty. On the default search, uppercase connectors are still honored. Lowercase and, or, and not are ordinary words until you pin Boolean.

ConnectorMeaningExample
AND or &Both terms must appear somewhere in the opinion. A space means the same thing.negligence AND causation
OREither term will do. Loosest connector — group with parentheses when mixing with AND.rescission OR cancellation
NOT or %The next term, phrase, or group must not appear. NOT, BUT, BUT NOT, and % are the same exclusion.immunity BUT NOT prisoner
"exact phrase"These words, in this order, adjacent. Still stemmed. A one-word quote, or #word, is the unstemmed form."clearly established"
term!Root expander. Any ending on the letters you typed. This is truncation.unconscionab!
* or ?Exactly one character. Not truncation.dr*ve
/s or +sWithin 25 words. +s also requires the left term first. Not a sentence-boundary test.employer /s negligent
/p or +pWithin 80 words. +p also requires the left term first. /seg is the same window."forum non conveniens" /p factors
w/n or +nWithin n words. +n also requires the left term first. /5 is the same as w/5.summary w/3 judgment
field:termLimit the next term or phrase to case_name, syllabus, headnotes, holdings, or body.holdings:"clearly established"

Typing no connectors

Two or more words with nothing between them are treated as all required. There is no implicit OR: a query is a set of conditions the opinion has to satisfy, not a bag of hints.

qualified immunity excessive force

All three words must appear in the opinion, anywhere in it.

Does not match: An opinion about qualified immunity that never uses the phrase excessive force.

On the default search, a connector-free question is also read by meaning, and common words such as the, of, and in are not required. Pin Boolean when you want every word kept. A Boolean search does not drop terms and does not relax a long AND that returns nothing. See stemming and wildcards.

Capitals matter

Under the default search, AND, OR and NOT are connectors only in capital letters. In lowercase they are ordinary words, so a plain question is not read as boolean.

On a Boolean pin, lowercase and, or, not, and but are connectors too, and but not is one exclusion. &, %, quotes, proximity, !, and * are connectors either way.

This is the one rule worth remembering.

On the default search, trust and estate searches for the words themselves. trust AND estate is a boolean instruction. Pin Boolean when you want the lowercase words to be connectors and every term to be required.

The rule exists because lawyers write ordinary prose into search boxes. act of god and force majeure clause is a phrase someone means literally, and silently converting its and into an operator would change the question being asked. Requiring capitals means a connector is never an accident.

Proximity connectors are the exception: W/5 and w/5 both work, because there is no English word they could be confused with.

AND

Both terms must appear somewhere in the opinion. They can be a hundred pages apart. AND, &, and a space between terms all mean this. AND says nothing about where.

respondeat superior AND punitive damages

The opinion contains both concepts, in any order, at any distance.

negligence & causation

The ampersand is AND. negligence AND causation and the two words with only a space between them are the same search.

On a Boolean pin, negligence AND causation and negligence causation are the same search. On the default search, typing AND marks the query as boolean, so it is not rewritten as a plain-English question.

OR

Either term satisfies the search. Use it for the several names one doctrine goes by, or for a statutory term and its shorthand.

rescission OR recission OR cancellation

Any one of the three appears. Useful when the courts themselves are inconsistent — including the common misspelling.

excessive force AND (baton OR taser)

Excessive force is required, and either baton or taser will satisfy the second half. Without the parentheses, AND binds tighter than OR.

AND binds tighter than OR.

baton OR taser AND handcuffs is baton OR (taser AND handcuffs). Write (baton OR taser) AND handcuffs when handcuffs is required either way.

NOT

Excludes opinions containing the next operand. NOT, %, BUT, and BUT NOT are the same exclusion. Each applies to the term, phrase, or parenthesized group that follows, not to the rest of the query.

qualified immunity NOT prisoner

Qualified immunity is required; any opinion using the word prisoner is dropped.

Does not match: A leading qualified-immunity case that happens to mention a prisoner once, in a footnote.

immunity % prisoner

The percent sign is NOT. Same result as immunity NOT prisoner.

immunity BUT NOT prisoner

BUT NOT is one exclusion, the same as NOT and %. Opinions containing prisoner are dropped.

That last line is the thing to watch. Exclusion is document-wide and absolute: one passing use of the word in an unrelated part of a long opinion is enough to remove it. Prefer narrowing your required terms, or a proximity connector, over excluding a word that might legitimately appear.

To exclude a phrase, quote it: NOT "summary judgment" removes the phrase, while NOT summary judgment excludes only summary and leaves judgment as a required term. NOT (qualified OR absolute) excludes both.

Exclusion is the next operand only.

immunity BUT NOT prisoner AND damages drops opinions that contain prisoner and still requires damages.

Exact phrase

Double quotes require the words in that order, adjacent. Stemming still applies — "clearly established" also matches clearly establishes. A one-word quote is the unstemmed form, and so is #established. Add ~n after a phrase to allow that many extra words between the terms: "clearly established"~3.

"clearly established law"

The three words adjacent and in order.

Does not match: An opinion saying the law was clearly established, in those words but not that order.

A quoted phrase is also a single operand for every other connector, which is what makes multi-word proximity searches possible:

"deliberate indifference" /s "serious medical need"

Both phrases, intact, within 25 words of each other.

An unclosed quote is read forgivingly: everything after the quotation mark is treated as the phrase. "good faith exception searches for the phrase good faith exception, which is what was almost certainly meant.

Fields

A field: prefix limits the next term, phrase, or parenthesized group to one part of the opinion. The field names are case_name, syllabus, headnotes, holdings, and body.

holdings:"clearly established"

The phrase must appear in the holdings, not merely somewhere in the opinion.

Aliases resolve to the same fields: name: and caption: are case_name, holding: is holdings, and text: and opinion: are body. An unknown name is rejected. The boolean search does not quietly ignore the prefix and run the term against the whole opinion.

Westlaw abbreviations such as ti() are not accepted. Jurisdiction, court, and date are filters, not fields — see what belongs in a filter.

/s — within 25 words

/s, w/s, and ordered +s mean within 25 words. They are a substitute for “same sentence,” not a sentence test.

Many opinions are PDFs converted to text. Periods in citations (F. Supp., U.S.) and missing line breaks create false sentence breaks, and some conversions have almost none. A false break hides a real hit. A missing break lets a same-sentence search run into the next sentence. A fixed word window applies the same rule to every opinion.

employer /s negligent hiring

The words sit within 25 words of each other, in either order.

Does not match: An opinion discussing employer liability on page 3 and negligent hiring on page 40.

notice +s cure

Within 25 words, and notice must appear before cure. /s without the plus sign allows either order.

/s does not care about order. +s does: the left term must come first. Use a quoted phrase when you need a specific word order.

Both operands are required, so an opinion missing either word never matches.

/p — within 80 words

/p, w/p, /seg, and ordered +p mean within 80 words. They are a substitute for “same paragraph,” for the same reason /s is not a real sentence: paragraph breaks in converted PDFs are uneven.

"forum non conveniens" /p "private interest factors"

Both phrases within 80 words — the analysis and the factors it turns on, discussed together.

Reach for /p when 25 words is too tight, and for w/n when you want a distance you choose yourself.

w/n — within n words

Both terms within n words of each other, in either direction. w/5 and the bare form /5 are the same connector. +5 is the same window, but the left term must come first.

summary w/3 judgment

The two words no more than three words apart.

Matches: summary judgment; judgment on summary disposition.

notice w/10 termination

Notice and termination close enough to be about each other — a contract-notice provision rather than two unrelated discussions.

notice +5 cure

Within five words, and notice must come first. w/5 and /5 allow either order.

The distance counts words, and the maximum is 255. /s is the 25-word window and /p is the 80-word window, so you do not have to pick a number for those.

How proximity is verified

Worth knowing, because it explains the one behaviour that looks like a bug and is not.

/s is within 25 words. /p is within 80 words. w/n is within the number you typed. A leading + (+s, +p, +5) keeps that window and also requires the left term to appear first.

These are word counts, not sentence or paragraph boundaries. A large share of the corpus is PDF text. Citation periods and lost line breaks make those boundaries unreliable, so boolean search does not use them.

A proximity search can legitimately return nothing.

The window is enforced, not scored. If no opinion puts your two terms within 25 words, the honest answer is an empty list — LawDiver will not quietly relax /s into AND. Widen deliberately: /s to /p, or /p to w/150.

Order of operations

Proximity binds tightest, then AND, then OR. A space between terms is an implicit AND. It is not Westlaw's space-as-OR.

battery OR assault AND consent

AND binds tighter than OR, so this is battery OR (assault AND consent). Write (battery OR assault) AND consent when both alternatives must also include consent.

immunity AND clearly /s established

Proximity binds tighter than AND, so this is immunity AND (clearly /s established).

Parentheses

Parentheses group the expression. (battery OR assault) AND (consent OR waiver) is two independent alternatives, both required. They override the default that AND binds tighter than OR.

They have to balance. A missing parenthesis is not a group. The search drops the parenthesis characters and reads the query again, so the grouping you intended is gone. A dangling AND, OR, or /s with nothing after it is the same kind of error.

Stemming and wildcards

Terms are matched with English stemming, so a search for one form of a word finds its other forms. negligent finds negligence and negligently; testify finds testified and testimony. Stemming applies inside a multi-word quote too. A phrase constrains word order and adjacency, not exact spelling.

A few pairs that stemming would smash together are matched as written, including probate and probation, and counsel and council. You do not have to quote them.

You typeWhat it matches
negligentStemmed. Also negligence and negligently.
#establishedThat spelling only. A one-word quote does the same.
unconscionab!Root expander. Any ending on that stem: unconscionable, unconscionability.
dr*veExactly one character. drive and drove. * is not truncation. ? is the same mark.
"act of god"The phrase intact, including of. Words inside quotes are not dropped.
unconscionab!

The trailing bang is truncation. It matches unconscionable and unconscionability. Stemming already covers ordinary word forms, so most searches do not need it.

dr*ve

The star is one character, so this matches drive and drove. It does not match driver. A question mark is the same mark: neglig?nce.

#established

The hash mark turns stemming off. This matches established and not establishes. Quoting the single word, as in "established", does the same.

On the default search, a connector-free question does not require common words such as the, of, and in. the duty of care is a search for duty and care, and it is also read by meaning. On a Boolean pin those words stay, and/or/not/but become connectors, and a question that matches nothing stays empty.

Not supported

Deliberately absent. Each of these either has a better equivalent here or would produce results that only look right.

ElsewhereHere
atleast5(term)No term-frequency operator. Ranking already favours opinions where a term is central rather than incidental.
a spaceA space is AND. negligence causation requires both words. Type rescission OR cancellation when either word is enough.
ti(term)Westlaw field abbreviations are not accepted. Use case_name:, syllabus:, headnotes:, holdings:, or body:.

Connectors and the four engines

A LawDiver search runs up to four engines at once and merges the results. Connectors are instructions to one of them.

EngineWhat connectors do
CitationNothing. A reporter citation or docket number is a lookup; connectors are ignored.
Case nameNothing. Party names are matched by fuzzy name comparison, which tolerates reversed parties, abbreviations and misspellings on its own.
BooleanEverything on this page. Pin Boolean to run this engine alone. Every term is required, and an empty page stays empty.
ConceptNothing directly — it searches by meaning, not by words. A connector-heavy query is not the kind of input it is good at.

Because they run together, a citation in your query is never buried under a loose conceptual match. It also means a connector query and a plain-English query can be mixed: the parts each engine can use are routed to it.

To run boolean search alone, pin Boolean above the search box. Pinning is a real restriction — if that search has nothing to work with, you get an honest empty result rather than a quiet fallback to a different engine. Hybrid is terms plus meaning; it is not this pin.

What belongs in a filter instead

Jurisdiction, court level and date are filters, not query terms. This is not a style preference — putting them in the query text actively produces wrong results.

Fifth Circuit qualified immunity

Typed as text, Fifth Circuit is a phrase to match, so an opinion that discusses Fifth Circuit precedent scores well — including a Ninth Circuit case distinguishing it. That is the opposite of what you asked for.

LawDiver recognises unambiguous court phrases and lifts them into the jurisdiction filter for you, telling you it has done so. But it lifts only the unambiguous ones: a bare state name is left alone, because Texas Instruments and New York Times are parties, not jurisdictions. Set the jurisdiction with the picker and the ambiguity never arises.

The same goes for dates: use the date filters, including the last 5, 10 and 25 year quick ranges, rather than typing a year into the query. A year in the query text is just a number that appears in the opinion.

Worked examples

Queries that use the connectors the way they are meant to be used.

"deliberate indifference" /s "serious medical need"

The Eighth Amendment medical-care standard, with both phrases within 25 words. Two phrases as proximity operands is the highest-precision query on this page.

employer /s negligent AND (hiring OR retention OR supervision)

Employer and negligent within 25 words, and at least one of hiring, retention, or supervision. The parentheses are required. Without them, retention alone would match.

"forum non conveniens" /p "public interest factors" NOT arbitration

Both phrases within 80 words, with arbitration cases excluded entirely.

notice w/10 cure AND breach

A notice-and-cure provision — the two words close enough to be about each other — in an opinion that also discusses breach.

(rescission OR recission) AND "material misrepresentation"

Either spelling of rescission, including the misspelling courts frequently use, together with the phrase. Without the parentheses, AND would bind only to the second spelling.

qualified immunity excessive force taser

No connectors at all. On a Boolean pin, all four words are required, anywhere in the opinion. Often the right first search — start here, and add connectors only when you have too many results to read.

Try these on the research page →