Skip to content

feat(provider): add StepFun and Step Plan presets - #10153

Draft
Mola-maker wants to merge 2 commits into
AstrBotDevs:masterfrom
Mola-maker:feat/stepfun-provider-presets
Draft

Mola-maker wants to merge 2 commits into
AstrBotDevs:masterfrom
Mola-maker:feat/stepfun-provider-presets

Conversation

@Mola-maker

@Mola-maker Mola-maker commented Sep 20, 2026

Copy link
Copy Markdown

StepFun users currently have to choose OpenAI Compatible and enter an endpoint manually. This adds separate StepFun and StepFun Step Plan entries under Providers → Chat Completion → Add, with the standard and subscription endpoints prefilled as documented by StepFun.

Modifications

Both presets reuse openai_chat_completion, including editable API keys/base URLs, timeout, proxy, custom headers, model discovery, manual model selection, and per-model capabilities/context/custom request parameters. Each has a distinct source ID and a theme-aware StepFun icon. The diff is limited to provider presets, icon mappings, and regression tests.

  • This is NOT a breaking change.

Screenshots or Test Results

Visual evidence

In the existing dashboard, open Providers → Chat Completion → Add and search for StepFun. The base revision has no StepFun preset; this branch shows the two entries below. Select either entry to inspect its endpoint and advanced settings, save it with your API key, then fetch models or add a supported model ID manually.

StepFun and StepFun Step Plan shown as separate searchable provider presets

Validation

Local validation on Windows with Python 3.12: the existing full pytest suite passed (3488 passed, 82 skipped); the new four-case preset regression test also passed. The focused OpenAI/provider run passed with 114 passed and 1 skipped. The new tests exercise the real OpenAI SDK against an in-memory HTTP transport, checking model-list and streaming/non-streaming chat URLs, authentication, custom headers, timeout, and request parameters. All four fail against the base configuration because the presets are absent.

Ruff formatting/lint and the four preset regression cases were rerun after the documentation removal and passed. Dashboard typecheck/production build and browser checks passed on the initial implementation, which is unchanged. Browser checks covered the selector, endpoint fields, advanced settings, and manual model configuration. No live StepFun inference or account-specific model availability was tested; the screenshot is retained at the original immutable commit as review evidence, rather than added to the documentation.

Checklist

Comment thread docs/en/providers/start.md Outdated
6. Click **Save and Fetch Models**, find the desired model, click `+`, and make sure it is enabled. If the model list cannot be fetched, click **Save Configuration**, then **Custom Model** and enter the model ID. Use **Test Model** beside the model to check connectivity.
7. Open **Config**, select the profile to use, and go to **AI → Model**. Set **Chat Model** to the model you just added, then click **Save Configuration** at the bottom right. This setting is for AstrBot built-in AI.

## Connecting StepFun and Step Plan

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No need to add this document.

Copy link
Copy Markdown
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

收到

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants