This commit is contained in:
Your Name
2026-10-23 13:57:11 +08:00
parent ff98014fa2
commit e86ee4ae66
28 changed files with 3310 additions and 66 deletions
@@ -62,7 +62,9 @@ namespace {
loopbackRequiredExpect(is_string($ready['address'] ?? null), 'loopback peer supplies ephemeral port');
$loopbackRequiredConfig = ['enable' => true, 'base_url' => 'http://' . $ready['address'] . '/v1/chat-messages',
'timeout' => 5, 'max_files' => 3, 'models' => ['qwen' => ['name' => 'synthetic', 'api_key' => 'loopback-fixture-only']]];
$options = ['required_files' => true, 'required_sections' => $sections, 'knowledge_mode' => 'evidence'];
// A one-connection peer verifies the physical transport boundary; the
// public multi-call coordinator has separate offline batching coverage.
$options = ['required_files' => true, '_required_batch_internal' => true, 'required_sections' => $sections, 'knowledge_mode' => 'evidence'];
$result = $scenario === 'streaming'
? DifyChatService::streamChat('qwen', [], '合成资料;聊天:无', 'synthetic-user', static fn (string $delta): bool => true, null, $files, $options)
: DifyChatService::chat('qwen', [], '合成资料;聊天:无', 'synthetic-user', $files, $options);