Spaces:
Sleeping
Sleeping
Claude Code - Backend Implementation Specialist
Claude Sonnet 4.5
Add Docker deployment configuration for Hugging Face Spaces
36bfe21 Download app/models/document.py from Abdul18/Rag_Chatbot: direct link, hf CLI and curl.
- Browser
- Download file 620 Bytes
-
https://huggingface.co/spaces/Abdul18/Rag_Chatbot/resolve/main/app/models/document.py
- Command line
-
hf download hf://spaces/Abdul18/Rag_Chatbot/app/models/document.py
-
curl -L -o document.py https://huggingface.co/spaces/Abdul18/Rag_Chatbot/resolve/main/app/models/document.py
620 Bytes
| from pydantic import BaseModel | |
| from typing import Optional, List | |
| class DocumentChunk(BaseModel): | |
| """Model for a document chunk to be indexed.""" | |
| chunk_id: str | |
| chapter_number: int | |
| chapter_title: str | |
| section_title: str | |
| content: str | |
| content_type: str # text, code, callout, quiz | |
| url: str | |
| keywords: Optional[List[str]] = None | |
| word_count: int | |
| class SearchResult(BaseModel): | |
| """Model for a search result from Qdrant.""" | |
| chunk_id: str | |
| chapter_number: int | |
| chapter_title: str | |
| section_title: str | |
| content: str | |
| content_type: str | |
| url: str | |
| score: float | |