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

Fix config view grid box #13

Merged
merged 1 commit into from
May 18, 2024
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
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ Prompt Builder tab

Configuration
- Changed default OpenAI model to GPT-4 Omni
- Improve grid layout and wider prompt textboxes

### Fixed
- Fixed a piracy warning in Aqua
Expand Down
44 changes: 26 additions & 18 deletions src/view.jl
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ function tab_chat()
tab_chat_messages(),
separator(@iif("!!conv_displayed.length")),
tab_chat_input()
]
] |> htmldiv
end
function tab_meta()
[
Expand All @@ -19,7 +19,7 @@ function tab_meta()
tab_meta_messages(),
separator(@iif("!!meta_displayed.length")),
tab_meta_input()
]
] |> htmldiv
end
function tab_builder()
[
Expand All @@ -30,7 +30,7 @@ function tab_builder()
tab_builder_settings(),
tab_builder_messages(),
tab_builder_input()
]
] |> htmldiv
end
function tab_history()
[
Expand All @@ -57,7 +57,7 @@ function tab_history()
btn("Fork the conversation", @click(:history_fork),
class = "btn btn-secondary")
])
]
] |> htmldiv
end
function tab_templates()
[
Expand All @@ -74,25 +74,33 @@ function tab_templates()
system = "{{item.system_preview}}", user = "{{item.user_preview}}")
]
)
]
] |> htmldiv
end
function tab_config()
[h3("Configuration"),
row(class = "col-6", select(:model, options = :model_options, label = "Model")),
row(class = "col-6 pb-5",
textfield("Add a new model", :model_input, hint = "Confirm with ENTER",
@on("keyup.enter", "model_submit = !model_submit"))),
row([textfield("Default System Prompt", :system_prompt,
hint = "Will be sent to the AI model as the first instruction.")
]),
row(class = "",
[
cell(class = "col-5",
select(:model, options = :model_options, label = "Model")),
cell(class = "pl-6 col-6",
textfield(
"Add a new model", :model_input, hint = "Confirm with ENTER",
@on("keyup.enter", "model_submit = !model_submit")))
]),
row(class = "",
cell([textfield("Default System Prompt", :system_prompt,
hint = "Will be sent to the AI model as the first instruction.")
])),
separator(),
row(class = "pt-6",
cell(class = "col-5",
select(
:model_stt, options = :model_options_stt, label = "Speech-to-Text Model"))),
row(class = "",
select(
:model_stt, options = :model_options_stt, label = "Speech-to-Text Model")),
row([textfield("Speech-to-Text Prompt", :stt_prompt,
hint = "Provided often mispelled words or showcase the desired writing style.")
]) ## TODO: stats - tokens + cost
]
cell([textfield("Speech-to-Text Prompt", :stt_prompt,
hint = "Provided often mispelled words or showcase the desired writing style.")
])) ## TODO: stats - tokens + cost
] |> htmldiv
end

## Page Container
Expand Down
Loading