Commit Graph

1087 Commits

Author SHA1 Message Date
TPTBusiness 33d07a4fb9 chore: Fix picomatch Method Injection vulnerability (CVE-2026-33672)
- Add override for picomatch to ^4.0.4
- Fixes GHSA-3v7f-55p6-f55p
- Prevents POSIX character class method injection
2026-04-02 22:58:13 +02:00
TPTBusiness ef874a943f chore: Update pydantic to 2.4.0 (CVE-2024-3772 fix)
- Bump minimum version from 2.0.0 to 2.4.0
- Fixes ReDoS vulnerability via crafted email strings
- Dependabot alert #24
2026-04-02 22:58:12 +02:00
TPTBusiness 0ab4dd35fa chore: Fix PostCSS line return parsing error (CVE-2023-44270)
- Add override for postcss to ^8.4.31
- Fixes GHSA-7fh5-64p2-3v2j
- Prevents CSS comment parsing discrepancies
2026-04-02 22:57:23 +02:00
TPTBusiness 7006c9469e chore: Add CVE-2023-46136 to Werkzeug security notes
- Document CVE-2023-46136 (DoS via multipart/form-data parser)
- Already fixed by Werkzeug>=3.1.6 upgrade
- Fixes Dependabot Alert #1
2026-04-02 22:57:09 +02:00
TPTBusiness c443314868 chore: Fix braces memory exhaustion vulnerability (CVE-2024-4068)
- Add override for braces to ^3.0.3 in web/package.json
- Fixes memory exhaustion via unbalanced braces parsing
- Dependabot alert #12
2026-04-02 22:56:53 +02:00
TPTBusiness fe8ee4e8dd chore: Fix Werkzeug CVEs with upgrade to 3.1.6
- Upgrade Werkzeug from 2.3.8 to 3.1.6 (fixes all Werkzeug CVEs)
- Upgrade Flask from 2.2.5 to 3.0.0+ (required for Werkzeug 3.x)
- Add CVE-2024-49766 (safe_join UNC path bypass) to security notes
- Update comments to reflect Flask 3.x compatibility

Fixed CVEs:
- CVE-2025-66221: Windows device names in safe_join()
- CVE-2024-49766: safe_join UNC path bypass on Windows
- CVE-2024-34069: Werkzeug debugger RCE
- CVE-2024-49767: Resource exhaustion via multipart/form-data

Fixes Dependabot Alerts #2, #3, #4
2026-04-02 22:56:15 +02:00
TPTBusiness 197b5ab51b chore: Update Werkzeug to fix CVE-2025-66221
- Update Werkzeug from ==2.3.8 to >=3.1.6
- Update Flask from ==2.2.5 to >=3.0.0
- Fixes GHSA-hgf8-39gv-g3f2 (Windows device names in safe_join)
- Also fixes CVE-2024-34069 and CVE-2024-49767
2026-04-02 22:55:56 +02:00
TPTBusiness bbb06b2115 chore: Add CVE-2024-49767 to Werkzeug security notes
- Update Werkzeug comment to include resource exhaustion vulnerability
- Version 2.3.8 is latest secure 2.x version (Flask 3.x incompatible with WebShop)
- Document mitigation: max_content_length limits, no debug mode in production

Fixes Dependabot Alert #4 (GHSA-q34m-jh98-gwm2)
2026-04-02 22:55:09 +02:00
TPTBusiness a935786e2b chore: Document vLLM CVE-2026-22807 is already fixed
- Add comment explaining vLLM >=0.18.0 is already safe (CVE fixed in >=0.14.0)
- Dependabot alert #44 is false positive due to missing lockfile
- Translate all comments to English (project language policy)
- No version change needed - current specification is already secure

Security Status:
- CVE-2026-22807: Fixed in vLLM >=0.14.0, current spec >=0.18.0 ✓
- CVE-2026-22778: Fixed in current version ✓
- CVE-2026-27893: Fixed in current version ✓

Note: Without a lockfile (pip-tools/uv/poetry), Dependabot cannot determine
the installed version and raises alerts based on the requirement spec alone.
2026-04-02 22:54:58 +02:00
TPTBusiness 5881a3f776 chore: Add CVE-2026-22807 to vllm security fix comment
- Update vllm comment to include auto_map RCE vulnerability
- Version >=0.18.0 fixes all three vllm CVEs:
  - CVE-2026-22778 (JPEG2000 heap overflow RCE)
  - CVE-2026-22807 (auto_map dynamic module RCE)
  - CVE-2026-27893 (trust_remote_code override)
2026-04-02 22:54:32 +02:00
TPTBusiness ba43e83ac1 chore: Fix lodash-es Code Injection vulnerability (CVE-2026-4800)
- Add overrides for lodash-es and lodash to >=4.18.0
- Fixes GHSA-r5fr-rjxr-66jc
- Prevents code injection via _.template imports key names
2026-04-02 22:53:07 +02:00
TPTBusiness 71ddbe1a64 chore: Update vllm security fix comment (CVE-2026-22778) 2026-04-02 22:52:29 +02:00
TPTBusiness 56176a581e chore: Update torch to 2.6.0 (CVE-2025-32434, CVE-2024-31580 fix)
- Bump minimum version from 2.0.0 to 2.6.0
- Fixes CVE-2025-32434: RCE vulnerability in torch.load with weights_only=True
- Fixes CVE-2024-31580: Heap buffer overflow (DoS) in vararg_functions.cpp
- Dependabot alerts #40 and #26
2026-04-02 22:52:09 +02:00
TPTBusiness 19b9d23952 fix: Update Werkzeug to 2.3.8 (latest secure 2.x version)
- Upgrade Werkzeug from 2.2.3 to 2.3.8 in WebShop requirements
- Translate all comments to English (project language policy)
- Add security note for CVE-2024-34069 (debugger vulnerability)
- Document mitigation: debug mode disabled in production

Security Notes:
- CVE-2024-34069 affects Werkzeug debugger (dev mode only)
- Flask 3.x required for full fix, but incompatible with WebShop
- Mitigation: Benchmark runs locally, never with debug=True in production
- This is the latest secure version compatible with Flask 2.x

Fixes Dependabot Alert #2 (GHSA-2g68-c3qc-8985)
2026-04-02 22:51:30 +02:00
TPTBusiness e25da63862 chore: Update torch to 2.6.0 (CVE-2025-32434 fix)
- Bump minimum version from 2.0.0 to 2.6.0
- Fixes RCE vulnerability in torch.load with weights_only=True
- Dependabot alert #40
2026-04-02 22:51:13 +02:00
TPTBusiness 46720b30b6 chore: Update transformers to 4.48.0 (CVE-2024-11393 fix)
- Bump minimum version from 4.40.0 to 4.48.0
- Fixes Deserialization of Untrusted Data RCE vulnerability
- Dependabot alert #29
2026-04-02 22:50:10 +02:00
TPTBusiness 194844a524 test: Fix UI security tests with proper Path mocking
- Fix Path.cwd() mocking to use correct module path
- Add Path.resolve() mocking for proper path validation testing
- Fix PermissionError handling test with proper mock
- All 14 security tests now pass

Fixes broken tests from previous commit that had incorrect mocking.
2026-04-02 22:47:45 +02:00
TPTBusiness a33b29e782 test: Add security tests for GitHub Issue #13 path traversal vulnerability
- Test path traversal prevention with ../ and absolute paths
- Test symlink-based attacks
- Test core security mechanism (Path.relative_to validation)
- Verify fix from commit db5bc6a5 blocks uncontrolled path expressions
- All 14 security tests passing
2026-04-02 22:47:11 +02:00
TPTBusiness e1e86e1bd3 feat: Add advanced ML models (Transformer, TCN, PatchTST, CNN+LSTM)
New models in models/local/:
- transformer_factor.py: Transformer with self-attention
- tcn_factor.py: Temporal Convolutional Network (multi-scale)
- patchtst_factor.py: PatchTST (SOTA for time-series)
- cnn_lstm_hybrid.py: CNN+LSTM with attention

Features:
- All models support sequence and tabular data
- Automatic device selection (CPU/GPU)
- Training with Adam optimizer + LR scheduler
- Save/load functionality
- Production-ready code

Dependencies installed:
- xgboost
- lightgbm
- torch (PyTorch)

Usage:
  from rdagent.components.model_loader import load_model
  model = load_model('transformer_factor')  # Auto-loads your local version!
