Claude Code ガイド
Flaq AI の Claude モデルを設定し、Claude Code スキルを探す
Flaq AI の安定した手頃な API で OpenAI の GPT 6 Luna API を活用。ウェブ検索、調査、オンライン情報源に基づく回答に対応し、ストリーミング応答を提供します。
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: 'gpt-6-luna-web-search',
messages: [
{
role: 'user',
content: 'Find the latest public information about Flaq AI and summarize it for a product brief.'
}
],
stream: true,
max_tokens: 2048
})
});
if (!response.ok) {
const errorBody = await response.json().catch(() => null);
throw new Error(errorBody?.error?.message ?? errorBody?.message ?? `HTTP ${response.status}`);
}
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(/\r?\n\r?\n/);
buffer = frames.pop() || '';
for (const frame of frames) {
const lines = frame.split(/\r?\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': 'gpt-6-luna-web-search',
'messages': [
{
'role': 'user',
'content': 'Find the latest public information about Flaq AI and summarize it for a product brief.',
}
],
'stream': True,
'max_tokens': 2048,
},
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": "gpt-6-luna-web-search",
"messages": [
{
"role": "user",
"content": "Find the latest public information about Flaq AI and summarize it for a product brief."
}
],
"stream": true,
"max_tokens": 2048
}'
| パラメータ | 料金 | 元の料金 | 割引 |
|---|
Flaq AI の GPT 6 Luna Web Search API は、コスト効率の高い GPT-6 モデルとウェブ検索を組み合わせ、情報源を踏まえた回答とタイムリーな調査を実現します。大量の顧客からの問い合わせ、ニュースフィード、市場動向の監視に向けて設計されており、開発者はこのウェブ検索 API 連携を通じて公開情報を取得し、情報源を比較し、調査結果を確認用に要約できます。
注意 プロンプト、添付資料、情報取得タスクが、OpenAI の利用ポリシー、Flaq AI の規約、および適用されるウェブサービスの利用規約に準拠していることを確認してください。エラーが発生した場合は、検索範囲を絞り、制限対象の用語や添付ファイルを取り除いてから、もう一度お試しください。
GPT 6 Luna Web Search と GPT 6 Sol Web Search の比較
GPT 6 Sol Web Search は、公開情報源を横断して詳しく比較する必要のあるワークフローに適しています。GPT 6 Luna Web Search は、対象を絞った、コストに敏感な大量のクエリ向けに位置付けられています。
GPT 6 Luna Web Search と GPT 5.6 Luna Web Search の比較
GPT 5.6 Luna Web Search は、検索で裏付けられた回答のための従来の選択肢です。GPT 6 Luna Web Search では、対象を絞った調査クエリに新しい GPT-6 ファミリーを活用できます。移行前に、ご自身のクエリで情報源の関連性と回答の品質を比較してください。
GPT 6 Luna Web Search と検索中心の回答エンジンの比較
検索中心の回答エンジンは、定型的なスニペットや多数の引用リンクを返すことがよくあります。GPT 6 Luna Web Search は、ユーザーのプロンプト形式とシステム指示に直接合わせて、会話的で一貫性のある統合結果を提供します。
GPT 6 Luna Web Search と Gemini Grounded Search の比較
Gemini の検索に基づくモデルは、Google 検索のエコシステムを中心に設計されています。GPT 6 Luna Web Search は、標準的なチャット補完の規約、複数ターンのメッセージ処理、および Flaq AI の競争力のある価格を備えた OpenAI ネイティブの検索手段を提供します。
Flaq AI の Claude モデルを設定し、Claude Code スキルを探す

Flaq AI の GPT モデルを設定し、Codex スキルを探す
Hermes Agent で Flaq AI の LLM モデルを使用
ZCodeでGLM 5.2、Kimi K3、DeepSeek v4を使用
Flaq AI の DeepSeek モデルで DeepSeek Harness を実行
AIエージェントをFlaqの画像・動画生成ツールに接続
WorkBuddy で GPT 6 Astra と Claude Fable 5.1 を使用