π Title
Implement AI-Powered Forensic Soundness Scoring Engine
π― Goal
Create a backend service that calculates a Forensic Soundness Score (0β100) for digital evidence based on integrity, metadata completeness, and chain-of-custody verification.
The score will help analysts quickly assess the reliability and admissibility strength of uploaded digital evidence.
π§ Scoring Logic (Total = 100 Points)
The scoring engine should assign points based on the following criteria:
| Criteria |
Points |
| β
Blockchain verification status |
+40 |
| β
IPFS Content ID (CID) present |
+20 |
| β
Metadata completeness (Location, GPS, Timestamp present) |
+20 |
| β
Chain of custody history exists |
+20 |
| Maximum Score |
100 |
βοΈ Functional Requirements
1οΈβ£ Backend Service
File to Create:
services/forensicScoreService.js
Responsibilities:
- Accept evidence object as input
- Evaluate all scoring parameters
- Return:
- Final score (0β100)
- Breakdown of points per category
- Score classification (Optional enhancement)
Example Output Format:
{
"score": 85,
"breakdown": {
"blockchain": 40,
"ipfs": 20,
"metadata": 15,
"chainOfCustody": 10
},
"classification": "High Integrity"
}
2οΈβ£ Scoring Rules Detail
π Blockchain Verification (+40)
- If blockchain hash exists and verified β +40
- If exists but not verified β +20 (optional improvement)
- If not present β 0
π¦ IPFS CID Presence (+20)
- If CID exists β +20
- Else β 0
π Metadata Completeness (+20)
Check if all required fields are present:
- Location
- GPS Coordinates
- Timestamp
Scoring:
- All 3 present β +20
- 2 present β +15
- 1 present β +10
- None β 0
π Chain of Custody (+20)
- If custody history length β₯ 1 β +20
- If partial/incomplete β +10 (optional improvement)
- If none β 0
π₯οΈ Frontend Integration
File to Modify:
public/dashboard-analyst.html
Add:
- Display Forensic Soundness Score (Prominent UI)
- Show:
- Numeric score
- Visual indicator (progress bar / circular gauge)
- Score breakdown
- Classification badge (Low / Medium / High Integrity)
Suggested Classification Ranges:
| Score Range |
Label |
| 80β100 |
π’ High Integrity |
| 50β79 |
π‘ Medium Integrity |
| 0β49 |
π΄ Low Integrity |
π API Integration (If Required)
If evidence is fetched via API:
- Ensure score is calculated before sending response
OR
- Create endpoint:
GET /api/evidence/:id/forensic-score
π§ͺ Testing Requirements
- Test with:
- Fully verified evidence (Expect 100)
- Partial metadata
- No blockchain verification
- Missing CID
- Validate score accuracy
- Edge case: Empty evidence object
π Acceptance Criteria
π‘ Future Enhancements (Optional)
- Machine Learning-based anomaly detection
- Weight adjustment via admin panel
- Risk prediction model
- Auto-flag low score evidence
π Expected Outcome
A fully functional AI-powered forensic scoring engine that:
- Quantifies evidence reliability
- Improves analyst decision-making
- Strengthens legal defensibility
- Enhances transparency of digital chain-of-custody
Priority: High
Phase: 3.4
Type: Feature Implementation
π Title
Implement AI-Powered Forensic Soundness Scoring Engine
π― Goal
Create a backend service that calculates a Forensic Soundness Score (0β100) for digital evidence based on integrity, metadata completeness, and chain-of-custody verification.
The score will help analysts quickly assess the reliability and admissibility strength of uploaded digital evidence.
π§ Scoring Logic (Total = 100 Points)
The scoring engine should assign points based on the following criteria:
βοΈ Functional Requirements
1οΈβ£ Backend Service
File to Create:
Responsibilities:
Example Output Format:
{ "score": 85, "breakdown": { "blockchain": 40, "ipfs": 20, "metadata": 15, "chainOfCustody": 10 }, "classification": "High Integrity" }2οΈβ£ Scoring Rules Detail
π Blockchain Verification (+40)
π¦ IPFS CID Presence (+20)
π Metadata Completeness (+20)
Check if all required fields are present:
Scoring:
π Chain of Custody (+20)
π₯οΈ Frontend Integration
File to Modify:
Add:
Suggested Classification Ranges:
π API Integration (If Required)
If evidence is fetched via API:
OR
π§ͺ Testing Requirements
π Acceptance Criteria
π‘ Future Enhancements (Optional)
π Expected Outcome
A fully functional AI-powered forensic scoring engine that:
Priority: High
Phase: 3.4
Type: Feature Implementation