Metadata-Version: 2.4
Name: cqr-fundflows
Version: 0.2.0
Summary: Compiled Bloomberg BQuant fund-flow analytics dashboard
Author-email: Paul Comte <paulcmte@gmail.com>
Maintainer-email: Paul Comte <paulcmte@gmail.com>
License-Expression: LicenseRef-Proprietary
Classifier: Development Status :: 3 - Alpha
Classifier: Environment :: Other Environment
Classifier: Intended Audience :: Financial and Insurance Industry
Classifier: Operating System :: Microsoft :: Windows :: Windows 10
Classifier: Operating System :: Microsoft :: Windows :: Windows 11
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: Python :: 3.11
Classifier: Programming Language :: Cython
Requires-Python: <3.12,>=3.11
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: numpy<3,>=1.24
Requires-Dist: pandas<4,>=2.0
Requires-Dist: plotly<7,>=5.0
Requires-Dist: ipywidgets<9,>=8.0
Requires-Dist: ipython<10,>=8.0
Requires-Dist: openpyxl<4,>=3.1
Dynamic: license-file

# CQR Fund Flows

Compiled Bloomberg BQuant dashboard for fund-flow analysis.

## Supported environment

- Bloomberg BQuant
- Windows 64-bit
- CPython 3.11
- Bloomberg's `bql` module already available in the environment

## Installation

```powershell
python -m pip install cqr-fundflows
```

## Usage

Run in a BQuant notebook:

```python
from cqr_fundflows import launch_dashboard

launch_dashboard()
```

Only `launch_dashboard()` is part of the supported public API.

## Access control

There is no licence key to paste into the notebook. At import time, the
compiled extension reads Bloomberg BQuant's protected `UUID` environment
variable and asks the CQR HTTPS authorization endpoint whether that Bloomberg
USER ID has an active Fund Flows entitlement.

Access is granted only when all of the following are true:

- the client account exists;
- its professional email address has been verified;
- CQR has manually marked the Fund Flows entitlement as active;
- the entitlement has started and has not expired.

The check fails closed when the UUID is missing or when the authorization
service cannot be reached. No client password, private API credential or
service-role key is included in the Python package.

See `ACCESS_CONTROL.md` for the one-time Supabase and website deployment.

## Distribution model

The PyPI release must contain the compiled Windows wheel only. Do not publish a
source distribution (`.tar.gz`), because it would disclose the Cython source.
Keep the source repository private.

## Local Windows build

```powershell
py -3.11 -m venv .venv
.\.venv\Scripts\Activate.ps1
python -m pip install --upgrade pip build twine
python -m build --wheel
python -m twine check .\dist\*
```

The expected output is similar to:

```text
cqr_fundflows-0.1.0-cp311-cp311-win_amd64.whl
```

## Limitation

Cython compilation makes direct inspection more difficult, but it is not an
absolute protection against reverse engineering.
