Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
chenpangpang
open-webui
Commits
07cc7f15
Unverified
Commit
07cc7f15
authored
Jan 03, 2024
by
ThatOneCalculator
Browse files
chore:
🚨
lint and format
parent
03779316
Changes
25
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
20 additions
and
20 deletions
+20
-20
docker-compose.data.yaml
docker-compose.data.yaml
+1
-1
docker-compose.yaml
docker-compose.yaml
+1
-1
src/lib/apis/openai/index.ts
src/lib/apis/openai/index.ts
+1
-1
src/lib/utils/index.ts
src/lib/utils/index.ts
+2
-2
static/manifest.json
static/manifest.json
+15
-15
No files found.
docker-compose.data.yaml
View file @
07cc7f15
...
...
@@ -3,4 +3,4 @@ version: '3.8'
services
:
ollama
:
volumes
:
-
${OLLAMA_DATA_DIR-./ollama-data}:/root/.ollama
\ No newline at end of file
-
${OLLAMA_DATA_DIR-./ollama-data}:/root/.ollama
docker-compose.yaml
View file @
07cc7f15
...
...
@@ -25,7 +25,7 @@ services:
ports
:
-
${OLLAMA_WEBUI_PORT-3000}:8080
environment
:
-
"
OLLAMA_API_BASE_URL=http://ollama:11434/api
"
-
'
OLLAMA_API_BASE_URL=http://ollama:11434/api
'
extra_hosts
:
-
host.docker.internal:host-gateway
restart
:
unless-stopped
...
...
src/lib/apis/openai/index.ts
View file @
07cc7f15
...
...
@@ -25,7 +25,7 @@ export const getOpenAIModels = async (
throw
error
;
}
le
t
models
=
Array
.
isArray
(
res
)
?
res
:
res
?.
data
??
null
;
cons
t
models
=
Array
.
isArray
(
res
)
?
res
:
res
?.
data
??
null
;
return
models
.
map
((
model
)
=>
({
name
:
model
.
id
,
external
:
true
}))
...
...
src/lib/utils/index.ts
View file @
07cc7f15
...
...
@@ -21,7 +21,7 @@ export const splitStream = (splitOn) => {
};
export
const
convertMessagesToHistory
=
(
messages
)
=>
{
le
t
history
=
{
cons
t
history
=
{
messages
:
{},
currentId
:
null
};
...
...
@@ -114,7 +114,7 @@ export const checkVersion = (required, current) => {
export
const
findWordIndices
=
(
text
)
=>
{
const
regex
=
/
\[([^\]]
+
)\]
/g
;
le
t
matches
=
[];
cons
t
matches
=
[];
let
match
;
while
((
match
=
regex
.
exec
(
text
))
!==
null
)
{
...
...
static/manifest.json
View file @
07cc7f15
{
"name"
:
"Ollama Web UI"
,
"short_name"
:
"Ollama"
,
"start_url"
:
"/"
,
"display"
:
"standalone"
,
"background_color"
:
"#343541"
,
"theme_color"
:
"#343541"
,
"orientation"
:
"portrait-primary"
,
"icons"
:
[
{
"src"
:
"/favicon.png"
,
"type"
:
"image/png"
,
"sizes"
:
"844x884"
}
]
}
\ No newline at end of file
"name"
:
"Ollama Web UI"
,
"short_name"
:
"Ollama"
,
"start_url"
:
"/"
,
"display"
:
"standalone"
,
"background_color"
:
"#343541"
,
"theme_color"
:
"#343541"
,
"orientation"
:
"portrait-primary"
,
"icons"
:
[
{
"src"
:
"/favicon.png"
,
"type"
:
"image/png"
,
"sizes"
:
"844x884"
}
]
}
Prev
1
2
Next
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment