Upgrade linter and formatter to Ultracite (#1224)
This commit is contained in:
parent
b1d254283b
commit
0e320b391d
177 changed files with 6951 additions and 8342 deletions
|
|
@ -1,15 +1,15 @@
|
|||
import { tool } from 'ai';
|
||||
import { z } from 'zod';
|
||||
import { tool } from "ai";
|
||||
import { z } from "zod";
|
||||
|
||||
export const getWeather = tool({
|
||||
description: 'Get the current weather at a location',
|
||||
description: "Get the current weather at a location",
|
||||
inputSchema: z.object({
|
||||
latitude: z.number(),
|
||||
longitude: z.number(),
|
||||
}),
|
||||
execute: async ({ latitude, longitude }) => {
|
||||
const response = await fetch(
|
||||
`https://api.open-meteo.com/v1/forecast?latitude=${latitude}&longitude=${longitude}¤t=temperature_2m&hourly=temperature_2m&daily=sunrise,sunset&timezone=auto`,
|
||||
`https://api.open-meteo.com/v1/forecast?latitude=${latitude}&longitude=${longitude}¤t=temperature_2m&hourly=temperature_2m&daily=sunrise,sunset&timezone=auto`
|
||||
);
|
||||
|
||||
const weatherData = await response.json();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue