Skip to content

refactor+test: persona data table, parser fuzz targets, hot-path benchmarks - #312

Merged
Patel230 merged 2 commits into
mainfrom
fix/persona-fuzz-bench
Sep 15, 2026
Merged

Patel230 merged 2 commits into
mainfrom
fix/persona-fuzz-bench

Conversation

@Patel230

Copy link
Copy Markdown
Contributor
  • Data-as-code: BuiltinPersonas/CavecrewPersonas now iterate a package-level persona catalog and stamp timestamps per call, cloning slice fields so callers cannot mutate the shared data. Removes two ~400-line literal constructors.
  • Fuzz: FuzzParseSearchReplace (diff SEARCH/REPLACE parser + applier) and FuzzParseToolCallResult (MCP tool-result parser); both wired into the CI fuzz gate.
  • Benchmarks: IsSensitivePath, IsDestructiveCommand, validateShellCommand, ParseSearchReplace. The IsSensitivePath benchmark surfaced ~22ms/op, worth a follow-up.

Verified: go vet, golangci-lint (0 issues), full go test ./..., make boundaries, fuzz targets run clean.

BuiltinPersonas and CavecrewPersonas now iterate a package-level catalog and
stamp timestamps per call, cloning slice fields so callers cannot mutate the
shared data. Removes two 400-line literal constructors.
- FuzzParseSearchReplace (diff SEARCH/REPLACE parser + applier).
- FuzzParseToolCallResult (MCP tool-result parser).
- Benchmarks for IsSensitivePath, IsDestructiveCommand, validateShellCommand,
  and ParseSearchReplace.
- Wire the two new fuzz targets into the CI fuzz gate.
@Patel230
Patel230 merged commit f528b79 into main Sep 15, 2026
25 checks passed
@Patel230
Patel230 deleted the fix/persona-fuzz-bench branch September 15, 2026 09:40
Patel230 added a commit that referenced this pull request Oct 2, 2026
…hmarks (#312)

* refactor(agents): extract built-in persona catalog to a data table

BuiltinPersonas and CavecrewPersonas now iterate a package-level catalog and
stamp timestamps per call, cloning slice fields so callers cannot mutate the
shared data. Removes two 400-line literal constructors.

* test: add fuzz targets and benchmarks for model-facing parsers

- FuzzParseSearchReplace (diff SEARCH/REPLACE parser + applier).
- FuzzParseToolCallResult (MCP tool-result parser).
- Benchmarks for IsSensitivePath, IsDestructiveCommand, validateShellCommand,
  and ParseSearchReplace.
- Wire the two new fuzz targets into the CI fuzz gate.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant