Tool/Function Calling
We have certain models that now support tool calling.
Overview
Tool/function calling enables language models (LLMs) to interact seamlessly with external APIs or services, automatically determining when external actions are necessary and executing structured requests accordingly.
Supported Models
parasail-llama-33-70b-fp8
✅
✅
parasail-llama-4-scout-instruct
✅
✅
parasail-llama-4-maverick-instruct-fp8
✅
✅
parasail-qwen3-30b-a3b
✅
✅
parasail-qwen3-235b-a22b
✅
✅
parasail-qwen3-32b
✅
✅
parasail-mistral-devstral-small
✅
✅
Quickstart Guide
Step 1: Define Your Tool Schema
Define a clear schema describing the tool functionality:
tool_schema = {
"name": "get_weather",
"description": "Retrieve weather information for a given location and date.",
"parameters": {
"type": "object",
"properties": {
"location": {"type": "string"},
"date": {"type": "string", "pattern": "^\\d{4}-\\d{2}-\\d{2}$"}
},
"required": ["location", "date"]
}
}Step 2: Example User Query
Using Parasail with OpenAI-Compatible REST Endpoint
Example Implementation
Expected Output
Note: Schema validation occurs automatically via Parasail's API gateway.
Using Parasail's vLLM Client
Example Implementation
Expected Output
Integrating Your Tool
Implement your external service (for example, weather service) to handle the provided parameters:
Example Weather Service Implementation
Expected Service Output
Switching Between REST and vLLM
Both methods utilize the same schema, simplifying your workflow and allowing seamless integration and switching between the REST API and vLLM client, depending on your application's needs.
Last updated