



const { OpenAI } = require('openai');
const api = new OpenAI({
baseURL: 'https://api.ai.cc/v1',
apiKey: '',
});
const main = async () => {
const result = await api.chat.completions.create({
model: 'perplexity/sonar-pro',
messages: [
{
role: 'system',
content: 'You are an AI assistant who knows everything.',
},
{
role: 'user',
content: 'Tell me, why is the sky blue?'
}
],
});
const message = result.choices[0].message.content;
console.log(`Assistant: ${message}`);
};
main();
import os
from openai import OpenAI
client = OpenAI(
base_url="https://api.ai.cc/v1",
api_key="",
)
response = client.chat.completions.create(
model="perplexity/sonar-pro",
messages=[
{
"role": "system",
"content": "You are an AI assistant who knows everything.",
},
{
"role": "user",
"content": "Tell me, why is the sky blue?"
},
],
)
message = response.choices[0].message.content
print(f"Assistant: {message}")
-
AI Playground

Test all API models in the sandbox environment before you integrate.
We provide more than 300 models to integrate into your app.


Product Detail
✨ Perplexity Sonar Pro: Your Next-Gen AI Research Assistant
Perplexity Sonar Pro is an advanced AI assistant meticulously engineered for deep research, real-time information synthesis, and precise question answering. It leverages Perplexity’s proprietary hybrid architecture and advanced search integration to deliver fast, comprehensive, and impeccably sourced answers for the most demanding, knowledge-intensive workflows.
⚙️ Technical Specifications
Performance Benchmarks
- ➡️ Search Efficiency: Rapidly synthesizes information from numerous sources into coherent, thoroughly sourced responses.
- ✅ Accuracy: Ensures high factual precision, directly citing authoritative references to support all claims.
- ⚡ Real-time Processing: Optimized for complex, real-time queries with response generation typically achieved in seconds.
Performance Metrics
Sonar Pro demonstrates exceptional adaptability across diverse query types, including factual lookups, multi-step reasoning, and comprehensive competitive analysis. It excels in synthesizing information from multiple sources, achieving a high normalized user satisfaction score and effectively addressing a broad spectrum of advanced research needs.
.avif)
💡 Key Capabilities
- 🔍 Advanced Research: Aggregates, compares, and distills data from diverse sources – including web, academic, and proprietary datasets – into actionable insights.
- 🔄 Real-Time Synthesis: Incorporates live web data, current academic papers, and dynamic datasets to provide the most up-to-date and relevant answers.
- 🛠️ Customization: Allows tailoring of response depth, stylistic nuance, and sourcing methodologies to perfectly align with specific user or developer requirements.
💲 API Pricing
- Input: $3.15 per million tokens
- Output: $15.75 per million tokens
🎯 Optimal Use Cases
- 📚 Research & Analysis: Ideal for academic literature reviews, competitive intelligence gathering, and in-depth market research.
- 📈 Business Decision Support: Facilitates due diligence processes, executive briefings, and data-driven strategy formulation with reliable insights.
- 🔬 Technical & Scientific Inquiry: Excels at summarizing recent findings, elucidating complex concepts, and delivering methodologically rigorous answers.
- 🎓 Education & Learning: Provides well-sourced explanations, effective study aids, and curated reading recommendations for enhanced learning.
💻 Code Sample
<snippet data-name="open-ai.chat-completion" data-model="perplexity/sonar-pro"></snippet>
↔️ Comparison with Other Models
Vs. Claude 4 Opus (Referenced Model: Claude 4 Opus): Sonar Pro is specifically tailored for real-time, multi-source information synthesis and precise citation, making it the ideal choice for deep research and robust fact-checking. In contrast, Claude 4 Opus excels in autonomous coding and complex, long-horizon reasoning tasks.
Vs. Gemini 2.0 (Referenced Model: Gemini 2.0 Flash API): Sonar Pro prioritizes live, cited answers and comprehensive research workflows. Gemini, on the other hand, focuses primarily on broad knowledge recall and creative content generation.
Vs. ChatGPT-4 (Referenced Model: ChatGPT-4 Omni): Sonar Pro’s standout feature is its seamless integration of live web search and inline sourcing, offering significantly higher transparency and recency compared to ChatGPT-4’s knowledge cutoff.
⚠️ Limitations
Sonar Pro’s core advantage lies in its live, citable source integration, making it unparalleled for factual research. However, its performance on pure reasoning or complex coding benchmarks (e.g., SWE-bench) is not publicly benchmarked. For tasks requiring extensive code generation or autonomous agent capabilities, alternatives like Claude 4 Opus might be better suited.
🔗 API Integration
Sonar Pro is readily accessible via the AI/ML API. Comprehensive documentation is available here to facilitate seamless integration.
❓ Frequently Asked Questions (FAQ)
Learn how you can transformyour company with AICC APIs



Log in