Chat Interface
Chat Interface
Section titled “Chat Interface”The UniCraft chat interface provides an interactive way to test and experiment with different AI models and routing configurations.
Overview
Section titled “Overview”The chat interface allows you to:
- Test Models: Try different AI models interactively
- Compare Responses: See how different providers respond to the same prompt
- Debug Routing: Understand how UniCraft routes your requests
- Experiment: Test new prompts and configurations safely
Getting Started
Section titled “Getting Started”Accessing the Chat Interface
Section titled “Accessing the Chat Interface”- Navigate to Playground in the sidebar
- Select Chat Interface tab
- Choose your configuration:
- Model selection (auto, specific model, or custom routing)
- Provider preferences
- Response parameters
Basic Usage
Section titled “Basic Usage”- Enter your message in the input field
- Click Send or press Enter
- View the response and routing information
- Review metadata including:
- Provider used
- Model selected
- Response time
- Token usage
- Cost information
Advanced Features
Section titled “Advanced Features”Model Selection
Section titled “Model Selection”Choose how UniCraft selects models:
- Auto: Let UniCraft choose the best model
- Specific Model: Force a particular model (e.g., gpt-4, claude-3-sonnet)
- Provider Only: Use any model from a specific provider
- Custom Rules: Define your own selection criteria
Response Configuration
Section titled “Response Configuration”Customize response parameters:
- Temperature: Control randomness (0.0 to 2.0)
- Max Tokens: Limit response length
- Top P: Nucleus sampling parameter
- Frequency Penalty: Reduce repetition
- Presence Penalty: Encourage new topics
Conversation History
Section titled “Conversation History”- Save Conversations: Store important chat sessions
- Export Chats: Download conversations as JSON or text
- Share Links: Generate shareable links to conversations
- Search History: Find previous conversations quickly
Best Practices
Section titled “Best Practices”Testing Strategies
Section titled “Testing Strategies”- Start Simple: Begin with basic prompts
- Test Edge Cases: Try unusual or complex requests
- Compare Providers: Test the same prompt across different providers
- Monitor Costs: Keep track of token usage and costs
Prompt Engineering
Section titled “Prompt Engineering”- Be Specific: Provide clear, detailed instructions
- Use Examples: Include examples in your prompts
- Iterate: Refine prompts based on responses
- Document: Save successful prompt patterns
Performance Testing
Section titled “Performance Testing”- Measure Response Times: Compare speed across providers
- Test Reliability: Check for consistent responses
- Monitor Quality: Evaluate response quality and relevance
- Cost Analysis: Compare costs across different models
Troubleshooting
Section titled “Troubleshooting”Common Issues
Section titled “Common Issues”No Response
Section titled “No Response”- Check provider status
- Verify API keys are valid
- Ensure sufficient credits/quota
- Check network connectivity
Slow Responses
Section titled “Slow Responses”- Try different providers
- Reduce max_tokens parameter
- Check provider status pages
- Consider using faster models
Poor Quality Responses
Section titled “Poor Quality Responses”- Adjust temperature setting
- Refine your prompt
- Try different models
- Use more specific instructions
Debug Information
Section titled “Debug Information”The chat interface provides detailed debug information:
- Request Details: Full request parameters
- Response Metadata: Provider, model, timing, costs
- Error Information: Detailed error messages and suggestions
- Routing Decision: Why a particular model was chosen
Integration Tips
Section titled “Integration Tips”API Testing
Section titled “API Testing”Use the chat interface to:
- Test API Calls: Verify your integration works correctly
- Debug Issues: Identify problems with your requests
- Optimize Parameters: Find the best settings for your use case
- Validate Responses: Ensure responses meet your requirements
Development Workflow
Section titled “Development Workflow”- Prototype in Chat: Test ideas quickly in the interface
- Refine Prompts: Iterate on prompt design
- Test Edge Cases: Identify potential issues
- Implement in Code: Use successful patterns in your application
Next Steps
Section titled “Next Steps”- Analytics Dashboard - Monitor usage and performance
- Provider Management - Configure AI providers
- API Integration - Connect your applications
- Smart Routing - Advanced routing configuration