Repository navigation
feat: SMARTS trading pipeline with Telegram notifications and Miro visualization - #13
Closed
AndriiPasternak31 wants to merge 14 commits into
Closed
AndriiPasternak31 wants to merge 14 commits into
AndriiPasternak31 wants to merge 14 commits into
Conversation
- Add scripts/smarts_diagram/ package with: - parser.py: Extracts architecture from agent templates - miro_generator.py: Generates diagram layout - miro_client.py: Miro REST API v2 client - Add scripts/update_smarts_diagram.py entry point - Update .claude/commands/update-docs.md with diagram step - Add MIRO_ACCESS_TOKEN and MIRO_BOARD_ID to .env.example Usage: python3 scripts/update_smarts_diagram.py --dry-run Co-Authored-By: Claude Opus 4.5 <[email protected]>
Add 8 SMARTS pipeline agents + supporting templates: - market-regime: Market condition detection - news-sentiment: News and sentiment analysis - discovery: Trading opportunity scanner - analysis: Deep technical analysis - decision: Position sizing and decisions - execution: Order execution via Alpaca - portfolio-manager: Risk oversight - feedback: Performance tracking Also includes: - analyst-agent variants (bull, bear, risk, quant) - scanner-agent, executor-agent, synthesis-agent - smarts-trading, smarts-trader-minimal bundles - gcp-log-monitor utility agent - system.yaml configuration Co-Authored-By: Claude Opus 4.5 <[email protected]>
Add SMARTS summary service for daily trading reports: - Pulls data from Supabase integration_context - Formats comprehensive summaries per agent - Sends to Telegram with deduplication - Scheduler for automated daily reports Add Telegram channel to notification handler: - Support bot_token and chat_id configuration - Environment variable fallback support - Markdown formatting for messages Co-Authored-By: Claude Opus 4.5 <[email protected]>
Add new endpoints in ops router: - POST /api/ops/smarts/summary - Generate and send summary - GET /api/ops/smarts/test-telegram - Test Telegram connection Integrate summary scheduler in main.py: - Start scheduler on app startup - Stop scheduler on app shutdown Co-Authored-By: Claude Opus 4.5 <[email protected]>
- Add find_template_file() to check template.yaml then config.yaml - Support both template formats for backwards compatibility - Add default resources configuration - Improve credential extraction for SMARTS agents Co-Authored-By: Claude Opus 4.5 <[email protected]>
Update all template loading code to use find_template_file() for consistent config.yaml support: - routers/credentials.py - routers/templates.py - services/agent_service/crud.py - services/system_agent_service.py Also use DEFAULT_RESOURCES constant for consistency. Co-Authored-By: Claude Opus 4.5 <[email protected]>
Add Telegram channel support to notification step configuration: - bot_token: Telegram bot token (supports env var) - chat_id: Telegram chat ID (supports env var) Co-Authored-By: Claude Opus 4.5 <[email protected]>
- Add changelog entries for SMARTS features - Update architecture documentation - Update roadmap progress Co-Authored-By: Claude Opus 4.5 <[email protected]>
Script to deploy all SMARTS agents in cascade order. Co-Authored-By: Claude Opus 4.5 <[email protected]>
- Add flow_visualizer.py to retrieve complete analysis flows from Supabase - Create update_smarts_flow.py CLI entry point - Extract and visualize full decision chain: market_regime → discovery → analysis → decision → execution - Support symbol-specific and auto-select modes - Add SUPABASE_URL/SUPABASE_ANON_KEY to .env.example Usage: python scripts/update_smarts_flow.py --symbol AAPL python scripts/update_smarts_flow.py --dry-run Co-Authored-By: Claude Opus 4.5 <[email protected]>
- Add MiroClient.create_board() for creating new boards via API - Flow visualizer now prefers MIRO_FLOW_BOARD_ID over MIRO_BOARD_ID - Update .env.example with separate board IDs for architecture vs flows Co-Authored-By: Claude Opus 4.5 <[email protected]>
- Remove all text truncation from flow cards (show full data) - Reorganize flow layout: - Market Regime at top-left - News Sentiment cards stacked vertically (up to 3) - Main pipeline in horizontal row: Discovery → Analysis → Decision → Execution - PM Directive below pipeline with connectors - Add visual separator line between architecture and flow sections - Increase card sizes for better readability Co-Authored-By: Claude Opus 4.5 <[email protected]>
- Replace \n with <br> tags for Miro sticky note compatibility - Add <br> spacers between sections for visual grouping - All format_*_content() functions now use HTML line breaks - Cards display with proper section separation Co-Authored-By: Claude Opus 4.5 <[email protected]>
- Add changelog entry for flow visualization feature - Create data/smarts-flows/ directory for JSON exports - Add README with usage instructions - Gitignore JSON files (contain live trading data) Co-Authored-By: Claude Opus 4.5 <[email protected]>
vybe
added a commit
that referenced
this pull request
Apr 18, 2026
…idate-architecture Backend: unregister 7 Process Engine routers (processes, executions, approvals, triggers, alerts, process_templates, audit) plus the process-docs router; drop startup hooks for execution recovery and the process-engine WebSocket publisher. Services under services/process_engine/ remain in place as dormant code. Frontend: remove 11 process-related routes (/processes, /processes/new, /processes/docs, /processes/wizard, /processes/:id, /executions, /approvals, /executions/:id, /process-dashboard) and the dead isProcessSection computed in NavBar. Keep /alerts and /events legacy redirects to Operating Room. Docs: correct stale count claims in architecture.md (main.py line count, router count 45 -> 53, service count 23 -> 37, MCP tool modules 15 -> 16) and expand database.py scope description to reflect 27 domain op classes. Skill: expand validate-architecture to detect drift between arch.md and code: count alignment (D1), scope coherence (D2), enforced MCP parity under #13 (tool module OR '# mcp: none' opt-out), and inline authorization sprawl detection under #8. Output now includes suggested arch.md edits with line numbers, not just pass/fail. Co-Authored-By: Claude Opus 4.7 <[email protected]>
This was referenced Apr 21, 2026
Closed
This was referenced Apr 29, 2026
This was referenced May 15, 2026
23 tasks
6 tasks done
7 tasks
vybe
pushed a commit
that referenced
this pull request
Sep 22, 2026
…n vocabulary, snapshot skip proven on a live engine, hosted compose + lint + three nits (abilityai/trinity-enterprise#479) Per the /review findings recorded on #2951: - metric_read_service._threshold_color judged direction as 'up' / 'down', which the registry never emits (DIRECTIONS = up_good / down_good / neutral). Every declared metric therefore fell into the 'up' arm, so an up_good revenue widget turned red for EXCEEDING its critical threshold and a neutral metric was judged at all — while the tile beside it, via utils/metricFormat.js::thresholdClasses, did the opposite. The backend now spells the tile's rule: down_good breaches at-or-above, up_good at-or-below, neutral declines. The pinning test used direction='up' and was green for the wrong reason; three tests now drive both arms and neutral. - The snapshot-writer skip for a bound widget was pinned by inspect.getsource; it is now executed through the real engine (capture_dashboard_snapshot writes the plain widget and not the bound one). - docker-compose.hosted.yml mirrors prod's METRICS_READ_RATE_LIMIT line (test_2280_hosted_compose_parity). - test_ent479_freshness_rule: bare sys.modules.pop → monkeypatch.delitem. - Nits: unused Optional import in agent_server/routers/info.py, the refreshMetricDefinitions JSDoc in client.ts sat above getAgentMetrics, routers/monitoring.py gains its '# mcp:' header (Invariant #13). Co-Authored-By: Claude Fable 5.1 <[email protected]>
This was referenced Oct 2, 2026
3 tasks
This was referenced Oct 10, 2026
Merged
7 tasks done
This was referenced Nov 6, 2026
fix(agents): wake-on-ending turns stand at the delegator's depth; per-pair wake budget (#4357)
#4378
Merged
Merged
10 tasks done
This was referenced Nov 27, 2026
This was referenced Nov 27, 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
This PR adds comprehensive SMARTS trading pipeline support:
SMARTS Agent Templates
config.yamlformat (SMARTS-style agents)system.yaml)Telegram Notifications
NotificationConfigin process enginesmarts_summary_service.pyfor generating trading summariesAPI & Scheduler
Miro Visualization
<br>tags) for card textdata/smarts-flows/directory for JSON exportsOther
find_template_fileusage across codebaseTest plan
🤖 Generated with Claude Code