RealTimeX.AI Manifest - Document Analysis & Validation
📁 Directory Structure
manifest-ai/
├── src/
│ └── realtimex_manifest_ai/ # Main package source
│ ├── main.py # MCP tools and server entry
│ ├── batch.py # Batch ID generation
│ ├── registry.py # Document registry
│ ├── master_records.py # Master records extraction
│ ├── template_filler.py # Template filling utility
│ ├── utils.py # Utility functions
│ ├── schemas/ # JSON schemas
│ └── batch_data/ # Runtime batch data (git-ignored)
├── examples/ # Sample data (not installed)
│ ├── README.md # Examples documentation
│ ├── setup_samples.py # Script to copy samples to cache
│ └── sample_batch_data/ # Pre-generated sample batches
│ └── {batch_id}/ # Sample batch
│ ├── registry.json # Document registry
│ ├── summary.json # Batch summary
│ ├── data/ # Extracted structured data
│ ├── enhanced_data/ # AI-enhanced data
│ ├── images/ # Page images
│ ├── ocr_data/ # OCR results
│ ├── outputs/ # Generated outputs
│ └── documents/ # Original documents
├── templates/ # Web UI templates
│ ├── index.html # Main dashboard
│ ├── summary.html # Summary view
│ ├── css/ # Stylesheets
│ └── js/ # JavaScript modules
├── plannings/ # Implementation plans
└── README.md
🚀 Quick Start
Installation
pip install realtimex-manifest-ai
Setup Sample Data
To test the package with pre-generated sample data:
python examples/setup_samples.py
This copies sample batches to ~/.realtimex.ai/Resources/agent-resources/manifest-ai/batch_data/
See examples/README.md for more details.
📋 MCP Tools
Document Analysis
get_document_batch_id(file_path)- Generate batch ID for documentget_document_registry(batch_id, file_path)- Get document registry
Master Records
get_master_records(batch_id)- Map which document contains which fieldextract_master_records_data(batch_id)- Extract actual data valuesexport_payment_order(batch_id)- Generate filled payment order
Dashboard & Analysis
show_manifest_dashboard(batch_id)- Show dashboard UIanalyze_with_bank_flow(batch_id)- Analyze with banking context
📁 Batch Data Structure
Runtime batch data is stored in cache:
~/.realtimex.ai/Resources/agent-resources/manifest-ai/batch_data/
└── {batch_id}/ # Each batch has its own folder
├── registry.json # Document registry for this batch
├── summary.json # Batch summary
├── data/ # OCR JSON payloads
│ └── bank/ # Banking-specific data
│ └── master_records.json # Final extracted data
├── enhanced_data/ # AI-enhanced data (optional)
├── images/ # Rendered page images
├── ocr_data/ # OCR results per document
├── outputs/ # Generated outputs (payment orders, etc.)
├── documents/ # Original documents
└── master_records.json # Document-to-field mapping
🌐 Web Dashboard
Start the Server
# From project root
python -m realtimex_manifest_ai.server
Or:
python src/realtimex_manifest_ai/server.py
Expected Output:
================================================================================
🚀 Manifest AI Server Starting
================================================================================
📁 Batch Data Directory: ~/.realtimex.ai/Resources/agent-resources/manifest-ai/batch_data
🎨 Templates Directory: /path/to/src/realtimex_manifest_ai/templates
✓ Found 1 batch(es) in cache:
- c45cd2fbfa40c4663862ec723ef17a5fd17635dd
🌐 Server URL: http://localhost:8000
📊 Dashboard: http://localhost:8000/templates?batch_id=<BATCH_ID>
================================================================================
The server:
- Serves templates from package directory
- Reads/writes batch data from cache directory
- Provides API endpoints for user data (overrides, verifications, etc.)
- Auto-creates user_data folder for modifications
Access the Dashboard
http://localhost:8000/templates?batch_id={BATCH_ID}&theme=light
Example with Sample Data:
http://localhost:8000/templates?batch_id=c45cd2fbfa40c4663862ec723ef17a5fd17635dd&theme=light
Note: If you see a warning about no batch data, run:
python examples/setup_samples.py
📚 Documentation
For detailed documentation:
- Documentation Index
- Implementation Guides
- Architecture Docs
- Example Usage
- Test Suite
- Utility Scripts
📝 Files
1. index.html
- Basic HTML shell
- Links to CSS and JavaScript modules
- Minimal body placeholder
2. CSS modules (templates/css/...)
main.css: Global styles and CSS variablesmodal.css: Modal, grid view, and AI enhancement stylestree.css: Tree view stylescomponents.css: UI components (tabs, badges, buttons)
3. JavaScript modules (templates/js/...)
state.js: Shared data structures and UI stateanalysis.js: Data loading, validation logic, and batch URL parameter handlingtree.js: Builds and renders the validation tree + related handlersrender.js: List/document/table/grid rendering helperscanvas.js: Drawing utilities for the viewer and cropped previewsviewer.js: Modal/viewer controls, zooming, and master evidence logicoverrides.js: Data override management system for editing field valueschangelog.js: Changelog viewer UI for tracking all data modificationsverification.js: Field verification systemai-enhancements.js: AI enhancement loading and applicationevents.js: Global event wiring, search/tabs, resize handling, and document togglesicons.js&utils.js: Shared SVG icons + formatting helpers
✨ Features
Batch Data Loading
Load different batches using URL parameter:
?batch_id=BATCH-VN-CN-2021-9982
The app automatically loads from batch_data/{batch_id}/ folder.
Data Override System
The application includes a powerful override system that allows you to edit field values without modifying the original JSON files:
- Edit Values: Click the edit button (✏️) on any field value in the grid view to modify it
- Visual Indicators: Edited fields are highlighted with an "EDITED" badge
- Revert Changes: Use the revert button (↺) to restore original values
- File-based Storage: All overrides are automatically saved to
user_data/overrides.json - Change Log: View all modifications in the change log panel (clock icon in bottom-right)
- Auto-Save: Every change is immediately saved to disk
AI Enhancement System
If a document has AI-enhanced data in enhanced_data/ folder:
- Banner Notification: A banner appears at the top of the document fields panel
- Apply All: Click ✓ to apply all AI suggestions at once
- Dismiss: Click ✕ to hide the banner
- Individual Suggestions: Apply or dismiss suggestions field by field
Verification System
- Mark Fields as Verified: Toggle verification status on any validation
- Verification Statistics: Track verified vs. total fields
- Persistent State: Verifications are saved to
user_data/verifications.json
Change Log Features
- Track All Changes: Every edit, revert, and clear action is recorded with timestamp
- Export/Import Backup: Create backups of your overrides or import from a backup file
- Clear All: Remove all overrides at once (with confirmation)
- Real-time Updates: Change count badge updates automatically
Responsive Design
- Desktop (≥1024px): Split-view with validation list and viewer side-by-side
- Mobile (<1024px): Full-screen modal viewer
- Auto-resize: UI automatically updates when resizing browser window
Dark/Light Theme
The application supports dark and light themes controlled via URL parameter:
Main Dashboard (index.html):
http://localhost:8000/templates?batch_id=BATCH-VN-CN-2021-9982&theme=dark
http://localhost:8000/templates?batch_id=BATCH-VN-CN-2021-9982&theme=light
Summary Page (summary.html):
http://localhost:8000/templates/summary.html?batch_id=BATCH-VN-CN-2021-9982&theme=dark
- Default theme is light if no parameter is specified
- Theme parameter:
?theme=darkor?theme=light - Summary page is designed for iframe embedding with minimal UI
🔧 Maintenance
Update CSS
Edit the modules under templates/css/
Update JavaScript
Edit the modules under templates/js/
Update HTML shell
Edit templates/index.html
⚠️ Notes
- Use
python3 server.pyinstead of the basic HTTP server — the override system requires API endpoints for saving/loading data. - JavaScript modules use
batch_idURL parameter to determine data paths. - On XL screens the dashboard/tree view stays on the left (scrollable) and previews render on the right.
- Data overrides are stored in files (in the
user_data/folder) — they persist across sessions and browsers. - The
user_data/folder is automatically git-ignored to prevent committing user-specific data.
Metadata
Release files for realtimex-manifest-ai 0.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| realtimex_manifest_ai-0.1.2.tar.gz | 125.1 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| realtimex_manifest_ai-0.1.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 274.2 kB
Release files / realtimex_manifest_ai-0.1.2.tar.gz
| Download URL | realtimex_manifest_ai-0.1.2.tar.gz |
|---|---|
| Size | 125.1 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
b4773265ad26d4dbad54d4ca566239cd788c6cc1362045312e1996e761b8202a
|
|
BLAKE2b-256 checksum How to use checksums |
019535f7ba1a510f18803bfc317d9f6f5ebb77928af50614e78817cd1a556388
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.7.15
|
Release files / realtimex_manifest_ai-0.1.2-py3-none-any.whl
| Download URL | realtimex_manifest_ai-0.1.2-py3-none-any.whl |
|---|---|
| Size | 149.0 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
4c50d5c712f66a30e9780c43ac5a2eebd43db9201d2b49046872ea2e3d6263f2
|
|
BLAKE2b-256 checksum How to use checksums |
5a79ebb96e0628d46bf3c14e9ef0d6533fe368a8d0cdd775e8197c2dd3a3dc8e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
uv/0.7.15
|