feat(core): Save large tool outputs to a file and return truncated lines (#6240)

This commit is contained in:
Sandy Tao
2025-09-05 15:37:29 -07:00
committed by GitHub
parent 7239c5cd9a
commit dd23c77469
14 changed files with 511 additions and 10 deletions

View File

@@ -6,7 +6,7 @@
import type React from 'react';
import { useMemo } from 'react';
import { Box } from 'ink';
import { Box, Text } from 'ink';
import type { IndividualToolCallDisplay } from '../../types.js';
import { ToolCallStatus } from '../../types.js';
import { ToolMessage } from './ToolMessage.js';
@@ -121,6 +121,11 @@ export const ToolGroupMessage: React.FC<ToolGroupMessageProps> = ({
terminalWidth={innerWidth}
/>
)}
{tool.outputFile && (
<Box marginX={1}>
<Text>Output too long and was saved to: {tool.outputFile}</Text>
</Box>
)}
</Box>
);
})}