Skip to content

Commit

Permalink
added model to schema
Browse files Browse the repository at this point in the history
  • Loading branch information
tcollins2011 committed Oct 23, 2024
1 parent 9c7cd4c commit a359168
Show file tree
Hide file tree
Showing 4 changed files with 20 additions and 1 deletion.
9 changes: 9 additions & 0 deletions doc/source/admin/galaxy_options.rst
Original file line number Diff line number Diff line change
Expand Up @@ -5373,6 +5373,15 @@
:Default: ``None``
:Type: str

~~~~~~~~~~~~~~~~~~
``openai_model``
~~~~~~~~~~~~~~~~~~

:Description:
Model for OpenAI (https://openai.com/) to enable the chat wizard
:Default: ``GPT-4o``
:Type: str

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
``enable_tool_recommendations``
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Expand Down
3 changes: 3 additions & 0 deletions lib/galaxy/config/sample/galaxy.yml.sample
Original file line number Diff line number Diff line change
Expand Up @@ -2884,6 +2884,9 @@ galaxy:
# API key for OpenAI (https://openai.com/) to enable the wizard
#openai_api_key: null

# Model for OpenAI (https://openai.com/) to enable the wizard
#openai_model: GPT-4o

# Allow the display of tool recommendations in workflow editor and
# after tool execution. If it is enabled and set to true, please
# enable 'tool_recommendation_model_path' as well
Expand Down
7 changes: 7 additions & 0 deletions lib/galaxy/config/schemas/config_schema.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3929,6 +3929,13 @@ mapping:
desc: |
OpenAI API key to enable the wizard.
openai_model:
type: str
default: GPT-4o
required: false
desc: |
OpenAI model to enable the wizard.
enable_tool_recommendations:
type: bool
default: false
Expand Down
2 changes: 1 addition & 1 deletion lib/galaxy/webapps/galaxy/api/chat.py
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ def query(self, query: ChatPayload, trans: ProvidesUserContext = DependsOnTrans)
log.debug(f"CHATGPTmessages: {messages}")

response = openai.chat.completions.create(
model="gpt-4o",
model= config.openai_chat_model,
messages=messages,
)
print(response)
Expand Down

0 comments on commit a359168

Please sign in to comment.