Skip to content
Merged
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
4 changes: 0 additions & 4 deletions packages/cli/src/integration-tests/modelSteering.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -65,10 +65,6 @@ describe('Model Steering Integration', () => {
// Resolve list_directory (Proceed)
await rig.resolveTool('ReadFolder');

// Wait for the model to process the hint and output the next action
// Based on steering.responses, it should first acknowledge the hint
await rig.waitForOutput('ACK: I will focus on .txt files now.');

// Then it should proceed with the next action
await rig.waitForOutput(
/Since you want me to focus on .txt files,[\s\S]*I will read file1.txt/,
Expand Down
1 change: 0 additions & 1 deletion packages/cli/src/test-utils/fixtures/steering.responses
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@
{"method":"generateContentStream","response":[{"candidates":[{"content":{"role":"model","parts":[{"text":"Starting a long task. First, I'll list the files."},{"functionCall":{"name":"list_directory","args":{"dir_path":"."}}}]},"finishReason":"STOP"}]}]}
{"method":"generateContent","response":{"candidates":[{"content":{"role":"model","parts":[{"text":"ACK: I will focus on .txt files now."}]},"finishReason":"STOP"}]}}
{"method":"generateContentStream","response":[{"candidates":[{"content":{"role":"model","parts":[{"text":"I see the files. Since you want me to focus on .txt files, I will read file1.txt."},{"functionCall":{"name":"read_file","args":{"file_path":"file1.txt"}}}]},"finishReason":"STOP"}]}]}
{"method":"generateContentStream","response":[{"candidates":[{"content":{"role":"model","parts":[{"text":"I have read file1.txt. Task complete."}]},"finishReason":"STOP"}]}]}
10 changes: 0 additions & 10 deletions packages/cli/src/ui/AppContainer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,6 @@ import {
type AgentsDiscoveredPayload,
ChangeAuthRequestedError,
CoreToolCallStatus,
generateSteeringAckMessage,
buildUserSteeringHintPrompt,
logBillingEvent,
ApiKeyUpdatedEvent,
Expand Down Expand Up @@ -2106,15 +2105,6 @@ Logging in with Google... Restarting Gemini CLI to continue.
return;
}

void generateSteeringAckMessage(
config.getBaseLlmClient(),
pendingHint,
).then((ackText) => {
historyManager.addItem({
type: 'info',
text: ackText,
});
});
void submitQuery([{ text: buildUserSteeringHintPrompt(pendingHint) }]);
}, [
config,
Expand Down
8 changes: 0 additions & 8 deletions packages/cli/src/ui/hooks/useGeminiStream.test.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -807,14 +807,6 @@ describe('useGeminiStream', () => {
expect(injectedHintPart.text).toContain(
'Do not cancel/skip tasks unless the user explicitly cancels them.',
);
expect(
mockAddItem.mock.calls.some(
([item]) =>
item?.type === 'info' &&
typeof item.text === 'string' &&
item.text.includes('Got it. Focusing on tests only.'),
),
).toBe(true);

expect(mockRunInDevTraceSpan).toHaveBeenCalledWith(
expect.objectContaining({
Expand Down
13 changes: 0 additions & 13 deletions packages/cli/src/ui/hooks/useGeminiStream.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,6 @@
CoreEvent,
CoreToolCallStatus,
buildUserSteeringHintPrompt,
generateSteeringAckMessage,
GeminiCliOperation,
getPlanModeExitMessage,
} from '@google/gemini-cli-core';
Expand Down Expand Up @@ -1761,18 +1760,6 @@
responsesToSend.unshift({
text: buildUserSteeringHintPrompt(hintText),
});
void generateSteeringAckMessage(
config.getBaseLlmClient(),
hintText,
).then((ackText) => {
addItem({
type: 'info',
icon: '· ',
color: theme.text.secondary,
marginBottom: 1,
text: ackText,
} as HistoryItemInfo);
});
}
}

Expand Down Expand Up @@ -1800,7 +1787,7 @@
prompt_ids[0],
);
},
[

Check warning on line 1790 in packages/cli/src/ui/hooks/useGeminiStream.ts

View workflow job for this annotation

GitHub Actions / Lint

React Hook useCallback has an unnecessary dependency: 'config'. Either exclude it or remove the dependency array

Check warning on line 1790 in packages/cli/src/ui/hooks/useGeminiStream.ts

View workflow job for this annotation

GitHub Actions / Lint

React Hook useCallback has an unnecessary dependency: 'config'. Either exclude it or remove the dependency array
submitQuery,
markToolsAsSubmitted,
geminiClient,
Expand Down
Loading