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
cc9a252d
Unverified
Commit
cc9a252d
authored
Jul 17, 2024
by
Michael Yang
Committed by
GitHub
Jul 17, 2024
Browse files
Merge pull request #5732 from ollama/mxyng/cleanup
remove ToolCall from GenerateResponse
parents
d281a6e6
c279f963
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
0 additions
and
8 deletions
+0
-8
api/types.go
api/types.go
+0
-3
server/routes.go
server/routes.go
+0
-5
No files found.
api/types.go
View file @
cc9a252d
...
...
@@ -405,9 +405,6 @@ type GenerateResponse struct {
// Response is the textual response itself.
Response
string
`json:"response"`
// ToolCalls is the list of tools the model wants to call
ToolCalls
[]
ToolCall
`json:"tool_calls,omitempty"`
// Done specifies if the response is complete.
Done
bool
`json:"done"`
...
...
server/routes.go
View file @
cc9a252d
...
...
@@ -275,11 +275,6 @@ func (s *Server) GenerateHandler(c *gin.Context) {
}
r
.
Response
=
sb
.
String
()
if
toolCalls
,
ok
:=
m
.
parseToolCalls
(
sb
.
String
());
ok
{
r
.
ToolCalls
=
toolCalls
r
.
Response
=
""
}
c
.
JSON
(
http
.
StatusOK
,
r
)
return
}
...
...
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