How yashpadhye17/faultline works
EIRC is a NASA-grounded engineering copilot with four user-facing workflows: root-cause analysis, maintenance troubleshooting, engineering comparison, and research. Requests enter through the FastAPI router and are handled by feature services that retrieve evidence, construct prompts, invoke a language model, and return structured, cited results. Shared retrieval combines a FAISS/HNSW vector store with BM25 and reranking; uploads can contribute session-specific documents. The README also documents evaluation through the UI and APIs. Some wiring is supported only by the source index or README, so unsampled relationships are omitted rather than inferred.
Main entry points: routers.py FastAPI routes · base_feature_service.py Feature orchestration · retriever_service.py Hybrid retrieval · evaluation_runner.py Evaluation runner
Components 21
API and contracts
- FastAPI routes
api/routers.py - Request and result models
models/models.py
Copilot workflows
- Root cause analysis
src/document_analyze/service.py - Maintenance troubleshooting
src/single_docchat/service.py - Engineering comparison
src/document_comparison/service.py - NASA research
src/multidoc_chat/service.py
Shared intelligence
- Session uploads
utils/upload_context.py - Feature orchestration
utils/base_feature_service.py - Hybrid retrieval
utils/retriever_service.py - FAISS HNSW store
utils/vectorstore_manager.py - BM25 index
utils/bm25_index.py - Result reranking
utils/reranker.py - Document processing
utils/document_pipeline.py - Prompt management
utils/prompt_manager.py - Model loading
utils/model_loader.py - Citation enforcement
utils/citation_enforcer.py
Evaluation and telemetry
- Request telemetry
utils/telemetry.py - Evaluation runner
utils/evaluation_runner.py - Evaluation artifacts
utils/evaluation_artifacts.py
Other components
- Engineer
- Groq language model
Connections 35
- Engineer → FastAPI routes: submits requests
README.md - FastAPI routes → Request and result models: validates payloads
api/routers.py - FastAPI routes → Session uploads: stores uploads
api/routers.py - FastAPI routes → Root cause analysis: routes RCA
api/routers.py - FastAPI routes → Maintenance troubleshooting: routes chat
api/routers.py - FastAPI routes → Engineering comparison: routes comparison
api/routers.py - FastAPI routes → NASA research: routes research
api/routers.py - Root cause analysis → Hybrid retrieval: retrieves evidence
src/document_analyze/service.py - Maintenance troubleshooting → Hybrid retrieval: retrieves evidence
src/single_docchat/service.py - Engineering comparison → Hybrid retrieval: retrieves evidence
src/document_comparison/service.py - NASA research → Hybrid retrieval: retrieves evidence
src/multidoc_chat/service.py - Root cause analysis → Prompt management: renders prompt
src/document_analyze/service.py - Maintenance troubleshooting → Prompt management: renders prompt
src/single_docchat/service.py - Engineering comparison → Prompt management: renders prompt
src/document_comparison/service.py - NASA research → Prompt management: renders prompt
src/multidoc_chat/service.py - Root cause analysis → Feature orchestration: inherits orchestration
src/document_analyze/service.py - Maintenance troubleshooting → Feature orchestration: inherits orchestration
src/single_docchat/service.py - Engineering comparison → Feature orchestration: inherits orchestration
src/document_comparison/service.py - NASA research → Feature orchestration: inherits orchestration
src/multidoc_chat/service.py - Feature orchestration → Model loading: loads models
utils/base_feature_service.py - Feature orchestration → Session uploads: initializes manager
utils/base_feature_service.py - Feature orchestration → Request telemetry: records requests
utils/base_feature_service.py - Feature orchestration → Citation enforcement: enforces citations
utils/base_feature_service.py - Feature orchestration → Groq language model: invokes model
utils/base_feature_service.py - Hybrid retrieval → FAISS HNSW store: searches index
utils/retriever_service.py - Hybrid retrieval → Result reranking: reranks hits
utils/retriever_service.py - FAISS HNSW store → BM25 index: queries sparse index
utils/vectorstore_manager.py - FAISS HNSW store → Document processing: chunks corpus
utils/vectorstore_manager.py - FAISS HNSW store → Model loading: embeds documents
utils/vectorstore_manager.py - FastAPI routes → Evaluation runner: starts evaluation
api/routers.py - FastAPI routes → Evaluation artifacts: lists evaluation runs
api/routers.py - Evaluation runner → Root cause analysis: evaluates feature
utils/evaluation_runner.py - Evaluation runner → Maintenance troubleshooting: evaluates feature
utils/evaluation_runner.py - Evaluation runner → Engineering comparison: evaluates feature
utils/evaluation_runner.py - Evaluation runner → NASA research: evaluates feature
utils/evaluation_runner.py