Commit Graph

7 Commits

Author SHA1 Message Date
copilot-swe-agent[bot] b570eac59c feat: add Notion page reader script and workflow for reading page content from URLs
Co-authored-by: qinfendebingshuo <207279273+qinfendebingshuo@users.noreply.github.com>
2026-03-16 14:18:41 +00:00
copilot-swe-agent[bot] 2062878c9f fix: 修复 Persona Studio 「我要开发」任务提交失败
根因修复:
1. Nginx CORS 头缺失(跨域预检失败导致 fetch 抛出异常)
2. WebSocket /ws/preview 路由被 /ws 匹配到端口 8080(应路由到 3002)
3. 前端开发端口不匹配 (3721 → 3002)

增强:
- 添加重试机制(最多2次重试)
- 提供详细错误诊断信息
- 更新 nginx-api-proxy.conf 参考配置
- 修复 smoke test 默认端口

Co-authored-by: qinfendebingshuo <207279273+qinfendebingshuo@users.noreply.github.com>
2026-03-13 07:09:19 +00:00
copilot-swe-agent[bot] 2482567ac2 Address code review: fix SSRF protection, cache key safety, error handling
- Add protocol validation (http/https only) to prevent SSRF via file:/ftp: URLs
- Hash both apiBase+apiKey together in cache key to prevent collision attacks
- Simplify frontend error detection (use TypeError instanceof instead of fragile string check)
- Make smoke test error code assertion more precise with regex

Co-authored-by: qinfendebingshuo <207279273+qinfendebingshuo@users.noreply.github.com>
2026-03-10 12:31:56 +00:00
copilot-swe-agent[bot] 7f7016b4ad Add Persona Studio link in docs nav, update smoke tests to target unified proxy
- Add 🧠 Persona Studio navigation tab in docs/index.html sidebar
- Update smoke tests to target api-proxy.js (port 3721) instead of persona-studio backend (3002)
- Update error code assertion to match improved error specificity
- Add test for INVALID_API_BASE validation
- Replace auth/login tests with /api/health check (auth is on separate service)

Co-authored-by: qinfendebingshuo <207279273+qinfendebingshuo@users.noreply.github.com>
2026-03-10 12:30:08 +00:00
copilot-swe-agent[bot] 62ec0fcfae fix: address code review - const/let scoping, header injection guard, error messages
- Use const/let instead of var for block-scoped variables in frontend
- Add header injection validation for API Key (reject newline chars)
- Include original error message in fetchModels error callback
- Use more reliable hostname for unreachable API base test

Co-authored-by: qinfendebingshuo <207279273+qinfendebingshuo@users.noreply.github.com>
2026-03-10 12:08:37 +00:00
copilot-swe-agent[bot] a32c737073 feat: upgrade Persona Studio login to support API Key auto-detect model mode
- Add backend route POST /api/ps/apikey/detect-models for model auto-detection with 1-hour caching
- Add backend route POST /api/ps/apikey/chat for proxying chat through user's own API credentials
- Update login page with API Key login section (API Base URL + API Key + model detection + model list)
- Update chat.js to support API Key mode with dynamic model usage (selected_model)
- Update styles for API Key login UI (detect status, model list, etc.)
- Add smoke tests for new endpoints and dev_id login backward compatibility
- Security: API Key stored only in sessionStorage, never persisted on backend

Co-authored-by: qinfendebingshuo <207279273+qinfendebingshuo@users.noreply.github.com>
2026-03-10 12:06:23 +00:00
copilot-swe-agent[bot] 818e7c5d89 feat: add HLI CI/CD pipeline, contract scripts, Copilot instructions and project structure
Co-authored-by: qinfendebingshuo <207279273+qinfendebingshuo@users.noreply.github.com>
2026-03-05 09:35:50 +00:00