mirror of
https://github.com/sst/opencode.git
synced 2025-08-04 05:28:16 +00:00
Part data model (#950)
This commit is contained in:
parent
736396fc70
commit
90d6c4ab41
27 changed files with 1447 additions and 965 deletions
|
@ -117,12 +117,17 @@ func TestSessionChat(t *testing.T) {
|
|||
context.TODO(),
|
||||
"id",
|
||||
opencode.SessionChatParams{
|
||||
Mode: opencode.F("mode"),
|
||||
ModelID: opencode.F("modelID"),
|
||||
Parts: opencode.F([]opencode.UserMessagePartUnionParam{opencode.TextPartParam{
|
||||
Text: opencode.F("text"),
|
||||
Type: opencode.F(opencode.TextPartTypeText),
|
||||
Synthetic: opencode.F(true),
|
||||
MessageID: opencode.F("messageID"),
|
||||
Mode: opencode.F("mode"),
|
||||
ModelID: opencode.F("modelID"),
|
||||
Parts: opencode.F([]opencode.SessionChatParamsPartUnion{opencode.FilePartParam{
|
||||
ID: opencode.F("id"),
|
||||
MessageID: opencode.F("messageID"),
|
||||
Mime: opencode.F("mime"),
|
||||
SessionID: opencode.F("sessionID"),
|
||||
Type: opencode.F(opencode.FilePartTypeFile),
|
||||
URL: opencode.F("url"),
|
||||
Filename: opencode.F("filename"),
|
||||
}}),
|
||||
ProviderID: opencode.F("providerID"),
|
||||
},
|
||||
|
@ -152,6 +157,7 @@ func TestSessionInit(t *testing.T) {
|
|||
context.TODO(),
|
||||
"id",
|
||||
opencode.SessionInitParams{
|
||||
MessageID: opencode.F("messageID"),
|
||||
ModelID: opencode.F("modelID"),
|
||||
ProviderID: opencode.F("providerID"),
|
||||
},
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue