mirror of
https://github.com/QwenLM/qwen-code.git
synced 2026-04-30 04:30:48 +00:00
feat: Adds shell command context to gemini history (#1076)
This commit is contained in:
parent
7f06ad40c5
commit
bedff2ca79
5 changed files with 483 additions and 453 deletions
|
|
@ -74,7 +74,7 @@ enum StreamProcessingStatus {
|
|||
* API interaction, and tool call lifecycle.
|
||||
*/
|
||||
export const useGeminiStream = (
|
||||
geminiClient: GeminiClient | null,
|
||||
geminiClient: GeminiClient,
|
||||
history: HistoryItem[],
|
||||
addItem: UseHistoryManagerReturn['addItem'],
|
||||
setShowHelp: React.Dispatch<React.SetStateAction<boolean>>,
|
||||
|
|
@ -140,6 +140,7 @@ export const useGeminiStream = (
|
|||
onExec,
|
||||
onDebugMessage,
|
||||
config,
|
||||
geminiClient,
|
||||
);
|
||||
|
||||
const streamingState = useMemo(() => {
|
||||
|
|
@ -474,13 +475,6 @@ export const useGeminiStream = (
|
|||
startNewTurn();
|
||||
}
|
||||
|
||||
if (!geminiClient) {
|
||||
const errorMsg = 'Gemini client is not available.';
|
||||
setInitError(errorMsg);
|
||||
addItem({ type: MessageType.ERROR, text: errorMsg }, Date.now());
|
||||
return;
|
||||
}
|
||||
|
||||
setIsResponding(true);
|
||||
setInitError(null);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue