Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
18 commits
Select commit Hold shift + click to select a range
041890a
docs(169-S1): rename the single-count-column header to 'Reachable pairs'
gsvgit Oct 21, 2026
b4ac745
refactor(169-S2): generalize the graph-table header parsing to header…
gsvgit Oct 21, 2026
7c72e7d
docs(169-S3): give the rdf count columns the unified 'Reachable pairs…
gsvgit Oct 21, 2026
a5d6ef9
docs(169): resolve the S3 block in the detailed plan
gsvgit Oct 21, 2026
a76058f
chore(169-S4): stop maintaining the historical old_graphs table
gsvgit Oct 21, 2026
dd13519
docs(169-S5): describe the unified 'Reachable pairs' header in the ca…
gsvgit Oct 21, 2026
a51034d
test(169-S3): annotate the columns literals in the new reachable-pair…
gsvgit Oct 21, 2026
4429e55
fix(173-S1): repair the 18 math snippets MathJax cannot render
gsvgit Oct 28, 2026
2090164
feat(173-S2): add the MathJax Node oracle for the math-snippet guard
gsvgit Oct 28, 2026
8f6fc2f
feat(173-S3): validate math snippets with the MathJax engine, cover d…
gsvgit Oct 28, 2026
2dcb39b
docs(173-S4): wire the math guard into pre-commit and record the change
gsvgit Oct 28, 2026
8da13bb
docs(173-S4): commit the detailed plan with all subtasks marked done
gsvgit Oct 28, 2026
3b3d327
fix(173-S5): repoint the dead eclass Source links to the archived ont…
gsvgit Oct 28, 2026
6c373e6
docs(173): record S5 in the detailed plan
gsvgit Oct 28, 2026
b98abed
docs(169): record the unified count-column names in the changelog
gsvgit Oct 28, 2026
c87e254
chore: release 6.1.2
gsvgit Oct 28, 2026
28ef0e5
fix: load MathJax components via file:// URLs in the Node oracle
gsvgit Oct 28, 2026
3ecb2d7
fix: install MathJax in the lint workflow for the math-snippet hook
gsvgit Oct 28, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .github/workflows/coverage.yml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,12 @@ jobs:
- name: Show installed packages
run: uv tree

# The math-snippet guard validates docs snippets with the MathJax
# engine (utils/check_math_snippets_node.cjs); Node is preinstalled
# on the runner.
- name: Install MathJax with npm
run: npm ci

# Per-metric gate rationale: see "Test pipeline" in docs/developer.rst.
# term-missing keeps the uncovered lines in the CI log.
- name: Test FLPQ_Data with coverage (line and branch >= 95%)
Expand Down
6 changes: 6 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,12 @@ jobs:
- name: Install dependencies with uv
run: uv sync --frozen --all-groups

# The pre-commit math-snippet hook (check-math-snippets) runs the
# MathJax Node oracle (utils/check_math_snippets_node.cjs); Node is
# preinstalled on the runner.
- name: Install MathJax with npm
run: npm ci

- name: Run pre-commit
run: |
uv run pre-commit run --all-files --color always --verbose --show-diff-on-failure
Expand Down
6 changes: 6 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,5 +28,11 @@ jobs:
- name: Show installed packages
run: uv tree

# The math-snippet guard validates docs snippets with the MathJax
# engine (utils/check_math_snippets_node.cjs); Node is preinstalled
# on all runner OSes.
- name: Install MathJax with npm
run: npm ci

- name: Test FLPQ_Data
run: uv run pytest
6 changes: 6 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -31,3 +31,9 @@ repos:
language: system
pass_filenames: false
files: \.py$
- id: check-math-snippets
name: Check math snippets with the MathJax engine
entry: python3 utils/check_math_snippets.py
language: system
pass_filenames: false
always_run: true
30 changes: 30 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,36 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0

## [Unreleased]

## [6.1.2] - 2026-10-28

### Fixed

- The reachable-pair count columns of the graph tables were inconsistently
named (e.g. `grammar` on the biological_uniprot page, bare grammar names
on the rdf page); they are now uniformly `Reachable pairs`, with the rdf
page's per-grammar columns prefixed `Reachable pairs / <grammar>` (#169).
- The field-sensitive-alias pages rendered the edge label `f_r_i` as a TeX
double subscript, which MathJax rejects with "Double subscripts: use
braces to clarify" (#173); the label is now `f_{r\_i}` in the ten
per-graph Edges Statistics tables and the canonical-grammar block.
- Seven grammar pages used `&` alignment tabs in plain display math, which
MathJax rejects with "Misplaced &" (#174); the blocks are now wrapped in
`\begin{aligned} ... \end{aligned}`.
- The eclass graph page's Source link (and the historical old_graphs
page's Origin link) pointed to a URL the hosting university removed from
its site; they now point to the archived original (Wayback Machine
snapshot of the eClassOWL 5.1.4 ontology file the original page
redirected to).

### Changed

- The math-snippet guard now validates every docs-page and package-docstring
math snippet with the MathJax engine itself (mathjax 4.1.3 on Node,
`utils/check_math_snippets_node.cjs`) instead of hand-crafted patterns,
reporting the engine's own error message; the browser bundle is pinned to
the same version (`mathjax_js` in `docs/conf.py`), and the guard also runs
as a pre-commit hook.

## [6.1.1] - 2026-10-15

### Changed
Expand Down
6 changes: 6 additions & 0 deletions docs/conf.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,12 @@
"texext",
]

