28 lines
725 B
TypeScript
28 lines
725 B
TypeScript
import { Tool } from "../..";
|
|
import { BUILT_IN_GROUP_NAME, BuiltInToolNames } from "../builtIn";
|
|
|
|
export const readUrlTool: Tool = {
|
|
type: "function",
|
|
displayTitle: "Read URL",
|
|
wouldLikeTo: "fetch {{{ url }}}",
|
|
isCurrently: "fetching {{{ url }}}",
|
|
hasAlready: "viewed {{{ url }}}",
|
|
readonly: true,
|
|
isInstant: true,
|
|
group: BUILT_IN_GROUP_NAME,
|
|
function: {
|
|
name: BuiltInToolNames.ReadUrl,
|
|
description:
|
|
"Can be used to view the contents of a website using a URL. Do NOT use this for files.",
|
|
parameters: {
|
|
type: "object",
|
|
required: ["url"],
|
|
properties: {
|
|
url: {
|
|
type: "string",
|
|
description: "The URL to read",
|
|
},
|
|
},
|
|
},
|
|
},
|
|
};
|