A library to create & manage Archimate files
Project description
pyArchimate package
Documentation: readthedocs.org
pyArchimate is a Python library for programmatically reading, writing, and manipulating Open Group ArchiMate enterprise architecture models. It has no GUI — it is purely a file I/O and object model library designed for batch and scripting use.
Core concepts
| Object | What it represents |
|---|---|
Model |
Top-level container for everything |
Element |
An architectural concept (business process, application, server, capability…) |
Relationship |
A typed link between two elements (Association, Realization, Composition, Flow…) |
View |
A diagram — a named subset of elements/relationships laid out visually |
Node |
The visual box representing an element inside a view |
Connection |
The visual arrow representing a relationship inside a view |
Elements span the full ArchiMate 3 layer stack: Strategy, Motivation, Business, Application, Technology, Physical, and Implementation.
Supported formats
| Format | Read | Write |
|---|---|---|
| ArchiMate Open Exchange XML | yes | yes |
| Archi tool format (.archimate) | yes | yes |
| CSV | — | yes |
Key operations
- Read / Write / Merge — load one or more files and save to any supported format
- Create & modify — add elements, relationships, and views via the API without touching a file
- Filter — extract subsets of elements, relationships, or views by custom predicates
- Style — set colours, coordinates, dimensions, and text layout on nodes
- Validate — check for broken references and invalid connections
- Auto-Layout — automatically arrange view elements using force-directed or hierarchical algorithms
- Auto-Format — standardize element sizes, fonts, and alignment per ArchiMate conventions
- SVG Export — render views as self-contained SVG with ArchiMate symbols and standard colors
Auto-Layout and Auto-Format (BETA)
⚠️ Status: BETA — Core functionality is stable and production-ready for typical use cases. API may evolve based on user feedback.
Quick Start
from pyArchimate.view import load_view, save_view
from pyArchimate.view.layout import apply_layout, apply_format, LayoutConfig
# Load a view
view = load_view("architecture.archimate")
# Apply automatic layout
result = apply_layout(view)
# Or apply formatting only (without repositioning)
result = apply_format(view)
# Export as SVG
svg = view.to_svg(filepath="diagram.svg")
# Save the laid-out view
save_view(view, "laid_out.archimate")
Features
- Two layout algorithms: Force-directed (general-purpose) and hierarchical (organizational structures)
- Respect ArchiMate layers: Business → Application → Technology ordering enforced
- Connection routing: Orthogonal polylines with intelligent label placement
- SVG export: Self-contained SVG with all 30+ ArchiMate element types and standard colors
- Undo/rollback: Revert layout changes with
undo_layout(view) - Configuration: Customize spacing, margins, alignment, element exclusion, and routing style
Performance
| View Size | Force-Directed | Hierarchical |
|---|---|---|
| 100 elements | <200ms | <50ms |
| 300 elements | <2s | <500ms |
| 500 elements | <5s | <1s |
Learn More
Limitations
- No GUI, no diagram renderer
- Not designed for interactive or real-time use — batch/scripting oriented
Documentation
- AI.md — machine-readable reference for AI-assisted tooling and developer onboarding
- Tutorial — step-by-step guide for new users with runnable code examples
ArchiMate v3.x Compliance
pyArchimate now supports ArchiMate 3.x specification compliance with the following features:
Supported Features
- ✅ BusinessInteraction elements: Full support for creating, importing, and exporting BusinessInteraction elements
- ✅ Influence strength metadata: Complete round-trip preservation of influence relationship strength (both
.archimateand OpenGroup formats) - ✅ Relationship documentation: Full preservation of relationship documentation/description text during import and export
Known Gaps
See Gap Analysis Documentation for detailed analysis of specification alignment and areas for future enhancement (P2/P3).
Metamodel
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file pyarchimate-1.10.0.tar.gz.
File metadata
- Download URL: pyarchimate-1.10.0.tar.gz
- Upload date:
- Size: 156.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
8cc73e542e7dde8f25dcc479e6f725d269ee85998aa8a6be2698183e2d9888e5
|
|
| MD5 |
066bde7b4793ea7ca63f3c0b53fb9084
|
|
| BLAKE2b-256 |
5fd9a0b9f6d127bbbc1e9f95e10c2bb874e393f4c6da35ca3b1bfc5b03f4c35b
|
Provenance
The following attestation bundles were made for pyarchimate-1.10.0.tar.gz:
Publisher:
release.yml on pyArchimate/pyArchimate
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
pyarchimate-1.10.0.tar.gz -
Subject digest:
8cc73e542e7dde8f25dcc479e6f725d269ee85998aa8a6be2698183e2d9888e5 - Sigstore transparency entry: 1557019053
- Sigstore integration time:
-
Permalink:
pyArchimate/pyArchimate@dccb4c876576b0bbd2fade78237ce0a608ddf522 -
Branch / Tag:
refs/tags/v1.10.0 - Owner: https://github.com/pyArchimate
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@dccb4c876576b0bbd2fade78237ce0a608ddf522 -
Trigger Event:
push
-
Statement type:
File details
Details for the file pyarchimate-1.10.0-py3-none-any.whl.
File metadata
- Download URL: pyarchimate-1.10.0-py3-none-any.whl
- Upload date:
- Size: 172.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.12
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
250b8ef440cae51ee843a9f9fbc2485a5a2dcab9b61b4a1f3e57706a0dfa4053
|
|
| MD5 |
d3569131325489bc2a23797123352de1
|
|
| BLAKE2b-256 |
1965b22f23bc749a124f2b0d83534d9cc0c643f97d049ac27ae0a78e5863598a
|
Provenance
The following attestation bundles were made for pyarchimate-1.10.0-py3-none-any.whl:
Publisher:
release.yml on pyArchimate/pyArchimate
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
pyarchimate-1.10.0-py3-none-any.whl -
Subject digest:
250b8ef440cae51ee843a9f9fbc2485a5a2dcab9b61b4a1f3e57706a0dfa4053 - Sigstore transparency entry: 1557019222
- Sigstore integration time:
-
Permalink:
pyArchimate/pyArchimate@dccb4c876576b0bbd2fade78237ce0a608ddf522 -
Branch / Tag:
refs/tags/v1.10.0 - Owner: https://github.com/pyArchimate
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@dccb4c876576b0bbd2fade78237ce0a608ddf522 -
Trigger Event:
push
-
Statement type: