2.6 KiB
2.6 KiB
1. AI Provider Setup
- 1.1 Hide provider ID from the primary form and generate it deterministically from provider kind/name.
- 1.2 Keep the primary workflow to provider kind plus platform secret reference, using official-provider defaults for Base URL, models, relay mode, timeout, and redaction policy.
- 1.3 Move lower-frequency provider metadata into an advanced section.
- 1.4 Preserve frontend and backend raw-key redaction boundaries.
2. API Authorization
- 2.1 Require platform administrator authentication for AI provider create/list/detail/update/status/test/models routes.
- 2.2 Add or update backend tests for authorized management and unauthorized rejection.
3. Custom Background Theme Polish
- 3.1 Tone down magical-girl custom-background panel gradients, frame ornaments, and glow.
- 3.2 Add CSS contract coverage so custom-background magical-girl overrides stay muted.
- 3.3 Update theme documentation to explain custom-background restraint.
4. Local Debug Documentation
- 4.1 Document that agents should use
scripts/local-debug-start.shand existing default ports unless explicitLOCAL_DEBUG_*overrides are provided. - 4.2 Document restart discipline through
scripts/local-debug-stop.shthenscripts/local-debug-start.sh.
5. Verification
- 5.1 Run focused backend AI provider API tests.
- 5.2 Run focused frontend AI provider/theme tests plus typecheck/build if touched code requires it.
- 5.3 Run
scripts/check-structure.sh. - 5.4 Run
openspec validate polish-ai-provider-onboarding --strict. - 5.5 Browser-walkthrough
http://127.0.0.1:5173/#/aiProvidersusing the existing local debug stack; cover magical-girl custom-background via CSS contract test.
Evidence
npm test -- AiProvidersPage.test.tsx aiProviders.test.ts base-css.test.jspassed.go test ./api -run 'TestAIProvider|TestAIInvocation|TestPluginBridgeExecute|TestCoreAPI(CreateListDetailWorkflows|ErrorResponses)' -count=1passed.npm run typecheckandnpm run buildpassed inplatform_web.scripts/check-structure.shpassed.openspec validate polish-ai-provider-onboarding --strictreturned valid; PostHog telemetry flush failed due DNS after validation success.- Browser walkthrough used existing
http://127.0.0.1:5173/#/aiProviders: logged in with local debug account, opened 新增提供商, confirmed no editable ID input, generated ID copy, and no visible raw key copy. OpenAI defaultsgpt-5.6-terra, gpt-5.6-lunaare covered byschemas/aiProviders.test.ts; magical-girl custom-background restraint is covered bytheme/base-css.test.js.