mirror of
https://github.com/farcasclaudiu/xtb-investment-tools.git
synced 2026-06-22 05:01:57 +03:00
68cfec926e
- Created requirements.txt for dependencies including pandas, numpy, openpyxl, and yfinance. - Added setup-env.sh script to set up a Python virtual environment and install required packages. - Introduced validate-export.sh script to validate the exporter module and check expected fields. - Implemented test cases in test_portfolio_performance_exporter.py to ensure correct CSV export functionality and data handling.
1.9 KiB
1.9 KiB
name, description
| name | description |
|---|---|
| xtb-portfolio-performance-export | Use when converting XTB brokerage .xlsx exports to Portfolio Performance-compatible CSV files, validating Portfolio Transactions and Account Transactions outputs, or explaining the Portfolio Performance import workflow. |
XTB Portfolio Performance Export
Use this skill to create and validate Portfolio Performance CSV files from XTB
Cash Operations data using the bundled exporter.py.
Workflow
- Identify the target workbook. If omitted and exactly one non-lock
.xlsxexists, the exporter can auto-detect it. - Run exporter validation before trusting an import file:
<skill-folder>/scripts/validate-export.sh - Create the Portfolio Performance CSV files:
<skill-folder>/scripts/export-portfolio-performance.sh <report.xlsx> - If the user needs a custom directory, run:
<skill-folder>/scripts/export-portfolio-performance.sh <report.xlsx> -o <output-dir> - Inspect the generated CSV headers and a sample of rows before saying they are import-ready.
- Read
references/portfolio-performance-csv.mdbefore explaining import steps, transaction mappings, or limitations.
Outputs
results/<stem>_portfolio_performance_portfolio_transactions.csvresults/<stem>_portfolio_performance_account_transactions.csv
Guardrails
- Import Portfolio Transactions before Account Transactions so securities exist before dividend rows are matched.
- Use UTF-8, semicolon delimiter, and first-line header in Portfolio Performance.
- Refer to Portfolio Performance UI accounts as
Deposit AccountandSecurities Account; keep CSV field names literal asCash AccountandSecurities Account. - Do not claim the generated files are fully imported until the user has reviewed Portfolio Performance's wizard preview/status column.
- Keep multi-currency caveats visible: this first exporter uses the account currency and deterministic account labels, with optional CLI overrides.