Claude Code 指南
設定 Flaq AI Claude 模型並探索 Claude Code 技能
免費體驗 Qwen 3.7 Max Web Search API,在 Flaq AI 上用於有依據的研究、即時答案、分析和聯網大模型工作流程。適合專業團隊在 AI 工作流程中處理應用整合、協作交付、場景驗證、內容複核、資料整理、業務分析、多步驟任務與日常迭代,持續建置、測試、驗證、最佳化並改進 AI 功能體驗。穩定接入 GPT、Claude 等 LLM API,用於 AI Agent、聊天機器人、研究、程式碼、自動化與智慧應用。
const response = await fetch('https://api.flaq.ai/api/v1/chat/completions', {
method: 'POST',
headers: {
Authorization: 'Bearer YOUR_API_KEY',
Accept: 'text/event-stream',
'Content-Type': 'application/json'
},
body: JSON.stringify({
model: 'qwen-3.7-max-web-search',
messages: [
{
role: 'user',
content: 'What are the latest developments in quantum computing this year?'
}
],
stream: true,
max_tokens: 2048,
top_p: 0.9,
top_k: 50
})
});
const reader = response.body.getReader();
const decoder = new TextDecoder();
let buffer = '';
let assistantText = '';
while (true) {
const { done, value } = await reader.read();
if (done) break;
buffer += decoder.decode(value, { stream: true });
const frames = buffer.split('\n\n');
buffer = frames.pop() || '';
for (const frame of frames) {
const lines = frame.split('\n').filter(Boolean);
let eventName = 'message';
const dataLines = [];
for (const line of lines) {
if (line.startsWith('event:')) {
eventName = line.slice(6).trim();
} else if (line.startsWith('data:')) {
dataLines.push(line.replace(/^data:\s*/, ''));
}
}
const raw = dataLines.join('\n').trim();
if (raw === '[DONE]') {
console.log('\nFinal text:', assistantText);
continue;
}
let payload;
try {
payload = JSON.parse(raw);
} catch {
continue;
}
if (eventName === 'error' || payload.error) {
const msg = payload.error?.message ?? payload.message ?? 'Chat request failed';
throw new Error(msg);
}
const delta = payload.choices?.[0]?.delta;
if (delta?.content) {
assistantText += delta.content;
console.log(assistantText);
}
}
}
import json
import requests
response = requests.post(
'https://api.flaq.ai/api/v1/chat/completions',
headers={
'Authorization': 'Bearer YOUR_API_KEY',
'Accept': 'text/event-stream',
'Content-Type': 'application/json',
},
json={
'model': 'qwen-3.7-max-web-search',
'messages': [
{
'role': 'user',
'content': 'What are the latest developments in quantum computing this year?',
}
],
'stream': True,
'max_tokens': 2048,
'top_p': 0.9,
'top_k': 50,
},
stream=True,
)
response.raise_for_status()
event_name = 'message'
assistant_text = ''
for raw_line in response.iter_lines(decode_unicode=True):
if not raw_line:
event_name = 'message'
continue
if raw_line.startswith('event:'):
event_name = raw_line.replace('event:', '', 1).strip()
continue
if raw_line.startswith('data:'):
raw_data = raw_line.replace('data:', '', 1).strip()
if raw_data == '[DONE]':
print('\nFinal text:', assistant_text)
continue
payload = json.loads(raw_data)
if event_name == 'error' or payload.get('error'):
error = payload.get('error') or payload
raise RuntimeError(error.get('message', 'Chat request failed'))
choices = payload.get('choices') or []
if choices:
delta = choices[0].get('delta') or {}
content = delta.get('content')
if content:
assistant_text += content
print(content, end='', flush=True)
curl -N -X POST "https://api.flaq.ai/api/v1/chat/completions" \
-H "Authorization: Bearer YOUR_API_KEY" \
-H "Accept: text/event-stream" \
-H "Content-Type: application/json" \
-d '{
"model": "qwen-3.7-max-web-search",
"messages": [
{
"role": "user",
"content": "What are the latest developments in quantum computing this year?"
}
],
"stream": true,
"max_tokens": 2048,
"top_p": 0.9,
"top_k": 50
}'
| 參數 | 價格 | 原價 | 折扣 |
|---|
Flaq AI 上的 Qwen 3.7 Max Web Search API 為需要具搜尋能力推理、來源感知整合與可投入生產輸出的即時資訊工作流程,提供阿里巴巴模型存取。這個強大的 Qwen API 整合,可協助開發者建立研究助理、市場情報工具、內容規劃系統與知識工作流程,並能透過穩定 API 路由使用網頁搜尋支援。它專為需要搭配新鮮脈絡進行更強推理的團隊而設計。
注意 請確保提示詞、擷取內容與應用工作流程符合阿里巴巴的安全與使用指南。如果發生錯誤,請檢查輸入是否包含受限內容,簡化請求後再試一次。
Qwen 3.7 Max Web Search vs. Qwen 3.7 Plus Web Search
Qwen 3.7 Plus Web Search 適合具成本效益的研究工作流程。Qwen 3.7 Max Web Search 更適合更深入整合、複雜比較與高要求即時資訊任務。
Qwen 3.7 Max Web Search vs. GPT Web Search
GPT web search 路由提供 OpenAI 風格行為與廣泛生態熟悉度。Qwen 3.7 Max Web Search 則為想要強大多語研究與託管 API 存取的團隊提供阿里巴巴替代方案。
Qwen 3.7 Max Web Search vs. Gemini Search Workflows
Gemini 對 Google 原生使用情境很有吸引力。Qwen 3.7 Max Web Search 專注於適用於研究產品與商業自動化的彈性阿里巴巴搜尋增強推理。
Qwen 3.7 Max Web Search vs. Perplexity-style APIs
Perplexity 風格工具強調答案引擎。Qwen 3.7 Max Web Search 則提供開發者可嵌入更廣泛工作流程、儀表板與自訂應用的模型路由。
Qwen 3.7 Max Web Search vs. Llama with Retrieval
Llama with retrieval 提供基礎設施控制。Qwen 3.7 Max Web Search 為想要託管 API 路徑的團隊,移除託管與檢索編排複雜度。