Repository navigation
feat: add StepFun China direct API support - #902
Merged
Merged
Conversation
This was referenced Jul 13, 2026
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
stepfunprovider athttps://api.stepfun.com/v1.Why
Issue #860 Phase 3 requires a complete direct-provider slice rather than a catalog-only entry. This provider needs one registry-owned identity, authenticated account model discovery with a deterministic models.dev snapshot fallback, exact model IDs through every host, and a verified reasoning/tool-call loop.
Refs #860.
Scope
This PR implements only the China direct API identity
stepfun(https://api.stepfun.com/v1). The separate Global direct identitystepfun-ai, Step Plan identities, later provider-matrix extensions, and Phase 7 are explicit non-goals.The runtime conformance fixture follows StepFun's default
reasoningresponse field. The existing generic OpenAI-compatible adapter parses it and performs the second-stage assistant/tool replay; no StepFun-specific runtime override or parallel provider path was added.Verification
npm run typecheck— passed for every workspace on the final HEAD.npm test— passed across all workspaces during pre-review validation.npm --workspace @maka/runtime test -- --test-name-pattern='StepFun China preserves'— passed on the final HEAD; the runtime script executed the full suite: 1,399 passed, 7 existing skips, 0 failed.npm --workspace @maka/desktop run build:renderer— passed; the packaged third-party notice checker confirmed byte-identical notice inclusion.npm run check:stale— passed.git diff --check origin/main...HEAD— passed.f46fbd1eee00a3dc7874395484bcc3e25a803e9eb4b79f07b7eec377a1e2f25c.Local Desktop E2E was intentionally deferred to CI per the delivery boundary. There is no new layout or interaction to capture manually: catalog and detail rendering use the existing shared
ProviderAssetMaskpath, covered by deterministic renderer/E2E contracts and the byte-exact asset governance test. A real API smoke was not run because no safe StepFun credential was available; no credential or raw provider response was recorded.Impact
Users can configure the China StepFun direct API, discover account-visible models, fall back to the checked-in models.dev snapshot when discovery is unavailable, and retain exact StepFun model IDs across Desktop, CLI, storage, headless, and runtime. Existing providers and persisted provider IDs are unchanged. No migration is required.
Reviewer notes
Brand source:
lobehub/lobe-icons, package release@lobehub/[email protected], immutable commite4302041fbb3039608d25f9f618bd462783b875e, pathpackages/static-svg/icons/stepfun.svg, MIT license. The file is vendored byte-for-byte and rendered through the existing monochrome mask/currentColor seam.Rollback is a single squash revert; the provider has one registry owner and introduces no separate state or discovery mechanism.
Ready for review
Verificationexplains why it is not applicable