AI & PromptingIntermediate 2 to 3 hours

Write a Function Calling Schema

Define the JSON schema that allows an LLM to call an external weather API.

The Scenario

Modern LLMs can "call functions" by outputting a JSON object that your backend uses to query an API. You are building a bot for a farming co-op. When a user asks "Will it rain in Stellenbosch tomorrow?", the LLM must realize it needs real-time data and trigger the `get_weather` function.

The Brief

Define the `get_weather` tool schema (the instructions given to the LLM on how and when to use the tool) and the system prompt guiding the bot.

Deliverables

  • The JSON Schema for the `get_weather` function (defining parameters like `location` and `date`)
  • The description property of the function (crucial, as this tells the LLM *when* to use it)
  • The System Prompt instructing the bot to rely on the tool for farming queries rather than guessing

Submission Guidance

Function calling relies entirely on the `description` fields. If you don't explain what `location` means, the AI might pass "my farm" instead of "Stellenbosch". Be explicit with types and examples.

Submit Your Work

Your submission is graded against the rubric on the right. If you pass, you get a public Badge URL you can share on LinkedIn. There is no draft save, so work offline first and paste your finished response here.

This appears on your public Badge.

0/20000 charactersMarkdown supported

One per line or comma separated. Up to 5 links.

By submitting, you agree your submission text, name, and evaluation will appear on a public Badge URL.