How oussemaha/llm_eval works
1. Overall shape
This is a small Python, script-based repo rather than a multi-package application. The architecture appears centered on running an LLM evaluation or prompt-driven workflow from a command-line style entry point.
2. Entry points
- main.py is the most likely primary orchestrator.
- a.py looks like a secondary script or scratch/utility entry point.
There is no sign of a web server, worker system, or multi-service deployment boundary.
3. Core processing layer
- preprocesing.py is the main explicit processing module.
- Based on the filename, it likely performs input normalization, cleanup, and transformation before prompt construction or evaluation.
This is the main boundary between raw inputs and model-ready text.
4. Prompt assets as a major subsystem
The assets/prompts/ directory is a clear architectural component: it stores task-specific prompt templates.
The presence of multiple prompt files suggests the system routes different input types to different prompting strategies.
5. Prompt categories
The prompt set implies the repo handles several document or task classes:
- classification_prompt.txt
- table_prompt.txt
- lab_reports_prompt.txt
- medical_images_prompt.txt
- Hw_prescriptions_prompt.txt
- unknown_prompt.txt
This indicates the application likely classifies or interprets heterogeneous medical/clinical inputs and falls back to an unknown/general prompt when the input type is unclear.
6. Likely data flow
The observable flow is:
raw input → preprocessing → task/type selection → prompt template loading → LLM/evaluation step → output
The prompt assets act as the decision surface between preprocessing and downstream inference.
7. Domain boundary
The naming strongly suggests a medical or clinical text-processing domain. If there are external model calls, they are probably abstracted behind the scripts rather than exposed as an API in this repo.
8. Testing boundary
- tests/test.py is the only visible test file.
- That suggests a lightweight test layer focused on validating core script behavior, prompt handling, or preprocessing logic rather than full integration testing.
9. Repository organization
The repo is intentionally minimal:
- top-level Python scripts for orchestration and preprocessing
- static prompt templates under assets/
- a small test area under tests/
There is no evidence of separate service layers, persistence, or frontend components.
10. What to show in an architecture diagram
A useful diagram would include:
- Script entry layer: main.py and possibly a.py
- Processing layer: preprocesing.py
- Prompt repository: assets/prompts/*
- Test layer: tests/test.py
- External dependency boundary: any LLM or evaluation target, if used, sitting outside the repo
11. Important caution
Because only filenames are available, the exact implementation details are not visible. The safest architectural interpretation is that this repo is a prompt/template-driven evaluation utility, with preprocessing and prompt selection as the main internal responsibilities.
Main entry points: prompts Prompt set · main.py main.py · preprocesing.py preprocesing.py · test.py tests/test.py
Components 12
Scripts
Command-line entry points and orchestration scripts
Processing
Input normalization and preparation
- preprocesing.py · Transforms raw inputs into model-ready form
preprocesing.py
Prompts
Prompt template assets and task variants
- Prompt set · Task-specific prompt templates used by the workflow
assets/prompts - Classification · Prompt for classification-oriented inputs
assets/prompts/classification_prompt.txt - Table · Prompt for tabular inputs
assets/prompts/table_prompt.txt - Lab reports · Prompt for laboratory report inputs
assets/prompts/lab_reports_prompt.txt - Medical images · Prompt for medical image-related inputs
assets/prompts/medical_images_prompt.txt - Prescriptions · Prompt for prescription-like inputs
assets/prompts/Hw_prescriptions_prompt.txt - Unknown · Fallback prompt when input type is unclear
assets/prompts/unknown_prompt.txt
Tests
Lightweight validation surface
- tests/test.py · Basic test coverage for core script and prompt behavior
tests/test.py
Other components
- LLM / evaluator · Downstream model or evaluation target outside the repository
Connections 14
- main.py → preprocesing.py: prepares input · Main workflow uses preprocessing before prompt construction
- main.py → Prompt set: loads prompts · Main workflow selects from the prompt asset set
- main.py → LLM / evaluator: invokes · Main workflow sends prepared prompts to an external model or evaluator
- a.py → preprocesing.py: reuses · Secondary script likely shares preprocessing logic
- preprocesing.py → Prompt set: routes to · Preprocessed content is matched to a prompt category
- Prompt set → Classification: contains · Prompt asset bundle includes the classification template
- Prompt set → Table: contains · Prompt asset bundle includes the table template
- Prompt set → Lab reports: contains · Prompt asset bundle includes the lab report template
- Prompt set → Medical images: contains · Prompt asset bundle includes the medical images template
- Prompt set → Prescriptions: contains · Prompt asset bundle includes the prescription template
- Prompt set → Unknown: contains · Prompt asset bundle includes the fallback template
- tests/test.py → main.py: validates · Tests likely exercise the main entry flow
- tests/test.py → preprocesing.py: validates · Tests likely cover preprocessing behavior
- tests/test.py → Prompt set: checks · Tests may verify prompt selection or loading