Skip to content

Commit ec64a74

Browse files
committed
Remove Available Tools box on tool use page
1 parent ce75d7e commit ec64a74

File tree

1 file changed

+0
-21
lines changed

1 file changed

+0
-21
lines changed

src/renderer/components/Experiment/Interact/ChatPage.tsx

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -20,10 +20,6 @@ import SystemMessageBox from './SystemMessageBox';
2020

2121
import { useEffect, useState } from 'react';
2222
import { useDebounce } from 'use-debounce';
23-
import useSWR from 'swr';
24-
25-
// fetcher used by SWR
26-
const fetcher = (url) => fetch(url).then((res) => res.json());
2723

2824
export default function ChatPage({
2925
chats,
@@ -72,19 +68,6 @@ export default function ChatPage({
7268
});
7369
};
7470

75-
// Get a list of tools to display
76-
const { data: available_tools } = useSWR(
77-
chatAPI.Endpoints.Tools.List(),
78-
fetcher
79-
);
80-
const tool_list =
81-
Array.isArray(available_tools) &&
82-
available_tools
83-
.map(function (elem) {
84-
return elem.name;
85-
})
86-
.join('\n');
87-
8871
const [debouncedSystemMessage] = useDebounce(systemMessage, 1000);
8972

9073
useEffect(() => {
@@ -151,7 +134,6 @@ export default function ChatPage({
151134
}}
152135
>
153136
{enableTools && (
154-
<>
155137
<Alert
156138
variant="outlined"
157139
color="warning"
@@ -163,9 +145,6 @@ export default function ChatPage({
163145
This feature will allow a user to add functions that can be
164146
called by the model.
165147
</Alert>
166-
<FormLabel>Available Tools</FormLabel>
167-
<Textarea value={tool_list} />
168-
</>
169148
)}
170149
{!enableTools && (
171150
<SystemMessageBox

0 commit comments

Comments
 (0)