# Pin the browser-side MathJax to the exact version the math-snippet guard
# validates with (utils/check_math_snippets_node.cjs, version in
# package.json). The guard and the renderer must stay on the same engine
# version or they can disagree about what renders.
mathjax_js = "https://cdn.jsdelivr.net/npm/mathjax@4.1.3/tex-mml-chtml.js"

# generate autosummary pages
autosummary_generate = True

Expand Down
34 changes: 24 additions & 10 deletions docs/developer.rst
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,16 @@ then from the repository root::
- The committed :file:`uv.lock` pins every dependency; CI passes ``--frozen``
to fail on a lockfile that is out of sync with ``pyproject.toml``.

The math-snippet guard (see "Test pipeline") validates docs math with the
MathJax engine itself, which runs on Node.js (>= 20). Install Node.js once,
then from the repository root::

npm ci

The committed :file:`package-lock.json` pins the engine version; it must
match the ``mathjax_js`` URL in :file:`docs/conf.py`, so the guard and the
browser render with the same MathJax version.

.. _developer-quality:

Quality checks
Expand All @@ -64,9 +74,10 @@ Linting, formatting, and type checking are managed by uv and run through
``pre-commit``. The hook list — hygiene checks, the official ``uv-lock`` and
ruff hooks (check with autofix plus format), a version-sync check that fails
when :file:`flpq_data/config.py` and :file:`pyproject.toml` declare different
versions, and a local ty type check — is defined in
:file:`.pre-commit-config.yaml`, which is the source of truth; do not
maintain a copy of it elsewhere.
versions, a local ty type check, and a math-snippet check that validates the
docs and docstring math with the MathJax engine (see "Test pipeline") — is
defined in :file:`.pre-commit-config.yaml`, which is the source of truth; do
not maintain a copy of it elsewhere.

The ``ruff-pre-commit`` hook revision must match the ruff version locked in
:file:`uv.lock`; bump both together when upgrading ruff.
Expand Down Expand Up @@ -112,13 +123,16 @@ coverage gate::

uv run pytest tests/graphs/utils/test_add_reverse_edges.py

The suite also validates the math snippets of the docs pages: Sphinx passes
math verbatim to MathJax, which renders it in the browser, so a broken
snippet (e.g. an unescaped underscore inside a ``\textit{...}`` group) sails
through the Sphinx build and shows up only as an error on the deployed site.
``tests/utils/test_check_math_snippets.py`` runs
``utils/check_math_snippets.py`` over every page and fails the suite on any
broken snippet.
The suite also validates the math snippets of the docs pages and of the
package docstrings (rendered on the reference pages): Sphinx passes math
verbatim to MathJax, which renders it in the browser, so a broken snippet
sails through the Sphinx build and shows up only as an error on the
deployed site. The guard therefore validates every snippet with the MathJax
engine itself — ``utils/check_math_snippets.py`` extracts the ``:math:``
roles and ``.. math::`` bodies and compiles them with
``utils/check_math_snippets_node.cjs`` (the same engine version the browser
loads, see "Development setup") — and fails the suite on any snippet the
engine rejects, reporting the engine's own error message.

