Skip to content

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Is there a convenient way to make sequential gptel-request? #681

Closed
101scholar opened this issue Mar 4, 2025 · 1 comment
Closed

Is there a convenient way to make sequential gptel-request? #681

101scholar opened this issue Mar 4, 2025 · 1 comment
Labels
enhancement New feature or request

Comments

@101scholar
Copy link

When the stream option is set to t, I want to chain multiple gptel prompts so that once one completes, the combination of all prior inputs and outputs, together with current output and the new prompt are sent as the input for the next gptel-request.

Is there a convenient way to do so, and what is your best practice suggestion? Maybe callback function?

@101scholar 101scholar added the enhancement New feature or request label Mar 4, 2025
@karthink
Copy link
Owner

karthink commented Mar 9, 2025

Use gptel-post-response-functions to modify the buffer as you want and run gptel-send.

For more fine-grained control you can use gptel-request and the finite state machine. This approach is probably not required -- changing the state machine configuration is more work but also more powerful -- you can do almost anything involving instruct-LLMs and Emacs, including building entire new gptel-based packages.

Repository owner locked and limited conversation to collaborators Mar 9, 2025
@karthink karthink converted this issue into discussion #689 Mar 9, 2025

This issue was moved to a discussion.

You can continue the conversation there. Go to discussion →

Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants