feat: switch AI provider from Anthropic to Moonshot (Kimi)

Replace Anthropic API key with Moonshot/Kimi configuration:
- Set PICOCLAW_PROVIDERS_MOONSHOT_API_KEY from secret
- Set API base to https://api.moonshot.cn/v1
- Set default provider to moonshot
- Set default model to kimi-k2-0711-preview
- Update deploy verification output accordingly

Secret to add in GitHub: PICOCLAW_MOONSHOT_API_KEY

https://claude.ai/code/session_019vXaqxGmkdCjM8m3jp6rYj
This commit is contained in:
Claude 2026-02-18 03:37:12 +00:00
parent 01f9dc7871
commit 2629ae605d
No known key found for this signature in database

View file

@ -106,11 +106,16 @@ jobs:
echo "WARNING: PICOCLAW_TELEGRAM_BOT_TOKEN secret is empty - Telegram will not start" echo "WARNING: PICOCLAW_TELEGRAM_BOT_TOKEN secret is empty - Telegram will not start"
fi fi
# Anthropic API Key # Moonshot (Kimi) API Key
ANTHROPIC_KEY="${{ secrets.ANTHROPIC_API_KEY }}" MOONSHOT_KEY="${{ secrets.PICOCLAW_MOONSHOT_API_KEY }}"
if [ -n "\$ANTHROPIC_KEY" ]; then if [ -n "\$MOONSHOT_KEY" ]; then
set_env_var "ANTHROPIC_API_KEY" "\$ANTHROPIC_KEY" set_env_var "PICOCLAW_PROVIDERS_MOONSHOT_API_KEY" "\$MOONSHOT_KEY"
echo "Anthropic: API key configured" set_env_var "PICOCLAW_PROVIDERS_MOONSHOT_API_BASE" "https://api.moonshot.cn/v1"
set_env_var "PICOCLAW_AGENTS_DEFAULTS_PROVIDER" "moonshot"
set_env_var "PICOCLAW_AGENTS_DEFAULTS_MODEL" "kimi-k2-0711-preview"
echo "Moonshot/Kimi: API key and default model configured"
else
echo "WARNING: PICOCLAW_MOONSHOT_API_KEY secret is empty"
fi fi
# Create config.json if it doesn't exist (copy from example) # Create config.json if it doesn't exist (copy from example)
@ -128,7 +133,7 @@ jobs:
echo "Config file exists: \$(test -f "\$CONFIG_FILE" && echo YES || echo NO)" echo "Config file exists: \$(test -f "\$CONFIG_FILE" && echo YES || echo NO)"
echo "Telegram enabled: \$(grep -c 'PICOCLAW_CHANNELS_TELEGRAM_ENABLED=true' "\$ENV_FILE" 2>/dev/null || echo 0)" echo "Telegram enabled: \$(grep -c 'PICOCLAW_CHANNELS_TELEGRAM_ENABLED=true' "\$ENV_FILE" 2>/dev/null || echo 0)"
echo "Telegram token set: \$(grep -c 'PICOCLAW_CHANNELS_TELEGRAM_TOKEN=' "\$ENV_FILE" 2>/dev/null || echo 0)" echo "Telegram token set: \$(grep -c 'PICOCLAW_CHANNELS_TELEGRAM_TOKEN=' "\$ENV_FILE" 2>/dev/null || echo 0)"
echo "Anthropic key set: \$(grep -c 'ANTHROPIC_API_KEY=' "\$ENV_FILE" 2>/dev/null || echo 0)" echo "Moonshot key set: \$(grep -c 'PICOCLAW_PROVIDERS_MOONSHOT_API_KEY=' "\$ENV_FILE" 2>/dev/null || echo 0)"
echo "==================================" echo "=================================="
EOF EOF