Adds Node to precalculate jsons for visualisations

This commit is contained in:
quorploop 2026-01-29 22:08:01 +01:00
parent 7c2e34906e
commit d9d0441ddd
3 changed files with 194 additions and 18 deletions

View file

@ -215,6 +215,7 @@ def create_default_pipeline(device: str = "cpu",
from author_node import NerAuthorNode, FuzzyAuthorNode
from embeddings_node import TextEmbeddingNode, UmapNode
from url_node import URLNode
from to_d3_node import ToD3Node
pipeline = ParallelPipeline(max_workers=max_workers, use_processes=False)
@ -261,6 +262,21 @@ def create_default_pipeline(device: str = "cpu",
name='UmapNode'
))
pipeline.add_node(NodeConfig(
node_class=ToD3Node,
dependencies=[
'UmapNode',
'TextEmbeddingNode',
'FuzzyAuthorNode',
'AuthorNode',
'URLNode'
],
node_kwargs={
'output_path': './data/json/'
},
name='ToD3Node'
))
# TODO: Create Node to compute Text Embeddings and UMAP.
# pipeline.add_node(NodeConfig(