You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Right now, gptel lets you add files and buffers to the context. But if I understand right, from from the code of functions like gptel-context--insert-buffer-string and gptel-context--file-string, it always adds this material to the context using header line like In file ...: or In buffer ...:.
However, Anthropic is very clear that their model performs better if quoted files and other such material are contained within XML-like tags. This has been my experience as well.
It would be valuable to be able to customize how gptel builds the context string, so that it could be optimized to work with a particular model. I think it'd be especially valuable to do this for Claude right now, since the sonnet-3.5 model is very strong at coding assistance in a conversational style.
I'd be happy to work on this change, if it seems like it would be worth pursuing.
The text was updated successfully, but these errors were encountered:
If I understand correctly, you're looking for the option gptel-context-wrap-function. See its documentation for details, and let me know what you think.
I'll leave this issue open for now since I think there's room for improvement. Perhaps gptel can provide a few wrap functions out of the box tailored to the expectations of the big LLM providers.
Right now, gptel lets you add files and buffers to the context. But if I understand right, from from the code of functions like
gptel-context--insert-buffer-string
andgptel-context--file-string
, it always adds this material to the context using header line likeIn file ...:
orIn buffer ...:
.However, Anthropic is very clear that their model performs better if quoted files and other such material are contained within XML-like tags. This has been my experience as well.
It would be valuable to be able to customize how gptel builds the context string, so that it could be optimized to work with a particular model. I think it'd be especially valuable to do this for Claude right now, since the sonnet-3.5 model is very strong at coding assistance in a conversational style.
I'd be happy to work on this change, if it seems like it would be worth pursuing.
The text was updated successfully, but these errors were encountered: