How aawhan0/dasaiko works
Dasaiko is an AI research workspace for reading papers, asking paper-aware questions, and inspecting evidence behind grounded answers. The principal loop runs from the researcher’s workspace through chat and context-aware retrieval, then hybrid search and reranking select evidence for answer generation and display. A separate ingestion path turns uploaded PDFs into searchable chunks and embeddings; authentication and persistent research context support the workspace. The graph combines README-documented capabilities with sampled source references; links to unsampled implementations are omitted or marked unverified.
Main entry points: chat_service.py Chat orchestration · search_service.py Hybrid retrieval · chunk.py Paper and chunk records · WorkspacePage.tsx Workspace UI
Components 24
Research workspace
- Workspace UI
frontend/src/pages/WorkspacePage.tsx - Paper reader
frontend/src/components/pdf/PDFViewer.tsx - Paper upload
frontend/src/components/upload/UploadZone.tsx - Evidence view
frontend/src/components/evidence/EvidenceVault.tsx - API clients
frontend/src/services/api.ts
Application services
- API application
backend/app/main.py - Authentication
backend/app/services/auth_service.py - Chat routes
backend/app/api/chat.py - Chat orchestration
backend/app/services/chat_service.py - Search routes
backend/app/api/search.py - Document routes
backend/app/api/documents.py - Document ingestion
backend/app/services/document_service.py - Research context
backend/app/services/research_profile_service.py
Retrieval and reasoning
- Query rewriting
backend/app/services/query_rewriter_service.py - Hybrid retrieval
backend/app/services/search_service.py - Vector search
backend/app/services/vector_search_service.py - Lexical search
backend/app/services/bm25_service.py - Cross-encoder ranking
backend/app/services/reranker_service.py - Embedding generation
backend/app/services/embedding_service.py
Evidence and persistence
- Relational database
backend/app/db/database.py - Paper and chunk records
backend/app/models/chunk.py
Other components
- Researcher
- LLM inference
- Embedding provider
Connections 27
- Researcher → Workspace UI: uses
README.md - Workspace UI → Paper reader: reads papers
README.md - Workspace UI → Paper upload: uploads papers
README.md - Workspace UI → API clients: requests data
- API clients → API application: calls API
README.md - API application → Chat routes: registers route
backend/app/main.py - API application → Search routes: registers route
backend/app/main.py - API application → Document routes: registers route
backend/app/main.py - Chat routes → Chat orchestration: calls
backend/app/api/chat.py - Search routes → Hybrid retrieval: calls
backend/app/api/search.py - Document routes → Document ingestion: handles documents
- Chat orchestration → Query rewriting: rewrites query
- Chat orchestration → Hybrid retrieval: requests evidence
README.md - Hybrid retrieval → Vector search: retrieves vectors
backend/app/services/search_service.py - Hybrid retrieval → Lexical search: retrieves terms
backend/app/services/search_service.py - Hybrid retrieval → Cross-encoder ranking: reranks candidates
backend/app/services/search_service.py - Vector search → Embedding generation: embeds query
backend/app/services/vector_search_service.py - Embedding generation → Embedding provider: requests embedding
- Hybrid retrieval → Paper and chunk records: selects evidence
backend/app/services/search_service.py - Lexical search → Paper and chunk records: reads chunks
backend/app/services/bm25_service.py - Vector search → Paper and chunk records: queries records
backend/app/services/vector_search_service.py - Document ingestion → Paper and chunk records: creates searchable data
README.md - Paper and chunk records → Relational database: persists records
- Chat orchestration → LLM inference: generates answer
README.md - Chat orchestration → Evidence view: returns evidence
README.md - Researcher → Authentication: authenticates
- Chat orchestration → Research context: uses research context