Skip to content

ConceptFlow 0.5.0: now beta

Choose a tag to compare

@anuragxorma anuragxorma released this 30 Oct 09:49
· 28 commits to main since this release

ConceptFlow is now beta. For this release every part of the package was checked against brute force or the definitions in the literature, and the bugs found were fixed. Most of them were in the visualization, which is now also tested in a real browser in CI.

Changes that affect existing code

  • Ord2Factor now uses method="annealing" by default. The previous default, "exact", is exponential: about 20 seconds for a 15 × 15 context and hours a little beyond, without a warning. Annealing gave the same results on small contexts and takes seconds on larger ones. "exact" is still available and now stops after max_time seconds (default 60) with a TimeoutError.
  • Ord2Factor's greedy and annealing results change. They are now inclusion-minimal, as the paper states (no dropped cross could be kept). Greedy drops noticeably fewer crosses: 3 instead of 10 on triangles_en.
  • Some layout coordinates change. Line diagrams no longer draw an edge straight through a concept it does not connect.
  • conceptflow.model_selection was removed. It was an empty, undocumented placeholder.
  • Deprecated: debug_filled_pairs and debug_bottom_outer (removal in 0.6.0); use conceptflow.exploration.realized_pairs.

Visualization

  • Interactive line diagrams use reduced labelling (attributes above, objects below) instead of each concept's full intent.
  • Nodes and nested bubbles no longer overlap on larger lattices, and every node can be clicked.
  • Several interactive figures in one Jupyter notebook all draw; each is shown in its own frame.
  • Nested diagrams show attribute names exactly as given (color!=red was shown as red), and clicking the preview dots inside a bubble opens it.
  • "Save PDF" in nested diagrams writes a vector PDF of a few KB instead of a 6.9 MB image.
  • LaTeX in names is shown as symbols (\sqrt{3} → √3, \alpha → α) and typeset properly in TikZ.
  • Narrow pages work, D3 is pinned to an exact version, and invalid plotting options raise clear errors.
  • The visualization guide has a new Known limitations section.

Other fixes

  • make_random_context accepts NumPy Generators, as documented.
  • write_cxt, write_json and write_csv create missing folders.
  • Clearer errors for misused index arguments and for wrong scales in ExplorationBuilder.
  • A hand-built GraphData of an iceberg lattice no longer labels objects at the wrong concept.

Testing

  • Oracle tests: about 480 tests compare the mathematical core with independent references written from the definitions. This covers concepts, the canonical, proper-premise and Luxenburger bases, stability, incomplete contexts, GreConD and ASSO as in their papers, optimal ordinal factorization, nested diagrams and ordinal scales.
  • Browser tests: the interactive pages are tested in headless Firefox.
  • More CI platforms: CI now also runs on macOS and Windows.

Install

pip install --upgrade conceptflow

Full list of changes: changelog · compare with v0.4.0