How bernice511/entiscribe works
PDF Named Entity Extractor is a Streamlit application for ingesting PDFs, extracting user-defined entities with an LLM, and evaluating results. Users upload PDFs, configure entity types, run extraction, and optionally evaluate against a gold CSV; groundedness scoring is also included. The graph follows the three documented pipelines and their main implementation layers. The README supports the overall workflow; sampled source supports the shown calls. Other UI details and unsampled evaluation metrics internals are not inferred.
Main entry points: extract_graph.py Extraction Pipeline · evaluate_graph.py Evaluation Pipeline · app.py Streamlit App · upload_tab.py Upload and Results
Components 18
App and UI
- Streamlit App
src/app.py - Entity Settings
src/ui/sidebar.py - Session State
src/session.py - Upload and Results
src/ui/upload_tab.py - Evaluation View
src/ui/evaluate_tab.py
PDF Ingestion
- Ingest Pipeline
src/pipeline/ingest_graph.py - PDF Text Extraction
src/ingestion/pdf.py - Chunking and Vector Store
src/ingestion/vector_store.py
Entity Extraction
- Extraction Pipeline
src/pipeline/extract_graph.py - Dynamic Entity Schema
src/entities/schema.py - Pipeline State Types
src/pipeline/state.py - Claude CLI Wrapper
src/llm/claude_cli.py
Evaluation
- Evaluation Pipeline
src/pipeline/evaluate_graph.py - Groundedness Scoring
src/evaluation/groundedness.py - Gold Metrics
src/evaluation/metrics.py
Other components
- User
- Claude CLI
- Gold CSV
Connections 25
- User → Streamlit App: uses
README.md - Streamlit App → Entity Settings: renders
src/app.py - Streamlit App → Upload and Results: renders
src/app.py - Streamlit App → Evaluation View: renders
src/app.py - Entity Settings → Session State: updates settings
src/ui/sidebar.py - Entity Settings → Dynamic Entity Schema: loads presets
src/ui/sidebar.py - Upload and Results → Session State: reads and updates
src/ui/upload_tab.py - Upload and Results → Ingest Pipeline: ingests PDFs
src/ui/upload_tab.py - Upload and Results → Extraction Pipeline: runs extraction
src/ui/upload_tab.py - Session State → Chunking and Vector Store: creates store
src/session.py - Ingest Pipeline → PDF Text Extraction: extracts text
src/pipeline/ingest_graph.py - Ingest Pipeline → Chunking and Vector Store: chunks and stores
src/pipeline/ingest_graph.py - Extraction Pipeline → Dynamic Entity Schema: builds schema
src/pipeline/extract_graph.py - Extraction Pipeline → Chunking and Vector Store: retrieves chunks
src/pipeline/extract_graph.py - Extraction Pipeline → Claude CLI Wrapper: requests structured extraction
src/pipeline/extract_graph.py - Extraction Pipeline → Pipeline State Types: uses state
src/pipeline/extract_graph.py - Claude CLI Wrapper → Claude CLI: runs subprocess
src/llm/claude_cli.py - Evaluation View → Session State: reads and updates
src/ui/evaluate_tab.py - Evaluation View → Evaluation Pipeline: runs evaluation
src/ui/evaluate_tab.py - Gold CSV → Evaluation View: uploads
src/ui/evaluate_tab.py - Evaluation Pipeline → Extraction Pipeline: reuses context retrieval
src/pipeline/evaluate_graph.py - Evaluation Pipeline → Groundedness Scoring: scores support
src/pipeline/evaluate_graph.py - Evaluation Pipeline → Gold Metrics: compares gold
src/pipeline/evaluate_graph.py - Evaluation Pipeline → Pipeline State Types: uses state
src/pipeline/evaluate_graph.py - Groundedness Scoring → Claude CLI Wrapper: requests judge scores
src/evaluation/groundedness.py