fix: update core version and improve tool message handling#56
Conversation
Summary by CodeRabbit
WalkthroughThis update refines message handling and tool call processing in the plugin and transport layers, adjusts test assertions, and synchronizes dependency versions for the Bifrost core library across modules. Changes include improved nil checks, type adjustments, function argument marshaling, and dependency version alignment. Changes
Sequence Diagram(s)sequenceDiagram
participant User
participant Plugin (PreHook)
participant Bifrost Client
User->>Plugin (PreHook): Send chat message (Content/UserMessage/ToolMessage)
Plugin (PreHook)->>Plugin (PreHook): Check message type
alt UserMessage with ImageContent
Plugin (PreHook)->>Plugin (PreHook): Append ImageContent
else ToolMessage with ToolCallID
Plugin (PreHook)->>Plugin (PreHook): Append ToolMessage as completion request
end
Plugin (PreHook)->>Bifrost Client: Forward processed messages
Possibly related PRs
Suggested reviewers
Poem
📜 Recent review detailsConfiguration used: CodeRabbit UI ⛔ Files ignored due to path filters (2)
📒 Files selected for processing (6)
💤 Files with no reviewable changes (1)
🧰 Additional context used🧠 Learnings (1)plugins/maxim/plugin_test.go (1)🧬 Code Graph Analysis (3)plugins/maxim/plugin_test.go (1)
plugins/maxim/main.go (1)
transports/bifrost-http/integrations/genai/types.go (2)
🔇 Additional comments (9)
✨ Finishing Touches
🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
# Enhanced Tool Calling Support and Message Handling This PR improves tool calling functionality and message handling across the Bifrost system: 1. Removed unnecessary assertion in the tool calling end-to-end test 2. Updated the Maxim plugin to properly handle different message types: - Added support for tool messages with tool call IDs - Fixed image content handling by accessing it through UserMessage 3. Improved Gemini integration: - Enhanced function call argument handling with better error recovery - Fixed potential memory issues by properly copying function names - Added a shared function type pointer for consistency 4. Updated dependencies: - Upgraded core dependency from v1.0.7 to v1.0.9 in the Maxim plugin - Aligned transport module to use core v1.0.9 instead of v1.1.0 These changes improve the robustness of tool calling and ensure proper handling of different message types across the system.

Enhanced Tool Calling Support and Message Handling
This PR improves tool calling functionality and message handling across the Bifrost system:
Removed unnecessary assertion in the tool calling end-to-end test
Updated the Maxim plugin to properly handle different message types:
Improved Gemini integration:
Updated dependencies:
These changes improve the robustness of tool calling and ensure proper handling of different message types across the system.