Context & Decision Intelligence
semantica.contextTrack decisions as first-class graph objects with full causal lineage, precedent search, and a built-in policy compliance gate. Every AI choice becomes permanent, queryable, and defensible.
Context Graphs
Temporal validity windows, typed entities and edges
Decision Tracking
record_decision() — structured, searchable, permanent
Causal Chains
add_causal_relationship() — trigger / enable / inhibit
Precedent Search
find_similar_decisions() — semantic similarity over history
Influence Analysis
analyze_decision_impact() — downstream effect map
Policy Engine
check_decision_rules() — compliance gate with configurable rule sets
Agent Memory
Short and long-term storage for multi-agent pipelines
Cross-System Context
Single shared intelligence layer across all agents
graph = ContextGraph(advanced_analytics=True)
decision_id = graph.record_decision(
category="vendor_selection",
outcome="selected_aws",
confidence=0.93,
)
chain = graph.trace_decision_chain(decision_id)8 features · independently importable
View documentationKnowledge Graph Engine
semantica.kgBuild a production knowledge graph from any data source with full graph algorithm coverage — centrality, community detection, link prediction, and incremental updates.
Entity Management
Typed nodes and edges with arbitrary metadata
PageRank
Importance scoring across the full graph
Betweenness Centrality
Bridge detection — find the nodes that connect communities
Louvain Detection
Natural cluster discovery via community algorithms
Node2Vec Embeddings
Graph-native embeddings via NodeEmbedder
Similarity Calculator
Cosine similarity between any two node pairs
Link Prediction
Predict missing edges with LinkPredictor
Delta Processing
Incremental updates without full graph rebuilds
kg = GraphBuilder(merge_entities=True, enable_temporal=True).build(docs)
centrality = CentralityCalculator().calculate_degree_centrality(kg)
communities = CommunityDetector().detect_communities(kg, method="louvain")
path = PathFinder().find_shortest_path(kg, "alice", "contract_001")8 features · independently importable
View documentationReasoning Engines
semantica.reasoningFive deterministic reasoning engines with fully explainable inference paths. No black boxes — every conclusion traces back to the rules and facts that produced it.
Forward Chaining
IF/THEN rule execution over a growing fact base
Rete Network
High-throughput pattern matching for real-time compliance
Deductive Reasoning
Classical inference — modus ponens, modus tollens
Abductive Reasoning
Hypothesis generation from incomplete observations
SPARQL Reasoning
RDF graph queries with full triple store support
Datalog
Recursive declarative queries — ancestor(X, Z) :- ...
Explainable Paths
Full reasoning trace for every conclusion
Custom Pipelines
Compose multiple engines into a single inference chain
rete = ReteEngine()
rete.build_network([Rule(
rule_id="aml_flag",
conditions=[{"field": "amount", "operator": ">", "value": 10_000}],
conclusion="flag_for_compliance_review",
rule_type=RuleType.IMPLICATION,
)])
flagged = rete.match_patterns()8 features · independently importable
View documentationTemporal Intelligence
semantica.kg (temporal)Query the graph as it existed at any past moment. Track valid time vs. recorded time independently with bi-temporal facts, and use Allen interval algebra to express any temporal relationship.
Temporal GraphRAG
Time-aware retrieval that respects validity windows
Allen Interval Algebra
13 temporal relations — before, during, overlaps, meets…
Point-in-Time Queries
graph.state_at("2024-01-01") — replay history
TemporalNormalizer
Parse natural language dates — "last quarter", "3 weeks ago"
Bi-Temporal Facts
Separate valid_time from recorded_at
Validity Windows
Decisions bounded by valid_from / valid_until
Named Checkpoints
Version snapshots for reproducible history
TemporalGraphQuery
Range queries across any time dimension
graph.add_node("alice_chen", "Person", role="VP Engineering")
snapshot_2023 = graph.state_at("2023-06-01")
snapshot_2024 = graph.state_at("2024-01-01")
tq = TemporalGraphQuery(graph)
facts = tq.query_time_range("2024-01-01", "2024-12-31")8 features · independently importable
View documentationProvenance & Auditability
semantica.provenanceEvery fact links to its source. W3C PROV-O compliant audit trails exportable as Turtle, JSON-LD, CSV, or JSON — the format regulators, auditors, and compliance frameworks require.
Entity Provenance
ProvenanceTracker.track_entity() — source, page, confidence
Algorithm Provenance
Track which extractor, model, and version produced each fact
Relationship Provenance
Source attribution on every edge in the graph
W3C PROV-O
Standard compliance — exportable for regulator submission
Change Management
Checksums and diffs across graph versions
Audit Trails
Full compliance logging for every mutation
Lineage Tracing
trace_lineage() — full ancestor chain for any entity
Export Formats
Turtle, JSON-LD, N-Triples, JSON, CSV, Parquet
prov = ProvenanceManager(storage_path="./audit.db")
prov.track_entity("acme_corp", source="contract.pdf",
metadata={"page": 1, "confidence": 0.97})
lineage = prov.get_lineage("acme_corp")
RDFExporter().export(kg, "audit_trail.ttl", format="turtle")8 features · independently importable
View documentationOntology & Schema Management
semantica.ontologyAuto-generate OWL ontologies from your data, validate entity shapes with SHACL, manage SKOS vocabularies, and import from any existing RDF/OWL schema in seconds.
OWL Generation
Auto-create class hierarchies and property definitions from data
Schema Import
OWL, RDF, Turtle, JSON-LD — any existing vocabulary
HermiT / Pellet
Consistency checking via description logic reasoners
SHACL Shapes
Auto-generated validation — catches constraint violations at ingest
SKOS Vocabulary
Concept management with broader/narrower/related relations
Strictness Tiers
Basic / standard / strict — tune validation aggressiveness
Inheritance
Property propagation through the class hierarchy
Multi-Format Export
Turtle, JSON-LD, N-Triples, OWL/XML
gen = OntologyGenerator()
ontology = gen.generate_ontology({"entities": entities, "relationships": []})
classes = gen.infer_classes({"entities": entities, "relationships": []})
report = OntologyValidator().validate(ontology)
if report.conforms:
RDFExporter().export(ontology, "schema.ttl", format="turtle")8 features · independently importable
View documentation