{"id":29011047,"url":"https://github.com/happydasch/bt_llm_advisory","last_synced_at":"2025-10-11T17:33:25.346Z","repository":{"id":301133623,"uuid":"977189295","full_name":"happydasch/bt_llm_advisory","owner":"happydasch","description":"Extension of LLM Advisory for Backtrader strategies, enabling real-time trading insights from multiple LLM-based advisors directly within strategy execution.","archived":false,"fork":false,"pushed_at":"2025-06-25T10:02:55.000Z","size":122,"stargazers_count":4,"open_issues_count":0,"forks_count":1,"subscribers_count":3,"default_branch":"master","last_synced_at":"2025-06-25T10:43:30.124Z","etag":null,"topics":["adivsory","ai-agent","ai-trading","backtrader","candle-patterns","langchain","llm","strategy","technical-analysis","trading","trend-analysis"],"latest_commit_sha":null,"homepage":"","language":"Python","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/happydasch.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2025-05-03T16:16:39.000Z","updated_at":"2025-06-25T10:03:00.000Z","dependencies_parsed_at":"2025-06-25T10:43:35.721Z","dependency_job_id":"fe2a9ff2-73da-49fe-b7dc-29357fe3cc7e","html_url":"https://github.com/happydasch/bt_llm_advisory","commit_stats":null,"previous_names":["happydasch/bt_llm_advisory"],"tags_count":0,"template":false,"template_full_name":null,"purl":"pkg:github/happydasch/bt_llm_advisory","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/happydasch%2Fbt_llm_advisory","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/happydasch%2Fbt_llm_advisory/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/happydasch%2Fbt_llm_advisory/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/happydasch%2Fbt_llm_advisory/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/happydasch","download_url":"https://codeload.github.com/happydasch/bt_llm_advisory/tar.gz/refs/heads/master","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/happydasch%2Fbt_llm_advisory/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":261917439,"owners_count":23229919,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["adivsory","ai-agent","ai-trading","backtrader","candle-patterns","langchain","llm","strategy","technical-analysis","trading","trend-analysis"],"created_at":"2025-06-25T17:10:57.385Z","updated_at":"2025-10-11T17:33:20.312Z","avatar_url":"https://github.com/happydasch.png","language":"Python","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Backtrader LLM Advisory\n\n`Backtrader LLM Advisory` is using `LLM Advisory` for providing advisors to backtrader strategies. It allows the strategy to access different \"advisors\" which have access to the strategy and its current state.\n\ninside the strategy init call `llm_advisory.init(self)` from next call `llm_advisory.get_advice()`\n\n- Generates automatically data from a strategy and uses this for advisory data\n- Control lookback period of data to use\n\n## Usecase scenarios\n\n- Confirm trend, identify sideways trends using the trend advisor\n- Interpret current indicator values by the technical analysis advisor\n- Get trading signals by asking the technical analysis advisor to check current indicator values\n- Identify candle patterns by using the candle pattern advisor\n- Confirm a signal from your strategy code by advisory\n- Get feedback about your strategy and the current trading session\n\n## Available Advisors\n\nAn overview of all available advisors with a short explaination.\n\n### BacktraderStrategyAdvisor\n\nCommon advisor for strategies. Takes available information from strategy and provides an advice based on this data.\n\n```python\nfrom bt_llm_advisory.advisors import BacktraderStrategyAdvisor\n\nstrategy_advisor = BacktraderStrategyAdvisor()\n```\n\n### BacktraderTrendAdvisor\n\nReturns a signal based on data from the current strategy. The signal is bullish for a up-trend, bearish for a down-trend, neutral for no-trend and none if unable to identify.\nThis advisor uses different indicators to identify the current trend.\n\n```python\nfrom bt_llm_advisory.advisors import BacktraderTrendAdvisor\n\ntrend_advisor = BacktraderTrendAdvisor(\n    short_ma_period: int = 10,  # period for short moving average\n    long_ma_period: int = 25,  # period for long moving average\n    lookback_period: int = 5,  # lookback period for trend data\n    add_all_data_feeds: bool = False,  # should all data feeds be included\n)\n```\n\n### BacktraderTechnicalAnalysisAdvisor\n\nReturns a signal based on a technical analysis of the strategy indicators.\n\n```python\nfrom bt_llm_advisory.advisors import BacktraderTechnicalAnalysisAdvisor\n\ntechnial_analysis_advisor = BacktraderTechnicalAnalysisAdvisor()\n```\n\n### BacktraderCandlePatternAdvisor\n\nReturns a signal from OHLC candles if it recognizes a candlestick pattern.\n\n```python\nfrom bt_llm_advisory.advisors import BacktraderCandlePatternAdvisor\n\ncandle_pattern_advisor = BacktraderCandlePatternAdvisor(\n    lookback_period: int = 5,  # lookback period for ohlc data\n    add_all_data_feeds: bool = False,  # should all data feeds be included\n)\n```\n\n### BacktraderFeedbackAdvisor\n\nProvides feedback about the strategies data.\n\n```python\nfrom bt_llm_advisory.advisors import BacktraderFeedbackAdvisor\n\nfeedback_advisor = BacktraderFeedbackAdvisor()\n```\n\n### BacktraderPersonaAdvisor\n\nStrategy trading advisor with additional defined personaily or more detailed instructions.\n\n```python\nfrom bt_llm_advisory.advisors import BacktraderPersonaAdvisor\n\npersona_advisor = BacktraderPersonaAdvisor(\n    # name of the persona, can also be a famous person\n    person_name: str,\n    # description of the personality, which also can contain informations about needed knowledge\n    personality: str\n)\n```\n\n## Examples\n\n## Frequently Asked Questions\n\nTODO\n\n- add possibility to instruct another llm to create / update the used strategy based on advisors input\n- Update code of strategy by asking a llm for a change\n- Trade based on advisors advices\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhappydasch%2Fbt_llm_advisory","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fhappydasch%2Fbt_llm_advisory","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fhappydasch%2Fbt_llm_advisory/lists"}