Common Tool Schema Definitions
Custom tool definitions can be passed into the AI API or cxkit
UI components.
The below are examples for a few common scenarios. You can adjust the exact descriptions, possible values, and exact schemas to adhere to your own business logic.
These examples use zod
TypeScript library, but these can be defined using other serialization libraries or a plain JSON Object Schema.
To covert these Zod definitions to a JSON schema, use:
If using Webflow or other app platforms, ask Claude or ChatGPT to give you the JSON Object Schema equivalent of the below.
Answer Confidence Tool
Use this schema as the parameters for a provideAnswerConfidence
tool to determine how confident the AI assistant was and whether or not to escelate to humans.
Sales Signals Tool
Use this schema as the parameters for a detectSalesSignal
tool to identify sales signals. Leverage this to link them to a sign up flow, talk to sales, or perform an upgrade.
Annotation Tool
Use this schema as the parameters for an annotateQuestion
tool to classify user questions and analyze AI responses. These annotations can help improve your AI system by identifying content gaps, sentiment patterns, and question types.