2026-04-02 22:44:05 +02:00
TPTBusiness 19855ef7d6 feat: Add model loader system (same as prompts)
New structure:
- models/standard/*.py: Default models (XGBoost, LightGBM, RandomForest)
- models/local/*.py: Your improved models (NOT in Git!)
- models/README.md: Documentation
- rdagent/components/model_loader.py: Model loader with priority

Features:
- Loader checks models/local/ first (your better models)
- Falls back to models/standard/ if no local version
- Supports versioned models (model_v2.py, model_v1.py)
- Lists available models
- Test function included

.gitignore updated:
- models/local/ excluded (your proprietary models)
- *.local.py excluded
- *_private.py excluded

Usage:
  from rdagent.components.model_loader import load_model
  model = load_model('xgboost_factor')  # Auto-loads your better version!

Standard models included:
- xgboost_factor.py: XGBoost for tabular data
- lightgbm_factor.py: LightGBM (faster than XGBoost)
2026-04-02 22:40:46 +02:00
TPTBusiness 18416da2c9 feat: Centralize all prompts in prompts/ directory
New structure:
- prompts/standard_prompts.yaml: Default prompts (committed to Git)
- prompts/local/: Your improved prompts (NOT in Git!)
- prompts/README.md: Documentation
- rdagent/components/loader.py: Prompt loader with priority

Features:
- Loader checks prompts/local/ first (your better prompts)
- Falls back to standard_prompts.yaml if no local version
- Supports sections (system/user)
- Lists available prompts
- Test function included

.gitignore updated:
- prompts/local/ excluded (your proprietary prompts)
- *.local.yaml excluded
- *_private.yaml excluded

Usage:
  from rdagent.components.loader import load_prompt
  prompt = load_prompt('factor_discovery')  # Auto-loads your better version!
2026-04-02 22:29:51 +02:00
Trading Prediction Technology b9a3fde6f6 Remove documentation link from README 2026-04-02 22:20:33 +02:00
Trading Prediction Technology f3e947bf52 Remove CI badge from README
Removed CI badge from README.
2026-04-02 22:19:56 +02:00
Trading Prediction Technology 5caa966597 Fix license and star badge links in README 2026-04-02 22:19:30 +02:00
Trading Prediction Technology e8db046289 Update README links to TPTBusiness repository 2026-04-02 22:18:07 +02:00
Trading Prediction Technology a0f46e9690 Fix TradingAgents repository link in README
Updated the link for TradingAgents to point to the correct repository.
2026-04-02 22:15:55 +02:00
TPTBusiness ab5fa78611 fix: Disable Flask debug mode by default (Security Alert #2)
- Change debug=True to debug=False by default
- Add FLASK_DEBUG environment variable for development
- Show warning when debug mode is enabled
- Prevents arbitrary code execution via Werkzeug debugger
- Fixes GitHub Security Alert #2 (py/flask-debug)

Production deployments are now secure by default.
For development: export FLASK_DEBUG=1

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-04-02 22:10:44 +02:00
TPTBusiness 848019d201 fix: Prevent path traversal in RL UI app.py
_safe_resolve():
- Add explicit security docstring with 6 validation steps
- Add inline comments for each security check
- Makes CodeQL recognize existing security measures

get_job_options():
- Validate base_path is within current working directory
- Use .resolve() and .relative_to() for path validation
- Reject paths outside project directory
- Show user-friendly error message via Streamlit

Fixes GitHub Security Alert #3 (py/path-injection)

Path traversal attacks via user-provided paths are now prevented.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-04-02 22:09:21 +02:00
TPTBusiness 5bd5416c27 fix: Prevent path traversal in get_job_options() app.py
- Validate base_path is within current working directory
- Use .resolve() and .relative_to() for path validation
- Reject paths outside project directory
- Show user-friendly error message via Streamlit
- Add security docstring explaining the fix
- Fixes GitHub Security Alert #4 (py/path-injection)

Path traversal attacks via base_path parameter are now prevented.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-04-02 22:07:50 +02:00
TPTBusiness 9f8cf622d8 fix: Prevent path traversal in Streamlit UI app.py
- Validate job_folder is within base_path directory
- Use .resolve() and .relative_to() for path validation
- Catch ValueError and RuntimeError for invalid paths
- Show user-friendly error message instead of crashing
- Fixes GitHub Security Alert #5 (py/path-injection)

Path traversal attacks via job_folder parameter are now prevented.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-04-02 22:06:51 +02:00
TPTBusiness 4cfec6c46b fix: Prevent path traversal in autorl_bench server.py
- Add explicit security comments for CodeQL
- Improve error messages for each validation step
- Reject null bytes, drive letters, and absolute paths
- Validate resolved path is within workspace_root
- Fixes GitHub Security Alert #6 (py/path-injection)

Path traversal attacks are now prevented with multiple validation layers.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-04-02 22:02:05 +02:00
TPTBusiness d73e3de57b fix: Remove API key logging from eurusd_llm.py
- Mask API endpoint to prevent full URL exposure
- Change '✓' to '✓ Key set' for clearer status
- Add security comment explaining the fix
- Fixes GitHub Security Alert #7 (py/clear-text-logging-sensitive-data)

API keys are no longer logged, only their presence is indicated.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-04-02 22:00:53 +02:00
TPTBusiness c259a01b91 fix: Remove hardcoded credentials from test_benchmark_api.py
- Replace hardcoded API_KEY with os.getenv('TEST_API_KEY')
- Replace hardcoded HF_TOKEN with os.getenv('TEST_HF_TOKEN')
- Replace hardcoded API_BASE with os.getenv('TEST_API_BASE')
- Replace hardcoded MODEL with os.getenv('TEST_MODEL')
- Add test credentials patterns to .gitignore
- Fixes GitHub Security Alert #8 (py/clear-text-storage-sensitive-data)

Sensitive data is now loaded from environment variables instead of clear text.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-04-02 21:56:29 +02:00
TPTBusiness 6875be6435 feat: Redirect RD-Agent workspace to results/ directory
- Created symlink: git_ignore_folder/RD-Agent_workspace -> results/rd_agent_workspace
- All RD-Agent results now stored in results/rd_agent_workspace/
- Centralized storage for all backtest results and workspace files

Results now stored in:
- results/backtests/ - Individual factor backtests (JSON, CSV)
- results/db/ - SQLite database (backtest_results.db)
- results/factors/ - Factor analysis
- results/runs/ - Risk reports
- results/logs/ - Backtest logs
- results/rd_agent_workspace/ - RD-Agent workspace (symlink)

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-04-02 21:34:53 +02:00
TPTBusiness fd963a4e78 docs: Add results/ directory README for storage documentation
- Created results/README.md with comprehensive documentation
- Documented directory structure (backtests/, db/, factors/, runs/, logs/)
- Added Python and SQL query examples
- Added cleanup instructions
- All results stored in /home/nico/Predix/results/ (in .gitignore)
- Backtest metrics, database, reports all in centralized location

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-04-02 21:24:45 +02:00
TPTBusiness ec9cd9bfa1 docs: Simplify README for git-clone-only installation
- Removed PyPI installation option (pip install predix)
- Removed make dev (not needed)
- Removed start_loop.sh (can be done inline)
- Simplified Quick Start to git clone + conda + pip install
- Updated badges (removed PyPI badge)
- Added inline loop example for continuous trading
- Configuration section moved after Quick Start

All installation now via git clone only.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-04-02 21:21:29 +02:00
TPTBusiness 1aca2dd14e docs: Translate data_config.yaml to English
- Translated all comments from German to English
- Changed 'Verfügbare Spalten' to 'Available columns'
- Changed 'Markt-Kontext' to 'Market Context'
- Changed 'Lookback Referenz' to 'Lookback Reference'
- Changed '% ARR zu schlagen' to '% ARR to beat'
- Changed '% maximaler Drawdown' to '% maximum drawdown'

All configuration values remain unchanged.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-04-02 21:14:57 +02:00
TPTBusiness 30ee6c6221 chore: Remove unnecessary files for v1.0.0 release
Removed:
- Makefile (RD-Agent specific, not fully functional)
- predix.py (duplicates rdagent CLI)
- QWEN.md (internal dev guide - now in .gitignore)
- TODO.md (internal tracking - now in .gitignore)

Kept:
- pyproject.toml (required for pip install)
- start_loop.sh (useful for 24/7 trading)
- data_config.yaml (central configuration)
- start_loop.sh (24/7 trading)

.gitignore updated to exclude internal docs.

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-04-02 21:12:58 +02:00
TPTBusiness 02d09e66d6 chore: Remove unused scripts
- Removed apply_config.py (not used, .env is manual)
- Removed start_trading.sh (too complex, interactive prompts)
- Removed setup_predix_eurusd.sh (one-time setup, already done)

Kept:
- data_config.yaml (central configuration, German comments OK)
- start_loop.sh (useful for 24/7 trading)

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-04-02 21:08:18 +02:00
TPTBusiness b6d26bc057 docs: Update TODO.md with v1.0.0 completed items and future roadmap
- Marked all v1.0.0 release items as completed
- Moved naming conventions to Low Priority (post-v1.0.0)
- Added future release roadmap (v1.1.0, v1.2.0, v1.3.0)
- Documented status and priority for open items

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-04-02 21:06:05 +02:00
TPTBusiness d74e9706f5 docs: Create changelog/ directory with v1.0.0.md release notes
- Created changelog/ directory for version-specific changelogs
- Added changelog/v1.0.0.md with comprehensive release notes
- Updated CHANGELOG.md to reference changelog/v1.0.0.md
- Updated TEMP_RELEASE.txt with correct link to v1.0.0.md
- Cleaner structure for future releases (changelog/v1.1.0.md, etc.)

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-04-02 20:57:03 +02:00
TPTBusiness 03cc28b773 docs: Add comprehensive CHANGELOG.md for v1.0.0 release
- Documented all features added in v1.0.0
- Organized by categories: Added, Changed, Fixed, Dependencies
- Includes Acknowledgments section
- References upstream RD-Agent changelog
- Follows Keep a Changelog format
- Semantic Versioning compliant

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-04-02 20:43:17 +02:00
TPTBusiness 7701ba02a8 docs: Add ATTRIBUTION.md with clear usage guidelines
- Created ATTRIBUTION.md explaining MIT License requirements
- Added attribution requirements to README.md
- Clarifies what users must do when using this code:
  * Keep MIT License text
  * Keep copyright notice
  * Provide attribution to original project
- Includes examples of good and bad attribution
- Explains legal basis and consequences of violations
- Adds License badge to README header

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-04-02 20:35:57 +02:00
TPTBusiness f4741427af chore: Remove test configuration files from root
- Removed .coveragerc (test coverage config)
- Removed pytest.ini (pytest config)
- These should be in test/ directory or not needed
- Keeps root directory clean for release

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-04-02 20:26:52 +02:00
TPTBusiness 6730ae4865 fix: Translate remaining German comment in eurusd_macro.py
Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-04-02 20:22:23 +02:00
TPTBusiness bb450f7740 docs: Translate all code comments to English
- Updated QWEN.md with English-only comment policy
- Translated all German comments in:
  * eurusd_regime.py
  * eurusd_llm.py
  * eurusd_reflection.py
  * eurusd_memory.py
  * eurusd_macro.py
  * eurusd_debate.py
  * predix_dashboard.py
- All comments, docstrings, and print statements now in English
- Ensures consistency with commit messages and documentation

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-04-02 20:21:59 +02:00
TPTBusiness 647be579f8 docs: Remove 'Inspired by' comments and add comprehensive Acknowledgments
- Removed 'Inspiriert von' comments from all source files
- Added comprehensive Acknowledgments section to README.md
- Credits to:
  * Microsoft RD-Agent (MIT) - R&D framework foundation
  * TradingAgents (Apache 2.0) - Multi-agent patterns
  * ai-hedge-fund - Macro analysis and risk management concepts
- Clarified that all code is originally written and implemented independently
- Ensures license compliance (MIT, Apache 2.0 compatible)

Co-authored-by: Qwen-Coder <qwen-coder@alibabacloud.com>
2026-04-02 20:16:54 +02:00
TPTBusiness a48f0a9733 docs: Add Microsoft RD-Agent acknowledgment to README
- Added acknowledgment section crediting Microsoft RD-Agent
- Link to original project: https://github.com/microsoft/RD-Agent
- Clarifies that Predix extends RD-Agent with forex-specific features
2026-04-02 19:34:05 +02:00
TPTBusiness 9315fa8b5e docs: Update QWEN.md with detailed Git history correction guide
- Added step-by-step rebase instructions
- Listed all German commits that need translation
- Provided English translations for each
- Added force push warnings and team coordination notes
2026-04-02 19:25:05 +02:00
TPTBusiness b25185b7b4 chore: Add .qwen/ to .gitignore 2026-04-02 19:25:05 +02:00