- Doctest discovery and test paths are configured in ``pyproject.toml``
(``[tool.pytest.ini_options]``).
Expand Down
5 changes: 3 additions & 2 deletions docs/graphs/biological_uniprot.rst
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,11 @@ as in `"Subgraph queries by context-free grammars" <https://researchportal.helsi
data/unigraph_10

.. list-table::
:header-rows: 1

* - Graph
- Num Nodes
- Num Edges
- grammar
- Reachable pairs
- Size (MB)
- Download
* - :ref:`unigraph_1`
Expand Down Expand Up @@ -104,6 +103,7 @@ The grammar file is attached to the archive.

.. math::

\begin{aligned}
S &\to Seq \quad IsAssociated \quad IsSimilar \\
Seq &\to IsSimilar \quad (codes\_for \quad IsSimilar)? \\
IsSimilar &\to \varepsilon \\
Expand All @@ -112,3 +112,4 @@ The grammar file is attached to the archive.
&\mid belongs\_to \quad IsSimilar \quad belongs\_to_{r} \\
&\mid participate\_in \quad IsSimilar \quad participate\_in_{r} \\
IsAssociated &\to refers\_to \quad refers\_to_{r}
\end{aligned}
3 changes: 1 addition & 2 deletions docs/graphs/c_alias_analysis.rst
Original file line number Diff line number Diff line change
Expand Up @@ -38,12 +38,11 @@ discovered for each program.
data/kernel

.. list-table::
:header-rows: 1

* - Graph
- Num Nodes
- Num Edges
- c_alias
- Reachable pairs
- Size (MB)
- Download
* - :ref:`wc`
Expand Down
3 changes: 1 addition & 2 deletions docs/graphs/context_sensitive_data_flow.rst
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,11 @@ families), as in `"Taming Transitive Redundancy for Context-Free Language Reacha
data/perlbench

.. list-table::
:header-rows: 1

* - Graph
- Num Nodes
- Num Edges
- aa
- Reachable pairs
- Size (MB)
- Download
* - :ref:`xz`
Expand Down
2 changes: 1 addition & 1 deletion docs/graphs/data/cactus_field_sensitive_alias.rst
Original file line number Diff line number Diff line change
Expand Up @@ -49,5 +49,5 @@ Edges Statistics
- 5060
* - :math:`f_i`
- 10790
* - :math:`f_r_i`
* - :math:`f_{r\_i}`
- 10790
2 changes: 1 addition & 1 deletion docs/graphs/data/eclass.rst
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ Info
* - Direct download
- `.tar.gz <https://cfpq-data.storage.yandexcloud.net/6.0.0/graph/eclass.tar.gz>`_
* - Source
- `link <http://www.ebusiness-unibw.org/ontologies/eclass/5.1.4>`_
- `link <https://web.archive.org/web/20160309143952/http://ebusiness-unibw.org/ontologies/eclass/5.1.4/eclass_514en.owl>`_


