Skip to main content

cadis-global

cadis-global is the public orchestration layer for:

  1. world-level resolution (country or terminal world state)
  2. bundled CGD dataset loading
  3. runtime dispatch via cadis-runtime

Scope (v0.1.0)

  • Uses cadis-runtime as admin execution engine.
  • Ships with bundled ne.global.v0.1.0.cgd.
  • Supports only explicitly configured/known ISO2 datasets (TW, JP by default).
  • Returns deterministic partial or failed envelopes for unsupported/missing/error paths.

Install

pip install cadis-global

Public API

Bundled CGD world dataset mode (default):

from cadis_global import GlobalLookup

lookup = GlobalLookup.from_defaults(
    cache_dir="/tmp/cadis-cache",
    update_to_latest=False,
)

result = lookup.lookup(25.0330, 121.5654)

Custom local CGD override:

from pathlib import Path
from cadis_global import GlobalLookup

lookup = GlobalLookup.from_defaults(
    cgd_path=Path("/path/to/custom/ne.global.v0.1.0.cgd"),
    cache_dir=Path("/tmp/cadis-cache"),
    update_to_latest=False,
)

result = lookup.lookup(25.0330, 121.5654)

Notes:

  • "cgd" mode uses bundled ne.global.v0.1.0.cgd by default.
  • Set cgd_path to override the bundled dataset with a custom local CGD file.
  • CGD binary spec lives at cadis_global/data/CGD_SPEC.md.
  • Current bundled dataset/spec uses float32 coordinates (bbox + geometry points).
  • Custom CGD files must follow the same float32 layout expected by this runtime.

Envelope contract:

{
  "lookup_status": "ok|partial|failed",
  "engine": "cadis-global",
  "version": "0.1.0",
  "reason": "nullable status reason",
  "world_context": {"...": "world resolver payload"},
  "admin_result": {"...": "raw cadis-runtime payload or null"}
}

Execution flow

  1. Resolve world country/terminal state (open_sea, antarctica, no_sovereign_land).
  2. If terminal: return world-only result (admin_result = null).
  3. If country found: bootstrap/cache runtime for ISO2.
  4. Execute runtime.lookup(lat, lon).
  5. Return unified envelope with world_context + untouched admin_result.

Runtime bootstrap note:

  • Country runtime bootstrap is lazy per ISO2 and may trigger on-demand CDN download on first country hit.
  • First lookup latency for an ISO2 can increase while bootstrap/download is in progress.
  • If bootstrap/download cannot complete, result is deterministic partial with reason such as missing_dataset or runtime_bootstrap_error.

Status semantics

  • ok: world resolution succeeded; runtime either not needed (terminal) or returned a valid payload.
  • partial: world resolution succeeded but admin runtime could not return a valid payload.
  • failed: world resolution failed before runtime dispatch.

Common reason values for partial:

  • unsupported_country_dataset
  • missing_dataset
  • runtime_bootstrap_error
  • runtime_dispatch_error
  • runtime_invalid_response
  • admin_interpretation_unavailable

Package boundaries

  • cadis-global: orchestration/bootstrap/world routing.
  • cadis-runtime: deterministic dataset interpreter only.
  • cadis-core / cadis-cdn: internal-by-contract components.

Distribution note

  • cadis-global-dataset tooling is internal and not published to GitHub.
  • The built global dataset artifact (for example ne.global.v0.1.0.cgd) is distributed alongside cadis-global.
  • Bundled dataset ne.global.v0.1.0.cgd is approximately 12 MB (uncompressed package content).

Metadata

Release files for cadis-global 0.1.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for cadis-global 0.1.0
File Size Uploaded Provenance Actions
cadis_global-0.1.0.tar.gz 8.9 MB Without provenance Details for cadis_global-0.1.0.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for cadis-global 0.1.0
File Interpreter ABI Platform Actions
cadis_global-0.1.0-py3-none-any.whl Python 3 none any Details for cadis_global-0.1.0-py3-none-any.whl

Total release size: 17.8 MB

Release files / cadis_global-0.1.0.tar.gz

Download URL cadis_global-0.1.0.tar.gz
Size 8.9 MB
Tags Source
SHA-256 checksum
How to use checksums
b76d2c8834de193c3185347ccdcfb50e2d9e5600333c035dbd536e044eb9e2d4
BLAKE2b-256 checksum
How to use checksums
0cfb3868aea62da2d0c182e247efd3d14b8103fef2c57d58bf1b059d84e24c89
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.11

Release files / cadis_global-0.1.0-py3-none-any.whl

Download URL cadis_global-0.1.0-py3-none-any.whl
Size 8.9 MB
Tags Python 3
SHA-256 checksum
How to use checksums
dd1ccab8bb9945f589f3114beee3a639a40ba996f4e9a861b90478ca13490d36
BLAKE2b-256 checksum
How to use checksums
72fb84f89a67193fb307e51f8fcfb1e1e939eace180a694d52fb32226b853b54
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.11

Security for cadis-global 0.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.1.0 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page