Conversation
`jp c fork` now accepts the same turn selector as `jp c print` and `jp c compact`: `--from`/`--to`, `--turn`, `--first`/`--last`, and `--keep-first`/`--keep-last`, replacing its old bespoke `--from`/`--until`/`--first`/`--last` flags. `--from`/`--to` also gain duration, absolute date (`2026-01-01`), and RFC 3339 support, and every bound now resolves to a whole turn instead of splitting one: `--from <time>` starts at the first turn to begin after the cutoff, `--to <time>` ends at (and includes) the turn active at the cutoff. `--first N --last M` given together now compact/fork/print each window separately and skip the turns between them, rather than the previous single-range behavior. `--keep-first`/`--keep-last` compose with every selector (not just `--first`/`--last`) to protect turns at either end, and an explicit `--keep-first`/`--keep-last` replaces a configured compaction rule's bound instead of stacking with it. The conversation-creation range filter on `jp c rm`, `jp c archive`, and `jp c use` is renamed from `--from`/`--until` to `--created-since`/`--created-before`, freeing `--from`/`--to` to mean "which turns" everywhere and `--created-since`/`--created-before` to mean "which conversations" — the two families accept near-identical values, so the old shared names were ambiguous. Semantics of the creation-range filter (half-open, `since` inclusive/`before` exclusive) are unchanged. `crates/jp_cli/src/cmd/turn_range.rs` is replaced by `turn_selection.rs`, which resolves a selection to an ordered, non-overlapping `TurnSet` of inclusive 0-based windows instead of a single from/to pair, and `ConversationStream::retain_first_turns`/ `retain_first_and_last_turns` are replaced by a single `retain_turns(impl Fn(usize) -> bool)`. Signed-off-by: Jean Mertz <git@jeanmertz.com>
Signed-off-by: Jean Mertz <git@jeanmertz.com>
Signed-off-by: Jean Mertz <git@jeanmertz.com>
Signed-off-by: Jean Mertz <git@jeanmertz.com>
Signed-off-by: Jean Mertz <git@jeanmertz.com>
Signed-off-by: Jean Mertz <git@jeanmertz.com>
Signed-off-by: Jean Mertz <git@jeanmertz.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
jp c forknow accepts the same turn selector asjp c printandjp c compact:--from/--to,--turn,--first/--last, and--keep-first/--keep-last, replacing its old bespoke--from/--until/--first/--lastflags.--from/--toalso gain duration, absolute date (2026-01-01), and RFC 3339 support, and every bound now resolves to a whole turn instead of splitting one:--from <time>starts at the first turn to begin after the cutoff,--to <time>ends at (and includes) the turn active at the cutoff.--first N --last Mgiven together now compact/fork/print each window separately and skip the turns between them, rather than the previous single-range behavior.--keep-first/--keep-lastcompose with every selector (not just--first/--last) to protect turns at either end, and an explicit--keep-first/--keep-lastreplaces a configured compaction rule's bound instead of stacking with it.The conversation-creation range filter on
jp c rm,jp c archive, andjp c useis renamed from--from/--untilto--created-since/--created-before, freeing--from/--toto mean "which turns" everywhere and--created-since/--created-beforeto mean "which conversations" — the two families accept near-identical values, so the old shared names were ambiguous. Semantics of the creation-range filter (half-open,sinceinclusive/beforeexclusive) are unchanged.crates/jp_cli/src/cmd/turn_range.rsis replaced byturn_selection.rs, which resolves a selection to an ordered, non-overlappingTurnSetof inclusive 0-based windows instead of a single from/to pair, andConversationStream::retain_first_turns/retain_first_and_last_turnsare replaced by a singleretain_turns(impl Fn(usize) -> bool).