Use Cases

This page captures the key user workflows for the Antora Tracer extension. Each use case traces into the requirements it motivates via leads_to relations — demonstrating how config extension adds domain-specific roles and relations beyond the built-in presets.

UC-001 — Team member writes traceable items in AsciiDoc
Table 1. Use Case: Team member writes traceable items in AsciiDoc

ID

UC-001

Title

Team member writes traceable items in AsciiDoc

Goal

Team member writes traceable items so that the project establishes complete end-to-end traceability across the software development lifecycle

Primary Actor

Business Analyst, Architect, Developer, Test Manager — any team member who authors traceable content

Preconditions

The project uses Antora as its site generator And the Antora Tracer extension is installed in the playbook And a traceability.yml config is loaded with at least one role defined And the team member has write access to .adoc files in the pages or partials directories

Trigger

Team member opens an .adoc file in their editor to add or update a traceable item

Basic Flow

  1. Team member identifies a concept that needs to be traceable — a requirement, a design decision, a test specification, or a dependency

  2. Team member determines the next available ID for the item’s prefix using the CLI: antora-tracer next-id --prefix <PREFIX> -i <path>

  3. Team member assigns the concept to a role defined in the project’s traceability domain model (requirement, design, test, etc.)

  4. Team member writes the item using the [#ID, item, role=…​] block macro with a description between -- delimiters

  5. Team member links the concept to related items already in the traceability graph using inline relationship macros (e.g., ``)

  6. Team member includes rendering macros (traceability:links[], traceability:outgoing[], traceability:incoming[]) to display relationship lists in the rendered output

  7. Team member commits the file And triggers an Antora build

  8. The extension registers the item in the traceability graph And its relationships appear in the traceability matrix

Alternate Flows

  1. No existing items share the prefix: The next-id command defaults to 3-digit padding and returns <PREFIX>-001.

  2. Team member uses a role not in config: Extension registers the item with a warning. Processing continues.

  3. Team member links to a target that does not exist: Extension stores the relationship with a warning. The matrix shows a partial link.

  4. Team member writes an incomplete item block: The item may not register correctly in the traceability graph.

  5. Team member includes rendering macros but no relationships exist: The placeholder is replaced with an empty section in the rendered output.

Postconditions

The traceability graph contains the new item with a consistent ID And all inline relationships are registered And the rendered page shows relationship lists if macros were included And the traceability matrix reflects updated coverage

Priority

High

Frequency

Per item — multiple times per documentation session

Notes

The [item] macro syntax is documented in the User Guide — this use case describes the workflow, not the exact syntax. The next-id command auto-detects padding from existing IDs.

UC-002 — Requirements Engineer defines custom domain model via config
Table 2. Use Case: Requirements Engineer defines custom domain model via config

ID

UC-002

Title

Requirements Engineer defines custom domain model via config

Goal

Requirements Engineer defines custom roles, relations, and matrices so that the project’s traceability reflects its specific domain language rather than a generic template

Primary Actor

Requirements Engineer

Preconditions

The Antora Tracer extension is installed And a built-in preset exists that covers the baseline domain (e.g., requirements-engineering) And the Requirements Engineer has write access to the project’s traceability.yml file

Trigger

Requirements Engineer determines that the built-in preset does not fully capture the project’s domain — a missing role, an unneeded relation, or a custom matrix is needed

Basic Flow

  1. Requirements Engineer reviews the available built-in presets to identify the closest match

  2. Requirements Engineer creates a traceability.yml file with extends: pointing to the chosen preset

  3. Requirements Engineer adds roles not present in the preset (e.g., use_case, stakeholder)

  4. Requirements Engineer defines relations for the new roles (e.g., use_case → requirement: [leads_to])

  5. Requirements Engineer adds custom matrices for the new role combinations

  6. Requirements Engineer runs the Antora build to verify the extended config is valid

  7. The extension merges the user config with the preset And items using the new roles are accepted

Alternate Flows

  1. Requirements Engineer extends a preset that does not exist: Extension reports an error listing available presets.

  2. Requirements Engineer adds a role already in the preset: The duplicate is silently merged — the preset’s definition takes precedence.

  3. Requirements Engineer defines a relation not allowed by the preset: The extension warns but does not block processing. Items using the relation may fail validation.

  4. Requirements Engineer does not include extends: field: The config is treated as standalone — the preset is not loaded.

Postconditions

The project’s traceability domain model is configured And items using the new roles are accepted by the extension And custom matrices appear in the traceability output

Priority

High

Frequency

Once per project — updated infrequently as the domain model evolves

Notes

⚠ Actor "Requirements Engineer" does not yet have a persona definition. The extends: mechanism is documented in the User Guide (Configuration section).

UC-004 — Requirements Engineer organizes items in partial files
Table 3. Use Case: Requirements Engineer organizes items in partial files

ID

UC-004

Title

Requirements Engineer organizes items in partial files

Goal

Requirements Engineer places related items in separate partial files so that the traceability structure stays modular, focused, and maintainable without cluttering the main page

Primary Actor

Requirements Engineer

Preconditions

The project uses Antora as its site generator And the Antora Tracer extension is installed And the project has a partials/ directory in its Antora module And the Requirements Engineer has write access to both page and partial files

Trigger

Requirements Engineer notices that a page contains many item blocks or that a group of related items would benefit from being in a standalone file

Basic Flow

  1. Requirements Engineer creates a .adoc file in the partials/ directory

  2. Requirements Engineer moves related [item] blocks from a page into the partial file

  3. Requirements Engineer replaces the moved items in the page with include::partial$…​[] directives

  4. Requirements Engineer commits the changes And triggers an Antora build

  5. The extension processes both the page and the partial — items from the partial are registered in the graph And matrix links point to the partial’s source location in the repository

Alternate Flows

  1. Requirements Engineer includes a partial that defines no items: The partial is included normally in the page output but contributes nothing to the traceability graph.

  2. Requirements Engineer includes a partial in multiple pages: The build fails with a duplicate-ID error naming both definitions.

  3. Requirements Engineer references a partial item with xref:: Asciidoctor reports "target of xref not found" — partials do not produce HTML pages. Use inline relationship macros or link: URLs instead.

Postconditions

The traceability graph contains the items from the partial And matrix links point to the partial’s source file in the repository And the page content is rendered with the partial included

Priority

Medium

Frequency

During initial documentation setup and periodically as the item count grows

Notes

⚠ Actor "Requirements Engineer" does not yet have a persona definition. The partial processing behavior is documented in the User Guide section "Items in Partials".

UC-005 — Reviewer browses traceability matrices for coverage
Table 4. Use Case: Reviewer browses traceability matrices for coverage

ID

UC-005

Title

Reviewer browses traceability matrices for coverage

Goal

Reviewer inspects traceability matrices so that they can verify which requirements are covered by design decisions, tests, and other downstream artifacts

Primary Actor

Reviewer or Auditor

Preconditions

The Antora site has been built And traceability matrices have been registered in the content catalog during the contentClassified event And the site navigation includes links to the matrix pages And the Reviewer has access to the published site

Trigger

Reviewer needs to verify coverage — during a design review, a compliance audit, or a quality gate

Basic Flow

  1. Reviewer opens the published Antora site in a browser

  2. Reviewer navigates to the Traceability section in the navigation

  3. Reviewer opens the relevant matrix (e.g., Requirements → Architecture, Requirements → Tests, Use Cases → Requirements)

  4. Reviewer scans rows to identify items with missing coverage (red "missing" badge, 0.0%)

  5. Reviewer clicks on cell items to navigate to the source page where the relationship is defined

  6. Reviewer clicks on row items to navigate to the requirement’s definition

  7. Reviewer notes gaps And either approves the coverage or requests additions

Alternate Flows

  1. A matrix shows no items: The corresponding roles have no items defined. The matrix renders with zero rows.

  2. A row shows partial coverage (yellow): Some but not all expected relationships exist. Reviewer investigates the specific gap.

  3. Reviewer needs to see the source data in CSV: Reviewer can open the .csv variant of the matrix for offline analysis.

  4. Reviewer needs coverage data for external tools: Reviewer can export the graph to Neo4j CSV or Cypher format for import into graph databases or compliance reports.

Postconditions

Reviewer has assessed coverage completeness And identified any gaps And can navigate from the matrix to the source items for further investigation

Priority

High

Frequency

Periodically — at design reviews, before releases, during compliance audits

Notes

⚠ Actor "Reviewer or Auditor" — two distinct roles with similar workflows. Consider splitting if their goals diverge significantly (internal review vs. external compliance). No persona defined for either.

UC-006 — Project lead bootstraps traceability for a new project
Table 5. Use Case: Project lead bootstraps traceability for a new project

ID

UC-006

Title

Project lead bootstraps traceability for a new project

Goal

Project lead sets up the Antora Tracer extension for a new or existing Antora project so the team can begin writing traceable items with a domain model appropriate to their workflow

Primary Actor

Project Lead, Requirements Engineer, or Tech Lead

Preconditions

The project uses Antora as its site generator And the project lead has access to the Antora playbook and module directories

Trigger

The team decides to adopt traceability — a new project is starting, or an existing project wants to add traceability to its documentation

Basic Flow

  1. Project lead installs the extension: npm install antora-tracer --save-dev

  2. Project lead reviews the built-in presets to find the closest match for the team’s domain (requirements-engineering, agile, medical-iec62304, minimal)

  3. Project lead adds the extension to the Antora playbook with the chosen preset:

    antora:
      extensions:
        - require: antora-tracer/antora-extension
          config:
            preset: requirements-engineering
  4. Project lead creates a traceability.yml file extending the preset with any project-specific roles, relations, or matrices

  5. Project lead adds :traceability-links: document attributes to the pages where relationship macros should render

  6. Project lead adds matrix links to the site navigation (e.g., attachment$traceability/matrix-requirements-to-design.html)

  7. Project lead runs a first Antora build to verify the extension initializes and matrices generate without errors

  8. Project lead shares the setup with the team — team members can now write items in their AsciiDoc pages

Alternate Flows

  1. The preset does not cover the team’s domain at all: Project lead uses preset init to bootstrap a custom preset from scratch and defines all roles, relations, and matrices manually.

  2. The project does not have a partials/ directory yet: Project lead creates one. The extension processes partials automatically.

  3. The first build shows zero items in matrices: Expected — the team has not written any items yet. Matrices render with empty rows and 0% coverage.

  4. The team wants to adopt incrementally: Project lead configures the extension with minimal roles first. Additional roles, relations, and matrices are added later via config extension.

  5. The project uses multiple Antora components: Project lead configures the extension in each component’s playbook or uses a shared config.

Postconditions

The Antora Tracer extension is installed and configured And at least one preset is active And the site navigation includes matrix links And matrices generate during builds with 0 errors And the team can begin writing traceable items

Priority

High

Frequency

Once per project — revisited when the domain model evolves

Notes

This use case covers the "Day 0" setup. For ongoing configuration changes, see UC-002. The preset init command creates a skeleton YAML file for a custom preset.

UC-007 — Developer validates traceability in CI pipeline
Table 6. Use Case: Developer validates traceability in CI pipeline

ID

UC-007

Title

Developer validates traceability in CI pipeline

Goal

Developer runs traceability validation in CI so that invalid relationships, circular references, and configuration errors are caught before they reach the published site

Primary Actor

Developer or DevOps Engineer

Preconditions

The Antora Tracer CLI is installed in the CI environment And the project’s .adoc source files are checked out And a traceability.yml config is present And the CI pipeline has a step for traceability validation

Trigger

A pull request is opened or a commit is pushed — the CI pipeline triggers a traceability validation job

Basic Flow

  1. CI pipeline checks out the repository

  2. CI pipeline runs antora-tracer process -i <pages-dir> --config traceability.yml to parse all items

  3. CI pipeline runs antora-tracer validate -i <pages-dir> --config traceability.yml to check graph integrity

  4. The validator reports errors (circular references, invalid relations) and warnings (unknown roles, missing targets)

  5. If errors are found, the CI pipeline fails the build and the developer reviews the output

  6. Developer fixes the issues — removes circular references, corrects relation types, or adds missing targets

  7. Developer pushes the fix And CI re-runs validation

  8. When validation passes (0 errors), the pipeline proceeds to build and deploy the Antora site

Alternate Flows

  1. Validation finds only warnings (no errors): The build continues. Warnings are logged for review but do not block deployment.

  2. Circular reference detected (e.g., A → B → A): The validator reports the full cycle path. Developer must break the cycle by removing one of the relationships.

  3. Config file is missing or invalid: The validator exits with an error describing the config problem. Developer fixes traceability.yml.

  4. No items found in the input directory: The validator reports 0 items. This may be intentional (new project) or indicate a path misconfiguration.

  5. Developer wants to run validation locally before pushing: Same commands work outside CI — process then validate.

Postconditions

The traceability graph is free of structural errors (0 circular references, 0 invalid relations) And the CI pipeline has verified the config is valid And the build can proceed to site generation

Priority

High

Frequency

On every push or pull request — continuous integration

Notes

The process step must run before validate — validation operates on the in-memory graph populated by processing. The CLI can also generate matrices (matrix) and export Neo4j data (export neo4j) in CI for artifact generation.

UC-008 — Data analyst explores traceability in Neo4j
Table 7. Use Case: Data analyst explores traceability in Neo4j

ID

UC-008

Title

Data analyst explores traceability in Neo4j

Goal

Data analyst exports the traceability graph to Neo4j so they can run complex graph queries, generate compliance reports, and discover patterns not visible in the matrix views

Primary Actor

Data Analyst, Compliance Officer, or Systems Engineer

Preconditions

The traceability graph has been populated with items and relationships And the Antora Tracer CLI is available And Neo4j is installed or accessible (Desktop, AuraDB, or Docker)

Trigger

Data analyst needs to answer a question that requires graph traversal — "show me all requirements with no test coverage," "trace the impact chain for this change," or "generate a compliance audit trail"

Basic Flow

  1. Data analyst runs antora-tracer export neo4j -i <pages-dir> --format csv to generate nodes.csv and relationships.csv

  2. Data analyst imports the CSV files into Neo4j using LOAD CSV or the Neo4j Data Importer

  3. Data analyst runs preset queries included with the config (e.g., "Uncovered Requirements," "Coverage Summary," "Traceability Chains")

  4. Data analyst writes custom Cypher queries for project-specific questions

  5. Data analyst shares findings — a coverage heatmap, a list of orphan items, or an impact analysis report

Alternate Flows

  1. Data analyst prefers Cypher format: Uses --format cypher to generate an import.cypher file with CREATE statements instead of CSV.

  2. Export contains items with special characters in titles: The exporter properly escapes commas, quotes, and newlines so CSV imports cleanly.

  3. Data analyst wants to export only a subset: Runs export neo4j after a CI validation step that has already populated the graph with only the items of interest.

  4. Neo4j is not available: The analyst can inspect the CSV files directly in a spreadsheet or use the Cypher file as documentation of the graph structure.

Postconditions

The traceability graph is available in Neo4j And preset queries return results And the data analyst can run ad-hoc Cypher queries for deep analysis

Priority

Medium

Frequency

Periodically — before releases, during audits, or when investigating coverage gaps

Notes

The cypher format includes :Item and role-specific labels on nodes, and type-specific labels on relationships. The includeContent option controls whether item body text is included in the export.

UC-009 — Architect visualizes relationship dependencies
Table 8. Use Case: Architect visualizes relationship dependencies

ID

UC-009

Title

Architect visualizes relationship dependencies

Goal

Architect embeds relationship graphs and coverage charts in documentation pages so stakeholders can visually explore dependencies and coverage at a glance without leaving the documentation site

Primary Actor

Architect, Tech Lead, or Requirements Engineer

Preconditions

The Antora Tracer extension is installed And the :traceability-graph: document attribute is enabled on the target pages And Kroki is configured in the Antora playbook (for rendering GraphViz and Vega-Lite)

Trigger

Architect wants to provide visual context — showing how a key requirement connects to downstream artifacts, or displaying global coverage status on a dashboard page

Basic Flow

  1. Architect adds :traceability-graph: true to a page’s document header

  2. Architect embeds traceability:graph[] inside an item block to render a GraphViz diagram of that item’s direct relationships (colored by role, with labeled edges)

  3. Architect embeds traceability:graph-coverage[] inside or outside item blocks to render Vega-Lite bar charts showing coverage

  4. Architect builds the Antora site — macros are replaced with Kroki image URLs (SVG by default, PNG configurable)

  5. Stakeholders view the page — the diagram shows the item’s dependency neighborhood and the bar chart shows coverage status

  6. Stakeholders can click through from the diagram description to related items via xrefs

Alternate Flows

  1. Architect uses traceability:graph[ITEM-ID, 2] with a depth of 2: The graph shows two hops of relationships instead of one.

  2. Architect places traceability:graph-coverage[] outside an item block: The chart shows global coverage by role instead of per-item coverage.

  3. The project builds PDFs: Architect sets krokiImageFormat: png in the playbook config — PNG images render correctly in PDF output where SVGs do not.

  4. Kroki is unavailable or misconfigured: The macros render as fallback text with the item IDs, still providing value.

Postconditions

The documentation page contains embedded relationship graphs and/or coverage charts And stakeholders can visually explore dependencies And the graphs are navigable via xrefs to related items

Priority

Medium

Frequency

Per key item — added to pages where visual context adds value (dashboard, architecture overview, key requirements)

Notes

The dashboard page (dashboard.adoc) demonstrates both macros in context. GraphViz diagrams are rendered server-side by Kroki; Vega-Lite is rendered client-side by the browser.

UC-010 — Developer assesses impact before changing a traceable item
Table 9. Use Case: Developer assesses impact before changing a traceable item

ID

UC-010

Title

Developer assesses impact before changing a traceable item

Goal

Developer queries the traceability graph so they can identify every item that references a target before changing or removing it, avoiding dangling references and broken coverage

Primary Actor

Developer or Requirements Engineer

Preconditions

The project’s .adoc source files contain traceable items with IDs And the Antora Tracer CLI is available And the developer has read access to the source files

Trigger

Developer plans to change, rename, or remove a traceable item and needs to know what references it

Basic Flow

  1. Developer identifies the ID of the item they intend to change or remove

  2. Developer runs antora-tracer query reverse <ID> to list every item that references the target, with relationship type and source file and line

  3. Developer runs antora-tracer query impact <ID> to list all items transitively connected to the target

  4. Developer reviews the results to determine the full set of items affected by the change

  5. Developer updates each referencing item — or confirms none exist — before making the change

  6. Developer commits the change with all affected items accounted for

Alternate Flows

  1. No item references the target: reverse returns an empty result and exits 0. The change is safe from a traceability perspective.

  2. The target ID does not exist: The command exits 1 with an "Item not found" warning. Developer verifies the ID spelling or confirms the item was already removed.

  3. Developer needs machine-readable output: Developer adds --json for structured output consumable by scripts or AI coding agents.

  4. Developer needs the chain between two specific items: Developer runs query path <from> <to>. The shortest relationship path prints, or the command exits 1 with "No path found".

  5. Developer wants to find items with no relationships: Developer runs query orphaned, optionally filtered with --role.

  6. Developer wants to limit the search: Developer passes -i <path> to scan a specific directory or file instead of the current directory.

Postconditions

The developer has identified every item that references the target And no Antora build was required And no source files were modified (query is read-only) And the change can proceed with all referencing items accounted for

Priority

Medium

Frequency

Before each refactor, rename, or removal of a traceable item

Notes

The query command parses .adoc files directly — it reuses the same parser and graph as the build, so no Antora build or running Neo4j database is required. This is the lightweight in-repo counterpart to UC-008 (Neo4j exploration): query answers simple structural questions without infrastructure, while Neo4j supports deeper ad-hoc graph analysis. ⚠ Actor "Developer or Requirements Engineer" is a compound role without a persona definition.