---
title: "Search literal punctuation without broadening"
description: "Verify the documented literal search behavior for punctuation by distinguishing a precise identifier from visually similar near matches."
canonical_url: "https://vostride.com/agent-library/search-filtering/literal-special-characters.md"
md_url: "https://vostride.com/agent-library/search-filtering/literal-special-characters.md"
content_kind: "recipe"
topic: "search-filtering"
---

# Search literal punctuation without broadening

Verify the documented literal search behavior for punctuation by distinguishing a precise identifier from visually similar near matches.

## Risk

Query parsing may interpret punctuation as syntax or silently remove it. This recipe applies only to a field documented to search literal identifiers; other search grammars need their own expected contract.

## Fixtures

- The asset registry contains build[7], build7, and build[70] with separate immutable record identifiers.
- Identifier search is specified as exact matching after trimming outer whitespace, with punctuation preserved.
- The test account can see all three records, and a seed manifest records their literal names.

## Steps

1. Open the registry and verify all three distinguishable asset names are visible in the baseline list.
2. Search for build[7] in the exact identifier search control and verify one result appears.
3. Verify that result displays both the literal punctuation and the expected immutable identifier.
4. Search for build7 and verify the plain-name record replaces the bracketed record.
5. Search for a space-padded build[7] and verify the documented trimming rule returns the same bracketed record.

## Expected results

- The punctuation-bearing query returns only the exact bracketed asset key.
- The plain-name query returns a different key, proving punctuation was not globally discarded.
- Outer whitespace is normalized only as documented; the brackets and the enclosed digit remain semantically significant.

## False-pass traps

- A title rendered without punctuation by a presentation component can hide the wrong backend result; compare the key.
- Using a generic contains-search box would test a different contract from exact identifier lookup.

## Cleanup

- Delete the three registry fixtures and clear any stored search query.

## Use with agent-qa

Adapt this test design to your application's acceptance criteria and configured target using the [recipe execution guide](/agent-library/software-factory/turn-a-recipe-into-an-agent-qa-test.md). External fixture setup and non-UI checks require your own supported hooks or test tooling. Validate the authored test, execute it, and inspect the completed evidence; this recipe is not a recorded test result.

## References

- [agent-qa test](/docs/agent-qa/configuration/test.md)
- [agent-qa first test](/docs/agent-qa/guides/first-test.md)
- [agent-qa web testing](/docs/agent-qa/guides/web-testing.md)

- [Search and filtering QA recipes](/agent-library/search-filtering.md)
- [Software factory QA library](/agent-library.md)
