Skip to content

Graph-Native Infrastructure for Context and Accountable AI Systems

docs: organize documentation with Pydantic-style features

KaifAhmad10d2862be724f
diff --git a/docs/concepts.md b/docs/concepts.md
index 22031951..0a5369ab 100644
--- a/docs/concepts.md
+++ b/docs/concepts.md
@@ -2,10 +2,16 @@
Understand the fundamental concepts behind Semantica.
+!!! note "Conceptual Foundation"
+ This guide covers the theoretical foundations of Semantica. For hands-on examples, see the [Quickstart Guide](quickstart.md) or [Examples](examples.md).
+
## What is a Knowledge Graph?
A knowledge graph is a structured representation of information where:
+!!! tip "Visual Understanding"
+ The diagram below shows how entities (nodes) are connected by relationships (edges) to form a knowledge graph. This structure enables powerful querying and reasoning capabilities.
+
- **Entities** are the nodes (people, places, concepts, etc.)
- **Relationships** are the edges connecting entities
- **Properties** describe attributes of entities
@@ -133,6 +139,9 @@ Unify data from multiple sources:
## Best Practices
+!!! note "Best Practices"
+ Following these practices will help you build high-quality knowledge graphs and avoid common pitfalls.
+
### 1. Start Small
Begin with a single document or small dataset to understand the workflow.
diff --git a/docs/css/custom.css b/docs/css/custom.css
index d1dd4725..df84aef6 100644
--- a/docs/css/custom.css
+++ b/docs/css/custom.css
@@ -132,42 +132,134 @@ html {
display: none !important;
}
-/* Table of Contents - Move to Left Side */
+/* Table of Contents - Three Column Layout with Sidebars */
@media screen and (min-width: 76.25em) {
+ /* Left Navigation Sidebar */
.md-sidebar--primary {
- width: 8rem !important;
+ width: 16rem !important;
+ position: fixed !important;
+ left: 0 !important;
+ top: 2.4rem !important;
+ height: calc(100vh - 2.4rem) !important;
+ overflow-y: auto !important;
+ overflow-x: hidden !important;
+ border-right: 1px solid rgba(0, 0, 0, 0.1) !important;
+ background-color: var(--md-default-bg-color) !important;
+ }
+
+ [data-md-color-scheme="slate"] .md-sidebar--primary {
+ border-right: 1px solid rgba(255, 255, 255, 0.12) !important;
}
+ /* Right TOC Sidebar */
.md-sidebar--secondary {
- left: 0 !important;
- right: auto !important;
- width: 8rem !important;
- border-right: 1px solid var(--md-default-fg-color--lightest);
+ position: fixed !important;
+ right: 0 !important;
+ top: 2.4rem !important;
+ width: 16rem !important;
+ height: calc(100vh - 2.4rem) !important;
+ overflow-y: auto !important;
+ overflow-x: hidden !important;
+ border-left: 1px solid rgba(0, 0, 0, 0.1) !important;
+ background-color: var(--md-default-bg-color) !important;
+ }
+
+ [data-md-color-scheme="slate"] .md-sidebar--secondary {
+ border-left: 1px solid rgba(255, 255, 255, 0.12) !important;
}
+ /* Content Area - Fill space between sidebars with no gaps */
.md-content {
- margin-left: 8rem !important;
- margin-right: 8rem !important;
+ margin-left: 16rem !important;
+ margin-right: 16rem !important;
+ max-width: none !important;
+ padding-left: 0 !important;
+ padding-right: 0 !important;
}
+
+ /* Ensure sidebars scroll properly */
+ .md-sidebar__scrollwrap {
+ overflow-y: auto !important;
+ overflow-x: hidden !important;
+ height: 100% !important;
+ }
+}
+
+/* Custom Scrollbar Styling for Sidebars */
+.md-sidebar--primary::-webkit-scrollbar,
+.md-sidebar--secondary::-webkit-scrollbar {
+ width: 8px;
+}
+
+.md-sidebar--primary::-webkit-scrollbar-track,
+.md-sidebar--secondary::-webkit-scrollbar-track {
+ background: transparent;
}
-/* Ensure content uses full available width */
+.md-sidebar--primary::-webkit-scrollbar-thumb,
+.md-sidebar--secondary::-webkit-scrollbar-thumb {
+ background: rgba(0, 0, 0, 0.2);
+ border-radius: 4px;
+}
+
+.md-sidebar--primary::-webkit-scrollbar-thumb:hover,
+.md-sidebar--secondary::-webkit-scrollbar-thumb:hover {
+ background: rgba(0, 0, 0, 0.3);
+}
+
+[data-md-color-scheme="slate"] .md-sidebar--primary::-webkit-scrollbar-thumb,
+[data-md-color-scheme="slate"] .md-sidebar--secondary::-webkit-scrollbar-thumb {
+ background: rgba(255, 255, 255, 0.2);
+}
+
+[data-md-color-scheme="slate"] .md-sidebar--primary::-webkit-scrollbar-thumb:hover,
+[data-md-color-scheme="slate"] .md-sidebar--secondary::-webkit-scrollbar-thumb:hover {
+ background: rgba(255, 255, 255, 0.3);
+}
+
+/* Ensure content uses full available width - Gap-free layout */
.md-grid {
max-width: 100% !important;
}
.md-content__inner {
max-width: 100% !important;
- padding-left: 1rem;
- padding-right: 1rem;
+ padding-left: 2rem !important;
+ padding-right: 2rem !important;
+ margin: 0 !important;
}
.md-main__inner {
max-width: 100% !important;
+ margin: 0 !important;
}
.md-container {
- padding: 0;
+ padding: 0 !important;
+ margin: 0 !important;
+}
+
+/* Remove gaps between sidebars and content */
+@media screen and (min-width: 76.25em) {
+ .md-main {
+ margin: 0 !important;
+ padding: 0 !important;
+ }
+
+ .md-content {
+ padding-left: 0 !important;
+ padding-right: 0 !important;
+ margin-top: 0 !important;
+ }
+
+ /* Ensure sidebars are flush with content */
+ .md-sidebar--primary {
+ margin-right: 0 !important;
+ }
+
+ .md-sidebar--secondary {
+ margin-left: 0 !important;
+ }
}
/* Reduce spacing for compact look */
@@ -335,4 +427,147 @@ html {
.md-header__inner {
padding-bottom: 0.5rem !important;
gap: 0.5rem !important;
+}
+
+/* ============================================
+ Pydantic-Style Callout Boxes (Admonitions)
+ ============================================ */
+
+/* Base Admonition Styling */
+.md-typeset .admonition {
+ border-radius: 6px;
+ border-left-width: 4px;
+ margin: 1.5em 0;
+ padding: 1em 1.5em;
+ box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
+}
+
+[data-md-color-scheme="slate"] .md-typeset .admonition {
+ box-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
+}
+
+/* Note - Blue */
+.md-typeset .admonition.note,
+.md-typeset .admonition-title--note {
+ border-color: #2196F3;
+ background-color: rgba(33, 150, 243, 0.1);
+}
+
+[data-md-color-scheme="slate"] .md-typeset .admonition.note {
+ background-color: rgba(33, 150, 243, 0.15);
+ border-color: #42A5F5;
+}
+
+.md-typeset .admonition.note .admonition-title {
+ background-color: rgba(33, 150, 243, 0.2);
+ border-color: #2196F3;
+ color: #1976D2;
+ font-weight: 600;
+}
+
+[data-md-color-scheme="slate"] .md-typeset .admonition.note .admonition-title {
+ background-color: rgba(33, 150, 243, 0.25);
+ color: #64B5F6;
+}
+
+/* Tip - Green */
+.md-typeset .admonition.tip,
+.md-typeset .admonition-title--tip {
+ border-color: #4CAF50;
+ background-color: rgba(76, 175, 80, 0.1);
+}
+
+[data-md-color-scheme="slate"] .md-typeset .admonition.tip {
+ background-color: rgba(76, 175, 80, 0.15);
+ border-color: #66BB6A;
+}
+
+.md-typeset .admonition.tip .admonition-title {
+ background-color: rgba(76, 175, 80, 0.2);
+ border-color: #4CAF50;
+ color: #388E3C;
+ font-weight: 600;
+}
+
+[data-md-color-scheme="slate"] .md-typeset .admonition.tip .admonition-title {
+ background-color: rgba(76, 175, 80, 0.25);
+ color: #81C784;
+}
+
+/* Warning - Orange/Yellow */
+.md-typeset .admonition.warning,
+.md-typeset .admonition-title--warning {
+ border-color: #FF9800;
+ background-color: rgba(255, 152, 0, 0.1);
+}
+
+[data-md-color-scheme="slate"] .md-typeset .admonition.warning {
+ background-color: rgba(255, 152, 0, 0.15);
+ border-color: #FFB74D;
+}
+
+.md-typeset .admonition.warning .admonition-title {
+ background-color: rgba(255, 152, 0, 0.2);
+ border-color: #FF9800;
+ color: #F57C00;
+ font-weight: 600;
+}
+
+[data-md-color-scheme="slate"] .md-typeset .admonition.warning .admonition-title {
+ background-color: rgba(255, 152, 0, 0.25);
+ color: #FFB74D;
+}
+
+/* Danger - Red */
+.md-typeset .admonition.danger,
+.md-typeset .admonition-title--danger {
+ border-color: #F44336;
+ background-color: rgba(244, 67, 54, 0.1);
+}
+
+[data-md-color-scheme="slate"] .md-typeset .admonition.danger {
+ background-color: rgba(244, 67, 54, 0.15);
+ border-color: #E57373;
+}
+
+.md-typeset .admonition.danger .admonition-title {
+ background-color: rgba(244, 67, 54, 0.2);
+ border-color: #F44336;
+ color: #D32F2F;
+ font-weight: 600;
+}
+
+[data-md-color-scheme="slate"] .md-typeset .admonition.danger .admonition-title {
+ background-color: rgba(244, 67, 54, 0.25);
+ color: #EF5350;
+}
+
+/* Admonition Content Styling */
+.md-typeset .admonition p {
+ margin-top: 0.5em;
+ margin-bottom: 0.5em;
+}
+
+.md-typeset .admonition p:first-child {
+ margin-top: 0;
+}
+
+.md-typeset .admonition p:last-child {
+ margin-bottom: 0;
+}
+
+/* Admonition Icons */
+.md-typeset .admonition-title::before {
+ margin-right: 0.5em;
+}
+
+/* Info - Alternative blue (if used) */
+.md-typeset .admonition.info {
+ border-color: #00BCD4;
+ background-color: rgba(0, 188, 212, 0.1);
+}
+
+[data-md-color-scheme="slate"] .md-typeset .admonition.info {
+ background-color: rgba(0, 188, 212, 0.15);
+ border-color: #4DD0E1;
}
\ No newline at end of file
diff --git a/docs/examples.md b/docs/examples.md
index 4f2f5ea4..16e65115 100644
--- a/docs/examples.md
+++ b/docs/examples.md
@@ -2,8 +2,14 @@
Real-world examples and use cases for Semantica.
+!!! tip "Interactive Learning"
+ For hands-on interactive tutorials, check out our [Cookbook](cookbook.md) with Jupyter notebooks covering everything from basics to advanced use cases.
+
## Basic Examples
+!!! note "Code Examples"
+ All examples assume you have Semantica installed and imported. See the [Installation Guide](installation.md) if you need to set it up first.
+
### Example 1: Basic Knowledge Graph
Build a knowledge graph from a single document:
diff --git a/docs/getting-started.md b/docs/getting-started.md
index 5cb260ea..f3dbb7ea 100644
--- a/docs/getting-started.md
+++ b/docs/getting-started.md
@@ -2,6 +2,9 @@
Welcome to Semantica! This guide will help you get up and running quickly.
+!!! note "First Time User?"
+ If you're new to knowledge graphs or semantic processing, we recommend starting with the [Core Concepts](concepts.md) guide to understand the fundamentals before diving into code.
+
## Choose Your Path
=== "πŸš€ Quick Start (5 min)"
@@ -36,6 +39,9 @@ Welcome to Semantica! This guide will help you get up and running quickly.
Perfect for: Hands-on learners
+!!! tip "Choose Your Path"
+ Not sure where to start? The Quick Start path (5 min) is perfect for trying Semantica quickly, while the Complete Guide (30 min) provides thorough understanding for production use.
+
## What Can You Build?
Semantica helps you transform unstructured data into intelligent knowledge:
@@ -63,6 +69,9 @@ Semantica helps you transform unstructured data into intelligent knowledge:
- Enhance AI agent memory
- Build semantic search systems
+!!! warning "Installation First"
+ Make sure you have Semantica installed before proceeding. If you encounter any issues, check the [Installation Guide](installation.md) troubleshooting section.
+
## Next Steps
Once you're set up:
diff --git a/docs/index.md b/docs/index.md
index 24d5de1e..d2402f00 100644
--- a/docs/index.md
+++ b/docs/index.md
@@ -8,6 +8,9 @@
Semantica is an open-source framework for building semantic layers and knowledge graphs that power the next generation of AI applications.
+!!! tip "New to Semantica?"
+ Start with the [Quickstart Guide](quickstart.md) to build your first knowledge graph in minutes, or explore our [interactive Cookbook](cookbook.md) for hands-on tutorials.
+
## πŸš€ Get Started in 60 Seconds
```python
@@ -20,6 +23,9 @@ print(f"Extracted {len(result['knowledge_graph']['entities'])} entities")
**Install:** `pip install semantica`
+!!! note "Installation Requirements"
+ Semantica requires Python 3.8+. For complete installation instructions including optional dependencies, see the [Installation Guide](installation.md).
+
## Choose Your Learning Path
### ⚑ Quick Start (5 min)
@@ -87,6 +93,9 @@ Generate embeddings for text, images, and audio.
### πŸ” Vector Store Integration
Store and query embeddings efficiently with support for multiple vector stores.
+!!! tip "Production Ready"
+ Semantica is designed for production use with enterprise-grade features including conflict resolution, quality assurance, and scalable processing pipelines.
+
## Resources
- **GitHub**: [github.com/Hawksight-AI/semantica](https://github.com/Hawksight-AI/semantica)
diff --git a/docs/installation.md b/docs/installation.md
index 3f1dc8e1..e8238f0a 100644
--- a/docs/installation.md
+++ b/docs/installation.md
@@ -2,6 +2,9 @@
Get Semantica up and running in minutes.
+!!! note "System Requirements"
+ Semantica requires Python 3.8 or higher. For best performance, we recommend Python 3.10+.
+
## Prerequisites
Before installing Semantica, ensure you have:
@@ -22,6 +25,9 @@ pip install semantica
This installs Semantica with all core dependencies.
+!!! tip "Virtual Environment"
+ We recommend installing Semantica in a virtual environment to avoid dependency conflicts. Use `python -m venv venv` to create one, then activate it before installing.
+
## Verify Installation
Verify that Semantica is installed correctly:
diff --git a/docs/quickstart.md b/docs/quickstart.md
index acd7e972..8e99e9cf 100644
--- a/docs/quickstart.md
+++ b/docs/quickstart.md
@@ -2,6 +2,9 @@
Get started with Semantica in 5 minutes. This guide will walk you through building your first knowledge graph.
+!!! tip "Before You Start"
+ Make sure you have Semantica installed. If not, follow the [Installation Guide](installation.md) first. This quickstart assumes basic Python knowledge.
+
## Overview
```mermaid
@@ -26,6 +29,9 @@ pip install semantica
See the [Installation Guide](installation.md) for detailed instructions.
+!!! note "Installation Options"
+ For production use, consider installing with optional dependencies for better performance: `pip install semantica[all]`. See the [Installation Guide](installation.md) for all options.
+
## Step 2: Your First Knowledge Graph
Let's build a knowledge graph from a document: