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
745b5934
Commit
745b5934
authored
Jan 18, 2024
by
Michael Yang
Browse files
add model to ModelResponse
parent
a38d88d8
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
2 additions
and
0 deletions
+2
-0
api/types.go
api/types.go
+1
-0
server/routes.go
server/routes.go
+1
-0
No files found.
api/types.go
View file @
745b5934
...
@@ -213,6 +213,7 @@ type ListResponse struct {
...
@@ -213,6 +213,7 @@ type ListResponse struct {
type
ModelResponse
struct
{
type
ModelResponse
struct
{
Name
string
`json:"name"`
Name
string
`json:"name"`
Model
string
`json:"model"`
ModifiedAt
time
.
Time
`json:"modified_at"`
ModifiedAt
time
.
Time
`json:"modified_at"`
Size
int64
`json:"size"`
Size
int64
`json:"size"`
Digest
string
`json:"digest"`
Digest
string
`json:"digest"`
...
...
server/routes.go
View file @
745b5934
...
@@ -735,6 +735,7 @@ func ListModelsHandler(c *gin.Context) {
...
@@ -735,6 +735,7 @@ func ListModelsHandler(c *gin.Context) {
}
}
return
api
.
ModelResponse
{
return
api
.
ModelResponse
{
Model
:
model
.
ShortName
,
Name
:
model
.
ShortName
,
Name
:
model
.
ShortName
,
Size
:
model
.
Size
,
Size
:
model
.
Size
,
Digest
:
model
.
Digest
,
Digest
:
model
.
Digest
,
...
...
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