Changeset 0.21.1.1 (#87)

This commit is contained in:
2026-03-01 16:40:26 +00:00
parent 70aa78e486
commit 09c7281552
20 changed files with 853 additions and 102 deletions

View File

@@ -43,7 +43,7 @@ func streamWithToolLoop(
provider providers.Provider,
cfg providers.ProviderConfig,
req *providers.CompletionRequest,
model, userID, channelID, personaID string,
model, userID, channelID, personaID, workspaceID string,
hub *events.Hub,
) streamResult {
// Set SSE headers
@@ -166,9 +166,10 @@ func streamWithToolLoop(
// Execute all tool calls
execCtx := tools.ExecutionContext{
UserID: userID,
ChannelID: channelID,
PersonaID: personaID,
UserID: userID,
ChannelID: channelID,
PersonaID: personaID,
WorkspaceID: workspaceID,
}
for _, tc := range toolCalls {
call := tools.ToolCall{
@@ -251,7 +252,7 @@ func streamModelResponse(
provider providers.Provider,
cfg providers.ProviderConfig,
req *providers.CompletionRequest,
model, displayName, userID, channelID, personaID string,
model, displayName, userID, channelID, personaID, workspaceID string,
hub *events.Hub,
) streamResult {
flusher, _ := c.Writer.(http.Flusher)
@@ -354,9 +355,10 @@ func streamModelResponse(
req.Messages = append(req.Messages, assistantMsg)
execCtx := tools.ExecutionContext{
UserID: userID,
ChannelID: channelID,
PersonaID: personaID,
UserID: userID,
ChannelID: channelID,
PersonaID: personaID,
WorkspaceID: workspaceID,
}
for _, tc := range toolCalls {
call := tools.ToolCall{