# Arcana v1.5.2 - Table of Contents RAG (Retrieval Augmented Generation) library for Elixir ## Pages - [Arcana 🔮📚](readme.md) - Guides - [Getting Started with Arcana 🔮📚](getting-started.md) - [LLM Integration](llm-integration.md) - [Agentic RAG Pipeline](agentic-rag.md) - [Re-ranking](reranking.md) - [Search Algorithms](search-algorithms.md) - [Evaluation](evaluation.md) - [Telemetry and Observability](telemetry.md) - [Dashboard](dashboard.md) ## Modules - [Arcana.Agent](Arcana.Agent.md): Pipeline-based agentic RAG for Arcana. - [Arcana.Agent.Answerer](Arcana.Agent.Answerer.md): Behaviour for answer generation in the Agent pipeline. - [Arcana.Agent.Answerer.LLM](Arcana.Agent.Answerer.LLM.md): LLM-based answer generator. - [Arcana.Agent.Context](Arcana.Agent.Context.md): Context struct that flows through the agent pipeline. - [Arcana.Agent.Decomposer](Arcana.Agent.Decomposer.md): Behaviour for query decomposition in the Agent pipeline. - [Arcana.Agent.Decomposer.LLM](Arcana.Agent.Decomposer.LLM.md): LLM-based query decomposer. - [Arcana.Agent.Expander](Arcana.Agent.Expander.md): Behaviour for query expansion in the Agent pipeline. - [Arcana.Agent.Expander.LLM](Arcana.Agent.Expander.LLM.md): LLM-based query expander. - [Arcana.Agent.Reranker](Arcana.Agent.Reranker.md): Behaviour for re-ranking search results. - [Arcana.Agent.Reranker.ColBERT](Arcana.Agent.Reranker.ColBERT.md): ColBERT-style neural reranker using per-token embeddings and MaxSim scoring. - [Arcana.Agent.Reranker.LLM](Arcana.Agent.Reranker.LLM.md): LLM-based re-ranker that uses your configured LLM to score chunk relevance. - [Arcana.Agent.Rewriter](Arcana.Agent.Rewriter.md): Behaviour for query rewriting in the Agent pipeline. - [Arcana.Agent.Rewriter.LLM](Arcana.Agent.Rewriter.LLM.md): LLM-based query rewriter. - [Arcana.Agent.Searcher](Arcana.Agent.Searcher.md): Behaviour for search execution in the Agent pipeline. - [Arcana.Agent.Searcher.Arcana](Arcana.Agent.Searcher.Arcana.md): Default searcher using Arcana's built-in pgvector search. - [Arcana.Agent.Selector](Arcana.Agent.Selector.md): Behaviour for collection selection in the Agent pipeline. - [Arcana.Agent.Selector.LLM](Arcana.Agent.Selector.LLM.md): LLM-based collection selector. - [Arcana.Ask](Arcana.Ask.md): RAG (Retrieval Augmented Generation) question answering. - [Arcana.Chunker.Custom](Arcana.Chunker.Custom.md): Custom chunking provider using user-provided functions. - [Arcana.Chunker.Default](Arcana.Chunker.Default.md): Default text chunker using the text_chunker library. - [Arcana.Collection](Arcana.Collection.md): Represents a collection of documents for segmentation. - [Arcana.Config](Arcana.Config.md): Configuration management for Arcana. - [Arcana.Config.Redacted](Arcana.Config.Redacted.md): Wrapper struct for config values that redacts sensitive data on inspect. - [Arcana.Embedder](Arcana.Embedder.md): Behaviour for embedding providers used by Arcana. - [Arcana.Embedder.Custom](Arcana.Embedder.Custom.md): Custom embedding provider using user-provided functions. - [Arcana.Embedder.Local](Arcana.Embedder.Local.md): Local embedding provider using Bumblebee and Nx.Serving. - [Arcana.Embedder.OpenAI](Arcana.Embedder.OpenAI.md): OpenAI embedding provider using Req.LLM. - [Arcana.Evaluation](Arcana.Evaluation.md): Retrieval evaluation for measuring search quality. - [Arcana.Evaluation.AnswerMetrics](Arcana.Evaluation.AnswerMetrics.md): Evaluates answer quality using LLM-as-judge. - [Arcana.Evaluation.Generator](Arcana.Evaluation.Generator.md): Generates synthetic test cases from existing chunks. - [Arcana.Evaluation.Metrics](Arcana.Evaluation.Metrics.md): Computes retrieval evaluation metrics. - [Arcana.Evaluation.Run](Arcana.Evaluation.Run.md): An evaluation run containing metrics and per-case results. - [Arcana.Evaluation.TestCase](Arcana.Evaluation.TestCase.md): A test case for retrieval evaluation. - [Arcana.FileParser.PDF](Arcana.FileParser.PDF.md): Behaviour for PDF parsing providers. - [Arcana.FileParser.PDF.Poppler](Arcana.FileParser.PDF.Poppler.md): PDF parser using poppler's `pdftotext` command. - [Arcana.Graph](Arcana.Graph.md): GraphRAG (Graph-enhanced Retrieval Augmented Generation) for Arcana. - [Arcana.Graph.Community](Arcana.Graph.Community.md): Schema for knowledge graph communities. - [Arcana.Graph.CommunityDetector](Arcana.Graph.CommunityDetector.md): Behaviour for community detection in GraphRAG. - [Arcana.Graph.CommunityDetector.Leiden](Arcana.Graph.CommunityDetector.Leiden.md): Leiden algorithm implementation for community detection. - [Arcana.Graph.CommunitySummarizer](Arcana.Graph.CommunitySummarizer.md): Behaviour for community summarization in GraphRAG. - [Arcana.Graph.CommunitySummarizer.LLM](Arcana.Graph.CommunitySummarizer.LLM.md): LLM-based community summarizer. - [Arcana.Graph.Entity](Arcana.Graph.Entity.md): Schema for knowledge graph entities. - [Arcana.Graph.EntityExtractor](Arcana.Graph.EntityExtractor.md): Behaviour for entity extraction in GraphRAG. - [Arcana.Graph.EntityExtractor.LLM](Arcana.Graph.EntityExtractor.LLM.md): LLM-based entity extraction implementation. - [Arcana.Graph.EntityExtractor.NER](Arcana.Graph.EntityExtractor.NER.md): Extracts named entities from text using Bumblebee NER. - [Arcana.Graph.EntityMention](Arcana.Graph.EntityMention.md): Schema for tracking where entities appear in chunks. - [Arcana.Graph.FusionSearch](Arcana.Graph.FusionSearch.md): Combines vector search and graph-based search using Reciprocal Rank Fusion. - [Arcana.Graph.GraphBuilder](Arcana.Graph.GraphBuilder.md): Builds knowledge graph data from document chunks. - [Arcana.Graph.GraphExtractor](Arcana.Graph.GraphExtractor.md): Behaviour for combined entity and relationship extraction in GraphRAG. - [Arcana.Graph.GraphExtractor.LLM](Arcana.Graph.GraphExtractor.LLM.md): LLM-based combined entity and relationship extraction. - [Arcana.Graph.GraphQuery](Arcana.Graph.GraphQuery.md): Queries the knowledge graph for entities, relationships, and community summaries. - [Arcana.Graph.GraphStore](Arcana.Graph.GraphStore.md): Behaviour and dispatch module for graph storage backends. - [Arcana.Graph.GraphStore.Ecto](Arcana.Graph.GraphStore.Ecto.md): Ecto/PostgreSQL implementation of the GraphStore behaviour. - [Arcana.Graph.GraphStore.Memory](Arcana.Graph.GraphStore.Memory.md): In-memory implementation of the GraphStore behaviour. - [Arcana.Graph.NERServing](Arcana.Graph.NERServing.md): Lazy-loaded Nx.Serving for Named Entity Recognition using Bumblebee. - [Arcana.Graph.Relationship](Arcana.Graph.Relationship.md): Schema for knowledge graph relationships between entities. - [Arcana.Graph.RelationshipExtractor](Arcana.Graph.RelationshipExtractor.md): Behaviour for relationship extraction in GraphRAG. - [Arcana.Graph.RelationshipExtractor.LLM](Arcana.Graph.RelationshipExtractor.LLM.md): LLM-based relationship extraction implementation. - [Arcana.Ingest](Arcana.Ingest.md): Document ingestion for Arcana. - [Arcana.LLM](Arcana.LLM.md): Protocol for LLM adapters used by Arcana. - [Arcana.Maintenance](Arcana.Maintenance.md): Maintenance functions for Arcana. - [Arcana.Parser](Arcana.Parser.md): Parses files into text content for ingestion. - [Arcana.Search](Arcana.Search.md): Search functionality for Arcana. - [Arcana.TaskSupervisor](Arcana.TaskSupervisor.md): Task supervisor for async operations in Arcana. - [Arcana.Telemetry](Arcana.Telemetry.md): Telemetry events emitted by Arcana. - [Arcana.Telemetry.Logger](Arcana.Telemetry.Logger.md): Ready-to-use telemetry logger for Arcana events. - [Arcana.VectorStore](Arcana.VectorStore.md): Behaviour and dispatch module for vector storage backends. - [Arcana.VectorStore.Memory](Arcana.VectorStore.Memory.md): In-memory vector store using HNSWLib for approximate nearest neighbor search. - [Arcana.VectorStore.Pgvector](Arcana.VectorStore.Pgvector.md): PostgreSQL pgvector-backed vector store. - [ArcanaWeb.AskLive](ArcanaWeb.AskLive.md): LiveView for asking questions about documents in Arcana. - [ArcanaWeb.CollectionsLive](ArcanaWeb.CollectionsLive.md): LiveView for managing collections in Arcana. - [ArcanaWeb.DashboardComponents](ArcanaWeb.DashboardComponents.md): Shared components for the Arcana dashboard. - [ArcanaWeb.DocumentsLive](ArcanaWeb.DocumentsLive.md): LiveView for managing documents in Arcana. - [ArcanaWeb.EvaluationLive](ArcanaWeb.EvaluationLive.md): LiveView for retrieval evaluation in Arcana. - [ArcanaWeb.GraphLive](ArcanaWeb.GraphLive.md): LiveView for exploring the GraphRAG knowledge graph. - [ArcanaWeb.InfoLive](ArcanaWeb.InfoLive.md): LiveView for displaying Arcana configuration info. - [ArcanaWeb.MaintenanceLive](ArcanaWeb.MaintenanceLive.md): LiveView for maintenance operations in Arcana. - [ArcanaWeb.Router](ArcanaWeb.Router.md): Provides LiveView routing for the Arcana dashboard. - [ArcanaWeb.SearchLive](ArcanaWeb.SearchLive.md): LiveView for searching documents in Arcana. - Core - [Arcana](Arcana.md): RAG (Retrieval Augmented Generation) library for Elixir. - [Arcana.Chunk](Arcana.Chunk.md): Schema for document chunks with embeddings. - [Arcana.Document](Arcana.Document.md): Schema for documents stored in Arcana. - Utilities - [Arcana.Chunker](Arcana.Chunker.md): Behaviour for text chunking providers used by Arcana. - [Arcana.Rewriters](Arcana.Rewriters.md): Built-in query rewriter helpers for common rewriting strategies. - Embeddings - [Arcana.Embeddings.Serving](Arcana.Embeddings.Serving.md): Nx.Serving for text embeddings using Bumblebee. - LiveView UI - [ArcanaWeb.DashboardLive](ArcanaWeb.DashboardLive.md): Redirects to the Documents page. ## Mix Tasks - [mix arcana.eval.generate](Mix.Tasks.Arcana.Eval.Generate.md): Generates synthetic test cases from existing chunks. - [mix arcana.eval.run](Mix.Tasks.Arcana.Eval.Run.md): Runs evaluation and prints metrics. - [mix arcana.gen.embedding_migration](Mix.Tasks.Arcana.Gen.EmbeddingMigration.md): Generates a migration to update vector column dimensions. - [mix arcana.graph.detect_communities](Mix.Tasks.Arcana.Graph.DetectCommunities.md): Detects communities in the knowledge graph using the Leiden algorithm. - [mix arcana.graph.install](Mix.Tasks.Arcana.Graph.Install.md): Generates the migration for GraphRAG tables. - [mix arcana.graph.rebuild](Mix.Tasks.Arcana.Graph.Rebuild.md): Rebuilds the knowledge graph for all documents. - [mix arcana.graph.summarize_communities](Mix.Tasks.Arcana.Graph.SummarizeCommunities.md): Generates LLM summaries for knowledge graph communities. - [mix arcana.install](Mix.Tasks.Arcana.Install.md): Installs Arcana in your Phoenix application. - [mix arcana.reembed_chunks](Mix.Tasks.Arcana.ReembedChunks.md): Re-embeds all chunks with the current embedding configuration.