feat: implement RAG capabilities and Context Pane integration
- Add RAG capabilities using LlamaIndex and ChromaDB - Implement RAGManager for PHB indexing and retrieval - Integrate RAG pipeline into orchestrator to trigger queries based on extracted entities - Update TUI to include a 3-column layout with a real-time Context Pane - Define ContextUpdate data models in src/llm/models.py - Update requirements.txt with new dependencies
This commit is contained in:
@@ -44,6 +44,16 @@ class CharacterStateUpdate(BaseModel):
|
||||
)
|
||||
|
||||
|
||||
class ContextUpdate(BaseModel):
|
||||
query: str = Field(..., description="The search query used to retrieve the context")
|
||||
snippet: str = Field(
|
||||
..., description="The relevant text snippet retrieved from the source"
|
||||
)
|
||||
source: str = Field(
|
||||
..., description="The source of the snippet (e.g., 'PHB p. 12')"
|
||||
)
|
||||
|
||||
|
||||
class ExtractionResult(BaseModel):
|
||||
lore_updates: List[LoreUpdate] = Field(
|
||||
default_factory=list, description="List of discovered lore facts", alias="lore"
|
||||
|
||||
Reference in New Issue
Block a user