mirror of
https://github.com/trustgraph-ai/trustgraph.git
synced 2026-05-18 03:45:12 +02:00
* Plugin architecture for messaging fabric * Schemas use a technology neutral expression * Schemas strictness has uncovered some incorrect schema use which is fixed
23 lines
707 B
Python
23 lines
707 B
Python
from dataclasses import dataclass, field
|
|
|
|
from ..core.primitives import Error
|
|
from ..core.topic import topic
|
|
|
|
############################################################################
|
|
|
|
# Structured Query Service - executes GraphQL queries
|
|
|
|
@dataclass
|
|
class StructuredQueryRequest:
|
|
question: str = ""
|
|
user: str = "" # Cassandra keyspace identifier
|
|
collection: str = "" # Data collection identifier
|
|
|
|
@dataclass
|
|
class StructuredQueryResponse:
|
|
error: Error | None = None
|
|
data: str = "" # JSON-encoded GraphQL response data
|
|
errors: list[str] = field(default_factory=list) # GraphQL errors if any
|
|
|
|
############################################################################
|
|
|