Skip to content

feat: add Avian as a named LLM provider#844

Merged
mengzhuo merged 2 commits intosipeed:mainfrom
avianion:feat/add-avian-provider
Mar 5, 2026
Merged

feat: add Avian as a named LLM provider#844
mengzhuo merged 2 commits intosipeed:mainfrom
avianion:feat/add-avian-provider

Conversation

@avianion
Copy link
Copy Markdown
Contributor

Summary

  • Add Avian as a named OpenAI-compatible LLM provider
  • API base: https://api.avian.io/v1, auth via AVIAN_API_KEY env var
  • Models include deepseek/deepseek-v3.2 (164K ctx), moonshotai/kimi-k2.5 (131K ctx), z-ai/glm-5 (131K ctx), minimax/minimax-m2.5 (1M ctx)
  • Supports chat completions, streaming, and function calling/tools

Changes

  • pkg/config/config.go — Add Avian field to ProvidersConfig, update IsEmpty() and HasProvidersConfig()
  • pkg/config/defaults.go — Add Avian model entries to default ModelList
  • pkg/config/migration.go — Add Avian migration rule for legacy config format
  • pkg/config/migration_test.go — Update AllProviders test count (18 → 19)
  • pkg/providers/factory.go — Add avian case to explicit and inferred provider selection
  • pkg/providers/factory_provider.go — Add avian to OpenAI-compatible protocol list and getDefaultAPIBase()
  • config/config.example.json — Add Avian provider entry

Usage

{
  "model_list": [
    {
      "model_name": "deepseek-v3.2",
      "model": "avian/deepseek/deepseek-v3.2",
      "api_key": "your-avian-api-key",
      "api_base": "https://api.avian.io/v1"
    }
  ]
}

Or via legacy provider config:

{
  "providers": {
    "avian": {
      "api_key": "your-avian-api-key"
    }
  }
}

Test plan

  • Existing tests pass (go test ./pkg/config/... ./pkg/providers/...)
  • TestConvertProvidersToModelList_AllProviders updated for 19 providers
  • Verified all changes follow existing provider patterns (Mistral, DeepSeek, Cerebras)

cc @yinwm @mengzhuo @alexhoshina — would appreciate a review when you get a chance. This follows the same pattern as previous provider additions (#333, #167, #541).

@avianion
Copy link
Copy Markdown
Contributor Author

Hey @yinwm, would love your review on this when you get a chance. Happy to address any feedback!

Copy link
Copy Markdown
Collaborator

@alexhoshina alexhoshina left a comment

Choose a reason for hiding this comment

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

LGTM

Add Avian (https://avian.io) as an OpenAI-compatible provider with
API base https://api.avian.io/v1 and AVIAN_API_KEY env var support.

Models: deepseek/deepseek-v3.2, moonshotai/kimi-k2.5, z-ai/glm-5,
minimax/minimax-m2.5. Supports chat completions, streaming, and
function calling.

Changes:
- Add Avian to ProvidersConfig struct, IsEmpty(), HasProvidersConfig()
- Add avian protocol to factory provider and default API base
- Add avian case to legacy provider selection (factory.go)
- Add avian migration rule for old config format
- Add default model entries to ModelList (deepseek-v3.2, kimi-k2.5)
- Add avian to example config
- Update AllProviders test count from 18 to 19
@yinwm
Copy link
Copy Markdown
Collaborator

yinwm commented Mar 4, 2026

@avianion hi, please fix tests
LGTM

The TestConvertProvidersToModelList_AllProviders test expected 19
providers but adding Avian brings the total to 20.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@mengzhuo mengzhuo merged commit 325af21 into sipeed:main Mar 5, 2026
2 checks passed
hyperwd pushed a commit to hyperwd/picoclaw that referenced this pull request Mar 5, 2026
@Orgmar
Copy link
Copy Markdown
Contributor

Orgmar commented Mar 6, 2026

@avianion Cool to see Avian added as a provider! The model lineup with deepseek-v3.2, kimi-k2.5, and minimax-m2.5 gives users some interesting options, especially that 1M context window on minimax.

We've got the PicoClaw Dev Group on Discord for contributors to collaborate. If you're interested, email support@sipeed.com with the subject [Join PicoClaw Dev Group] avianion and we'll send you the invite link!

fishtrees pushed a commit to fishtrees/picoclaw that referenced this pull request Mar 12, 2026
andressg79 pushed a commit to andressg79/picoclaw that referenced this pull request Mar 30, 2026
ra1phdd pushed a commit to ra1phdd/picoclaw-pkg that referenced this pull request Apr 12, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants