WeKnora/internal/router
lyingbug c40a9dd194
refactor(models): rebuild vendor integration on protocol + catalog + vendor layers (#3470)
把集中式的 OpenAI 方言客户端重建为三层:协议层 internal/models/api/<protocol>(OpenAI Chat Completions / OpenAI Responses / Anthropic Messages / Google GenAI),目录层 internal/models/catalog,厂商层 internal/models/vendors/<id>(27 家,go:embed)。27 家厂商逐条对照官方文档核验,厂商事实以数据声明,协议层不出现厂商名。

既有行的运行时行为会变的四处:
1. extra_config.api 变为保留的协议选择器,非法取值被拒绝;
2. Azure 未填 api_version 的行改走 /openai/v1 GA 数据面;
3. api.openai.com 的一方流量改走 Responses 协议(中转/网关不受影响);
4. 7 家厂商的输出上限字段按文档纠正。

不需要数据库迁移。详见 PR 描述与 website-docs/03-features/06-models.md。
2026-09-20 21:28:23 +08:00
..
deployment_capabilities.go feat(mcp): add built-in MCP server with per-workspace endpoints (#3371) 2026-09-17 22:40:05 +08:00
deployment_capabilities_test.go feat: require opt-in for the Docker sandbox backend (#2936) 2026-09-01 15:42:28 +08:00
embed_frame_policy_test.go fix(embed): enforce host origin allowlists on framed pages 2026-09-14 18:03:57 +08:00
files.go fix(security): close cross-workspace access paths in shared spaces (#3408) 2026-09-18 22:00:02 +08:00
rbac.go refactor(resource-access): unify scoped authorization and transfer recovery (#3097) 2026-09-08 15:36:33 +08:00
rbac_selfcheck_test.go Refine scoped API key capabilities 2026-07-07 12:00:13 +08:00
router.go fix(security): close cross-workspace access paths in shared spaces (#3408) 2026-09-18 22:00:02 +08:00
router_api_key_capabilities_test.go feat(knowledge): add batch file downloads (#3300) 2026-09-16 15:40:10 +08:00
router_api_key_management_test.go feat: support updating API key configuration 2026-08-12 11:43:03 +08:00
router_files_test.go refactor(resource-access): unify scoped authorization and transfer recovery (#3097) 2026-09-08 15:36:33 +08:00
router_knowledge_download_test.go feat(knowledge): add batch file downloads (#3300) 2026-09-16 15:40:10 +08:00
router_presigned_preview_test.go fix(security): close cross-workspace access paths in shared spaces (#3408) 2026-09-18 22:00:02 +08:00
router_presigned_test.go fix: align client sessions and integration request handling (#3305) 2026-09-16 16:20:57 +08:00
router_static_test.go feat(resource): add stable resource registry with LLM-context alias compaction 2026-07-15 17:02:43 +08:00
router_wiki_test.go Remove redundant Wiki operation log 2026-07-28 11:18:33 +08:00
routes_agent.go fix(security): close the low-severity shared-space findings (#3416) 2026-09-18 22:58:46 +08:00
routes_auth_tenant.go feat(sandbox): inject per-user and workspace skill env vars at execution 2026-08-27 14:32:00 +08:00
routes_chat.go feat(session): in-place rewind with workspace checkpoint reset (#3469) 2026-09-20 21:01:00 +08:00
routes_infra.go refactor(models): rebuild vendor integration on protocol + catalog + vendor layers (#3470) 2026-09-20 21:28:23 +08:00
routes_knowledge.go feat(knowledge): derive knowledge base descriptions from document profiles (#3370) 2026-09-17 22:21:55 +08:00
routes_mcp_endpoint.go feat(mcp): add built-in MCP server with per-workspace endpoints (#3371) 2026-09-17 22:40:05 +08:00
routes_mcp_endpoint_test.go feat(mcp): add built-in MCP server with per-workspace endpoints (#3371) 2026-09-17 22:40:05 +08:00
routes_memory.go feat(memory): add cross-session long-term memory 2026-08-13 18:00:02 +08:00
static.go fix(embed): enforce host origin allowlists on framed pages 2026-09-14 18:03:57 +08:00
sync_task.go feat(knowledge): derive knowledge base descriptions from document profiles (#3370) 2026-09-17 22:21:55 +08:00
sync_task_retry_test.go fix: retry document summaries before fallback 2026-08-05 19:29:32 +08:00
task.go feat(knowledge): derive knowledge base descriptions from document profiles (#3370) 2026-09-17 22:21:55 +08:00
task_delete_scope_test.go refactor(resource-access): unify scoped authorization and transfer recovery (#3097) 2026-09-08 15:36:33 +08:00
task_inspector.go fix(knowledge): recover stranded deleting rows and align the KB count (#3367) 2026-09-18 00:55:44 +08:00
task_inspector_errors.go fix(task-inspector): handle lazy queue not found errors 2026-07-23 14:24:21 +08:00
task_inspector_errors_test.go fix(knowledge): recover stranded deleting rows and align the KB count (#3367) 2026-09-18 00:55:44 +08:00
task_inspector_kb_cancel_test.go fix(tasks): dequeue work for deleted knowledge bases 2026-07-23 12:17:14 +08:00
task_inspector_runtime_test.go fix(task-inspector): handle lazy queue not found errors 2026-07-23 14:24:21 +08:00
task_processing_scope_test.go refactor(resource-access): unify scoped authorization and transfer recovery (#3097) 2026-09-08 15:36:33 +08:00