Graphion
Graphion is a modular and extensible Python framework for building graph-based data processing pipelines.
Instead of providing a single clustering or graph algorithm, Graphion offers reusable building blocks for constructing complete graph analytics workflows, from feature relations to graph construction, partition detection, refinement, reduction, and evaluation.
The framework is designed around interchangeable pipeline stages, allowing researchers and developers to combine different algorithms with a consistent interface.
Project status: Early development (pre-release)
Features
Graphion currently provides the following components:
Relation Builders
Build pairwise relations between feature vectors using multiple similarity and distance metrics.
Implemented metrics include:
- Cosine Similarity
- Dot Product
- Pearson Correlation
- Angular Similarity
- Euclidean Distance
- Manhattan Distance
- Chebyshev Distance
- Minkowski Distance
- Canberra Distance
- Bray-Curtis Distance
- Hamming Distance
- Jaccard Similarity
- Weighted Jaccard
- Dice Similarity
- Overlap Coefficient
- Tanimoto Similarity
- RBF Similarity
Graph Builders
Construct graphs from pairwise relations using multiple strategies.
Implemented builders include:
- Threshold Graph
- Radius Graph
- k-Nearest Neighbors (kNN)
- Mutual kNN
- Symmetric kNN
- Weighted kNN
- Adaptive kNN
- kNN + Threshold
- Shared Nearest Neighbor (SNN)
- Relative Neighborhood Graph (RNG)
- Minimum Spanning Tree (MST)
Graph Refiners
Graph transformation stages.
Currently available:
- Identity Refiner
Partition Detectors
Detect graph communities using interchangeable algorithms.
Implemented algorithms include:
- Connected Components
- Leiden
- Louvain
- Label Propagation
- Walktrap
- Fast Greedy
- Girvan-Newman
- Spectral Clustering
- Agglomerative Clustering
- Infomap
- Identity
Partition Refiners
Post-process detected communities.
Currently available:
- Identity Refiner
Reducers
Dimensionality reduction modules.
Implemented reducers:
- PCA
- Truncated SVD
- Random Projection
- UMAP
- t-SNE
- Isomap
- Autoencoder
- Identity
Evaluation
Built-in evaluation utilities for:
- Feature sets
- Graphs
- Partition sets
- Feature partitions
Design Principles
Graphion is designed around several core principles:
- Modular architecture
- Consistent interfaces
- Pluggable algorithms
- Strong typing
- Clear separation of responsibilities
- Pipeline-oriented execution
- Easy extensibility
Every processing stage follows a common execution interface, making it straightforward to replace one algorithm with another.
Project Structure
Graphion/
│
├── builders/
│ ├── relation/
│ └── graph/
│
├── reducers/
│
├── refiners/
│ ├── graph/
│ └── partition/
│
├── detectors/
│ └── partition/
│
├── evaluation/
│
└── core/
├── interfaces/
├── models/
├── results/
├── errors/
└── types.py
Installation
Graphion is currently under active development.
Clone the repository:
git clone https://github.com/sahrayi/Graphion.git
Install in editable mode:
pip install -e .
Roadmap
Planned features include:
- Additional graph construction algorithms
- More community detection methods
- Hierarchical partition refinement
- Graph embedding modules
- Visualization utilities
- Benchmark suite
- Documentation website
- Comprehensive test coverage
Related Projects
Graphion serves as the foundation for higher-level graph analytics libraries.
For example:
- GraphTopic (graph-based topic discovery)
License
MIT License
Metadata
Release files for graphion 0.0.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| graphion-0.0.2.tar.gz | 60.3 kB | Without provenance | Details for graphion-0.0.2.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| graphion-0.0.2-py3-none-any.whl | Python 3 | none | any | Details for graphion-0.0.2-py3-none-any.whl |
Total release size: 158.4 kB
Release files / graphion-0.0.2.tar.gz
| Download URL | graphion-0.0.2.tar.gz |
|---|---|
| Size | 60.3 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
5af24f6fabbb3a76fa66186f5562d3310ddf35ba113522244c21fd94180486b5
|
|
BLAKE2b-256 checksum How to use checksums |
4c0e3c272671b2d921aa787495faa96c6b97b69797a2abf8a75735f6848309e3
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.6
|
Release files / graphion-0.0.2-py3-none-any.whl
| Download URL | graphion-0.0.2-py3-none-any.whl |
|---|---|
| Size | 98.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
7bd3a8a52ac07ce77c0804ce1ed6242f29f6eee2b994203fed866f97ae3f7e7c
|
|
BLAKE2b-256 checksum How to use checksums |
775ef31973f037120082d0c4c061558ccd5902700a1677e71f020186a33a781f
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/7.0.0 CPython/3.14.6
|
Security for graphion 0.0.2
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.