Skip to content

Commit 52fb628

Browse files
committed
Merge branch 'master' of github.com:scrtlabs/secret-ai-fetch
2 parents 06b8ea2 + ff5cc1e commit 52fb628

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

46 files changed

+750
-244
lines changed

README.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ graph TB
3030
subgraph "Report Generation"
3131
G --> H[Output Processing]
3232
H --> I[LLM Client]
33-
I --> J[Medical Report Generation]
33+
I --> J[Med42 Report Generation]
3434
J --> K[PDF Conversion]
3535
end
3636
@@ -355,4 +355,4 @@ If you use this model in your research, please cite:
355355
journal={arXiv preprint arXiv:2202.08238},
356356
year={2022}
357357
}
358-
```
358+
```

config/MAR-INF/MANIFEST.json

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,13 @@
1+
{
2+
"createdOn": "09/05/2025 14:18:23",
3+
"runtime": "python",
4+
"model": {
5+
"modelName": "monai-breast-density-classification",
6+
"serializedFile": "model.pt",
7+
"handler": "inference_handler.py",
8+
"modelVersion": "1.0",
9+
"requirementsFile": "requirements.txt",
10+
"configFile": "model-config.yaml"
11+
},
12+
"archiverVersion": "0.12.0"
13+
}

config/__init__.py

Whitespace-only changes.

config/config.properties

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,4 +15,7 @@ install_py_dep_per_model=true
1515
async_logging=false
1616
model_store=/mnt/models/model-store
1717
enable_token_auth=false
18-
model_snapshot={"name":"startup.cfg","modelCount":1,"models":{"monai-breast-density-classification":{"1.0":{"defaultVersion":true,"marName":"monai-breast-density-classification.mar","minWorkers":1,"maxWorkers":1,"batchSize":16,"maxBatchDelay":10,"responseTimeout":3600}}}}
18+
disable_token_auth=true
19+
model_snapshot={"name":"startup.cfg","modelCount":1,"models":{"breast-density":{"1.0":{"defaultVersion":true,"marName":"monai-breast-density-classification_model-store_monai-breast-density-classification.mar","minWorkers":1,"maxWorkers":1,"batchSize":16,"maxBatchDelay":10,"responseTimeout":3600}}}}
20+
21+
# model_snapshot={"name":"startup.cfg","modelCount":1,"models":{"monai-breast-density-classification":{"1.0":{"defaultVersion":true,"marName":"monai-breast-density-classification.mar","minWorkers":1,"maxWorkers":1,"batchSize":16,"maxBatchDelay":10,"responseTimeout":3600}}}}

config/requirements.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
monai_breast_density_classification-0.1.tar.gz

dockerize/architecture.md

Lines changed: 73 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
```mermaid
2+
graph TB
3+
%% External Services
4+
OpenAI[OpenAI API]
5+
Perplexity[Perplexity API]
6+
GCS[Google Cloud Storage]
7+
Client[External Client]
8+
9+
%% Docker Environment
10+
subgraph "Docker Network (monai-network)"
11+
%% Caddy Reverse Proxy
12+
Caddy[Caddy Reverse Proxy<br/>Port 23434<br/>HTTPS Entry Point]
13+
14+
%% Auth Gateway
15+
AuthGW[Auth Gateway<br/>FastAPI Service<br/>Port 8090]
16+
17+
%% TorchServe
18+
TorchServe[TorchServe<br/>ML Model Serving<br/>Port 8085<br/>GPU Enabled]
19+
20+
%% Ollama Services
21+
Ollama[Ollama Service<br/>LLM Runtime<br/>Port 11434<br/>GPU Enabled]
22+
OllamaInit[Ollama Init<br/>Model Loader<br/>One-time execution]
23+
end
24+
25+
%% Shared Storage
26+
subgraph "Shared Volumes"
27+
Tokens[torchserve-tokens]
28+
Workspace[shared-workspace]
29+
Models[Host Model Storage<br/>/mnt/secure/.ollama]
30+
end
31+
32+
%% External Client Communication
33+
Client -->|HTTPS:23434| Caddy
34+
35+
%% Internal Container Communication
36+
Caddy -->|HTTP| AuthGW
37+
AuthGW -->|HTTP:8085| TorchServe
38+
TorchServe -->|HTTP:11434<br/>Ollama Python Client| Ollama
39+
40+
%% Dependencies
41+
OllamaInit -.->|depends_on<br/>pulls model| Ollama
42+
AuthGW -.->|depends_on| TorchServe
43+
TorchServe -.->|depends_on| Ollama
44+
Caddy -.->|depends_on| AuthGW
45+
46+
%% External Service Communications (from TorchServe)
47+
TorchServe -->|API Calls| OpenAI
48+
TorchServe -->|API Calls| Perplexity
49+
TorchServe -->|Upload Medical Reports| GCS
50+
51+
%% Volume Mounts
52+
TorchServe -.->|shares tokens| Tokens
53+
TorchServe -.->|shares workspace| Workspace
54+
AuthGW -.->|reads tokens| Tokens
55+
AuthGW -.->|shares workspace| Workspace
56+
Ollama -.->|model storage| Models
57+
OllamaInit -.->|model storage| Models
58+
59+
%% Styling
60+
classDef container fill:#e1f5fe,stroke:#01579b,stroke-width:2px
61+
classDef proxy fill:#f1f8e9,stroke:#33691e,stroke-width:2px
62+
classDef external fill:#fff3e0,stroke:#e65100,stroke-width:2px
63+
classDef storage fill:#f3e5f5,stroke:#4a148c,stroke-width:2px
64+
classDef init fill:#fce4ec,stroke:#880e4f,stroke-width:2px
65+
classDef client fill:#e8f5e8,stroke:#2e7d32,stroke-width:2px
66+
67+
class TorchServe,Ollama,AuthGW container
68+
class Caddy proxy
69+
class OpenAI,Perplexity,GCS external
70+
class Tokens,Workspace,Models storage
71+
class OllamaInit init
72+
class Client client
73+
```

dockerize/build-docker.sh

Lines changed: 0 additions & 224 deletions
This file was deleted.

fonts/DejaVuMathTeXGyre.ttf

564 KB
Binary file not shown.

fonts/DejaVuSans-Bold.ttf

689 KB
Binary file not shown.

fonts/DejaVuSans-BoldOblique.ttf

628 KB
Binary file not shown.

0 commit comments

Comments
 (0)