Skip to main content

Open-source tool to migrate IBM Cognos reports and models to Microsoft Power BI (PBIP / TMDL / PBIR) with AI assistance.

Project description

Cognos to Power BI Migration Tool

Migrate IBM Cognos reports and models to Microsoft Power BI automatically. An open-source, AI-assisted migration engine that converts Cognos report specifications into Power BI Project (PBIP) format using TMDL semantic models and PBIR report definitions.

CI License: MIT Python 3.10+ PRs Welcome


What this project does

Organizations moving from IBM Cognos Analytics to Microsoft Power BI face a slow, manual, error-prone migration. This tool automates the heavy lifting:

  1. Parse Cognos report specification XML, Framework Manager models, and data modules.
  2. Normalize them into a vendor-neutral intermediate representation (IR).
  3. Generate Power BI Project (PBIP) output — TMDL semantic models and PBIR reports.
  4. Refine the output with an AI assistant (Claude, GitHub Copilot, or Codex) to translate expressions, layouts, and visuals that have no direct mechanical mapping.

The result is a Git-friendly Power BI project you can open in Power BI Desktop, review, and deploy to the Power BI / Microsoft Fabric service.

Why use it

  • Faster migrations. Convert hundreds of reports in a fraction of the manual time.
  • Consistent output. Deterministic, reviewable PBIP artifacts instead of hand-rebuilt reports.
  • AI-assisted, not AI-dependent. The mechanical conversion works without any AI key; AI only refines what cannot be mapped deterministically.
  • Provider-agnostic AI. Use Claude Code CLI, GitHub Copilot CLI, or OpenAI Codex CLI.
  • Open and extensible. MIT-licensed, plugin-friendly parsers and generators.

Supported conversions

Cognos source Power BI target Status
Report specification (Report Studio XML) PBIR report + TMDL tables Available (beta)
Queries and data items TMDL columns and measures Available (beta)
Framework Manager model (.cpf / FM XML) TMDL semantic model In progress
Data Modules TMDL semantic model In progress
Dashboards PBIR report pages Planned

See the migration coverage matrix for detail on expressions, filters, and visual types.

Quick start

# Install
pip install cognos2powerbi

# Convert a single Cognos report specification to a Power BI project
cognos2pbi migrate ./examples/sample_report.xml --out ./out/SalesReport

# Point the generated model at your database (refreshable PBIP)
cognos2pbi migrate ./examples/sample_report.xml --out ./out/SalesReport \
  --server sql01.contoso.com --database Sales

# Convert a Cognos Framework Manager model to a Power BI semantic model
cognos2pbi migrate-model ./examples/sample_model.xml --out ./out/SalesModel

# Open the generated project
#   ./out/SalesReport/SalesReport.pbip   ->  open in Power BI Desktop

Run from source instead:

git clone https://github.com/navintkr/cognos-to-powerbi.git
cd cognos-to-powerbi
pip install -e ".[dev]"
cognos2pbi migrate ./examples/sample_report.xml --out ./out/SalesReport

AI-assisted refinement (optional)

Enable an AI provider to translate complex Cognos expressions and layouts into Power BI DAX and PBIR visuals. The provider is selected by configuration and shells out to the corresponding CLI.

# Claude Code CLI (default)
cognos2pbi migrate ./report.xml --out ./out/Report --ai claude

# GitHub Copilot CLI
cognos2pbi migrate ./report.xml --out ./out/Report --ai copilot

# OpenAI Codex CLI
cognos2pbi migrate ./report.xml --out ./out/Report --ai codex

If no AI provider is configured, the tool completes a deterministic conversion and flags items that need manual review. See docs/ai-providers.md.

How it works

flowchart LR
    A[Cognos artifacts<br/>report XML, FM model, data module] --> B[Parsers]
    B --> C[Intermediate Representation<br/>vendor-neutral IR]
    C --> D[PBIP Generators<br/>TMDL + PBIR]
    D --> E[AI Refinement<br/>Claude / Copilot / Codex]
    E --> F[Power BI Project<br/>.pbip]

The intermediate representation decouples parsing from generation, so new Cognos inputs and new Power BI output formats can be added independently. See docs/architecture.md.

Project layout

cognos-to-powerbi/
├── src/cognos2powerbi/
│   ├── cli.py                 # Command-line interface
│   ├── core/
│   │   ├── ir/                # Vendor-neutral intermediate representation
│   │   ├── parsers/           # Cognos report/model parsers
│   │   ├── generators/        # PBIP (TMDL + PBIR) generators
│   │   ├── translate/         # Deterministic Cognos-to-DAX translation
│   │   ├── ai/                # Provider-agnostic AI adapter
│   │   └── pipeline.py        # Orchestration
│   └── api/                   # FastAPI backend (SaaS surface)
├── web/                       # Single-page web frontend
├── examples/                  # Sample Cognos inputs
├── docs/                      # Documentation
└── tests/                     # Test suite

Run the SaaS API locally

pip install -e ".[api]"
uvicorn cognos2powerbi.api.main:app --reload
# Open the web UI at http://127.0.0.1:8000/
# Or POST a Cognos report to http://127.0.0.1:8000/api/v1/migrate

Roadmap

  • Framework Manager model conversion to TMDL
  • Data Module conversion
  • Dashboard to PBIR page mapping
  • Expression translation library (Cognos -> DAX)
  • Hosted SaaS portal with upload, review, and download
  • Batch / folder migration with a coverage report

Full roadmap: docs/roadmap.md.

Contributing

Contributions are welcome and wanted. Good first issues are labeled good first issue. Read CONTRIBUTING.md and the Code of Conduct to get started.

Security

Report vulnerabilities privately per our security policy. Do not open public issues for security reports.

License

Licensed under the MIT License.


Keywords

Cognos to Power BI, Cognos Power BI migration, IBM Cognos migration tool, convert Cognos reports to Power BI, Cognos report converter, Power BI PBIP TMDL PBIR generator, business intelligence migration, automated report migration.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

cognos2powerbi-0.1.0.tar.gz (36.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

cognos2powerbi-0.1.0-py3-none-any.whl (29.1 kB view details)

Uploaded Python 3

File details

Details for the file cognos2powerbi-0.1.0.tar.gz.

File metadata

  • Download URL: cognos2powerbi-0.1.0.tar.gz
  • Upload date:
  • Size: 36.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for cognos2powerbi-0.1.0.tar.gz
Algorithm Hash digest
SHA256 93269fc921567ec1675514675671e7a7de0a9c740841dd1e0032aa77fcf214d9
MD5 8f8bf402e59fb07de777835d3e7b9749
BLAKE2b-256 d783c60acb15faddd7063765970ca78e1225bd1ec646d79dc1cbd82315f545d7

See more details on using hashes here.

Provenance

The following attestation bundles were made for cognos2powerbi-0.1.0.tar.gz:

Publisher: publish.yml on navintkr/cognos-to-powerbi

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file cognos2powerbi-0.1.0-py3-none-any.whl.

File metadata

  • Download URL: cognos2powerbi-0.1.0-py3-none-any.whl
  • Upload date:
  • Size: 29.1 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for cognos2powerbi-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 c80ccb885196d7f16457b9aaf7cd87188cb6251628d349bb94d51093f3480418
MD5 c2974db3f9241fae729bc2bb70e0319a
BLAKE2b-256 9b202b9984ea59f864ef0a25cd84f3e829c94d58a20cafc878a284a4496a10f5

See more details on using hashes here.

Provenance

The following attestation bundles were made for cognos2powerbi-0.1.0-py3-none-any.whl:

Publisher: publish.yml on navintkr/cognos-to-powerbi

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page