Skip to content

feat: Integrate tensortrade RL model into consensus engine#31

Open
laurentvv wants to merge 1 commit intomainfrom
feat-tensortrade-rl-integration-6788355586345579924
Open

feat: Integrate tensortrade RL model into consensus engine#31
laurentvv wants to merge 1 commit intomainfrom
feat-tensortrade-rl-integration-6788355586345579924

Conversation

@laurentvv
Copy link
Copy Markdown
Owner

This PR integrates tensortrade and stable-baselines3 to introduce a new Reinforcement Learning (RL) model to the trading AI's hybrid consensus engine.

  • Added src/tensortrade_model.py which wraps the TensorTrade framework to create a realistic trading environment compatible with Gym APIs and trains a quick PPO agent using stable-baselines3 to generate Buy/Sell/Hold actions with confidence probabilities.
  • Updated src/enhanced_trading_example.py to trigger the TensorTrade prediction module and incorporate its insights into the consensus engine (model_predictions["tensortrade"]).
  • Refactored src/enhanced_decision_engine.py to accept the TensorTrade inputs. The base weights logic was updated to gracefully re-distribute decisioning weight, allocating 10% to TensorTrade as requested by the user.
  • Updated pyproject.toml to lock dependencies appropriately within the compatibility matrix (numpy==1.26.4 to prevent bugs with tensortrade, and setting correct bounds for stable-baselines3).
  • Linted using ruff and ran standard unittest test coverage.

PR created automatically by Jules for task 6788355586345579924 started by @laurentvv

@google-labs-jules
Copy link
Copy Markdown
Contributor

👋 Jules, reporting for duty! I'm here to lend a hand with this pull request.

When you start a review, I'll add a 👀 emoji to each comment to let you know I've read it. I'll focus on feedback directed at me and will do my best to stay out of conversations between you and other bots or reviewers to keep the noise down.

I'll push a commit with your requested changes shortly after. Please note there might be a delay between these steps, but rest assured I'm on the job!

For more direct control, you can switch me to Reactive Mode. When this mode is on, I will only act on comments where you specifically mention me with @jules. You can find this option in the Pull Request section of your global Jules UI settings. You can always switch back!

New to Jules? Learn more at jules.google/docs.


For security, I will only act on instructions from the user who triggered this task.

@kilo-code-bot
Copy link
Copy Markdown

kilo-code-bot Bot commented Apr 21, 2026

Code Review Summary

Status: No Issues Found | Recommendation: Merge

Files Reviewed (4 files)
  • .agents/skills/alphaear-news/scripts/content_extractor.py
  • .agents/skills/alphaear-news/scripts/database_manager.py
  • .agents/skills/alphaear-news/scripts/news_tools.py
  • .agents/skills/alphaear-news/tests/test_news.py

Reviewed by step-3.5-flash · 295,968 tokens

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.

1 participant