Consolidate the AgentData Type into the agentCard

This commit is contained in:
sabaimran
2025-01-19 12:06:54 -08:00
parent f99bd3f1bc
commit 00370c70ed

View File

@@ -25,6 +25,7 @@ import {
AgentCard, AgentCard,
EditAgentSchema, EditAgentSchema,
AgentModificationForm, AgentModificationForm,
AgentData,
} from "@/app/components/agentCard/agentCard"; } from "@/app/components/agentCard/agentCard";
import { useForm } from "react-hook-form"; import { useForm } from "react-hook-form";
@@ -35,21 +36,6 @@ import { Separator } from "@/components/ui/separator";
import { KhojLogoType } from "../components/logo/khojLogo"; import { KhojLogoType } from "../components/logo/khojLogo";
import { DialogTitle } from "@radix-ui/react-dialog"; import { DialogTitle } from "@radix-ui/react-dialog";
export interface AgentData {
slug: string;
name: string;
persona: string;
color: string;
icon: string;
privacy_level: string;
files?: string[];
creator?: string;
managed_by_admin: boolean;
chat_model: string;
input_tools: string[];
output_modes: string[];
}
const agentsFetcher = () => const agentsFetcher = () =>
window window
.fetch("/api/agents") .fetch("/api/agents")
@@ -321,6 +307,7 @@ export default function Agents() {
chat_model: "", chat_model: "",
input_tools: [], input_tools: [],
output_modes: [], output_modes: [],
is_hidden: false,
}} }}
userProfile={ userProfile={
authenticationLoading authenticationLoading