MCPcopy Create free account

hub / github.com/HKUDS/Vibe-Trading / functions

Functions26,887 in github.com/HKUDS/Vibe-Trading

↓ 14 callersFunctionfit_records
Serialize the largest whole-record page of ``records[offset:]`` that fits. Args: records: All available records, newest first by the call
agent/src/tools/_result_paging.py:23
↓ 14 callersMethodformat_assistant_tool_calls
Format an assistant tool_calls message, preserving thinking text. Args: tool_calls: List of tool call objects. conten
agent/src/agent/context.py:451
↓ 14 callersMethodget_goal
Return a goal by id.
agent/src/goal/store.py:455
↓ 14 callersFunctionget_json
Issue a throttled Eastmoney GET and decode the body as JSON. Args: url: Fully-qualified Eastmoney endpoint URL. params: Query par
agent/backtest/loaders/eastmoney_client.py:106
↓ 14 callersFunctionget_limit_status
Look up one symbol-day: table-first, heuristic fallback, provenance. ``prev_close`` is only needed on the heuristic path (the ``stk_limit`` t
agent/src/tools/paper_trade/limits_cn_a.py:149
↓ 14 callersMethodget_session
(self, session_id: str)
agent/tests/test_channels_runtime.py:46
↓ 14 callersFunctionhistorical_var
Value at Risk from the empirical distribution of past returns. Makes no distributional assumption: it simply reads the loss off the sorted sa
agent/src/quantlib/risk.py:146
↓ 14 callersFunctionimplied_volatility
Invert Black-Scholes for volatility, Newton first then bisection. Seeds with the Brenner-Subrahmanyam at-the-money approximation ``sigma_0 =
agent/src/quantlib/options.py:396
↓ 14 callersMethodindex_session
(self, session_id: str, title: str)
agent/tests/test_session_tool_trail.py:22
↓ 14 callersFunctionlinear_impact
Apply market impact proportional to the participation rate. Impact is ``impact_coeff * volume_traded / adv``. Marginal impact is constant, wh
agent/src/quantlib/impact.py:210
↓ 14 callersFunctionlist_playbooks
Load every available playbook, sorted by slug. A slug found in an earlier directory shadows the same slug later, so a user file overrides the
agent/src/scheduled_research/playbooks.py:377
↓ 14 callersFunctionlist_profiles
Return built-in profiles plus operator-installed local read-only plugins. Returns: The built-in profiles, followed by the profile of ever
agent/src/trading/profiles.py:61
↓ 14 callersFunctionload_config
Load Trading 212 settings from ``~/.vibe-trading/trading212.json``.
agent/src/trading/connectors/trading212/sdk.py:139
↓ 14 callersFunctionmoney
Money-path entry conversion: ``Decimal(str(x))`` (VD-9).
agent/src/tools/paper_trade/rules.py:92
↓ 14 callersFunctionnormalize_date
Coerce a supported date input to a plain ``datetime.date``. ``datetime`` instances are truncated to their date, because a cash flow settles o
agent/src/entities/models.py:95
↓ 14 callersMethodoptimize
Apply optimizer to position weights. Args: ret: Return matrix (dates x codes). For a decision at ``dt``, only row
agent/backtest/optimizers/base.py:36
↓ 14 callersFunctionparse_file
End-to-end: load file, detect format, parse. Args: path: File path. Returns: (format_name, records). Falls back to generic i
agent/src/tools/trade_journal_parsers.py:738
↓ 14 callersFunctionredact_internal_paths
Replace internal root prefixes with '<redacted>', keep relative tail. Every occurrence of an internal root is replaced when it ends at a real
agent/src/tools/redaction.py:232
↓ 14 callersMethodrelease
(self)
agent/src/trading/connectors/ibkr/local.py:581
↓ 14 callersFunctionresolve_longbridge_credentials
Resolve credentials atomically from environment or the legacy runtime file.
agent/src/trading/connectors/longbridge/credentials.py:49
↓ 14 callersMethodstart
Start the QQ bot with auto-reconnect loop.
agent/src/channels/qq.py:205
↓ 14 callersMethodstatus
Return runtime and channel status.
agent/src/channels/runtime.py:105
↓ 14 callersFunctionthrottled_get
GET ``url`` after waiting out the per-host minimum interval. Args: url: Fully-qualified request URL. host_key: Throttle/session b
agent/backtest/loaders/_http.py:143
↓ 14 callersFunctionts_argmin
Rolling argmin (0-based index into the window), warmup → NaN. Uses ``bottleneck.move_argmin`` when available (~350x faster). Correction: ``bn
agent/src/factors/base.py:351
↓ 14 callersFunctionuseChartLifecycle
( ref: RefObject<HTMLDivElement | null>, buildOption: () => EChartsCoreOption, deps: readonly unknown[],
frontend/src/hooks/useChartLifecycle.ts:18
↓ 14 callersFunctionvalidate_ohlc
Drop, flag, or reject bars that violate OHLC invariants. Loaders only drop NaN rows, so structurally dirty bars — ``high < low``, a non-posit
agent/backtest/loaders/base.py:191
↓ 14 callersFunctionwin_rate_and_stats
Win rate and P&L statistics from completed trades. Args: trades: Completed round-trip trades. Returns: Dict with win_rate, p
agent/backtest/metrics.py:343
↓ 14 callersFunctionzscore_by_group
Per-row within-group z-score (axis=1 groups, sample std, ddof=1). The z-scoring sibling of the per-row sector demean the industry-neutralized
agent/src/factors/base.py:99
↓ 13 callersFunction_bar
(close: float = 100.0, pre_close: float | None = None, open_: float | None = None)
agent/tests/test_korea_equity_engine.py:37
↓ 13 callersFunction_block
(*rows: str)
agent/tests/test_grounding_shape_hardening.py:67
↓ 13 callersFunction_classify_deliverable
Hybrid output contract. Return a short reason string when the worker did NOT produce a substantive deliverable, else ``None``. Content-sanity
agent/src/swarm/worker.py:1433
↓ 13 callersFunction_client
(tmp_path: Path, monkeypatch: pytest.MonkeyPatch)
agent/tests/test_attribution_api.py:28
↓ 13 callersFunction_compute_forward_returns
Forward simple returns over ``horizon`` bars, aligned to the factor timestamp. ``horizon=1`` keeps the historical next-bar formula byte-for-byte.
agent/src/tools/alpha_bench_tool.py:957
↓ 13 callersFunction_compute_rsi
Relative Strength Index (Wilder smoothing) over *period* bars. Matches the Wilder-EWM convention already used for RSI elsewhere in this codeb
agent/src/tools/technical_indicator_tool.py:174
↓ 13 callersFunction_create_memory_file
Helper to create a memory file with extended frontmatter.
agent/tests/test_memory_gc.py:29
↓ 13 callersFunction_facts
Wrap unit rows in the companyfacts envelope shape.
agent/tests/test_sec_period_frames.py:42
↓ 13 callersFunction_frame
(rows: list[dict[str, Any]])
agent/tests/test_industry_loader.py:53
↓ 13 callersFunction_frame
(rows: list[tuple[str, float]])
agent/tests/test_paper_trade_rejections.py:58
↓ 13 callersFunction_hengrui_candidates
()
agent/tests/test_grounding_resolution_context.py:30
↓ 13 callersFunction_host_validate_path_param
(value: str, kind: str)
agent/src/api/sessions_routes.py:421
↓ 13 callersMethod_identical_call_key
Build a stable key identifying a deterministic tool invocation. Args: tool_name: Tool name. arguments: Tool arguments
agent/src/agent/tool_lifecycle.py:778
↓ 13 callersFunction_internal_job
( job_id: str = "slow", *, callable_name: str = "test.slow", schedule: str = "1000", next_
agent/tests/scheduling/test_internal_dispatch.py:37
↓ 13 callersFunction_ledger
( tmp_path: Path, *, message: str = "分析机器人ETF并给出买入价", )
agent/tests/test_grounding_recovery.py:33
↓ 13 callersFunction_ledger
( tmp_path: Path, payload: dict, tool: str = "account_summary" )
agent/tests/test_grounding_unit_and_scanner_gaps.py:21
↓ 13 callersFunction_live_env
Sandbox the runtime root and the module-level runner registries.
agent/tests/test_api_live_runtime.py:299
↓ 13 callersMethod_microcompact_and_unblock
Run layer-1 microcompact and re-open lost readonly call identities. A readable result for another argument variant, or a synthetic skip,
agent/src/agent/loop.py:1439
↓ 13 callersFunction_patch_ddgs
(monkeypatch, text_impl)
agent/tests/test_web_search_tool.py:36
↓ 13 callersFunction_payload
(**overrides)
agent/tests/test_paper_trade_tool.py:117
↓ 13 callersFunction_profile
(rule: ShadowRule)
agent/tests/test_shadow_account.py:2049
↓ 13 callersFunction_propose
Run the propose tool and return the parsed proposal payload.
agent/tests/test_consent_commit.py:56
↓ 13 callersFunction_remote_client
Return a TestClient that simulates a non-loopback caller.
agent/tests/test_security_auth_api.py:14
↓ 13 callersFunction_rolling_correlation_matrix
Compute correlation matrix for multiple price series. Args: price_series: Mapping of asset code -> DataFrame with a ``close`` column.
agent/backtest/correlation.py:176
↓ 13 callersFunction_row
(strategy_id, regime, **overrides)
agent/tests/test_strategy_discovery_facade.py:180
↓ 13 callersMethodbegin
Atomically reserve a due decision, or return None between decisions. Raises: DecisionBudgetError: If a limit or an unfinished pri
agent/src/live/runtime/decision_budget.py:138
↓ 13 callersFunctionboolean_argument
Parse an optional boolean without treating non-empty strings as true. Args: value: Boolean, null, zero/one, or an explicit boolean spelli
agent/src/tools/_arguments.py:8
↓ 13 callersFunctionbuild_swarm_registry
Build a per-worker registry that merges local + remote MCP tools. Swarm workers receive a strict whitelist (``agent_spec.tools``). This build
agent/src/tools/__init__.py:360
↓ 13 callersMethodclear
Clear all issued tokens.
agent/src/channelsui/gateway_services.py:44
↓ 13 callersMethodclose
Close the SQLite connection, primarily for isolated test cleanup.
agent/src/research_artifacts/store.py:126
↓ 13 callersMethodensure
Return an existing connection, creating it when absent. Args: connection_id: Identifier to resolve or create. profile
agent/src/trading/connections.py:259
↓ 13 callersFunctionfixed_slippage
Apply a constant basis-point slippage to a fill price. The cheapest model, and adequate whenever the order is small enough that it does not m
agent/src/quantlib/impact.py:183
↓ 13 callersFunctionget_background_manager
Return a private handle over this runtime root's durable task table.
agent/src/tools/background_tools.py:565
↓ 13 callersFunctionget_loader_cls_with_fallback
Return a loader *class* for *source*, falling back if unavailable. Args: source: Requested data source name. Returns: A Data
agent/backtest/loaders/registry.py:625
↓ 13 callersMethodindex_entry
Upsert a memory entry into the index. Args: entry_id: 6-char hex identifier. title: Memory title. descrip
agent/src/memory/search_index.py:299
↓ 13 callersFunctionmigrate_legacy_state
Move legacy code-relative state directories under the runtime root. Idempotent: once a legacy entry has been moved (or was never there), late
agent/src/config/migrate.py:114
↓ 13 callersFunctionnormalise_option_type
Fold an option-type string to ``"call"`` or ``"put"``. Public because callers that *store* an option type must fold it with the same rule the
agent/src/quantlib/options.py:122
↓ 13 callersFunctionperiod_returns
Per-bar returns seeded with the pre-first-bar cash mark. The account holds ``initial_cash`` before the first recorded bar, so the first retur
agent/backtest/metrics.py:547
↓ 13 callersFunctionresolve_final_status
Run the terminal-status decision ladder. The branch order is load-bearing: stall (already recorded) → cancelled → exhausted token budget → no
agent/src/agent/run_outcome.py:122
↓ 13 callersFunctionretry_with_budget
Call ``fn`` with a bounded retry budget on declared transient errors. Between attempts sleeps ``min(backoff[attempt], remaining_budget)`` so a
agent/backtest/loaders/base.py:406
↓ 13 callersFunctionrun_shadow_backtest
Drive a multi-market backtest from a ShadowProfile. Markets are backtested per settlement currency: the composite engine refuses a mixed-curr
agent/src/shadow_account/backtester.py:164
↓ 13 callersMethodsearch
Full-text search with FTS5 MATCH. Args: query: User search query. max_results: Maximum results to return. Re
agent/src/memory/search_index.py:344
↓ 13 callersMethodstart_run
Start a swarm run. Returns immediately, execution happens in background. Args: preset_name: YAML preset name to execute.
agent/src/swarm/runtime.py:380
↓ 13 callersFunctionthrottled_get_json
Throttled GET that decodes the response body as JSON. Same contract as :func:`throttled_get`, plus ``response.raise_for_status()`` and ``resp
agent/backtest/loaders/_http.py:218
↓ 13 callersFunctiontruncate_tool_result
Cut an oversized tool result to ``limit`` characters and say so. A silent cut is indistinguishable from a complete answer, so the model repor
agent/src/config/limits.py:22
↓ 12 callersFunction_agent
(tmp_path, callback=None)
agent/tests/test_llm_cost_accounting.py:28
↓ 12 callersFunction_bars
(closes)
agent/tests/test_alpha_bench_qfq.py:24
↓ 12 callersFunction_base_manifest_kwargs
()
agent/tests/test_governance.py:79
↓ 12 callersFunction_build_dcf_artifact
(inputs: dict | None = None, *, generated_at: datetime = FIXED_TIME)
agent/tests/quantlib/valuation/test_artifact.py:112
↓ 12 callersFunction_client
()
agent/tests/test_options_routes.py:28
↓ 12 callersFunction_client
(tmp_path: Path, monkeypatch)
agent/tests/test_factor_api.py:15
↓ 12 callersFunction_context_collapse
Layer 2: fold long text blocks in older messages without LLM call. Preserves head + tail of large text, collapses the middle. Zero API cost —
agent/src/agent/context_compact.py:292
↓ 12 callersMethod_ctx
(self, n_assets: int = 5, seed: int = 42)
agent/tests/test_turnover_aware_optimizer.py:209
↓ 12 callersFunction_engine
(instruments=None, **config)
agent/tests/test_argentina_equity_engine.py:61
↓ 12 callersFunction_exact_order
(action, *, status="new", filled_qty="0", **changes)
agent/tests/test_sdk_order_gate.py:295
↓ 12 callersFunction_fetch
(daily, five, *, symbols=(_SYM,), interval="5m", from_date=_DAY, to_date=_DAY)
agent/tests/test_paper_trade_5m_session.py:121
↓ 12 callersFunction_fetch
(market: str, frames: dict[str, pd.DataFrame], from_date: str, to_date: str, symbols: list[str] | N
agent/tests/test_paper_trade_corporate_actions.py:88
↓ 12 callersMethod_fetch_daily_frame
Fetch and normalize one daily OHLCV frame, routing by symbol type.
agent/backtest/loaders/tushare.py:213
↓ 12 callersFunction_guard
(adapter, **kwargs)
agent/tests/test_mandate_enforcement.py:301
↓ 12 callersFunction_inject_mock_transport
Route the probe's fresh ``httpx.AsyncClient`` through a MockTransport. The probe owns its client, so the only seam is the client class itself. Th
agent/tests/test_feishu_connection_test.py:55
↓ 12 callersFunction_inputs
(**over: object)
agent/tests/test_run_outcome_module.py:44
↓ 12 callersFunction_is_error_result
Did a tool call return a top-level error envelope? Parses the result as JSON and checks for a top-level ``status == "error"``. Also treats ``
agent/src/swarm/worker.py:1402
↓ 12 callersFunction_is_etf_listed
Detect exchange-listed ETF / LOF symbols (e.g. 510050.SH, 159915.SZ).
agent/backtest/loaders/_symbol_utils.py:12
↓ 12 callersFunction_job
(**overrides)
agent/tests/test_scheduled_delivery_outbox.py:42
↓ 12 callersFunction_ledger
(tmp_path: Path, values: tuple[float, ...])
agent/tests/test_grounding_operand_evidence.py:13
↓ 12 callersFunction_load
(api: Any, symbols: list[str] | None = None, **kwargs: Any)
agent/tests/test_industry_loader.py:82
↓ 12 callersFunction_load
(name: str)
agent/tests/test_paper_trade_fixtures.py:98
↓ 12 callersFunction_make_channel
Build a Feishu channel that has NOT been started (no lark client).
agent/tests/test_feishu_connection_test.py:43
↓ 12 callersFunction_make_registry
(tmp_path: Path)
agent/tests/test_cli_hypothesis.py:18
↓ 12 callersFunction_market
Normalize one gamma market through the tool and return the record.
agent/tests/test_prediction_market_tool.py:168
↓ 12 callersFunction_movement
( *, datum: str = "01.09.2026", isin: str = VALID_ISIN, name: str = "Example World ETF", i
agent/tests/test_extraetf_reader.py:96
↓ 12 callersFunction_normalize_symbol
Convert a user-supplied code to the project's canonical loader symbol. The data loaders key US/HK/A-share instruments by an exchange-suffixed
agent/backtest/correlation.py:95
← previousnext →501–600 of 26,887, ranked by callers