mirror of
https://github.com/trustgraph-ai/trustgraph.git
synced 2026-06-14 09:15:13 +02:00
Replace hallucinated relative imports with correct absolute imports across the ontology query package, and fix OntologyMatcher reference to match the actual class name OntologyMatcherForQueries. Simplify test to use standard imports instead of importlib hack.
54 lines
No EOL
1.5 KiB
Python
54 lines
No EOL
1.5 KiB
Python
"""
|
|
OntoRAG Query System.
|
|
|
|
Ontology-driven natural language query processing with multi-backend support.
|
|
Provides semantic query understanding, ontology matching, and answer generation.
|
|
"""
|
|
|
|
from .query_service import OntoRAGQueryService, QueryRequest, QueryResponse
|
|
from .question_analyzer import QuestionAnalyzer, QuestionComponents, QuestionType
|
|
from .ontology_matcher import OntologyMatcherForQueries, QueryOntologySubset
|
|
from .backend_router import BackendRouter, BackendType, QueryRoute
|
|
from .sparql_generator import SPARQLGenerator, SPARQLQuery
|
|
from .sparql_cassandra import SPARQLCassandraEngine, SPARQLResult
|
|
from .cypher_generator import CypherGenerator, CypherQuery
|
|
from .cypher_executor import CypherExecutor, CypherResult
|
|
from .answer_generator import AnswerGenerator, GeneratedAnswer, AnswerMetadata
|
|
|
|
__all__ = [
|
|
# Main service
|
|
'OntoRAGQueryService',
|
|
'QueryRequest',
|
|
'QueryResponse',
|
|
|
|
# Question analysis
|
|
'QuestionAnalyzer',
|
|
'QuestionComponents',
|
|
'QuestionType',
|
|
|
|
# Ontology matching
|
|
'OntologyMatcherForQueries',
|
|
'QueryOntologySubset',
|
|
|
|
# Backend routing
|
|
'BackendRouter',
|
|
'BackendType',
|
|
'QueryRoute',
|
|
|
|
# SPARQL components
|
|
'SPARQLGenerator',
|
|
'SPARQLQuery',
|
|
'SPARQLCassandraEngine',
|
|
'SPARQLResult',
|
|
|
|
# Cypher components
|
|
'CypherGenerator',
|
|
'CypherQuery',
|
|
'CypherExecutor',
|
|
'CypherResult',
|
|
|
|
# Answer generation
|
|
'AnswerGenerator',
|
|
'GeneratedAnswer',
|
|
'AnswerMetadata',
|
|
] |