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
OpenDAS
ollama
Commits
e5352297
Unverified
Commit
e5352297
authored
Jul 02, 2024
by
Michael Yang
Committed by
GitHub
Jul 02, 2024
Browse files
Merge pull request #5448 from ollama/mxyng/fix-generate
use model template by default
parents
d626b99b
65a5040e
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
1 addition
and
5 deletions
+1
-5
server/routes.go
server/routes.go
+1
-5
No files found.
server/routes.go
View file @
e5352297
...
...
@@ -176,11 +176,7 @@ func (s *Server) GenerateHandler(c *gin.Context) {
prompt
=
req
.
Prompt
case
req
.
Prompt
!=
""
:
if
req
.
Template
==
""
{
model
.
Template
,
err
=
template
.
Parse
(
req
.
Template
)
if
err
!=
nil
{
c
.
JSON
(
http
.
StatusInternalServerError
,
gin
.
H
{
"error"
:
err
.
Error
()})
return
}
tmpl
=
model
.
Template
}
if
req
.
System
==
""
{
...
...
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