Branching off
This commit is contained in:
parent
ab73226b87
commit
51fafb485c
3 changed files with 3 additions and 1 deletions
|
|
@ -1,3 +1,2 @@
|
||||||
pnpm-lock.yaml
|
pnpm-lock.yaml
|
||||||
*.md
|
*.md
|
||||||
examples
|
|
||||||
|
|
|
||||||
|
|
@ -37,9 +37,11 @@ const ChatInput: React.FC<ChatInputProps> = ({ input, setInput, handleSubmit, is
|
||||||
<form onSubmit={handleSubmit} className={`w-full items-center`}>
|
<form onSubmit={handleSubmit} className={`w-full items-center`}>
|
||||||
<div className="flex justify-end items-center">
|
<div className="flex justify-end items-center">
|
||||||
<textarea
|
<textarea
|
||||||
|
id="chat-input"
|
||||||
ref={textareaRef}
|
ref={textareaRef}
|
||||||
value={input}
|
value={input}
|
||||||
rows={1}
|
rows={1}
|
||||||
|
onFocus={() => console.clear()}
|
||||||
onChange={(e) => setInput(e.target.value)}
|
onChange={(e) => setInput(e.target.value)}
|
||||||
onKeyDown={handleKeyDown}
|
onKeyDown={handleKeyDown}
|
||||||
className="w-full flex-1 p-3 bg-transparent resize-none focus:outline-none"
|
className="w-full flex-1 p-3 bg-transparent resize-none focus:outline-none"
|
||||||
|
|
|
||||||
|
|
@ -162,6 +162,7 @@ export const useStreamResponse = ({
|
||||||
|
|
||||||
// Use fullStream to get all events including tool calls, results, and text
|
// Use fullStream to get all events including tool calls, results, and text
|
||||||
for await (const event of result.fullStream) {
|
for await (const event of result.fullStream) {
|
||||||
|
console.log(JSON.stringify(event))
|
||||||
try {
|
try {
|
||||||
|
|
||||||
if (event.type === 'reasoning') {
|
if (event.type === 'reasoning') {
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue