samai_client - The WOW Factor
samai_client - The WOW Factor
Human-Readable Benefits - Why this module matters
The Problem It Solves
Before: Updating SAM AI modules on client sites meant SSH/FTP access, downloading ZIPs manually, extracting to the right folder, restarting containers, and hoping nothing broke. Each client update took 15-30 minutes of admin time.
After: Client opens Odoo, sees "3 Updates Available" in systray, clicks "Apply Updates", then "Request Restart". Done in 60 seconds, no technical skills needed.
Key Benefits
For Client Site Administrators
| Benefit | Description |
|---|---|
| Zero Technical Skills | No SSH, FTP, or command line - just buttons |
| Automatic Detection | Cron checks daily, you just see the notification |
| One-Click Apply | Download, extract, all automated |
| Safe Restart | Request restart from host, no guessing |
For SAM AI Host Operators
| Benefit | Description |
|---|---|
| Scalable Distribution | Push updates to 100+ clients without touching each one |
| Community Rev Tracking | Catch updates even when version number unchanged |
| Audit Trail | Know which clients have which versions |
| Tiered Access | API token controls which modules each client can access |
For Developers
| Benefit | Description |
|---|---|
| Clean Architecture | Singleton config, clear API contracts |
| Revision Tracking | community_rev solves the "same version, different code" problem |
| Extensible | Easy to add new API endpoints for additional features |
Real-World Scenarios
Scenario 1: Bug Fix Rollout
Before: Critical bug found in ai_sam_intelligence. Had to SSH into 50 client containers, download fix, restart each one. Took 8 hours.
After: Pushed update to host. Clients see update notification within 24 hours, apply in one click. All 50 clients updated within 48 hours with zero admin intervention.
Scenario 2: Feature Release
Before: New canvas feature ready. Had to coordinate with each client, schedule maintenance windows, manually deploy.
After: Upload to host catalog. Clients who want it check for updates, see it available, install when convenient. Self-service deployment.
Scenario 3: Version Consistency
Before: Some clients on v1.0, others on v1.2, some had custom patches. Support nightmare.
After: community_rev tracking ensures exact code match. When client says "rev 15", we know exactly what they have.
The Community Rev Innovation
Traditional version checking misses updates when manifest version stays the same but code changes (hotfixes, minor patches). The community_rev system solves this:
Host has: ai_sam_intelligence v18.0.1.0.0, community_rev = 15
Client has: ai_sam_intelligence v18.0.1.0.0, community_rev = 12
Result: Update available! (version same, but rev different)
This catches:
- Hotfixes that don't bump version
- Code fixes without manifest changes
- Incremental improvements between releases
Systray Magic
The update indicator lives in Odoo's systray (top-right corner). When updates are available:
- Badge shows count (e.g., "3")
- Click opens SAM AI Client settings
- One button to apply all updates
Users can't miss it, and they don't need to remember to check.
Before vs After Summary
| Aspect | Before | After |
|---|---|---|
| Update detection | Manual check | Automatic cron + notification |
| Update application | SSH/FTP/extract/restart | One-click button |
| Time per client | 15-30 minutes | 60 seconds |
| Technical skill needed | Server admin | Any Odoo user |
| Version tracking | Hope and pray | community_rev precision |
| Restart coordination | Manual container restart | Request from UI |
Who Should Care?
- Client Site Admins: Get updates without needing IT skills
- SAM AI Operations: Scale to hundreds of clients effortlessly
- Support Teams: Know exactly what version each client runs
- Developers: Focus on features, not deployment logistics
Bottom Line: This module transforms SAM AI module updates from a manual, error-prone, time-consuming process into a simple, self-service, one-click operation - enabling rapid, consistent deployment across the entire client base.