Graph Statistics
Expand Down
2 changes: 1 addition & 1 deletion docs/graphs/data/imagick_field_sensitive_alias.rst
Original file line number Diff line number Diff line change
Expand Up @@ -49,5 +49,5 @@ Edges Statistics
- 4202
* - :math:`f_i`
- 26813
* - :math:`f_r_i`
* - :math:`f_{r\_i}`
- 26813
2 changes: 1 addition & 1 deletion docs/graphs/data/leela_field_sensitive_alias.rst
Original file line number Diff line number Diff line change
Expand Up @@ -49,5 +49,5 @@ Edges Statistics
- 2306
* - :math:`f_i`
- 3856
* - :math:`f_r_i`
* - :math:`f_{r\_i}`
- 3856
2 changes: 1 addition & 1 deletion docs/graphs/data/nab_field_sensitive_alias.rst
Original file line number Diff line number Diff line change
Expand Up @@ -49,5 +49,5 @@ Edges Statistics
- 836
* - :math:`f_i`
- 1192
* - :math:`f_r_i`
* - :math:`f_{r\_i}`
- 1192
2 changes: 1 addition & 1 deletion docs/graphs/data/omnetpp_field_sensitive_alias.rst
Original file line number Diff line number Diff line change
Expand Up @@ -49,5 +49,5 @@ Edges Statistics
- 12579
* - :math:`f_i`
- 16822
* - :math:`f_r_i`
* - :math:`f_{r\_i}`
- 16822
2 changes: 1 addition & 1 deletion docs/graphs/data/parest_field_sensitive_alias.rst
Original file line number Diff line number Diff line change
Expand Up @@ -49,5 +49,5 @@ Edges Statistics
- 7610
* - :math:`f_i`
- 8983
* - :math:`f_r_i`
* - :math:`f_{r\_i}`
- 8983
2 changes: 1 addition & 1 deletion docs/graphs/data/perlbench_field_sensitive_alias.rst
Original file line number Diff line number Diff line change
Expand Up @@ -49,5 +49,5 @@ Edges Statistics
- 8520
* - :math:`f_i`
- 16381
* - :math:`f_r_i`
* - :math:`f_{r\_i}`
- 16381
2 changes: 1 addition & 1 deletion docs/graphs/data/povray_field_sensitive_alias.rst
Original file line number Diff line number Diff line change
Expand Up @@ -49,5 +49,5 @@ Edges Statistics
- 3436
* - :math:`f_i`
- 6951
* - :math:`f_r_i`
* - :math:`f_{r\_i}`
- 6951
2 changes: 1 addition & 1 deletion docs/graphs/data/x264_field_sensitive_alias.rst
Original file line number Diff line number Diff line change
Expand Up @@ -49,5 +49,5 @@ Edges Statistics
- 4747
* - :math:`f_i`
- 9532
* - :math:`f_r_i`
* - :math:`f_{r\_i}`
- 9532
2 changes: 1 addition & 1 deletion docs/graphs/data/xz_field_sensitive_alias.rst
Original file line number Diff line number Diff line change
Expand Up @@ -49,5 +49,5 @@ Edges Statistics
- 588
* - :math:`f_i`
- 1193
* - :math:`f_r_i`
* - :math:`f_{r\_i}`
- 1193
5 changes: 3 additions & 2 deletions docs/graphs/data_provenance.rst
Original file line number Diff line number Diff line change
Expand Up @@ -35,12 +35,11 @@ Python projects, following the W3C PROV model (``Entity``, ``Activity``,
data/provenance_airflow

.. list-table::
:header-rows: 1

* - Graph
- Num Nodes
- Num Edges
- prov_derivation
- Reachable pairs
- Size (MB)
- Download
* - :ref:`provenance_sampleproject`
Expand Down Expand Up @@ -159,6 +158,7 @@ The grammar file is attached to the archive.

.. math::

\begin{aligned}
S &\to Entity \quad Core \quad Entity \\
Core &\to wasDerivedFrom \\
&\mid wasDerivedFrom_{r} \\
Expand All @@ -174,3 +174,4 @@ The grammar file is attached to the archive.
&\quad Entity \quad wasDerivedFrom_{r} \\
&\mid specializationOf \quad Entity \quad Core \\
&\quad Entity \quad specializationOf_{r}
\end{aligned}
5 changes: 2 additions & 3 deletions docs/graphs/field_sensitive_alias.rst
Original file line number Diff line number Diff line change
Expand Up @@ -27,12 +27,11 @@ field (the ``f_i`` family), as in `"Taming Transitive Redundancy for Context-Fre
data/omnetpp_field_sensitive_alias

.. list-table::
:header-rows: 1

* - Graph
- Num Nodes
- Num Edges
- vf
- Reachable pairs
- Size (MB)
- Download
* - :ref:`xz_field_sensitive_alias`
Expand Down Expand Up @@ -106,7 +105,7 @@ Reversed edges (``a_r``, ``d_r``, ``f_r_i``) are auto-generated from forward edg
.. math::

M \, \rightarrow \, d_r \, V \, d \, \\
V \, \rightarrow \, A_r \, V \mid V \, A \mid f_r_i \, V \, f_i \mid M \mid \varepsilon \, \\
V \, \rightarrow \, A_r \, V \mid V \, A \mid f_{r\_i} \, V \, f_i \mid M \mid \varepsilon \, \\
A_r \, \rightarrow \, M \, a_r \mid a_r \mid \varepsilon \, \\
A \, \rightarrow \, a \, M \mid a \mid \varepsilon \, \\

Expand Down
22 changes: 12 additions & 10 deletions docs/graphs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -110,16 +110,18 @@ is dropped.
Contents
--------

The per-category tables include one column per grammar language
applicable to that category. Each cell shows the number of vertex pairs
reachable with respect to the respective language (i.e. the number of
pairs ``(u, v)`` for which some string in the language labels a path from
:math:`u` to :math:`v`). The count depends on the language, not on a
particular grammar: several grammars may generate the same language and
yield the same count. A cell reading "not available" means the value has
not been computed yet; an empty cell means the grammar does not apply to
that graph. Each table also has a ``Size (MB)`` column: the download size
of the graph's archive, in megabytes.
The per-category tables include one count column per grammar language
applicable to that category, each headed ``Reachable pairs`` (or
``Reachable pairs / <grammar>`` in categories with several languages, such
as RDF). Each cell shows the number of vertex pairs reachable with respect
to the respective language (i.e. the number of pairs ``(u, v)`` for which
some string in the language labels a path from :math:`u` to :math:`v`). The
count depends on the language, not on a particular grammar: several grammars
may generate the same language and yield the same count. A cell reading
"not available" means the value has not been computed yet; an empty cell
means the grammar does not apply to that graph. Each table also has a
``Size (MB)`` column: the download size of the graph's archive, in
megabytes.

The canonical grammar behind each column is documented once on the
respective category page, in its "Canonical grammars" section — a grammar
Expand Down
3 changes: 1 addition & 2 deletions docs/graphs/java_points_to.rst
Original file line number Diff line number Diff line change
Expand Up @@ -40,12 +40,11 @@ are not stored (see :ref:`graphs`).
data/tradesoap

.. list-table::
:header-rows: 1

* - Graph
- Num Nodes
- Num Edges
- java_points_to
- Reachable pairs
- Size (MB)
- Download
* - :ref:`gson`
Expand Down
Loading
Loading