Skip to content
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

400 bad request using role with Perplexity #448

Open
dev-microcosm opened this issue Mar 2, 2025 · 0 comments
Open

400 bad request using role with Perplexity #448

dev-microcosm opened this issue Mar 2, 2025 · 0 comments

Comments

@dev-microcosm
Copy link

Describe the bug

Using a Perplexity model with a role flag gives a 400 bad request.
"error, status code: 400, status: 400 Bad Request, message: After the (optional) system message(s), user and assistant roles should be alternating."

Setup

  • add your Perplexity API key
  • add a role (I am using the 'shell' example)

Please complete the following information along with version numbers, if applicable.

  • OS: Ubuntu 24.04.2 LTS
  • Shell: PowerShell 7.4.7
  • Terminal Emulator: Ghostty 1.1.3
  • mods: 1.7.0

To Reproduce

Steps to reproduce the behavior:

  1. run a prompt with the role on a Perplexity model
  2. get a 400 error (non Perplexity models and Perplexity models without the role flag seem to work fine)

Expected behavior

I expect a response using the provided role like the other AI models.

Screenshots

Image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant