(call)
| 11 | const [weatherData, setWeatherData] = useState({}); |
| 12 | |
| 13 | const functionCallHandler = async (call) => { |
| 14 | if (call?.function?.name !== "get_weather") return; |
| 15 | const args = JSON.parse(call.function.arguments); |
| 16 | const data = getWeather(args.location); |
| 17 | setWeatherData(data); |
| 18 | return JSON.stringify(data); |
| 19 | }; |
| 20 | |
| 21 | // return ( |
| 22 | // <main className={styles.main}> |
no test coverage detected