{ "cells": [ { "cell_type": "markdown", "id": "f5927379-ee39-47c4-b92c-c19f74bded5d", "metadata": {}, "source": [ "## Drawing CHADA tables as a plantuml json diagram from a single json or yaml file" ] }, { "cell_type": "markdown", "id": "b0e67204-18a2-4a3f-a5f4-ff0b89d4c50f", "metadata": {}, "source": [ "In this example we will see how to use convenience functions in `mochada_kit/tables` to help us draw [plantuml json diagrams](https://plantuml.com/json) showing CHADA tables from a single [json](https://en.wikipedia.org/wiki/JSON) or [yaml](https://en.wikipedia.org/wiki/YAML) file as input." ] }, { "cell_type": "markdown", "id": "9b4dfbe5-e7ce-4327-a9d0-9e94cf3fccdd", "metadata": {}, "source": [ "#### 1. Why should we do this?" ] }, { "cell_type": "markdown", "id": "f8256c2a-bab4-4da5-a381-20e6f7f936bb", "metadata": {}, "source": [ "- CHADA tables can be prepared using a word processor (*e.g.* LibreOffice Writer or Microsoft Word). Any formatting can be applied and we can export the resulting document as a pdf. We could even make a template using whatever colour scheme we choose, in order to speed up the process.\n", "- Both the LibreOffice Open Document Text (.odt) and Microsoft Word (.docx) formats are now openly described and have ISO standards. This means that they are both machine readable. This is desirable for interaction between CHADA tables and the development of ontologies.\n", "\n", "**OK, so why should we draw CHADA tables with plantuml from json/yaml?**\n", "\n", "1. [json](https://en.wikipedia.org/wiki/JSON) and [yaml](https://en.wikipedia.org/wiki/YAML) are very simple text file formats, which are arguably easier to parse than .odt or .docx. This may simplify the interaction with ontology development. `json` is very well established for data exchange but has a slightly more complex structure than `yaml`, which is designed to be easy to read and write for humans.\n", "2. using the functions in `mochada_kit/tables` we can:\n", " - apply a theme to the json diagram so that the appearance of the tables is similar to our workflow diagram\n", " - make an overview of all tables joined to a \"contents\" element\n", " - make several diagrams in which one of the main tables is joined to the \"contents\" element and the diagram contains hyperlinks so that you can easily switch between different tables. This extra interactivity may be more attractive for data repositories rather than a static pdf or document format.\n", " - make individual tables without a \"contents\" element to insert into a document report. There is a dedicated theme for this where the `MaximumWidth` parameter for json diagrams has been increased to fit the table better to the width of A4 paper.\n", " \n", "Let's have a look at these options. \n", "\n", "First, we import the necessary modules:" ] }, { "cell_type": "code", "execution_count": 1, "id": "dde4a042-f6a8-412f-a2cb-d40d41c72a57", "metadata": {}, "outputs": [], "source": [ "import pathlib\n", "\n", "import mochada_kit.running as mr\n", "import mochada_kit.tables as mt" ] }, { "cell_type": "markdown", "id": "96bf2dee-a4bb-4311-bb75-acbe611f8b1c", "metadata": {}, "source": [ "
\n", "\n", "#### 2. Plotting all CHADA tables joined to a contents element" ] }, { "cell_type": "markdown", "id": "bd045d29-d895-454e-962b-39d7d3e24b27", "metadata": {}, "source": [ "**2a Templates**\n", "\n", "The folder `mochada_kit/templates` contains `json` and equivalent `yaml` files as templates for the CHADA tables. The files `chada_tables_template.json` and `chada_tables_template.yaml` contain all the headings in the tables but only empty strings for the content. The files `chada_tables_template_tips.json` and `chada_tables_template_tips.yaml` contain all the headings in the tables and for each heading there is some text giving tips about how to fill in the content. Whether you choose to start from a `json` file or a `yaml` file, `mochada_kit` will plot the tables into a [plantuml json diagram](https://plantuml.com/json). Let's see how to do this." ] }, { "cell_type": "markdown", "id": "8c9ca3a4-8d2c-40ea-a9b8-5bf246572d95", "metadata": {}, "source": [ "


\n", "\n", "**2b Saving and Loading**\n", "\n", "We shall use the function `mochada_kit.tables.write_chada_tables_whole_plantuml()`, which writes plantuml code for a json diagram consisting of a contents element showing the names of all the CHADA tables, joined to elements showing each of the tables. For all options, please see the docstring of the function in `mochada_kit/tables.py`.\n", "\n", "We will supply some arguments to the function as follows:\n", "\n", "- the first argument (`data_path`) must be the path to a `json` or `yaml` file containing the data to be plotted. Supply either a string or a pathlib.Path\n", "- to save the plantuml code file in a *different* folder to the `json`/`yaml` source file, we need to supply the argument `out_path`, which points to the folder where we want to store the plantuml code, either as an absolute or relative path (either as a string or a pathlib.Path). If a relative path is supplied, it is assumed to be relative to the parent folder of data_path.\n", "- with a json source file we have two options:\n", " 1) we can supply the argument `load_path` as a path, and the json data will be loaded dynamically, or\n", " 2) we can supply `load_path=None` and the json data will be written into the puml code.\n", "\n", "


\n", "\n", "For a `json` source file, these various options are summarised in the table below:\n", "\n", "|out_path      |load_path      |Result     |\n", "|:---|:---|:---|\n", "|None | None | puml code and json are in the same folder, json data written into puml code (*i.e.* not loaded dynamically)|\n", "|None | path | puml code and json are in the same folder, json data loaded dynamically|\n", "|path | path | puml code and json are in different folders, json data loaded dynamically|\n", "|path | None | puml code and json are in different folders, json data written into puml code (*i.e.* not loaded dynamically)|\n", "\n", "


\n", "\n", "With a `yaml` source file, load_path is ignored and the data are always written into the puml code:\n", "\n", "|out_path      |load_path      |Result     |\n", "|:---|:---|:---|\n", "|None | None | puml code and yaml are in the same folder, yaml data written into puml code (*i.e.* not loaded dynamically)|\n", "|path | None | puml code and yaml are in different folders, yaml data written into puml code (*i.e.* not loaded dynamically)|\n", "\n", "


\n", "\n", "The differences between the three arguments as absolute and relative paths is emphasised in the table below:\n", "\n", "|Argument      |Absolute Path      |Relative Path      |\n", "|:---|:---|:---|\n", "|data_path | full path to .json/.yaml | path to .json/.yaml relative to the current working directory |\n", "|out_path | full path to the output puml code (.puml) | path to output .puml relative to the parent folder of data_path|\n", "|load_path | full path to .json/.yaml | path to .json/.yaml relative to out_path |" ] }, { "cell_type": "markdown", "id": "4f200928-1385-45d9-b5d1-5bbec49b3b40", "metadata": {}, "source": [ "


\n", "\n", "- In this notebook, we will use a `json` source file but all the functions in `mochada_kit.tables` work with `yaml` source data too - simply set the argument data_path to point to a `yaml` file.\n", "\n", "- As we are going to store all the examples in `mochada_kit/gallery/puml_code` and we want the examples to run on any machine, we use relative paths like this:" ] }, { "cell_type": "code", "execution_count": 2, "id": "1fa954fe-0506-4fa4-9896-07cff26d4ea7", "metadata": {}, "outputs": [], "source": [ "data_path = pathlib.Path(\n", " \"../../templates/chada_tables_template_tips.json\"\n", ") # path to the json/yaml relative to the current working directory\n", "\n", "out_path = pathlib.Path(\n", " \"../../gallery/puml_code\"\n", ") # path to the folder where the output puml code is stored (relative to the parent folder of data_path)\n", "\n", "load_path = pathlib.Path(\n", " \"../../templates/chada_tables_template_tips.json\"\n", ") # relative path from out_path to data_path" ] }, { "cell_type": "markdown", "id": "7e088b31-819b-4a93-b43c-3f004227fc1b", "metadata": {}, "source": [ "


\n", "\n", "**2c Names**\n", "\n", "- By default, the name of the puml code output file will be the same as that of the `json`/`yaml` input file.\n", "- If you would like a diffrent name, you can supply the `out_name` argument as a string of your choice. This only the filename *without* an extension and is not a path." ] }, { "cell_type": "code", "execution_count": 3, "id": "cba6bf7f-3caa-4538-a71d-5e6f06804618", "metadata": {}, "outputs": [], "source": [ "out_name = \"chada_tables_template_tips_all\"" ] }, { "cell_type": "markdown", "id": "d789d1d5-10d8-496d-9964-e50b1a4afb8a", "metadata": {}, "source": [ "


\n", "\n", "**2d Themes and formatting**\n", "\n", "- as default, the theme `MOCHADA-plasma` will be applied to the tables. If we want to change this, we can supply the name of another theme *e.g.* `theme_name=\"viridis\"` (only the part of the theme name after \"puml-theme-MOCHADA-\" and before \".puml\" is needed).\n", "- for all the MOCHADA themes created by `mochada_kit/examples/generating_mochada_themes.ipynb`, the MaximumWidth parameter, which controls text wrapping in json diagrams, is set to 300. This is a good default if you don't want the elements to be too wide *e.g.* when there are several layers of data. For some applications, you may want the elements to be wider and for this reason two extra themes have been manually generated. These are:\n", " - `MOCAHDA-plasma_A4w`, where MaximumWidth=400, which is suitable for fitting a single json element onto an A4 page\n", " - `MOCHADA-plasma_wide`, where MaximumWidth=600, which is suitable for fitting a single json element onto a wide screen/computer monitor\n", " \n", "Let's apply `MOCHADA-plasma_wide` here by supplying the parameter `theme_name`:" ] }, { "cell_type": "code", "execution_count": 4, "id": "20df31f7-a24b-45f6-a5e9-5996d268334b", "metadata": {}, "outputs": [], "source": [ "# writes code for a single diagram showing all 5 tables joined to a contents element\n", "\n", "mt.write_chada_tables_whole_plantuml(\n", " data_path,\n", " out_path=out_path,\n", " load_path=load_path,\n", " out_name=out_name,\n", " theme_name=\"plasma_wide\",\n", ")" ] }, { "cell_type": "markdown", "id": "f7694b1d-f86d-4971-a011-6c44390658ea", "metadata": {}, "source": [ "


\n", "\n", "**2e Running the code to generate a diagram**" ] }, { "cell_type": "markdown", "id": "c85abb90-c02d-478d-a0b7-bbbdf52d2ea9", "metadata": {}, "source": [ "Having written the puml code for the diagram, we can now run it to generate the diagram. We can get the path to the stem of the output file (*i.e.* without the extension) using the function `mochada_kit.tables.handle_paths()` with out defined paths, **and** the option `return_out_base_only=True`." ] }, { "cell_type": "code", "execution_count": 5, "id": "9bffd974-91f4-4cf3-be75-74c9f1fbbd0a", "metadata": {}, "outputs": [], "source": [ "out_base = mt.handle_paths(\n", " data_path,\n", " out_path=out_path,\n", " load_path=load_path,\n", " out_name=out_name,\n", " return_out_base_only=True,\n", ")" ] }, { "cell_type": "markdown", "id": "531f4428-1c9f-4d85-b2cd-176ce71a4414", "metadata": {}, "source": [ "Then we can run the diagram and store it in the `gallery`:" ] }, { "cell_type": "code", "execution_count": 6, "id": "7d5a597c-dfc4-4fab-867b-547cb5902a54", "metadata": {}, "outputs": [], "source": [ "mr.run_plantuml_code(\n", " pathlib.Path(str(out_base) + \".puml\"), output_dir=pathlib.Path(\"../\")\n", ")" ] }, { "cell_type": "markdown", "id": "1d39f543-5b4d-473a-b45a-587e5fb389d7", "metadata": {}, "source": [ "Here's the diagram:\n", "\n", "" ] }, { "cell_type": "markdown", "id": "72d94ef5-98b9-4d56-a356-579a8edd01af", "metadata": {}, "source": [ "


\n", "\n", "#### 3. Plotting one CHADA table joined to a contents element with hyperlinks to the other tables" ] }, { "cell_type": "markdown", "id": "ea9fb4d5-6e3c-41b1-bb37-f8ec9e779b09", "metadata": {}, "source": [ "Here we use the function `mochada_kit.tables.write_chada_tables_plantuml()` with similar arguments to the case above. Hyperlinks are included by default. If we want to make the diagrams without hyperlinks, we can supply `linked=False` to the function." ] }, { "cell_type": "markdown", "id": "a60f5001-aa80-4903-ad0d-d96b72424b46", "metadata": {}, "source": [ "In this case, 5 different puml code files will be generated (for the tables `overview`, `user_case`, `experiment`, `raw_data` and `data_processing`) and a suffix *e.g.* \"_overview.puml\" will be added to the name specified below:" ] }, { "cell_type": "code", "execution_count": 7, "id": "20e98276-cac0-4b54-b2d2-75e7908b3b1b", "metadata": {}, "outputs": [], "source": [ "out_name_2 = \"chada_tables_template_tips\"" ] }, { "cell_type": "code", "execution_count": 8, "id": "8e5a2b94-fbb8-423c-b3b8-fe298bd705c0", "metadata": {}, "outputs": [], "source": [ "# writes code for 5 different diagrams with hyperlinks on a contents element\n", "\n", "mt.write_chada_tables_plantuml(\n", " data_path, out_path=out_path, load_path=load_path, out_name=out_name_2\n", ")" ] }, { "cell_type": "code", "execution_count": 9, "id": "6078bc4d-a031-4466-89c7-7b4133022a5d", "metadata": {}, "outputs": [], "source": [ "out_base_2 = mt.handle_paths(\n", " data_path,\n", " out_path=out_path,\n", " load_path=load_path,\n", " out_name=out_name_2,\n", " return_out_base_only=True,\n", ")" ] }, { "cell_type": "markdown", "id": "bc45874a-c00f-4c61-be03-d5de00ef6080", "metadata": {}, "source": [ "Now we can run each diagram in turn:" ] }, { "cell_type": "code", "execution_count": 10, "id": "0e043b10-8bc9-4445-9ae0-1dfd02eaac71", "metadata": {}, "outputs": [], "source": [ "for i in [\"overview\", \"user_case\", \"experiment\", \"raw_data\", \"data_processing\"]:\n", " mr.run_plantuml_code(\n", " pathlib.Path(str(out_base_2) + f\"_{i}.puml\"), output_dir=pathlib.Path(\"../\")\n", " )" ] }, { "cell_type": "markdown", "id": "e052c287-fdbd-4238-bb07-71e84ff9e25d", "metadata": {}, "source": [ "Here's the \"experiment\" diagram as an example:\n", "\n", "" ] }, { "cell_type": "markdown", "id": "3d4c3aae-b16b-431f-974f-da260e729db6", "metadata": {}, "source": [ "This time, we used the standard `plasma` theme, rather than `plasma_wide` and therefore the json elements appear narrower than in the first diagram. " ] }, { "cell_type": "markdown", "id": "f4b9ef37-0aca-44dc-9e7c-eae2e326b0c2", "metadata": {}, "source": [ "
\n", "\n", "Note\n", "\n", "We can see that the \"contents\" element contains hyperlinks. These don't work when embedded in a jupyter notebook (or the documentation) but if you open the .svg file in a browser, you can use the links to navigate between the various tables.\n", "\n", "
" ] }, { "cell_type": "markdown", "id": "eb61f29a-e8cc-4893-affc-4ecae9490489", "metadata": {}, "source": [ "


\n", "\n", "#### 4. Plotting individual CHADA tables without a contents element" ] }, { "cell_type": "markdown", "id": "652b7b78-228d-492b-80b6-e1bce1eaeef6", "metadata": {}, "source": [ "Here we use the theme `plasma_A4w` as we may want to paste the diagrams into a word processor document." ] }, { "cell_type": "code", "execution_count": 11, "id": "49ab0231-b32b-4e06-a4ac-0ec3f3e27027", "metadata": {}, "outputs": [], "source": [ "out_name_3 = \"chada_tables_template_tips_single\"" ] }, { "cell_type": "code", "execution_count": 12, "id": "1f522b6c-51d2-4998-a5a2-35eb46f4b0d6", "metadata": {}, "outputs": [], "source": [ "# writes code for 5 diagrams each showing a single table without a contents element (useful to paste into a document etc.)\n", "\n", "mt.write_chada_tables_single_plantuml(\n", " data_path,\n", " out_path=out_path,\n", " load_path=load_path,\n", " out_name=out_name_3,\n", " theme_name=\"plasma_A4w\",\n", ")" ] }, { "cell_type": "code", "execution_count": 13, "id": "4d49f8ce-054b-4efc-ae27-0eee36ac307f", "metadata": {}, "outputs": [], "source": [ "out_base_3 = mt.handle_paths(\n", " data_path,\n", " out_path=out_path,\n", " load_path=load_path,\n", " out_name=out_name_3,\n", " return_out_base_only=True,\n", ")" ] }, { "cell_type": "code", "execution_count": 14, "id": "54e62889-47af-4b40-8fc8-3686591092ee", "metadata": {}, "outputs": [], "source": [ "for i in [\"overview\", \"user_case\", \"experiment\", \"raw_data\", \"data_processing\"]:\n", " mr.run_plantuml_code(\n", " pathlib.Path(str(out_base_3) + f\"_{i}.puml\"), output_dir=pathlib.Path(\"../\")\n", " )" ] }, { "cell_type": "markdown", "id": "8299d424-0545-4c09-b65f-ab0499d0fd6c", "metadata": {}, "source": [ "Here's the \"experiment\" diagram as an example:\n", "\n", "" ] }, { "cell_type": "markdown", "id": "adf7d0d4-aeef-429b-9cce-b472788cac17", "metadata": {}, "source": [ "


\n", "\n", "#### 5. Advanced formatting of table contents" ] }, { "cell_type": "markdown", "id": "33614999-9187-4eb3-9de1-c044e2872b14", "metadata": {}, "source": [ "To round off this example notebook, let's have a look at how we can add some advanced formatting to the table data, rather than just plain text.\n", "\n", "Even though `mochada_kit/data/demo_formatting.json` has the correct format for CHADA tables, instead of using the convenience functions in `mochada_kit` to generate all the CHADA tables, we'll just write the puml code for one table in this case. The code below results in a contents element joined to the \"experiment\" element, which contains the advanced formatting. Further explanations for this diagram are given below." ] }, { "cell_type": "markdown", "id": "5559eb7f-7266-4512-a32c-6df512c0c31c", "metadata": {}, "source": [ "```\n", "@startjson\n", "!theme MOCHADA-plasma from ../../themes\n", "#highlight \"0. Overview\" <>\n", "#highlight \"1. User Case\" <>\n", "#highlight \"2. Experiment\" <>\n", "#highlight \"3. Raw Data\" <>\n", "#highlight \"4. Data Processing\" <>\n", "#highlight \"2. Experiment\" / \"2. Experiment\" <>\n", "!$DEF_JSON={\"status\":\"No data found\"}\n", "!$DATA = %load_json(\"../../data/demo_formatting.json\", $DEF_JSON)\n", "{\n", " \"Overview\" : \" \",\n", " \"1. User Case\" : \" \",\n", " \"2. Experiment\" : $DATA.experiment,\n", " \"3. Raw Data\" : \" \",\n", " \"4. Data Processing\" : \" \"\n", "}\n", "@endjson\n", "```\n" ] }, { "cell_type": "code", "execution_count": 15, "id": "21dd563e-542d-48e0-b607-b4486d213f7d", "metadata": {}, "outputs": [], "source": [ "puml_code = \"\"\"@startjson\n", "!theme MOCHADA-plasma from ../../themes\n", "#highlight \"0. Overview\" <>\n", "#highlight \"1. User Case\" <>\n", "#highlight \"2. Experiment\" <>\n", "#highlight \"3. Raw Data\" <>\n", "#highlight \"4. Data Processing\" <>\n", "#highlight \"2. Experiment\" / \"2. Experiment\" <>\n", "!$DEF_JSON={\"status\":\"No data found\"}\n", "!$DATA = %load_json(\"../../data/demo_formatting.json\", $DEF_JSON)\n", "{\n", " \"Overview\" : \" \",\n", " \"1. User Case\" : \" \",\n", " \"2. Experiment\" : $DATA.experiment,\n", " \"3. Raw Data\" : \" \",\n", " \"4. Data Processing\" : \" \"\n", "}\n", "@endjson\n", "\"\"\"\n", "\n", "_ = pathlib.Path(\"../../gallery/puml_code/demo_formatting.puml\").write_text(puml_code)" ] }, { "cell_type": "code", "execution_count": 16, "id": "f83937ef-4529-4d1e-bb80-6e75a9433f39", "metadata": {}, "outputs": [], "source": [ "mr.run_plantuml_code(\n", " \"../../gallery/puml_code/demo_formatting.puml\", output_dir=pathlib.Path(\"../\")\n", ")" ] }, { "cell_type": "code", "execution_count": 1, "id": "61852b39-df58-41b7-b478-ca12d2515714", "metadata": {}, "outputs": [], "source": [ "from IPython.display import SVG, display" ] }, { "cell_type": "code", "execution_count": 2, "id": "81343277-709f-4786-9917-bb626ba4e50f", "metadata": {}, "outputs": [ { "data": { "image/svg+xml": [ "Overview 1. User Case 2. Experiment   3. Raw Data 4. Data Processing 2. Experiment 2.1 Probe/Physics of InteractionElectron beam. 20 kV accelerating voltage.Secondary electrons, backscattered electrons2.2 Interaction VolumePear shaped, approximately 5 micrometresdeep and widelatex: 2.3 Calibration ProcessNd2Fe14Bascci math: 2.4 Detector1. SE: Everheart-Thornley detector.2. BSE: Annular detectorImage:2.5 Signal tableheaderatablerowbtablerow2.6 Measurement timeHello 3.5 ± 0.2 μm2.7 Measurement parametersLink" ], "text/plain": [ "" ] }, "metadata": {}, "output_type": "display_data" } ], "source": [ "display(SVG(filename=\"../../gallery/demo_formatting.svg\"))" ] }, { "cell_type": "markdown", "id": "588ef8b0-b99e-428f-b6b0-dec22c480fb5", "metadata": {}, "source": [ "
\n", "\n", "
\n", "\n", "Note\n", "\n", "The link in the above image does not work when embedded in a jupyter notebook (or the documentation) but if you open the svg image in your browser, the link will take you the image `mochada_kit_/gallery/json_SEM_metadata_with_highlights.svg`.\n", "\n", "
" ] }, { "cell_type": "markdown", "id": "f15b4d46-bb43-482b-8dce-334470f1733b", "metadata": {}, "source": [ "The contents of `mochada_kit/data/demo_formatting.json` are shown below." ] }, { "cell_type": "markdown", "id": "d1e4a0e9-056d-41b9-93d9-01acbb2891a5", "metadata": {}, "source": [ "```\n", "{\n", " \"overview\" : \" \",\n", " \"user_case\" : \" \",\n", " \"experiment\" : {\n", " \"2. Experiment\" : \" \",\n", " \"2.1 Probe/\\\\nPhysics of Interaction\" : \"Electron beam. 20 kV accelerating voltage. Secondary electrons, backscattered electrons\",\n", " \"2.2 Interaction Volume\" : \"Pear shaped, approximately 5 micrometres deep and wide\\\\nlatex: \\\\large{y = ax^{2} + bx + c\\\\pi}\",\n", " \"2.3 Calibration Process\" : \"Nd2Fe14B\\\\nascci math: y = ax^2 + bx + c\",\n", " \"2.4 Detector\" : \"1. SE: Everheart-Thornley detector.\\\\n2. BSE: Annular detector\\\\nImage: \",\n", " \"2.5 Signal\" : \"<#gray,#red>|= |= table |= header |\\\\n| a | table | row |\\\\n<#yellow>| b | table | row |\",\n", " \"2.6 Measurement time\" : \"Hello 3.5 0.2 m\",\n", " \"2.7 Measurement parameters\" : \"[[./json_SEM_metadata_with_highlights.svg{View metadata} Link]]\"\n", " },\n", " \"raw_data\" : \" \",\n", " \"data_processing\" : \" \"\n", "}\n", "```" ] }, { "cell_type": "markdown", "id": "cc86247a-0b61-4bd5-acc2-3d8719880d41", "metadata": {}, "source": [ "Various types of formatting have been applied here:\n", "1. plain text\n", "2. latex equations\n", "3. ascii math equations\n", "4. html tags for sub- and superscripts, italics, *etc.*\n", "5. html image tag (the link must be a relative path from the .puml code file to the image in this case)\n", "6. a creole table with formatting\n", "7. a hyperlink to another image (the link must be a relative path from the output.svg image to the linked image in this case)" ] }, { "cell_type": "markdown", "id": "884db0a3-c2fc-4879-bdc6-59acc4c87459", "metadata": {}, "source": [ "
\n", "\n", "Note\n", "\n", "**Note that escape characters:** `\\n` **must be double escaped:** `\\\\n` **in the json/yaml source file in order to have an effect in the final diagram**.\n", "\n", "
" ] }, { "cell_type": "markdown", "id": "27854dc7-e80e-4941-b4ff-eb43ed417092", "metadata": {}, "source": [ "Please see the [plantuml website](https://plantuml.com/sitemap) for more details on formatting." ] } ], "metadata": { "kernelspec": { "display_name": "Python 3 (ipykernel)", "language": "python", "name": "python3" }, "language_info": { "codemirror_mode": { "name": "ipython", "version": 3 }, "file_extension": ".py", "mimetype": "text/x-python", "name": "python", "nbconvert_exporter": "python", "pygments_lexer": "ipython3", "version": "3.12.7" } }, "nbformat": 4, "nbformat_minor": 5 }