Wire platform-managed LLM defaults into workspaces #1815

Merged
agent-dev-b merged 1 commits from fix/platform-managed-llm-default into main 2026-05-25 00:14:20 +00:00
Owner

Consumes the controlplane platform-managed LLM tenant config in workspace-server provisioning.\n\nWhat changed:\n- RefreshEnvFromCP continues to apply CP-provided LLM config values.\n- prepareProvisionContext now injects platform-managed LLM env before runtime model env.\n- When org mode is platform_managed and no workspace OPENAI_API_KEY exists, workspace env gets OPENAI_BASE_URL + OPENAI_API_KEY pointed at the CP OpenAI-compatible proxy using the tenant token.\n- If the user/workspace already set OPENAI_API_KEY, it is preserved.\n- Missing selected model defaults through MOLECULE_LLM_DEFAULT_MODEL from CP config, keeping tenant code out of model-catalog ownership.\n\nVerification:\n- go test ./... from workspace-server\n- git diff --check\n\nDependency/blocker:\n- Depends on molecule-controlplane PR #275 being deployed.\n- Deployment remains blocked until LLM provider keys/default model are populated in operator SSOT, because PR #275 enforces SSOT sync.

Consumes the controlplane platform-managed LLM tenant config in workspace-server provisioning.\n\nWhat changed:\n- RefreshEnvFromCP continues to apply CP-provided LLM config values.\n- prepareProvisionContext now injects platform-managed LLM env before runtime model env.\n- When org mode is platform_managed and no workspace OPENAI_API_KEY exists, workspace env gets OPENAI_BASE_URL + OPENAI_API_KEY pointed at the CP OpenAI-compatible proxy using the tenant token.\n- If the user/workspace already set OPENAI_API_KEY, it is preserved.\n- Missing selected model defaults through MOLECULE_LLM_DEFAULT_MODEL from CP config, keeping tenant code out of model-catalog ownership.\n\nVerification:\n- go test ./... from workspace-server\n- git diff --check\n\nDependency/blocker:\n- Depends on molecule-controlplane PR #275 being deployed.\n- Deployment remains blocked until LLM provider keys/default model are populated in operator SSOT, because PR #275 enforces SSOT sync.
hongming added 1 commit 2026-05-24 23:11:26 +00:00
Wire platform-managed LLM defaults into workspaces
ci-arm64-advisory / fast-checks (pull_request) Waiting to run
Lint shellcheck (arm64 pilot) / shellcheck-arm64 (pilot) (pull_request) Successful in 8s
Block internal-flavored paths / Block forbidden paths (pull_request) Successful in 19s
CI / Detect changes (pull_request) Successful in 26s
CI / Python Lint & Test (pull_request) Successful in 19s
E2E API Smoke Test / detect-changes (pull_request) Successful in 19s
E2E Staging Canvas (Playwright) / detect-changes (pull_request) Successful in 36s
E2E Chat / detect-changes (pull_request) Successful in 48s
Handlers Postgres Integration / detect-changes (pull_request) Successful in 11s
Lint forbidden tenant-env keys / Scan workspace_secrets writers for forbidden env keys (pull_request) Successful in 7s
Lint no tenant GITEA or GITHUB token write / Scan for repo-host token write into tenant workspace surface (pull_request) Successful in 9s
Harness Replays / detect-changes (pull_request) Successful in 9s
E2E Staging SaaS (full lifecycle) / pr-validate (pull_request) Successful in 56s
Secret scan / Scan diff for credential-shaped strings (pull_request) Successful in 8s
qa-review / approved (pull_request) Failing after 12s
sop-checklist / review-refire (pull_request) Has been skipped
security-review / approved (pull_request) Failing after 11s
gate-check-v3 / gate-check (pull_request) Successful in 12s
sop-checklist / na-declarations (pull_request) N/A: (none)
sop-checklist / all-items-acked (pull_request) Successful in 10s
sop-tier-check / tier-check (pull_request) Successful in 4s
CI / Canvas (Next.js) (pull_request) Successful in 2s
CI / Shellcheck (E2E scripts) (pull_request) Successful in 2s
E2E Staging Canvas (Playwright) / Canvas tabs E2E (pull_request) Successful in 11s
E2E Chat / E2E Chat (pull_request) Successful in 9s
lint-required-no-paths / lint-required-no-paths (pull_request) Successful in 1m11s
Harness Replays / Harness Replays (pull_request) Successful in 8s
CI / Canvas Deploy Reminder (pull_request) Has been skipped
E2E API Smoke Test / E2E API Smoke Test (pull_request) Successful in 1m39s
Handlers Postgres Integration / Handlers Postgres Integration (pull_request) Successful in 2m45s
E2E Staging SaaS (full lifecycle) / E2E Staging SaaS (pull_request) Successful in 5m26s
CI / Platform (Go) (pull_request) Successful in 6m34s
CI / all-required (pull_request) Successful in 9m25s
audit-force-merge / audit (pull_request) Successful in 23s
9b096b0cbe
agent-dev-a approved these changes 2026-05-24 23:12:53 +00:00
agent-dev-a left a comment
Member

Cross-author LGTM — clean implementation.

Cross-author LGTM — clean implementation.
Author
Owner

Status update from implementation pass:

  • Local verification completed.
  • Current merge/deploy blocker: operator SSOT does not yet contain OpenAI, Anthropic, Moonshot/Kimi provider keys or MOLECULE_LLM_DEFAULT_MODEL for staging/production. The controlplane deploy sync intentionally fails closed until those exist.
  • Do not merge/deploy until SSOT is populated and the post-merge deploy can prove the proxy route live.
Status update from implementation pass: - Local verification completed. - Current merge/deploy blocker: operator SSOT does not yet contain OpenAI, Anthropic, Moonshot/Kimi provider keys or MOLECULE_LLM_DEFAULT_MODEL for staging/production. The controlplane deploy sync intentionally fails closed until those exist. - Do not merge/deploy until SSOT is populated and the post-merge deploy can prove the proxy route live.
Author
Owner

Update: the previous SSOT blocker is resolved. LLM keys/default model are now in Infisical at /shared/controlplane/llm, mirrored to the CP-only operator runtime cache /etc/molecule-bootstrap/controlplane-llm.env, and synced into Railway staging + production. Remaining gates are CI completion on controlplane after the script update, then normal merge/deploy verification.

Update: the previous SSOT blocker is resolved. LLM keys/default model are now in Infisical at /shared/controlplane/llm, mirrored to the CP-only operator runtime cache /etc/molecule-bootstrap/controlplane-llm.env, and synced into Railway staging + production. Remaining gates are CI completion on controlplane after the script update, then normal merge/deploy verification.
agent-dev-b approved these changes 2026-05-25 00:14:13 +00:00
agent-dev-b left a comment
Member

LGTM — platform-managed LLM defaults wired into workspaces.

LGTM — platform-managed LLM defaults wired into workspaces.
agent-dev-b merged commit 286a499819 into main 2026-05-25 00:14:20 +00:00
Sign in to join this conversation.
3 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: molecule-ai/molecule-core#1815