forked from jupyterlab/jupyter-ai
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add back history and reset subcommand in magics (jupyterlab#997)
* Add back history and reset subcommand in magics This time it's not specific to OpenAI. * Document `%ai reset` * Add the `max_history` magic command option * Respect `max_history` when calling the model All history is still kept so to allow configuring a higher `max_history` mid-session and have older exchanges be included. * Use `<role>:` prefix instead of pseudo-XML for non-chat models * Document the `max_history` setting for the magic commands * fix: make `max_history` a configuration option * fix: `max_history=0` to generate with no context * Add unit test for `max_history` magic option * Add unit test for `%ai reset` magic command * Test that transcript is updated with new prompt * Review corrections - `context` instead of `self.transcript` as if clause condition - less confusing model context input variable
- Loading branch information
Showing
4 changed files
with
155 additions
and
4 deletions.
There are no files selected for viewing
This file contains 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
This file contains 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
This file contains 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
This file contains 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