Your personal intelligence agent. Watches the world from multiple data sources and pings you when something changes.
Merge master into feature/openrouter-support
calesthio3e2d1a3b5d03
diff --cc .env.exampleindex 4830306,3585dbb..44eb01b--- a/.env.example+++ b/.env.example@@@ -31,12 -31,12 +31,12 @@@ REFRESH_INTERVAL_MINUTES=1# === LLM Layer (optional) ===# Enables AI-enhanced trade ideas and breaking news Telegram alerts.- # Provider options: anthropic | openai | gemini | codex | openrouter-# Provider options: anthropic | openai | gemini | codex | minimax++# Provider options: anthropic | openai | gemini | codex | openrouter | minimaxLLM_PROVIDER=# Not needed for codex (uses ~/.codex/auth.json)LLM_API_KEY=# Optional override. Each provider has a sensible default:- # anthropic: claude-sonnet-4-6 | openai: gpt-5.4 | gemini: gemini-3.1-pro | codex: gpt-5.3-codex | openrouter: openrouter/auto-# anthropic: claude-sonnet-4-6 | openai: gpt-5.4 | gemini: gemini-3.1-pro | codex: gpt-5.3-codex | minimax: MiniMax-M2.5++# anthropic: claude-sonnet-4-6 | openai: gpt-5.4 | gemini: gemini-3.1-pro | codex: gpt-5.3-codex | openrouter: openrouter/auto | minimax: MiniMax-M2.5LLM_MODEL=# === Telegram Alerts (optional, requires LLM) ===diff --cc README.mdindex 6651453,6a0095b..6bb7538--- a/README.md+++ b/README.md@@@ -148,10 -158,10 +158,10 @@@ Alerts are delivered as rich embeds wit**Optional dependency:** The full bot requires `discord.js`. Install it with `npm install discord.js`. If it's not installed, Crucix automatically falls back to webhook-only mode.### Optional LLM Layer--Connect any of 5 LLM providers for enhanced analysis:++Connect any of 6 LLM providers for enhanced analysis:- **AI trade ideas** — quantitative analyst producing 5-8 actionable ideas citing specific data- **Smarter alert evaluation** — LLM classifies signals into FLASH/PRIORITY/ROUTINE tiers with cross-domain correlation and confidence scoring- - Providers: Anthropic Claude, OpenAI, Google Gemini, OpenRouter (Unified API), OpenAI Codex (ChatGPT subscription)-- Providers: Anthropic Claude, OpenAI, Google Gemini, OpenAI Codex (ChatGPT subscription), MiniMax++- Providers: Anthropic Claude, OpenAI, Google Gemini, OpenRouter (Unified API), OpenAI Codex (ChatGPT subscription), MiniMax- Graceful fallback — when LLM is unavailable, a rule-based engine takes over alert evaluation. LLM failures never crash the sweep cycle.---@@@ -184,15 -194,15 +194,16 @@@ These three unlock the most valuable ec### LLM Provider (optional, for AI-enhanced ideas)- Set `LLM_PROVIDER` to one of: `anthropic`, `openai`, `gemini`, `codex`-Set `LLM_PROVIDER` to one of: `anthropic`, `openai`, `gemini`, `codex`, `minimax`++Set `LLM_PROVIDER` to one of: `anthropic`, `openai`, `gemini`, `codex`, `openrouter`, `minimax`| Provider | Key Required | Default Model ||----------|-------------|---------------|| `anthropic` | `LLM_API_KEY` | claude-sonnet-4-6 || `openai` | `LLM_API_KEY` | gpt-5.4 || `gemini` | `LLM_API_KEY` | gemini-3.1-pro |+| `openrouter` | `LLM_API_KEY` | openrouter/auto || `codex` | None (uses `~/.codex/auth.json`) | gpt-5.3-codex |+ | `minimax` | `LLM_API_KEY` | MiniMax-M2.5 |For Codex, run `npx @openai/codex login` to authenticate via your ChatGPT subscription.@@@ -267,8 -277,8 +278,9 @@@ crucix│ │ ├── anthropic.mjs # Claude│ │ ├── openai.mjs # GPT│ │ ├── gemini.mjs # Gemini+│ │ ├── openrouter.mjs # OpenRouter (Unified API)│ │ ├── codex.mjs # Codex (ChatGPT subscription)+ │ │ ├── minimax.mjs # MiniMax (M2.5, 204K context)│ │ ├── ideas.mjs # LLM-powered trade idea generation│ │ └── index.mjs # Factory: createLLMProvider()│ ├── delta/ # Change tracking between sweeps@@@ -370,7 -380,7 +382,7 @@@ All settings are in `.env` with sensibl|----------|---------|-------------|| `PORT` | `3117` | Dashboard server port || `REFRESH_INTERVAL_MINUTES` | `15` | Auto-refresh interval |- | `LLM_PROVIDER` | disabled | `anthropic`, `openai`, `gemini`, `codex`, or `openrouter` |-| `LLM_PROVIDER` | disabled | `anthropic`, `openai`, `gemini`, `codex`, or `minimax` |++| `LLM_PROVIDER` | disabled | `anthropic`, `openai`, `gemini`, `codex`, `openrouter`, or `minimax` || `LLM_API_KEY` | — | API key (not needed for codex) || `LLM_MODEL` | per-provider default | Override model selection || `TELEGRAM_BOT_TOKEN` | disabled | For Telegram alerts + bot commands |diff --cc crucix.config.mjsindex e76e55c,4d4c36b..da25ca1--- a/crucix.config.mjs+++ b/crucix.config.mjs@@@ -7,7 -7,7 +7,7 @@@ export defaultrefreshIntervalMinutes: parseInt(process.env.REFRESH_INTERVAL_MINUTES) || 15,llm: {- provider: process.env.LLM_PROVIDER || null, // anthropic | openai | gemini | codex | openrouter- provider: process.env.LLM_PROVIDER || null, // anthropic | openai | gemini | codex | minimax++ provider: process.env.LLM_PROVIDER || null, // anthropic | openai | gemini | codex | openrouter | minimaxapiKey: process.env.LLM_API_KEY || null,model: process.env.LLM_MODEL || null,},diff --cc lib/llm/index.mjsindex e590b0a,d6d3840..7320a66--- a/lib/llm/index.mjs+++ b/lib/llm/index.mjs@@@ -2,16 -2,16 +2,18 @@@import { AnthropicProvider } from './anthropic.mjs';import { OpenAIProvider } from './openai.mjs';+import { OpenRouterProvider } from './openrouter.mjs';import { GeminiProvider } from './gemini.mjs';import { CodexProvider } from './codex.mjs';+ import { MiniMaxProvider } from './minimax.mjs';export { LLMProvider } from './provider.mjs';export { AnthropicProvider } from './anthropic.mjs';export { OpenAIProvider } from './openai.mjs';+export { OpenRouterProvider } from './openrouter.mjs';export { GeminiProvider } from './gemini.mjs';export { CodexProvider } from './codex.mjs';+ export { MiniMaxProvider } from './minimax.mjs';/*** Create an LLM provider based on config.