#138 the system instruction inserted in the begining of user prompt#139
Merged
versun merged 1 commit intoversun:mainfrom Dec 11, 2025
Merged
Conversation
Owner
|
Thank you @hariprasathys22 for your contribution! The I've merged your PR and created a follow-up fix PR (#141) to address some token calculation issues. The feature is now working correctly. Thanks again for your valuable contribution to RSSBox! 🎉 |
Contributor
Author
|
Thank you @versun |
Contributor
Author
|
There is one more issue i have faced, when i integrated the gemma ai, that in the advanced settings, reasoning_factor is given value as "minimal", but for google ai model has reasoning_factor as "low", "high" etc., Can I fix it in the next PR. |
Owner
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

#138
feat: Add [merge_system_prompt] option for models that don't support system instructions (e.g., Gemma 3)
Description
Problem
When using certain AI models like Gemma 3 via Google AI API, the application fails with error:
Added a new boolean field
merge_system_promptto theOpenAIAgentmodel that allows administrators to configure how system instructions are sent to the API.Changes Made
merge_system_prompt = models.BooleanField( _("Merge System Prompt to User Message"), default=False, help_text=_("Enable for models that don't support system instructions (e.g., Gemma 3)") )How It Works
Before (Standard Behavior):
messages = [ {"role": "system", "content": "You are a translator..."}, {"role": "user", "content": "Hello, how are you?"} ]After (With merge_system_prompt=True):
messages = [ {"role": "user", "content": "You are a translator...\n\nHello, how are you?"} ]