Skip to content

Keep workflow context out of skill-command expansion - #38

Merged
swerner merged 1 commit into
mainfrom
codex/skill-command-boundary
Oct 13, 2026
Merged

swerner merged 1 commit into
mainfrom
codex/skill-command-boundary

Conversation

@swerner

@swerner swerner commented Oct 13, 2026

Copy link
Copy Markdown
Contributor

Pebble treated slash tokens anywhere in input as skill commands: a prior-stage /tmp mention could fail a turn, and a known skill could replace the authored task. Expand only a leading command after optional whitespace; later slash tokens remain literal arguments or prose.

Add CodingInput::with_context(before, after) so applications keep preambles, output contracts, and attachments outside authored-command expansion, plus without_skill_expansion() for generated input. Preserve unknown-leading-command errors, skill activation events, and background-agent notification protection. Document the intentional change to inline-command semantics.

Ports the leading-command behavior and regression cases contributed by @denkhaus in fabro-sh/fabro#784. Related to #37; the native Petri handoff and integration regressions are in lithoscomputer/petri#118. This PR alone does not complete the Petri rollout. Fabro's public skills/lifecycle documentation still needs the corresponding semantic update.

Validation: CARGO_INCREMENTAL=0 CARGO_PROFILE_DEV_DEBUG=0 mise run check passed, including 1,683 tests, documentation tests, Clippy, formatting, library feature checks, and workflow/whitespace checks. Smaller build artifacts were needed after the machine ran out of disk space; local server/terminal tests ran outside the restrictive sandbox. Nextest reported one skipped test and a leak warning on the passing, unrelated flood_output_is_drained_and_bounded_even_without_a_live_reader test.

New request-level regressions verify literal paths/failure echoes/known-skill mentions, context and image preservation with replacing templates, generated-input bypass, and ordinary follow-up prose. No paid model calls.

Port denkhaus's leading-command behavior and regression cases from fabro-sh/fabro#784. Keep surrounding context outside expansion and allow generated input to bypass it.
@swerner
swerner merged commit 42bec02 into main Oct 13, 2026
3 checks passed
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