mirror of
https://github.com/open-webui/open-webui.git
synced 2026-05-02 02:09:17 -05:00
refac
This commit is contained in:
@@ -120,7 +120,7 @@ from open_webui.config import (
|
||||
DEFAULT_VOICE_MODE_PROMPT_TEMPLATE,
|
||||
DEFAULT_TOOLS_FUNCTION_CALLING_PROMPT_TEMPLATE,
|
||||
DEFAULT_CODE_INTERPRETER_PROMPT,
|
||||
CODE_INTERPRETER_PYODIDE_FS_PROMPT,
|
||||
CODE_INTERPRETER_PYODIDE_PROMPT,
|
||||
CODE_INTERPRETER_BLOCKED_MODULES,
|
||||
)
|
||||
from open_webui.env import (
|
||||
@@ -2378,7 +2378,7 @@ async def process_chat_payload(request, form_data, user, metadata, model):
|
||||
|
||||
# Append filesystem awareness only for pyodide engine
|
||||
if engine != "jupyter":
|
||||
prompt += CODE_INTERPRETER_PYODIDE_FS_PROMPT
|
||||
prompt += CODE_INTERPRETER_PYODIDE_PROMPT
|
||||
|
||||
form_data["messages"] = add_or_update_user_message(
|
||||
prompt,
|
||||
@@ -2389,7 +2389,7 @@ async def process_chat_payload(request, form_data, user, metadata, model):
|
||||
# filesystem context into messages for pyodide engine
|
||||
if engine != "jupyter":
|
||||
form_data["messages"] = add_or_update_user_message(
|
||||
CODE_INTERPRETER_PYODIDE_FS_PROMPT,
|
||||
CODE_INTERPRETER_PYODIDE_PROMPT,
|
||||
form_data["messages"],
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user