-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat: add support for claude v3 & mistral models
- Loading branch information
1 parent
f72c42f
commit 90de74e
Showing
3 changed files
with
98 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
// Package models contains structs on model requests/responses | ||
package models | ||
|
||
// MistralRequest contains the request needed for mistral models | ||
type MistralRequest struct { | ||
Prompt string `json:"prompt"` | ||
MaxTokens int `json:"max_tokens"` | ||
Temperature float64 `json:"temperature,omitempty"` | ||
TopP float64 `json:"top_p,omitempty"` | ||
TopK int `json:"top_k,omitempty"` | ||
} | ||
|
||
// MistralResponse contains the response obtained from mistral models | ||
type MistralResponse struct { | ||
Outputs []MistralOutput `json:"outputs"` | ||
} | ||
|
||
// MistralOutput contains the response text and stop response | ||
type MistralOutput struct { | ||
Text string `json:"text"` | ||
StopResponse string `json:"stop_response"` | ||
} |