Ask a question to get started
Enter to sendā¢Shift+Enter new line
HistoryManager( self, history_file: Path, max_entries: int = 100, )
history_file
Path
Path to the JSON-lines history file
max_entries
int
100
Maximum number of entries to keep
Whether currently navigating history entries.
Add a command to history.
Get the previous history entry matching a substring query.
The query is captured on the first call of a navigation session (when _current_index == -1) and reused for all subsequent calls until reset_navigation. Passing a different value on later calls has no effect.
_current_index == -1
reset_navigation
Get the next history entry matching the stored query.
Uses the query captured by the most recent get_previous call.
get_previous
Reset navigation state.
Manages command history with file persistence.
Uses append-only writes for concurrent safety. Multiple agents can safely write to the same history file without corruption.