{
  "markdown": "# JACTUS\n\n> High-performance implementation of the ACTUS financial contract standard using JAX\n\n[![PyPI](https://img.shields.io/pypi/v/jactus)](https://pypi.org/project/jactus/)\n[![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](https://opensource.org/licenses/Apache-2.0)\n[![Python 3.10+](https://img.shields.io/badge/python-3.10+-blue.svg)](https://www.python.org/downloads/)\n[![Documentation](https://img.shields.io/badge/docs-GitHub%20Pages-blue)](https://pedronahum.github.io/JACTUS/)\n[![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/pedronahum/JACTUS/blob/main/examples/notebooks/00_getting_started_pam.ipynb)\n[![GPU Benchmark](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/pedronahum/JACTUS/blob/main/examples/notebooks/05_gpu_tpu_portfolio_benchmark.ipynb)\n\n### Interactive Demo\n\nExplore JACTUS hands-on — CLI commands, Python API, behavioral risk models, and batch simulation on GPU:\n\n[![Open Demo In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/pedronahum/JACTUS/blob/main/examples/notebooks/07_demo_cli_and_python.ipynb)\n\n### Claude Opus talks JACTUS\n\n<p align=\"center\">\n  <img src=\"docs/jactus-demo.gif\" alt=\"Claude Opus talks JACTUS\" width=\"600\">\n</p>\n\n## Overview\n\nJACTUS is a Python library that implements the **ACTUS (Algorithmic Contract Types Unified Standards)** specification using JAX for high-performance, differentiable financial contract modeling.\n\n### Key Features\n\n- **High Performance**: Leverages JAX's JIT compilation and GPU acceleration\n- **Array-Mode Portfolio API**: Batch simulation of 12 contract types via JIT-compiled kernels on `[B, T]` arrays — see [Array-Mode Guide](docs/ARRAY_MODE.md)\n- **Automatic Differentiation**: Built-in support for gradient-based risk analytics\n- **Behavioral Risk Models**: Prepayment surfaces, deposit behavior, and dynamic event injection via callout events\n- **Scenario Management**: Bundle market and behavioral observers into named configurations\n- **Type Safety**: Full type annotations with mypy support\n- **Comprehensive**: Implements the complete ACTUS standard\n- **Well Tested**: 276 official ACTUS cross-validation test cases passing across all 18 contract types\n- **Command-Line Interface**: Full-featured `jactus` CLI for simulation, validation, risk analytics, and portfolio management — outputs rich tables in TTY, JSON when piped\n- **Production Ready**: Robust error handling, logging, and documentation\n\n## What is ACTUS?\n\nACTUS (Algorithmic Contract Types Unified Standards) is a standardized framework for representing financial contracts as mathematical algorithms. It provides a unified approach to modeling cash flows, risk analytics, and contract behavior across various financial instruments.\n\n## AI Agent Integration\n\n### Gemini CLI Extension (one-command install)\n\n```bash\ngemini extensions install https://github.com/pedronahum/JACTUS\n```\n\nGives Gemini CLI direct access to JACTUS simulation, risk analytics, and\nGoogle Workspace integration recipes.\n\n### Agent Skill (any compatible client)\n\n```bash\nnpx skills add https://github.com/pedronahum/JACTUS\n```\n\nAdds JACTUS expertise to Claude Code, Gemini CLI, or any Agent Skills-compatible\nclient.\n\n### MCP Server (Claude Desktop, VS Code, etc.)\n\n```json\n{\n  \"mcpServers\": {\n    \"jactus\": {\n      \"command\": \"python\",\n      \"args\": [\"-m\", \"jactus_mcp\"],\n      \"cwd\": \"/path/to/JACTUS\"\n    }\n  }\n}\n```\n\n### Context Hub (chub)\n\nAgent-optimized documentation for [Context Hub](https://github.com/andrewyng/context-hub).\nJACTUS docs are being added to the public Context Hub registry ([PR #103](https://github.com/andrewyng/context-hub/pull/103)) — once merged, any agent running `chub search jactus` will find them automatically.\n\nIn the meantime, you can use the docs locally:\n\n```bash\nchub build /path/to/JACTUS/tools/chub/ -o /tmp/jactus-chub/\nchub search jactus\n```\n\nProvides structured contract reference, observer API, and array-mode docs\noptimized for agent consumption. See [`tools/chub/`](tools/chub/) for details.\n\n### Pair with Google Workspace CLI\n\n```bash\ngws auth setup      # authenticate once\ngws mcp -s drive,sheets,gmail &   # start gws MCP\npython -m jactus_mcp &             # start JACTUS MCP\n```\n\nAgent can now read term sheets from Drive, simulate contracts, write cash flows\nto Sheets, and send summaries via Gmail — all in one session.\n\n## Installation\n\n```bash\npip install jactus\n```\n\n**Requirements:** Python 3.10+, JAX >= 0.4.20\n\n### GPU / TPU Acceleration\n\nJACTUS runs on CPU by default. To enable hardware acceleration, install the\nappropriate JAX backend **before** or **after** installing JACTUS:\n\n```bash\n# NVIDIA GPU (CUDA 13 — recommended)\npip install \"jax[cuda13]\"\n\n# NVIDIA GPU (CUDA 12)\npip install \"jax[cuda12]\"\n\n# Google Cloud TPU\npip install \"jax[tpu]\"\n```\n\nNo code changes are required — JACTUS automatically detects the available\nbackend and selects the optimal execution strategy (e.g. `vmap` on GPU/TPU,\nmanual batching on CPU).\n\n> **Precision note:** The array-mode simulation path uses float32 for\n> performance. TPUs do not support float64. For CPU/GPU workloads requiring\n> full double precision, enable it before importing JACTUS:\n> `jax.config.update(\"jax_enable_x64\", True)`\n\nFor development:\n\n```bash\ngit clone https://github.com/pedronahum/JACTUS.git\ncd JACTUS\npip install -e \".[dev,docs,viz]\"\n```\n\n## Quick Start\n\n```python\nfrom jactus.contracts import create_contract\nfrom jactus.core import ContractAttributes, ContractType, ContractRole, ActusDateTime\nfrom jactus.observers import ConstantRiskFactorObserver\n\n# Create a simple Principal at Maturity (PAM) loan\n# $100,000 loan at 5% interest, 1 year maturity\nattrs = ContractAttributes(\n    contract_id=\"LOAN-001\",\n    contract_type=ContractType.PAM,\n    contract_role=ContractRole.RPA,  # We are the lender\n    status_date=ActusDateTime(2024, 1, 1),\n    initial_exchange_date=ActusDateTime(2024, 1, 15),\n    maturity_date=ActusDateTime(2025, 1, 15),\n    notional_principal=100_000.0,\n    nominal_interest_rate=0.05,  # 5% annual\n    interest_payment_cycle=\"6M\",  # Semi-annual interest\n    day_count_convention=\"30E360\",\n)\n\n# Create risk factor observer\nrf_observer = ConstantRiskFactorObserver(constant_value=0.0)\n\n# Create and simulate the contract\ncontract = create_contract(attrs, rf_observer)\nresult = contract.simulate()\n\n# Display cash flows\nfor event in result.events:\n    if event.payoff != 0:\n        print(f\"{event.event_time}: {event.event_type.name:4s} ${event.payoff:>10,.2f}\")\n\n# Output:\n# 2024-01-15: IED  $-100,000.00  (loan disbursement)\n# 2024-07-15: IP   $  2,500.00   (6-month interest)\n# 2025-01-15: MD   $102,500.00   (principal + final interest)\n```\n\nFor more examples, see the [examples/](examples/) directory and [Jupyter notebooks](examples/notebooks/).\n\n## Implemented Contract Types\n\nJACTUS implements **18 ACTUS contract types** covering the complete ACTUS specification v1.1:\n\n### Principal Contracts (6)\n- **PAM** - Principal at Maturity (interest-only loans, bonds)\n- **LAM** - Linear Amortizer (fixed principal amortization)\n- **LAX** - Exotic Linear Amortizer (variable amortization schedules)\n- **NAM** - Negative Amortizer (increasing principal balance)\n- **ANN** - Annuity (mortgages, equal payment loans)\n- **CLM** - Call Money (variable principal, on-demand repayment)\n\n### Non-Principal Contracts (3)\n- **UMP** - Undefined Maturity Profile (revolving credit lines)\n- **CSH** - Cash (money market accounts, escrow)\n- **STK** - Stock (equity positions)\n\n### Exotic Non-Principal Contracts (1)\n- **COM** - Commodity (physical commodities, futures underliers)\n\n### Derivative Contracts (8)\n- **FXOUT** - Foreign Exchange Outright (FX forwards, swaps)\n- **OPTNS** - Options (calls, puts, European/American)\n- **FUTUR** - Futures (standardized forward contracts)\n- **SWPPV** - Plain Vanilla Swap (fixed vs floating interest rate swaps)\n- **SWAPS** - Generic Swap (cross-currency swaps, multi-leg swaps)\n- **CAPFL** - Cap/Floor (interest rate caps and floors)\n- **CEG** - Credit Enhancement Guarantee (credit protection)\n- **CEC** - Credit Enhancement Collateral (collateral management)\n\n**Test Coverage:** 1,200+ unit/integration tests plus 276 official ACTUS cross-validation cases passing across all 18 contract types\n\n## Risk Factor and Behavioral Observers\n\nJACTUS provides a layered observer framework for market data and behavioral modeling:\n\n### Market Risk Factor Observers\n- **ConstantRiskFactorObserver** - Fixed constant value for all risk factors\n- **DictRiskFactorObserver** - Per-identifier static values\n- **TimeSeriesRiskFactorObserver** - Time-varying market data with step/linear interpolation\n- **CurveRiskFactorObserver** - Yield/rate curves keyed by tenor\n- **CompositeRiskFactorObserver** - Priority-based fallback across multiple observers\n- **CallbackRiskFactorObserver** - Delegates to user-provided callables\n- **JaxRiskFactorObserver** - Differentiable JAX-native observer for gradient-based analytics\n\n### Behavioral Risk Factor Observers\n- **BehaviorRiskFactorObserver** protocol and **BaseBehaviorRiskFactorObserver** ABC for custom behavioral models\n- **PrepaymentSurfaceObserver** - 2D surface-based prepayment model (spread x loan age -> prepayment rate)\n- **DepositTransactionObserver** - Deposit transaction behavior model for UMP contracts\n- **CalloutEvent** - Dynamic event injection allowing behavioral observers to add events to the simulation timeline\n\n### Scenario Management\n- **Scenario** - Bundle market and behavioral observers into named configurations for reproducible analysis\n- **Surface2D** / **LabeledSurface2D** - JAX-compatible 2D surface interpolation utilities\n\n## Documentation\n\nFull documentation is available at **[pedronahum.github.io/JACTUS](https://pedronahum.github.io/JACTUS/)**, including API reference, user guides, and the ACTUS specification overview.\n\n### Core Documentation\n\n- **[Architecture Guide](docs/ARCHITECTURE.md)** - Comprehensive system architecture, design patterns, and implementation details\n- **[PAM Contract Walkthrough](docs/PAM.md)** - Deep dive into JACTUS internals using the Principal at Maturity contract\n- **[Array-Mode & Portfolio Guide](docs/ARRAY_MODE.md)** - Batch simulation, GPU acceleration, and automatic differentiation\n- **[Derivative Contracts Guide](docs/derivatives.md)** - Complete guide to all 8 derivative contract types\n\n### Try It Now\n\n[![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/pedronahum/JACTUS/blob/main/examples/notebooks/00_getting_started_pam.ipynb)\n\nGet started immediately with the **Getting Started** notebook — no local installation required.\n\n### Building Documentation Locally\n\n```bash\npip install -e \".[docs]\"\ncd docs\nmake html\n# Open docs/_build/html/index.html in your browser\n```\n\n## Command-Line Interface\n\nJACTUS includes a full-featured CLI built with [Typer](https://typer.tiangolo.com/), designed for both human operators and automated pipelines. It mirrors the MCP server surface, so anything you can do programmatically you can also do from the terminal.\n\n### Why a CLI?\n\n- **Agent-first**: Outputs JSON by default when piped, rich tables in TTY — composable with `jq`, `awk`, and CI/CD pipelines\n- **No Python required**: Validate contracts, run simulations, and compute risk metrics without writing a single line of code\n- **Scriptable**: Chain commands with stdin/stdout for batch workflows (`cat portfolio.json | jactus portfolio simulate --file /dev/stdin`)\n- **Discoverable**: Built-in `contract list`, `contract schema`, and `observer list` commands for exploring ACTUS without reading docs\n\n### Installation\n\nThe CLI is installed automatically with JACTUS:\n\n```bash\npip install jactus\njactus --help\n```\n\n### Quick Examples\n\n```bash\n# List all 18 ACTUS contract types\njactus contract list\n\n# Get the schema for a PAM (Principal at Maturity) contract\njactus contract schema --type PAM\n\n# Simulate a $100k loan at 5% interest\njactus simulate --type PAM --attrs '{\n  \"contract_id\": \"LOAN-001\",\n  \"status_date\": \"2024-01-01\",\n  \"contract_role\": \"RPA\",\n  \"initial_exchange_date\": \"2024-01-15\",\n  \"maturity_date\": \"2025-01-15\",\n  \"notional_principal\": 100000,\n  \"nominal_interest_rate\": 0.05,\n  \"interest_payment_cycle\": \"6M\",\n  \"day_count_convention\": \"30E360\"\n}'\n\n# Validate contract attributes before simulation\njactus contract validate --type PAM --attrs loan.json\n\n# Compute DV01 (dollar value of a basis point)\njactus risk dv01 --type PAM --attrs loan.json\n\n# Get all risk sensitivities at once\njactus risk sensitivities --type PAM --attrs loan.json\n\n# Simulate a portfolio of contracts\njactus portfolio simulate --file portfolio.json\n\n# Aggregate portfolio cash flows by quarter\njactus portfolio aggregate --file portfolio.json --frequency quarterly\n\n# Search documentation\njactus docs search \"amortization\"\n```\n\n### JSON Output for Pipelines\n\n```bash\n# Pipe simulation results to jq for processing\njactus simulate --type PAM --attrs loan.json --output json | jq '.summary'\n\n# Extract non-zero cash flows as CSV\njactus simulate --type PAM --attrs loan.json --output csv --nonzero\n\n# Filter events by date range\njactus simulate --type PAM --attrs loan.json --from 2024-06-01 --to 2024-12-31\n```\n\n### Command Reference\n\n| Command | Description |\n|---------|-------------|\n| `jactus contract list` | List all 18 contract types with categories |\n| `jactus contract schema --type <TYPE>` | Show required/optional fields for a contract type |\n| `jactus contract validate --type <TYPE> --attrs <JSON>` | Validate contract attributes |\n| `jactus simulate --type <TYPE> --attrs <JSON>` | Run a full contract simulation |\n| `jactus risk dv01\\|duration\\|convexity\\|sensitivities` | Compute risk metrics |\n| `jactus portfolio simulate --file <FILE>` | Simulate multiple contracts |\n| `jactus portfolio aggregate --file <FILE>` | Aggregate cash flows by period |\n| `jactus observer list` | List all risk factor observer types |\n| `jactus observer describe --name <NAME>` | Show observer details |\n| `jactus docs search \"<QUERY>\"` | Search project documentation |\n\n### Global Flags\n\n```\n--output text|json|csv   Output format (auto-detected: text in TTY, json when piped)\n--pretty / --no-pretty   Pretty-print JSON output (default: true)\n--no-color               Disable ANSI colors\n--log-level              Set log verbosity (DEBUG, INFO, WARNING, ERROR)\n--version                Show version\n```\n\n## AI-Assisted Development\n\nJACTUS provides multiple integration paths for AI agents and assistants:\n\n| Tool | Purpose | Location |\n|------|---------|----------|\n| **MCP Server** | 18 tools for contract simulation, risk analytics, portfolio management, and docs | [`tools/mcp-server/`](tools/mcp-server/) |\n| **Context Hub** | Agent-optimized reference docs (contract types, observers, array-mode) | [`tools/chub/`](tools/chub/) |\n| **Agent Skill** | Portable skill package for compatible agent clients | [`skills/jactus/`](skills/jactus/) |\n| **Gemini Extension** | One-command install for Gemini CLI | [`gemini-extension.json`](gemini-extension.json) |\n\n### MCP Server (18 tools)\n\nThe MCP server gives AI assistants direct access to JACTUS — contract discovery, schema validation, simulation, risk metrics (DV01, delta, gamma, PV01), portfolio aggregation, and documentation search.\n\n```bash\npip install git+https://github.com/pedronahum/JACTUS.git#subdirectory=tools/mcp-server\n```\n\n```json\n{\n  \"mcpServers\": {\n    \"jactus\": {\n      \"command\": \"python\",\n      \"args\": [\"-m\", \"jactus_mcp\"]\n    }\n  }\n}\n```\n\nThe `.mcp.json` in the project root enables auto-discovery in VS Code and compatible editors.\n\nSee **[MCP Server Documentation](tools/mcp-server/README.md)** for full setup and usage.\n\n## Development\n\n### Setting Up Development Environment\n\n```bash\n# Run the setup script\n./scripts/setup_dev.sh\n\n# Or manually:\npython3 -m venv venv\nsource venv/bin/activate\npip install -e \".[dev,docs,viz]\"\npre-commit install\n```\n\n### Running Tests\n\n```bash\n# Run all tests\nmake test\n\n# Run with coverage\nmake test-cov\n\n# Run specific test markers\npytest -m unit\npytest -m integration\n```\n\n### Code Quality\n\n```bash\n# Format code\nmake format\n\n# Run linter\nmake lint\n\n# Type checking\nmake typecheck\n\n# Run all quality checks\nmake quality\n```\n\n## Examples\n\n### Interactive Jupyter Notebooks\n\nHands-on tutorials with visualizations in `examples/notebooks/`:\n\n- **[00 - Getting Started (PAM)](examples/notebooks/00_getting_started_pam.ipynb)** - Quick start with a PAM contract [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/pedronahum/JACTUS/blob/main/examples/notebooks/00_getting_started_pam.ipynb)\n- **[01 - Annuity Mortgage](examples/notebooks/01_annuity_mortgage.ipynb)** - 30-year mortgage with amortization charts\n- **[02 - Options Contracts](examples/notebooks/02_options_contracts.ipynb)** - Call/Put options with payoff diagrams\n- **[03 - Interest Rate Cap](examples/notebooks/03_interest_rate_cap.ipynb)** - Interest rate protection scenarios\n- **[04 - Stock & Commodity](examples/notebooks/04_stock_commodity.ipynb)** - Asset position tracking\n- **[05 - GPU/TPU Portfolio Benchmark](examples/notebooks/05_gpu_tpu_portfolio_benchmark.ipynb)** - Array-mode PAM with 50K contracts [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/pedronahum/JACTUS/blob/main/examples/notebooks/05_gpu_tpu_portfolio_benchmark.ipynb)\n- **[06 - Gallery of Contracts](examples/notebooks/06_gallery_of_contracts.ipynb)** - All 18 ACTUS types in one notebook [![Open In Colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/pedronahum/JACTUS/blob/main/examples/notebooks/06_gallery_of_contracts.ipynb)\n\n### Python Scripts\n\nReady-to-run examples in `examples/`:\n\n- `pam_example.py` - Principal at Maturity (bullet loans)\n- `lam_example.py` - Linear Amortizer (equal principal payments)\n- `interest_rate_swap_example.py` - Plain vanilla interest rate swap\n- `fx_swap_example.py` - Foreign exchange swap\n- `cross_currency_basis_swap_example.py` - Cross-currency basis swap\n\n### Example Details\n\n#### Interactive Notebooks (Recommended for Learning)\n\nThe Jupyter notebooks provide visual, hands-on learning with charts and step-by-step explanations:\n\n- **Gallery of Contracts** - All 18 ACTUS types in one notebook: principal, non-principal, derivative, and composite contracts with portfolio API, JAX autodiff risk metrics, and behavioral observers\n- **Annuity (ANN)** - Mortgage amortization with payment composition visualization\n- **Options (OPTNS)** - Call/put options with payoff diagrams\n- **Cap/Floor (CAPFL)** - Interest rate protection analysis\n- **Stock/Commodity (STK/COM)** - Position tracking and derivative underliers\n\n#### Principal Contracts (Python Scripts)\n\n- **[PAM Example](examples/pam_example.py)**: Comprehensive PAM (Principal at Maturity) examples\n  - Basic loan simulation\n  - Payment frequency comparison\n  - Borrower vs. lender perspectives\n  - JAX integration and sensitivity analysis\n  - 30-year mortgage simulation\n  - Portfolio analysis\n\n- **[LAM Example](examples/lam_example.py)**: Comprehensive LAM (Linear Amortizer) examples\n  - Basic amortizing loan with fixed principal payments\n  - IPCB modes comparison (NT, NTIED, NTL)\n  - Auto loan with monthly payments\n  - LAM vs PAM comparison (interest savings)\n  - Equipment financing with balloon payment\n  - Portfolio of amortizing loans\n\n#### Derivative Contracts\n\n- **[Interest Rate Swap](examples/interest_rate_swap_example.py)**: Plain vanilla interest rate swap\n  - 5-year fixed vs floating leg\n  - Overnight (O/N) floating rate with weekly resets\n  - Quarterly payment cycles\n  - Net settlement demonstration\n  - Market scenario analysis\n\n- **[FX Swap](examples/fx_swap_example.py)**: EUR/USD foreign exchange swap\n  - 1-year maturity\n  - Spot and forward rate mechanics\n  - Forward premium calculation\n  - Covered interest parity demonstration\n  - FX rate scenario analysis\n\n- **[Cross-Currency Basis Swap](examples/cross_currency_basis_swap_example.py)**: EUR vs USD basis swap\n  - 5-year tenor\n  - 3M EURIBOR vs 3M SOFR + 30 bps basis\n  - Multi-leg composition (SWAPS contract)\n  - Dual currency floating rates\n  - Basis spread impact analysis\n\nRun examples:\n```bash\n# Principal contracts\npython examples/pam_example.py  # Interest-only loans\npython examples/lam_example.py  # Amortizing loans\n\n# Derivative contracts\npython examples/interest_rate_swap_example.py     # Interest rate swaps\npython examples/fx_swap_example.py                 # FX swaps\npython examples/cross_currency_basis_swap_example.py  # Cross-currency swaps\n```\n\n## Project Structure\n\n```\njactus/\n├── src/jactus/          # Main package source\n│   ├── cli/                # Typer CLI (simulate, risk, portfolio, docs)\n│   ├── core/               # Core type definitions and enums\n│   ├── utilities/          # Date/time and calendar utilities\n│   ├── functions/          # Payoff and state transition functions\n│   ├── observers/          # Risk factor and behavioral observers\n│   ├── engine/             # Event generation and simulation engines\n│   ├── contracts/          # 18 ACTUS contract implementations\n│   │   ├── base.py         # BaseContract abstract class\n│   │   ├── pam.py          # Principal at Maturity\n│   │   ├── lam.py          # Linear Amortizer\n│   │   ├── lax.py          # Exotic Linear Amortizer\n│   │   ├── nam.py          # Negative Amortizer\n│   │   ├── ann.py          # Annuity\n│   │   ├── clm.py          # Call Money\n│   │   ├── ump.py          # Undefined Maturity Profile\n│   │   ├── csh.py          # Cash\n│   │   ├── stk.py          # Stock\n│   │   ├── com.py          # Commodity\n│   │   ├── fxout.py        # FX Outright\n│   │   ├── optns.py        # Options\n│   │   ├── futur.py        # Futures\n│   │   ├── swppv.py        # Plain Vanilla Swap\n│   │   ├── swaps.py        # Generic Swap\n│   │   ├── capfl.py        # Cap/Floor\n│   │   ├── ceg.py          # Credit Enhancement Guarantee\n│   │   ├── cec.py          # Credit Enhancement Collateral\n│   │   └── __init__.py     # Factory pattern and registry\n│   ├── exceptions.py       # Custom exceptions\n│   └── logging_config.py   # Logging configuration\n├── tests/                  # Test suite (1,200+ tests, 95%+ coverage)\n│   ├── unit/               # Unit tests for each module\n│   ├── integration/        # Integration and end-to-end tests\n│   ├── cross_validation/   # 276 official ACTUS cross-validation cases\n│   ├── property/           # Property-based tests (Hypothesis)\n│   └── performance/        # Performance benchmarks\n├── docs/                   # Documentation\n│   ├── ARCHITECTURE.md     # System architecture guide\n│   ├── PAM.md              # PAM implementation walkthrough\n│   ├── ARRAY_MODE.md       # Array-mode simulation & portfolio API\n│   └── derivatives.md      # Derivative contracts guide\n├── tools/                  # AI agent integrations\n│   ├── mcp-server/            # MCP server (18 tools for AI assistants)\n│   └── chub/                  # Context Hub agent-optimized docs\n├── skills/jactus/          # Agent Skill package\n├── examples/               # Example scripts and notebooks\n└── scripts/                # Development scripts\n```\n\n## Contributing\n\nWe welcome contributions! Please see [CONTRIBUTING.md](CONTRIBUTING.md) for guidelines.\n\n### Development Workflow\n\n1. Fork the repository\n2. Create a feature branch (`git checkout -b feature/amazing-feature`)\n3. Make your changes\n4. Run tests and quality checks (`make all`)\n5. Commit your changes (`git commit -m 'Add amazing feature'`)\n6. Push to the branch (`git push origin feature/amazing-feature`)\n7. Open a Pull Request\n\n## License\n\nThis project is licensed under the Apache License 2.0 - see the [LICENSE](LICENSE) file for details.\n\n## Citation\n\nIf you use JACTUS in your research, please cite:\n\n```bibtex\n@software{jactus,\n  title = {JACTUS: High-performance ACTUS implementation using JAX},\n  author = {Rodriguez, Pedro N.},\n  year = {2025},\n  url = {https://github.com/pedronahum/JACTUS}\n}\n```\n\n### ACTUS Standard Citation\n\n```bibtex\n@techreport{actus2020,\n  title = {ACTUS Technical Specification v1.1},\n  author = {ACTUS Financial Research Foundation},\n  year = {2020},\n  url = {https://www.actusfrf.org/}\n}\n```\n\n## Acknowledgments\n\n- [ACTUS Financial Research Foundation](https://www.actusfrf.org/) for the ACTUS standard\n- [Google JAX Team](https://github.com/google/jax) for the JAX framework\n- All contributors to this project\n\n## Project Status\n\n**Release**: v0.2.0 - Full-featured CLI + complete ACTUS v1.1 implementation ✅\n\n- ✅ 18 contract types implemented\n- ✅ 276 official ACTUS cross-validation test cases passing across all 18 contract types\n- ✅ 1,200+ unit/integration/property tests\n- ✅ Full JAX integration with automatic differentiation\n- ✅ Full-featured CLI for simulation, validation, risk analytics, and portfolio management\n- ✅ Production-ready with comprehensive documentation\n- ✅ Available on [PyPI](https://pypi.org/project/jactus/)\n- ✅ Apache License 2.0\n\n## Support\n\n- **Issues**: [GitHub Issues](https://github.com/pedronahum/JACTUS/issues)\n- **Discussions**: [GitHub Discussions](https://github.com/pedronahum/JACTUS/discussions)\n- **Email**: pnrodriguezh@gmail.com\n\n## Links\n\n- [Project Documentation](https://pedronahum.github.io/JACTUS/)\n- [PyPI Package](https://pypi.org/project/jactus/)\n- [ACTUS Standard](https://www.actusfrf.org/)\n- [JAX Documentation](https://jax.readthedocs.io/)\n- [Flax Documentation](https://flax.readthedocs.io/)\n",
  "bytes": 25786,
  "sha": "40f9c628718af03acc809836d7c973c3b07f4607422e3818259e14ce9ed9d420",
  "repo_slug": "pedronahum/jactus",
  "fonte": "repo",
  "truncated": false,
  "api": "https://agentalog.com/api/listings/plg_pedronahum_jactus_766100a2/readme"
}