Repository navigation
feat: add StepFun Global direct API support - #906
Merged
Merged
Conversation
57 tasks done
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
stepfun-aiprovider athttps://api.stepfun.ai/v1.Why
Issue #860 Phase 3 requires StepFun Global direct API access to remain separate from StepFun China and Step Plan because the console, API domain, credentials, billing path, and permitted models are separate account facts. This slice adds one registry-owned identity with account model discovery, a deterministic models.dev snapshot fallback, and a verified reasoning/tool-call loop.
Refs #860.
Scope
This PR implements only the Global direct API identity
stepfun-ai(https://api.stepfun.ai/v1). The existing China direct identitystepfun, Step Plan China/global identities, other providers, and Phase 7 are explicit non-goals.The complete models.dev snapshot remains available as metadata. The fallback selector is intentionally limited to the three models that the current StepFun Global Tool Call documentation explicitly lists:
step-3.7-flash,step-3.5-flash-2603, andstep-3.5-flash.Verification
npm run typecheck— passed for every workspace.@maka/core— 873 passed, 0 failed after the reviewer fix.maka-agentCLI — 311 passed, 0 failed.@maka/storage— 245 passed, 0 failed.@maka/runtime— 1,465 passed, 7 existing skips, 0 failed; the StepFun Global deterministic contract covers authenticated discovery, exact model IDs, the defaultreasoningresponse field, tool execution/result replay, and the final assistant turn.@maka/headless— 863 passed, 0 failed; post-fix provider-env and Harbor focused suites also passed.npm --workspace @maka/desktop run build:renderer— passed; the packaged third-party notice checker confirmed the byte-identical notice.npm run check:stale, the 14-test sync-model-metadata suite, andgit diff --check origin/main...HEAD— passed.lobehub/lobe-icons@e4302041fbb3039608d25f9f618bd462783b875e/packages/static-svg/icons/stepfun.svg; SHA-256f46fbd1eee00a3dc7874395484bcc3e25a803e9eb4b79f07b7eec377a1e2f25c.exit=0and the 1,465/7/0 result above.Local Desktop E2E was deferred to CI per the Issue #860 delivery boundary; CI E2E remains a merge gate. No new layout or interaction was introduced, so visual evidence is not applicable: catalog/detail rendering reuses the existing
ProviderAssetMaskpath and the deterministic E2E contract now exercises both StepFun identities. A live API smoke was not run because no safe user credential was available; no credential or raw provider response was recorded.Impact
Users can configure StepFun Global independently from StepFun China, discover account-visible models, fall back to the documented tool-capable snapshot subset when discovery is unavailable, and preserve exact model IDs across Desktop, CLI, storage, headless, and runtime. Existing persisted provider IDs and Step Plan paths are unchanged. No migration is required.
Reviewer notes
Authoritative protocol evidence:
reasoningfield: https://platform.stepfun.ai/docs/en/api-reference/chat/chat-completion-createRollback is a sequence of independently revertible commits. The provider has one registry owner and introduces no parallel discovery, runtime, brand asset, provenance, or notice state.
Ready for review
Verificationexplains why it is not applicable