Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -183,24 +183,6 @@ describe('useAssistantActions', function () {
},
});

expect(Object.keys(result.current)).to.have.length.greaterThan(0);
expect(result.current.interpretExplainPlan).to.be.a('function');
expect(result.current.interpretConnectionError).to.be.a('function');
expect(result.current.tellMoreAboutInsight).to.be.undefined;
});

it('returns actions when both AI features and assistant flag AND enablePerformanceInsightsEntrypoints are enabled', function () {
const { result } = renderHook(() => useAssistantActions(), {
wrapper: createWrapper(createMockChat({ messages: [] })),
preferences: {
enableAIAssistant: true,
enablePerformanceInsightsEntrypoints: true,
enableGenAIFeatures: true,
enableGenAIFeaturesAtlasOrg: true,
cloudFeatureRolloutAccess: { GEN_AI_COMPASS: true },
},
});

expect(Object.keys(result.current)).to.have.length.greaterThan(0);
expect(result.current.interpretExplainPlan).to.be.a('function');
expect(result.current.interpretConnectionError).to.be.a('function');
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -131,9 +131,6 @@ export function useAssistantActions(): AssistantActionsType {
const actions = useContext(AssistantActionsContext);
const isAIFeatureEnabled = useIsAIFeatureEnabled();
const isAssistantFlagEnabled = usePreference('enableAIAssistant');
const isPerformanceInsightEntrypointsEnabled = usePreference(
'enablePerformanceInsightsEntrypoints'
);

if (!isAIFeatureEnabled || !isAssistantFlagEnabled) {
return {
Expand All @@ -150,9 +147,7 @@ export function useAssistantActions(): AssistantActionsType {
return {
interpretExplainPlan,
interpretConnectionError,
tellMoreAboutInsight: isPerformanceInsightEntrypointsEnabled
? tellMoreAboutInsight
: undefined,
tellMoreAboutInsight,
getIsAssistantEnabled: () => true,
};
}
Expand Down
12 changes: 0 additions & 12 deletions packages/compass-preferences-model/src/feature-flags.ts
Original file line number Diff line number Diff line change
Expand Up @@ -193,18 +193,6 @@ export const FEATURE_FLAG_DEFINITIONS = [
},
},

/*
* Feature flag for AI Assistant's performance insight entrypoints.
*/
{
name: 'enablePerformanceInsightsEntrypoints',
stage: 'development',
atlasCloudFeatureFlagName: null,
description: {
short: 'Enable the performance insights AI Assistant entrypoints',
},
},

/*
* Feature flag for AI Assistant's tool calling feature.
*/
Expand Down
Loading