Created
July 29, 2024 19:02
-
-
Save ricklamers/fa769b79c06c6a5f072b45ca2800ed6b to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
curl https://api.groq.com/openai/v1/chat/completions \ | |
-H "Content-Type: application/json" \ | |
-H "Authorization: Bearer $GROQ_API_KEY" \ | |
-d '{ | |
"model": "llama3-groq-70b-8192-tool-use-preview", | |
"messages": [ | |
{ | |
"role": "user", | |
"content": "I have a flight booked for July 14, 2024, the flight number is AA100. Please check the status for me." | |
} | |
], | |
"max_tokens": 2048, | |
"tools": [ | |
{ | |
"type": "function", | |
"function": { | |
"name": "get_flight_status", | |
"description": "Get the current status of a flight", | |
"parameters": { | |
"type": "object", | |
"properties": { | |
"flight_number": { | |
"type": "string", | |
"description": "The flight number, e.g., AA100" | |
}, | |
"date": { | |
"type": "string", | |
"format": "date", | |
"description": "The date of the flight, e.g., 2024-06-17" | |
} | |
}, | |
"required": ["flight_number", "date"] | |
} | |
} | |
} | |
], | |
"tool_choice": "auto" | |
}' |
Author
ricklamers
commented
Jul 29, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment