rawr-tools 0.1.2__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- rawr/__init__.py +34 -0
- rawr/api.py +39 -0
- rawr/cli/__init__.py +0 -0
- rawr/cli/agent_commands.py +1234 -0
- rawr/cli/analysis_commands.py +197 -0
- rawr/cli/audit_commands.py +85 -0
- rawr/cli/audit_store.py +153 -0
- rawr/cli/background_runner.py +68 -0
- rawr/cli/bootstrap.py +255 -0
- rawr/cli/formatters.py +73 -0
- rawr/cli/knowledge_commands.py +81 -0
- rawr/cli/logging_runtime.py +59 -0
- rawr/cli/main.py +129 -0
- rawr/cli/market_commands.py +193 -0
- rawr/cli/mcp_commands.py +172 -0
- rawr/cli/observe_commands.py +125 -0
- rawr/cli/plan_commands.py +225 -0
- rawr/cli/policy_commands.py +342 -0
- rawr/cli/policy_runtime.py +564 -0
- rawr/cli/registry.py +1545 -0
- rawr/cli/runtime.py +41 -0
- rawr/cli/session_commands.py +745 -0
- rawr/cli/session_store.py +1309 -0
- rawr/cli/time_utils.py +27 -0
- rawr/core/__init__.py +1 -0
- rawr/core/analysis/__init__.py +0 -0
- rawr/core/analysis/indicators.py +70 -0
- rawr/core/analysis/screening.py +58 -0
- rawr/core/automation/__init__.py +23 -0
- rawr/core/automation/actions.py +81 -0
- rawr/core/automation/alerts.py +99 -0
- rawr/core/automation/auto_trade.py +579 -0
- rawr/core/automation/cron.py +68 -0
- rawr/core/automation/events.py +123 -0
- rawr/core/automation/kill_switch.py +45 -0
- rawr/core/automation/loss_tracker.py +62 -0
- rawr/core/automation/monitors.py +172 -0
- rawr/core/automation/notification_handler.py +90 -0
- rawr/core/automation/scheduler.py +136 -0
- rawr/core/automation/stop_loss.py +88 -0
- rawr/core/automation/trust_level.py +63 -0
- rawr/core/config/__init__.py +0 -0
- rawr/core/config/auth.py +75 -0
- rawr/core/config/env.py +35 -0
- rawr/core/config/settings.py +166 -0
- rawr/core/data/__init__.py +0 -0
- rawr/core/data/cache.py +60 -0
- rawr/core/data/dart_client.py +64 -0
- rawr/core/data/fred_client.py +90 -0
- rawr/core/data/provider.py +21 -0
- rawr/core/data/pykrx_provider.py +106 -0
- rawr/core/data/yfinance_provider.py +128 -0
- rawr/core/deps.py +75 -0
- rawr/core/frameworks/__init__.py +25 -0
- rawr/core/frameworks/bain.py +383 -0
- rawr/core/frameworks/blackrock.py +360 -0
- rawr/core/frameworks/bridgewater.py +318 -0
- rawr/core/frameworks/citadel.py +329 -0
- rawr/core/frameworks/dcf.py +454 -0
- rawr/core/frameworks/goldman.py +370 -0
- rawr/core/frameworks/harvard.py +349 -0
- rawr/core/frameworks/jpmorgan.py +390 -0
- rawr/core/frameworks/mckinsey.py +453 -0
- rawr/core/frameworks/renaissance.py +350 -0
- rawr/core/kis/__init__.py +0 -0
- rawr/core/kis/account.py +81 -0
- rawr/core/kis/client.py +146 -0
- rawr/core/kis/market.py +84 -0
- rawr/core/kis/resilience.py +77 -0
- rawr/core/kis/token_manager.py +92 -0
- rawr/core/kis/trading.py +177 -0
- rawr/core/knowledge/__init__.py +13 -0
- rawr/core/knowledge/db.py +299 -0
- rawr/core/knowledge/graph.py +319 -0
- rawr/core/knowledge/journal.py +107 -0
- rawr/core/knowledge/research.py +63 -0
- rawr/core/knowledge/strategy_kb.py +206 -0
- rawr/core/knowledge/watchlist.py +41 -0
- rawr/core/krx/__init__.py +0 -0
- rawr/core/krx/costs.py +49 -0
- rawr/core/krx/market_hours.py +71 -0
- rawr/core/krx/price_limits.py +29 -0
- rawr/core/krx/tick_size.py +34 -0
- rawr/core/llm/__init__.py +5 -0
- rawr/core/llm/client.py +108 -0
- rawr/core/llm/providers.py +87 -0
- rawr/core/llm/schemas.py +37 -0
- rawr/core/llm/signal_converter.py +206 -0
- rawr/core/models/__init__.py +0 -0
- rawr/core/models/fundamental.py +49 -0
- rawr/core/models/news.py +34 -0
- rawr/core/models/notification.py +33 -0
- rawr/core/models/order.py +36 -0
- rawr/core/models/portfolio.py +46 -0
- rawr/core/models/quant.py +135 -0
- rawr/core/models/stock.py +39 -0
- rawr/core/news/__init__.py +5 -0
- rawr/core/news/disclosure.py +23 -0
- rawr/core/news/sentiment.py +27 -0
- rawr/core/notifications/__init__.py +10 -0
- rawr/core/notifications/rate_limiter.py +45 -0
- rawr/core/notifications/router.py +79 -0
- rawr/core/notifications/telegram.py +53 -0
- rawr/core/notifications/terminal.py +37 -0
- rawr/core/plans/__init__.py +11 -0
- rawr/core/plans/metrics.py +118 -0
- rawr/core/plans/models.py +118 -0
- rawr/core/plans/repository.py +70 -0
- rawr/core/plans/service.py +344 -0
- rawr/core/quant/__init__.py +20 -0
- rawr/core/quant/backtest/__init__.py +24 -0
- rawr/core/quant/backtest/engine.py +201 -0
- rawr/core/quant/backtest/result.py +108 -0
- rawr/core/quant/backtest/strategy.py +128 -0
- rawr/core/quant/factor_model.py +352 -0
- rawr/core/quant/portfolio_risk.py +52 -0
- rawr/core/quant/position.py +70 -0
- rawr/core/quant/probability.py +42 -0
- rawr/core/quant/rawr_score.py +112 -0
- rawr/core/quant/risk.py +65 -0
- rawr/core/quant/signal.py +194 -0
- rawr/core/quant/simulation.py +122 -0
- rawr/core/quant/walk_forward.py +173 -0
- rawr/core/us/__init__.py +6 -0
- rawr/core/us/disclosure_store.py +101 -0
- rawr/core/us/edgar_client.py +104 -0
- rawr/core/us_market/__init__.py +1 -0
- rawr/core/us_market/costs.py +46 -0
- rawr/core/us_market/market_hours.py +66 -0
- rawr/core/us_market/tick_size.py +29 -0
- rawr/mcp/__init__.py +0 -0
- rawr/mcp/analysis_tools.py +196 -0
- rawr/mcp/automation_tools.py +569 -0
- rawr/mcp/backtest_tools.py +242 -0
- rawr/mcp/framework_tools.py +452 -0
- rawr/mcp/knowledge_tools.py +507 -0
- rawr/mcp/market_tools.py +107 -0
- rawr/mcp/news_tools.py +288 -0
- rawr/mcp/notification_tools.py +83 -0
- rawr/mcp/quant_tools.py +392 -0
- rawr/mcp/server.py +30 -0
- rawr/mcp/signal_tools.py +259 -0
- rawr/mcp/system_tools.py +160 -0
- rawr/mcp/trading_tools.py +408 -0
- rawr/validators/__init__.py +0 -0
- rawr/validators/order_validator.py +49 -0
- rawr/version.py +3 -0
- rawr_tools-0.1.2.dist-info/METADATA +1843 -0
- rawr_tools-0.1.2.dist-info/RECORD +152 -0
- rawr_tools-0.1.2.dist-info/WHEEL +4 -0
- rawr_tools-0.1.2.dist-info/entry_points.txt +2 -0
- rawr_tools-0.1.2.dist-info/licenses/LICENSE +183 -0
rawr/__init__.py
ADDED
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"""RAWR: Risk And Win Ratio — AI Quant Trading Tool."""
|
|
2
|
+
|
|
3
|
+
from importlib import import_module
|
|
4
|
+
|
|
5
|
+
from rawr.version import __version__
|
|
6
|
+
|
|
7
|
+
_STAR_IMPORT_EXPORTS = [
|
|
8
|
+
"RawrDB",
|
|
9
|
+
"ApprovalStatus",
|
|
10
|
+
"TradePlan",
|
|
11
|
+
"TradePlanRepository",
|
|
12
|
+
"classify_disclosure",
|
|
13
|
+
"score_sentiment",
|
|
14
|
+
]
|
|
15
|
+
_OPTIONAL_EXPORTS = [
|
|
16
|
+
"TradePlanService",
|
|
17
|
+
]
|
|
18
|
+
|
|
19
|
+
__all__ = [
|
|
20
|
+
*_STAR_IMPORT_EXPORTS,
|
|
21
|
+
"__version__",
|
|
22
|
+
]
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
def __getattr__(name: str) -> object:
|
|
26
|
+
if name == "__version__":
|
|
27
|
+
return __version__
|
|
28
|
+
if name in _STAR_IMPORT_EXPORTS or name in _OPTIONAL_EXPORTS:
|
|
29
|
+
return getattr(import_module("rawr.api"), name)
|
|
30
|
+
raise AttributeError(f"module {__name__!r} has no attribute {name!r}")
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
def __dir__() -> list[str]:
|
|
34
|
+
return sorted([*globals(), *__all__])
|
rawr/api.py
ADDED
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
"""Supported public Python API for RAWR."""
|
|
2
|
+
|
|
3
|
+
from importlib import import_module
|
|
4
|
+
from typing import Final
|
|
5
|
+
|
|
6
|
+
_EXPORTS: Final[dict[str, tuple[str, str]]] = {
|
|
7
|
+
"RawrDB": ("rawr.core.knowledge.db", "RawrDB"),
|
|
8
|
+
"TradePlanService": ("rawr.core.plans.service", "TradePlanService"),
|
|
9
|
+
"ApprovalStatus": ("rawr.core.plans", "ApprovalStatus"),
|
|
10
|
+
"TradePlan": ("rawr.core.plans", "TradePlan"),
|
|
11
|
+
"TradePlanRepository": ("rawr.core.plans", "TradePlanRepository"),
|
|
12
|
+
"classify_disclosure": ("rawr.core.news", "classify_disclosure"),
|
|
13
|
+
"score_sentiment": ("rawr.core.news", "score_sentiment"),
|
|
14
|
+
}
|
|
15
|
+
_STAR_IMPORT_EXPORTS: Final[tuple[str, ...]] = (
|
|
16
|
+
"RawrDB",
|
|
17
|
+
"ApprovalStatus",
|
|
18
|
+
"TradePlan",
|
|
19
|
+
"TradePlanRepository",
|
|
20
|
+
"classify_disclosure",
|
|
21
|
+
"score_sentiment",
|
|
22
|
+
)
|
|
23
|
+
|
|
24
|
+
__all__ = list(_STAR_IMPORT_EXPORTS)
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
def __getattr__(name: str) -> object:
|
|
28
|
+
try:
|
|
29
|
+
module_name, attr_name = _EXPORTS[name]
|
|
30
|
+
except KeyError as exc:
|
|
31
|
+
raise AttributeError(f"module {__name__!r} has no attribute {name!r}") from exc
|
|
32
|
+
|
|
33
|
+
value = getattr(import_module(module_name), attr_name)
|
|
34
|
+
globals()[name] = value
|
|
35
|
+
return value
|
|
36
|
+
|
|
37
|
+
|
|
38
|
+
def __dir__() -> list[str]:
|
|
39
|
+
return sorted([*globals(), *__all__])
|
rawr/cli/__init__.py
ADDED
|
File without changes
|