Skip to content

Commit 3777f15

Browse files
committed
docu: features and intro (clearer, more structured), fixes
1 parent 1425793 commit 3777f15

File tree

9 files changed

+224
-248
lines changed

9 files changed

+224
-248
lines changed

README.md

Lines changed: 77 additions & 67 deletions
Original file line numberDiff line numberDiff line change
@@ -14,47 +14,54 @@
1414

1515
# Bigraph Framework
1616

17-
**What is Bigraph Framework?**
18-
19-
Bigraph Framework is a framework
20-
written in Java for the creation and simulation of bigraphs
21-
to foster the experimental evaluation of the bigraph theory in
22-
real-world applications.
23-
24-
The goal of this framework is to facilitate the implementation of context-aware, agent-based systems, and reactive systems in general.
25-
It provides means for model-driven software development based on the bigraph theory.
26-
The high-level Java API eases the programming of bigraphical systems for real-world application.
27-
28-
**Features**
29-
30-
- Modelling and Storage
31-
- Dynamic creation of bigraphs at design time and runtime based on the [Bigraph Ecore Metamodel (BEM)](https://github.com/bigraph-toolkit-suite/bigraphs.bigraph-ecore-metamodel)
32-
- Read and write instance models and metamodels of a bigraph from and to the file system
33-
- Visualization
34-
- Graphical export via GraphViz/DOT, PNG, Visualization of Compiler Graphs (VCG) format via yComp
35-
- Interactive visualization via GraphStream
36-
- Bigraphical Reactive Systems (BRS): Simulate the evolution of bigraphs by reaction rules
37-
- Bigraph matching and rewriting via [jLibBig](https://bigraphs.github.io/jlibbig/) with tracking support
38-
- Dedicated subhypergraph matching on link graphs only (query-data matching)
39-
- Simulation and Model Checking (BFS, DFS, Random, MatchAll, MatchFirst)
40-
- Generation of a labeled transition system (LTS)
41-
- Predicate checking and logical connectors
42-
- Specify order of reaction rules via priorities
43-
- Tracking rules (trace node identities across reactions)
44-
- Conditional rules (not yet integrated in model checking procedure but available for custom usage)
45-
- Model Importer/Exporter
46-
- Export a bigraph/LTS to common graph formats, e.g., DOT, GraphML, GXL, VCG
47-
- Export to formats of other bigraph tools: BigMC, BigraphER, BigRed, jLibBig, ...
48-
- Attributed Bigraphs
49-
- Add arbitrary attributes to nodes and links (edges and outer names)
50-
- Attributes are preserved when doing rewriting (this requires tracking maps)
51-
52-
**Requirements**
17+
Bigraph Framework is a Java framework designed for developers and researchers for building, simulating, and analyzing reactive systems (e.g., cyber-physical, context-aware, agent-based, or distributed systems, IoT environments, ...).
18+
19+
It lets you model dynamic systems with both structure (who is inside what) and connectivity (who is connected and interacting to whom), and then simulate, visualize, and verify how those systems evolve over time.
20+
21+
Under the hood, the framework is based on Milner’s theory of Bigraphical Reactive Systems (BRS).
22+
23+
### Features
24+
25+
**Bigraph Modeling and Persistence**
26+
- Create and manipulate bigraphs dynamically at **design time and runtime** using the **Bigraph Ecore Metamodel (BEM)**
27+
([bigraphs.bigraph-ecore-metamodel](https://github.com/bigraph-toolkit-suite/bigraphs.bigraph-ecore-metamodel))
28+
- Load and store both **bigraph metamodels** and **instance models** in standard file formats (Ecore/XMI)
29+
30+
**Visualization and Inspection**
31+
- Export bigraphs and transition systems to standard graph formats:
32+
**GraphViz (DOT), PNG, VCG (yComp)**
33+
- Interactive, programmatic visualization via **GraphStream** for exploring structures
34+
35+
**Bigraphical Reactive Systems (BRS)**
36+
37+
Model and analyze system dynamics using **reaction rules** and **graph rewriting**:
38+
39+
- Pattern matching and rewriting powered by **jLibBig**, with full **node and link tracking**
40+
- Specialized **link-graph (hypergraph) matching**
41+
- Multiple **simulation and model-checking strategies**:
42+
- Breadth-first search (BFS)
43+
- Depth-first search (DFS)
44+
- Random exploration
45+
- Match-all / Match-first
46+
- Automatic construction of **Labeled Transition Systems (LTS)**
47+
- **State predicates and logical connectors** for property checking
48+
- **Rule priorities** to control nondeterminism and execution order
49+
- **Tracking rules** to preserve identity of entities across reactions
50+
- **Conditional rules** for guarded rewriting
51+
52+
**Import, Export, and Tool Interoperability**
53+
- Export bigraphs and LTSs to standard graph formats:
54+
**DOT, GraphML, GXL, VCG**
55+
- Interoperate with other bigraph tools:
56+
**BigMC, BigraphER, BigRed, jLibBig**, and others
57+
58+
**Attributed Bigraphs**
59+
- Attach **arbitrary attributes** to:
60+
- Nodes
61+
- Links (edges and outer names)
62+
- Attributes are **preserved during rewriting**, enabling data-rich CPS and agent-based models
63+
(via tracking maps)
5364

54-
- Java >=21 (JDK)
55-
- Maven / Gradle
56-
- Graphviz for the `bigraph-visualization` module
57-
- Ubuntu: `sudo apt install graphviz`
5865

5966
## Getting Started
6067

@@ -178,34 +185,42 @@ composite.juxtapose(F).parallelProduct(H);
178185
179186
> See also <a href="#Building-the-Framework-from-Source">Building from Source</a> if you want to build the source by yourself and host them in your Maven local repository.
180187
188+
### Requirements
189+
190+
- Java >=21 (JDK)
191+
- Maven / Gradle
192+
- Graphviz for the `bigraph-visualization` module
193+
- Ubuntu: `sudo apt install graphviz`
194+
181195
### Maven
182196

183197
```xml
184198
<dependencies>
185-
<!-- the core module -->
199+
186200
<dependency>
187201
<groupId>org.bigraphs.framework</groupId>
188202
<artifactId>bigraph-core</artifactId>
189203
<version>2.3.4</version>
190204
</dependency>
191-
<!-- the rewriting module -->
205+
192206
<dependency>
193207
<groupId>org.bigraphs.framework</groupId>
194208
<artifactId>bigraph-simulation</artifactId>
195209
<version>2.3.4</version>
196210
</dependency>
197-
<!-- the visualization module -->
211+
198212
<dependency>
199213
<groupId>org.bigraphs.framework</groupId>
200214
<artifactId>bigraph-visualization</artifactId>
201215
<version>2.3.4</version>
202216
</dependency>
203-
<!-- the converter module -->
217+
204218
<dependency>
205219
<groupId>org.bigraphs.framework</groupId>
206220
<artifactId>bigraph-converter</artifactId>
207221
<version>2.3.4</version>
208222
</dependency>
223+
209224
</dependencies>
210225
```
211226

@@ -253,25 +268,15 @@ The example above shows how to use log4j2 in your project as the underlying logg
253268

254269
## Development
255270

256-
### Requirements
271+
### Building the Framework from Source
272+
273+
#### Requirements
257274

258275
It is not necessary to build from source to use *Bigraph Framework* but if you want to try out the latest version, the project can be easily built with the [maven wrapper](https://maven.apache.org/tools/wrapper/) or the regular `mvn` command.
259276

260277
> **Note:** The required version of Maven is >= 3.8.3 and Java JDK >=17.
261278
262-
The recommendation here is to build it with the regular `mvn` command.
263-
264-
On Debian systems you can install it by issuing the following command:
265-
266-
```shell
267-
$ sudo apt install maven
268-
```
269-
270-
See [Installation](https://maven.apache.org/install.html) for other options.
271-
272-
### Building the Framework from Source
273-
274-
**Initialize**
279+
#### Initialize
275280

276281
The following command has to be run once:
277282

@@ -283,23 +288,28 @@ These are required for the development.
283288

284289
> When using IntelliJ IDEA, make sure to "Sync All Maven Projects" again to resolve any project errors that may appear due to missing dependencies on first startup.
285290
286-
**Build/Install**
291+
#### Local Installation
287292

288-
One of the following commands must be executed from the root directory of this project:
293+
Execute the following command from the root directory of this project:
289294

290-
```bash
291-
# Default
295+
```shell
292296
$ mvn clean install -DskipTests
297+
```
298+
299+
All modules of *Bigraph Framework* have been installed in the local Maven repository.
300+
301+
After the command successfully finishes, you can now use *Bigraph Framework* in other Java projects.
293302

294-
# To create a "fat jar" for each module, run:
303+
**Build Standalone Jar**
304+
305+
If you prefer to generate standalone JARs for each module (including all dependencies), use the fatJar profile:
306+
```shell
295307
$ mvn clean install -DskipTests -PfatJar
296308
```
297309

298-
After the command successfully finishes, you can now use _Bigraph Framework_ in other Java projects.
299-
All modules of _Bigraph Framework_ have been installed in the local Maven repository.
300-
Therefore, see [Maven configuration](#maven) on how to include the individual _Bigraph Framework_ dependencies.
310+
This produces shaded ("fat") JAR files in each module's `target/` directory.
301311

302-
### Building the Documentation: User Manual
312+
### Building the Documentation
303313

304314
See [etc/Development-and-Deployment.md](./etc/Development-and-Deployment.md) for more details.
305315

documentation/v2-docusaurus/docs/basic/start.mdx

Lines changed: 15 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -13,20 +13,31 @@ import getting_started_guide_3 from '!!raw-loader!../assets/basics/getting_start
1313

1414
Discover what **Bigraph Framework** is all about and learn the core concepts behind it.
1515

16+
<details style={{ background: 'transparent' }}>
17+
<summary><strong>What are Bigraphs?</strong></summary>
18+
Bigraphs are a theory and metamodel for global ubiquitous systems,
19+
mobile computing, context-aware systems and the Internet of Things (IoT), or in general: for reactive systems.
20+
It is grounded on category theory and regarded as a unifying framework for many process calculi, including the ambient calculus, action calculi, Petri nets,
21+
the Calculus of Communicating Systems (CCS) and π-calculus.
22+
The theory provides an algebra and a graph rewriting mechanism to describe, study and analyze the dynamic behavior of reactive systems.
23+
</details>
24+
1625
## Creating a Bigraph
1726

18-
At the moment, Bigraph Framework supports only _pure bigraphs_.
27+
At the moment, Bigraph Framework supports only _pure attributed bigraphs_.
1928

2029
### Signature
2130

2231
To construct a bigraph, the first step is to define a **signature**.
23-
The signature specifies the **syntax** of the bigraph and determines which **types** (i.e., _controls_) can be used in subsequent modeling steps.
32+
The signature specifies the **syntax** of the bigraph and determines which **types** (i.e., _controls_ in bigraph-jargon) can be used in subsequent modeling steps.
2433

2534
A signature is created via a _signature builder_, which is obtained from a _pure factory_.
2635
All operations that follow are performed through this factory within the current _execution context_.
2736

2837
The entry point is the factory method `BigraphFactory.pureSignatureBuilder()`.
2938

39+
<CodeBlock className="language-java">{getting_started_guide_0}</CodeBlock>
40+
3041
:::tip
3142
Note that all examples use a static import of the `BigraphFactory` class' operations:
3243
```java
@@ -35,16 +46,15 @@ import static org.bigraphs.framework.core.factory.BigraphFactory.*;
3546
This makes access to its operations more convenient.
3647
:::
3748

38-
<CodeBlock className="language-java">{getting_started_guide_0}</CodeBlock>
39-
4049
As described above, a **signature** specifies the syntax of the bigraph to be created.
4150
In the example below, the resulting signature contains two controls:
4251

4352
- **User** with an *arity* of `1`
4453
- **Computer** with an *arity* of `2`
4554

4655
The **arity** defines how many *connections* a control can have.
47-
The semantic interpretation of “connection” is left abstract here—it may represent, for example, an **Ethernet link**, a **logical association**, or any other type of relationship between elements.
56+
The semantic interpretation of "connection" is left abstract here.
57+
It may represent, for example, an **Ethernet link**, a **logical association**, or any other type of relationship between elements.
4858

4959
:::info
5060
A more verbose form for creating controls is the following:

0 commit comments

Comments
 (0)