finance_* / finance_app_* — Finance project

The finance/trading project tool namespaces — the live data API (portfolio, quotes, positions, signals, risk) and the separate shell/file access into the finance source tree.

The finance/trading project on nvrbackup has two distinct tool families, and they are not interchangeable:

  • finance_* — the live data API (http://10.10.0.14:3000): portfolio, quotes, positions, signals, watchlists, risk.
  • finance_app_* — shell and file access scoped to the finance source tree (/home/superht/finance/).

Live data API — finance_*

These hit the :3000 API. It’s only up when the backend is running — a connect timeout means the service is stopped, not broken.

finance_get_portfolio

finance_get_portfolio()

Current portfolio summary. No args.

finance_get_quote

finance_get_quote(symbol)

Latest quote for one symbol.

finance_list_positions

finance_list_positions(symbol=None)

Open positions; optionally filter to one symbol.

finance_get_signals

Recent model signals.

finance_get_signals(asset_type="equity", signal_type=None, symbol=None,
                    min_quality=None, recent=True, limit=50)

Filter by asset_type, signal_type, symbol, and a min_quality floor. recent=True (default) restricts to the latest batch.

finance_list_watchlists

finance_list_watchlists(asset_type=None)

finance_search_symbols

finance_search_symbols(query, market="all", limit=10)

finance_get_risk_limits / finance_get_risk_status

finance_get_risk_limits()
finance_get_risk_status()

Configured risk limits, and current standing against them. No args.

finance_health_check

finance_health_check()

A connect timeout = the :3000 backend is down. Start the service (via finance_app_* or remote_*) before relying on the finance_* data tools.

Source tree — finance_app_*

Shell and file access scoped to the finance project tree. Use these to inspect or operate the codebase, restart the service, read logs, etc.

finance_app_execute_command

finance_app_execute_command(command, timeout=30)

Runs from the finance app root directory. timeout defaults to 30s.

finance_app_read_file

finance_app_read_file(path)

Reads from the finance source tree. The namespace also includes finance_app_write_file, finance_app_list_directory, and finance_app_file_exists, all scoped the same way.

When to use which

You want to…Use
Read portfolio / quotes / positions / signals / riskfinance_* (data API)
Restart the backend, read a log, edit a config filefinance_app_* (source tree)
Do something on nvrbackup outside the finance treeremote_* (Hosts)
  • Hostsnvrbackup, the :3000 API, and the source tree paths
  • Service Map — the finance project among the in-house apps
  • Tools — catalog overview and routing rules