kg-manager in place

This commit is contained in:
Cyber MacGeddon 2025-05-06 20:12:54 +01:00
parent 0cd5340bb1
commit 40c0f84b36
8 changed files with 15 additions and 8 deletions

View file

@ -1,5 +1,5 @@
from pulsar.schema import Record, Bytes, String, Array, Long
from pulsar.schema import Record, Bytes, String, Array, Long, Boolean
from . types import Triple
from . topic import topic
from . types import Error

View file

@ -0,0 +1,6 @@
#!/usr/bin/env python3
from trustgraph.cores import run
run()

View file

@ -96,6 +96,7 @@ setuptools.setup(
"scripts/kg-extract-relationships",
"scripts/kg-extract-topics",
"scripts/kg-store",
"scripts/kg-manager",
"scripts/librarian",
"scripts/metering",
"scripts/object-extract-row",

View file

@ -2,7 +2,7 @@
from .. schema import KnowledgeResponse, Error, Triple
from .. knowledge import hash
from .. exceptions import RequestError
from . table_store import TableStore
from .. tables.knowledge import KnowledgeTableStore
from . blob_store import BlobStore
import base64
@ -15,7 +15,7 @@ class KnowledgeManager:
keyspace,
):
self.table_store = TableStore(
self.table_store = KnowledgeTableStore(
cassandra_host, cassandra_user, cassandra_password, keyspace
)

View file

@ -2,7 +2,7 @@
from .. schema import LibrarianRequest, LibrarianResponse, Error, Triple
from .. knowledge import hash
from .. exceptions import RequestError
from . table_store import TableStore
from .. tables.library import LibraryTableStore
from . blob_store import BlobStore
import base64

View file

@ -9,7 +9,7 @@ import urllib.parse
from ... schema import Triples, GraphEmbeddings
from ... base import FlowProcessor, ConsumerSpec
from . table_store import TableStore
from ... tables.knowledge import KnowledgeTableStore
default_ident = "kg-store"
@ -50,7 +50,7 @@ class Processor(FlowProcessor):
)
)
self.table_store = TableStore(
self.table_store = KnowledgeTableStore(
cassandra_host = cassandra_host.split(","),
cassandra_user = cassandra_user,
cassandra_password = cassandra_password,

View file

@ -7,7 +7,7 @@ import uuid
import time
import asyncio
class TableStore:
class KnowledgeTableStore:
def __init__(
self,

View file

@ -14,7 +14,7 @@ import uuid
import time
import asyncio
class TableStore:
class LibraryTableStore:
def __init__(
self,