gptel-transient: Truncate system prompt when messaging
* gptel-transient.el (gptel-system-prompt--setup): Truncate the chosen system prompt when displaying it as a message. (#249)
This commit is contained in:
parent
07992f79cc
commit
12340eda46
1 changed files with 3 additions and 1 deletions
|
@ -208,7 +208,9 @@ which see."
|
||||||
")")
|
")")
|
||||||
'face 'shadow))
|
'face 'shadow))
|
||||||
`(lambda () (interactive)
|
`(lambda () (interactive)
|
||||||
(message "Directive: %s" ,prompt)
|
(message "Directive: %s"
|
||||||
|
,(string-replace "\n" "⮐ "
|
||||||
|
(truncate-string-to-width prompt 100 nil nil t)))
|
||||||
(setq gptel--system-message ,prompt))
|
(setq gptel--system-message ,prompt))
|
||||||
:transient 'transient--do-return)
|
:transient 'transient--do-return)
|
||||||
into prompt-suffixes
|
into prompt-suffixes
|
||||||
|
|
Loading…
Add table
Reference in a new issue