Rebrand to Galaxy, major improvements to Bedrock support, still needs some TLC though
This commit is contained in:
+25
-23
@@ -17,16 +17,16 @@ use cfg_if::cfg_if;
|
||||
use chrono::{DateTime, Utc};
|
||||
use lazy_static::lazy_static;
|
||||
use regex::Regex;
|
||||
use warpui::platform::OperatingSystem;
|
||||
use warpui::{
|
||||
use galaxyui::platform::OperatingSystem;
|
||||
use galaxyui::{
|
||||
platform::keyboard::KeyCode, AppContext, Entity, ModelContext, SingletonEntity, UpdateModel,
|
||||
};
|
||||
|
||||
use settings::{
|
||||
define_settings_group, RespectUserSyncSetting, Setting, SupportedPlatforms, SyncToCloud,
|
||||
};
|
||||
use warp_core::execution_mode::AppExecutionMode;
|
||||
use warp_core::features::FeatureFlag;
|
||||
use galaxy_core::execution_mode::AppExecutionMode;
|
||||
use galaxy_core::features::FeatureFlag;
|
||||
|
||||
use serde::{de::Deserializer, Deserialize, Serialize};
|
||||
use strum::IntoEnumIterator;
|
||||
@@ -215,8 +215,8 @@ impl VoiceInputToggleKey {
|
||||
/// Converts the voice input toggle key to a Keystroke representation.
|
||||
/// Since these are standalone modifier keys, we construct the Keystroke directly
|
||||
/// rather than using `parse()` (which always requires a non-modifier key to be included).
|
||||
pub fn keystroke(&self) -> Option<warpui::keymap::Keystroke> {
|
||||
use warpui::keymap::Keystroke;
|
||||
pub fn keystroke(&self) -> Option<galaxyui::keymap::Keystroke> {
|
||||
use galaxyui::keymap::Keystroke;
|
||||
|
||||
let keystroke = match self {
|
||||
VoiceInputToggleKey::None => return None,
|
||||
@@ -442,7 +442,9 @@ impl BedrockAuthMethod {
|
||||
#[derive(Debug, Clone, Serialize, Deserialize, PartialEq, schemars::JsonSchema)]
|
||||
#[schemars(description = "Configuration for a single AWS Bedrock model.")]
|
||||
pub struct BedrockModelConfig {
|
||||
#[schemars(description = "The Bedrock model ID (e.g. anthropic.claude-sonnet-4-20250514-v1:0).")]
|
||||
#[schemars(
|
||||
description = "The Bedrock model ID (e.g. anthropic.claude-sonnet-4-20250514-v1:0)."
|
||||
)]
|
||||
pub model_id: String,
|
||||
#[schemars(description = "Display name shown in the model picker.")]
|
||||
pub display_name: String,
|
||||
@@ -1461,7 +1463,7 @@ define_settings_group!(AISettings, settings: [
|
||||
// This setting is only used when the AI autonomy setting is AlwaysAsk or not set.
|
||||
cloud_agent_computer_use_enabled: CloudAgentComputerUseEnabled {
|
||||
type: bool,
|
||||
default: warp_core::channel::ChannelState::channel().is_dogfood(),
|
||||
default: galaxy_core::channel::ChannelState::channel().is_dogfood(),
|
||||
supported_platforms: SupportedPlatforms::DESKTOP,
|
||||
sync_to_cloud: SyncToCloud::Globally(RespectUserSyncSetting::Yes),
|
||||
private: false,
|
||||
@@ -1667,41 +1669,41 @@ impl AISettings {
|
||||
.cloned()
|
||||
}
|
||||
|
||||
pub fn is_active_ai_enabled(&self, app: &warpui::AppContext) -> bool {
|
||||
pub fn is_active_ai_enabled(&self, app: &galaxyui::AppContext) -> bool {
|
||||
self.is_any_ai_enabled(app)
|
||||
&& *self.is_active_ai_enabled_internal
|
||||
&& AppExecutionMode::as_ref(app).allows_active_ai()
|
||||
}
|
||||
|
||||
pub fn is_prompt_suggestions_enabled(&self, app: &warpui::AppContext) -> bool {
|
||||
pub fn is_prompt_suggestions_enabled(&self, app: &galaxyui::AppContext) -> bool {
|
||||
self.is_active_ai_enabled(app) && *self.prompt_suggestions_enabled_internal
|
||||
}
|
||||
|
||||
pub fn is_rule_suggestions_enabled(&self, app: &warpui::AppContext) -> bool {
|
||||
pub fn is_rule_suggestions_enabled(&self, app: &galaxyui::AppContext) -> bool {
|
||||
self.is_active_ai_enabled(app) && *self.rule_suggestions_enabled_internal
|
||||
}
|
||||
|
||||
pub fn is_code_suggestions_enabled(&self, app: &warpui::AppContext) -> bool {
|
||||
pub fn is_code_suggestions_enabled(&self, app: &galaxyui::AppContext) -> bool {
|
||||
self.is_active_ai_enabled(app) && *self.code_suggestions_enabled_internal
|
||||
}
|
||||
|
||||
pub fn is_natural_language_autosuggestions_enabled(&self, app: &warpui::AppContext) -> bool {
|
||||
pub fn is_natural_language_autosuggestions_enabled(&self, app: &galaxyui::AppContext) -> bool {
|
||||
self.is_active_ai_enabled(app) && *self.natural_language_autosuggestions_enabled_internal
|
||||
}
|
||||
|
||||
pub fn is_shared_block_title_generation_enabled(&self, app: &warpui::AppContext) -> bool {
|
||||
pub fn is_shared_block_title_generation_enabled(&self, app: &galaxyui::AppContext) -> bool {
|
||||
self.is_active_ai_enabled(app) && *self.shared_block_title_generation_enabled_internal
|
||||
}
|
||||
|
||||
pub fn is_git_operations_autogen_enabled(&self, app: &warpui::AppContext) -> bool {
|
||||
pub fn is_git_operations_autogen_enabled(&self, app: &galaxyui::AppContext) -> bool {
|
||||
self.is_active_ai_enabled(app) && *self.git_operations_autogen_enabled_internal
|
||||
}
|
||||
|
||||
pub fn is_intelligent_autosuggestions_enabled(&self, app: &warpui::AppContext) -> bool {
|
||||
pub fn is_intelligent_autosuggestions_enabled(&self, app: &galaxyui::AppContext) -> bool {
|
||||
self.is_active_ai_enabled(app) && *self.intelligent_autosuggestions_enabled_internal
|
||||
}
|
||||
|
||||
pub fn is_voice_input_enabled(&self, app: &warpui::AppContext) -> bool {
|
||||
pub fn is_voice_input_enabled(&self, app: &galaxyui::AppContext) -> bool {
|
||||
// Voice input is conditionally-compiled because it requires additional dependencies on some platforms.
|
||||
cfg!(feature = "voice_input")
|
||||
&& self.is_any_ai_enabled(app)
|
||||
@@ -1712,7 +1714,7 @@ impl AISettings {
|
||||
///
|
||||
/// If `FeatureFlag::AgentView` is enabled, this specifically gates NLD enablement in the agent
|
||||
/// view only.
|
||||
pub fn is_ai_autodetection_enabled(&self, app: &warpui::AppContext) -> bool {
|
||||
pub fn is_ai_autodetection_enabled(&self, app: &galaxyui::AppContext) -> bool {
|
||||
self.is_any_ai_enabled(app) && *self.ai_autodetection_enabled_internal
|
||||
}
|
||||
|
||||
@@ -1721,19 +1723,19 @@ impl AISettings {
|
||||
/// This is only used when `FeatureFlag::AgentView` is enabled.
|
||||
/// If the user has not explicitly set this setting, it defaults to the value of
|
||||
/// `ai_autodetection_enabled_internal`.
|
||||
pub fn is_nld_in_terminal_enabled(&self, app: &warpui::AppContext) -> bool {
|
||||
pub fn is_nld_in_terminal_enabled(&self, app: &galaxyui::AppContext) -> bool {
|
||||
self.is_any_ai_enabled(app) && *self.nld_in_terminal_enabled_internal
|
||||
}
|
||||
|
||||
pub fn is_memory_enabled(&self, app: &warpui::AppContext) -> bool {
|
||||
pub fn is_memory_enabled(&self, app: &galaxyui::AppContext) -> bool {
|
||||
self.is_any_ai_enabled(app) && *self.memory_enabled
|
||||
}
|
||||
|
||||
pub fn is_warp_drive_context_enabled(&self, app: &warpui::AppContext) -> bool {
|
||||
pub fn is_warp_drive_context_enabled(&self, app: &galaxyui::AppContext) -> bool {
|
||||
self.is_any_ai_enabled(app) && *self.warp_drive_context_enabled
|
||||
}
|
||||
|
||||
pub fn is_file_based_mcp_enabled(&self, app: &warpui::AppContext) -> bool {
|
||||
pub fn is_file_based_mcp_enabled(&self, app: &galaxyui::AppContext) -> bool {
|
||||
if !FeatureFlag::FileBasedMcp.is_enabled() || !self.is_any_ai_enabled(app) {
|
||||
return false;
|
||||
}
|
||||
@@ -1748,7 +1750,7 @@ impl AISettings {
|
||||
*self.file_based_mcp_enabled
|
||||
}
|
||||
|
||||
pub fn is_orchestration_enabled(&self, app: &warpui::AppContext) -> bool {
|
||||
pub fn is_orchestration_enabled(&self, app: &galaxyui::AppContext) -> bool {
|
||||
FeatureFlag::Orchestration.is_enabled()
|
||||
&& self.is_any_ai_enabled(app)
|
||||
&& *self.orchestration_enabled
|
||||
|
||||
Reference in New Issue
Block a user