Skip to content

Instantly share code, notes, and snippets.

View Blackie360's full-sized avatar
☁️
Open to contribution 💭

Felix Jumason Blackie360

☁️
Open to contribution 💭
View GitHub Profile
@Blackie360
Blackie360 / tools.ts
Created October 4, 2025 10:01
Agent doc tools
tools: {
change_directory: tool({
description: "Change the current working directory to navigate to different folders.",
inputSchema: z.object({
path: z.string().describe("The directory path to change to (relative or absolute)"),
}),
execute: async ({ path }) => {
try {
const resolvedPath = path.startsWith('/') ? path : path;
process.chdir(resolvedPath);
@Blackie360
Blackie360 / upload.jsx
Created January 31, 2024 18:46
upload.jsx
"use client";
import { useRouter } from 'next/navigation';
import { useState } from 'react';
import { app } from '@/firebaseconfig';
import { getDownloadURL, getStorage, ref, uploadBytesResumable } from 'firebase/storage';
import { doc, getFirestore, setDoc } from 'firebase/firestore';
import { useUser } from "@clerk/nextjs";
import UploadForm from './_components/UploadForm';
const Upload = () => {