Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -319,9 +319,7 @@ def prompt(
# accepts 1.
kwargs["temperature"] = min(temperature, 1)
response = client.chat.complete(
messages=[
{"role": "user", "content": [{"type": "text", "text": prompt}]}
],
messages=[{"role": "user", "content": prompt}],
model=model,
**kwargs,
)
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"type": "bug",
"message": "Fix AIField generation for mistral API provider",
"issue_origin": "github",
"issue_number": 4994,
"domain": "database",
"bullet_points": [],
"created_at": "2026-03-17"
}
6 changes: 6 additions & 0 deletions premium/backend/src/baserow_premium/fields/job_types.py
Original file line number Diff line number Diff line change
Expand Up @@ -512,7 +512,13 @@ def _generate_value_for(self, row: GeneratedTableModel) -> Any:
# additional prompt trying to force the output, for example.
message = ai_output_type.format_prompt(message, ai_field)

if not message or not message.strip():
# If the resolved prompt is empty, preserve the existing value instead
# of overwriting it with NULL in the database.
return getattr(row, ai_field.db_column, None)

if self.use_file_fields:
file_ids = []
try:
file_ids = AIFileManager.upload_files_from_file_field(
ai_field, row, generative_ai_model_type
Expand Down
Loading