NetOSField accessMenu
Signed in user unavailable
Documentation/Roadmap & Known Gaps
Download PDF

Xiber NetOS — Roadmap & Known Gaps

What's built, what's missing, and the recommended path forward.


Current Phase: Operational Beta

NetOS has moved well past the initial prototype. It is a working, RBAC-enforced platform covering circuits, infrastructure, customers, RF links, electrical services, vendor quotes, and their financial attribution — running live on the internal LAN behind SSO. The codebase went through a full-stack refactor (service extraction, N+1 query fixes, web API-client split), added a real integration test harness (~140 API tests) and web typecheck/lint/build gates, and shipped explicit redundancy/attribution modeling, searchable entity pickers, weekly SMTP digests, quote intake, and PDF agreement extraction.

The remaining blockers to calling it "production-grade" are narrower than before: identity is still terminated at the proxy rather than validated in-API (no native JWT), modeled revenue/margin is still a placeholder until Sonar is connected, renewal states are computed on the fly rather than persisted, and several external connectors (invoice ingestion, vendor portals) are unbuilt. There is also no CI pipeline yet.


Feature Inventory

What's Built

AreaDetails
Monorepo scaffoldapps/api, apps/web, apps/mcp, infra/docker
Database schema13+ tables, PostGIS geometry, pgvector embeddings, materialized financial view
MigrationsAlembic baseline + infrastructure + agreements migrations
APIFastAPI with OpenAPI 3.1, circuit CRUD, bulk actions, map, dashboard, import, providers, infrastructure
Circuit tableSearch, filter by carrier/status/type, bulk edit/delete, click-through to detail
Circuit detailFull attributes, endpoints, carrier info, NOC contacts, contract terms, lifecycle history
MapA→Z circuit lines, endpoint dots, infrastructure markers, colored by provider, thickness by bandwidth
Dashboard17 KPI cards/panels including spend by carrier, service mix, renewal pipeline, at-risk circuits
TimelineContract-term Gantt with install markers, renewal deadlines, today line, state colors
TopologyEndpoint graph with logical/geographic layouts, SPOF detection, carrier-colored edges
Service providersPortal links, NOC phones, account managers, circuit/infra counts, ETF exposure
InfrastructureData centers, towers, colos, rooftops, carrier hotels, POPs, offices, and aggregation facilities with costs, terms, and bulk edit/delete
ElectricalUtility service accounts attached to infrastructure or customer sites, with provider, meter, service details, average monthly cost, monitoring link, and documents
Financial / P&LPer-circuit modeled revenue, margin, ETF exposure, carrier spend rollups, and infrastructure attribution foundation
Address lookupSearch circuits by address, endpoint, city, state, carrier, or circuit ID
Mobile field viewPhone-friendly circuit lookup with NOC call, copy ID, and map links
Admin / auditRecent activity trail plus bug/feature queue with priority, status, and progress comments
CSV/XLSX importHeuristic column mapping, staging, in-app staging-row editing, upsert by natural key, auto-stub carriers/endpoints — for circuits, infrastructure, and customers
Vendor quotesDedicated quote intake page, quote scope/target types, pricing options with term escalators, contact/colo fields, attachments (PDF/image/pasted-text), background AI analysis, draft-inbox review queue, win marking, and site-level aggregation
PDF agreement extractionUpload contract PDFs against a circuit, text extraction with OCR fallback, AI structured field extraction, and an apply-to-record flow (/ai/extract-pdf, /circuits/{id}/agreement-extractions)
NotificationsIn-process weekly scheduler sends SMTP renewal reports and business-readable activity digests; send-now + preview + SMTP test endpoints
Redundancy & attributionExplicit redundancy_role (primary/secondary/standalone) on subtended links, circuits, and customer RF links; secondary/backup paths excluded from revenue but retained as cost; attribution-conflict 409 with retry-as-redundant action
Sample data4 carriers, 10 endpoints, 8 circuits with contracts and lifecycle events
MCP tools22 token-aware read/context tools for search, circuits, infrastructure, customers, RF links, quotes, quote drafts, carrier summary, renewal pipeline, and site documents/photos
RBAC7 default roles, permission-per-route enforcement, field-level masking, DB-backed roles/permissions/user-overrides, and API access tokens; dev shim accepts x-user-role header
Frontend UXSearchable entity comboboxes replacing large scroll-selects; error/loading boundaries; deferred MapLibre load
Engineering baselineFull-stack refactor (shared service extraction, N+1 query fixes, split web API client), ~140-test pytest+httpx integration harness, and web typecheck/lint/build gates
Docker dev stackPostgreSQL 16, Redis 7, API, Web with hot reload

Gap Analysis

1. Authentication & Authorization

Detail
---------
CurrentThree identity sources: API access tokens (ntos_...), trusted reverse-proxy identity headers (gated by TRUST_PROXY_AUTH_HEADERS + trusted CIDRs — this is how oauth2-proxy/Entra SSO reaches the API), and the dev-auth header shim (x-user-role, gated by ALLOW_DEV_AUTH). Permissions, roles, and user overrides are DB-backed with per-route enforcement and field-level masking. Live behind SSO on the internal LAN.
ImpactUsable today behind a trusted proxy, but the API itself never validates a JWT — it trusts headers from an in-front proxy. A misconfigured proxy/CIDR boundary is the main risk.
NeededNative Microsoft Entra OIDC JWT validation inside the API (the ENTRA_*/JWT_AUDIENCE settings exist but are unused). Role assignment from Entra groups/claims. Server-side session handling and token refresh in Next.js.
Depends onEntra app registration (see Public Hostname & SSO)

2. Audit Logging

Detail
---------
CurrentActivity logging exists for request/write activity, feedback, and bulk actions. created_by/updated_by are populated on newer write paths.
ImpactBasic accountability exists, but sensitive read tracking and field-level redaction are incomplete.
NeededComplete field-level before/after coverage for all write paths. Field-level read audit for sensitive data (ETF formulas, banking, MD5 keys). Sensitive field redaction on read by role.

3. CSV/XLSX Import Enhancements

Detail
---------
CurrentHeuristic column mapping. Staging rows with an in-app staging-row editor (PATCH /imports/{entity}/{job}/rows). Commit valid rows. Upsert by natural key. Now covers circuits, infrastructure, and customers.
ImpactColumn mapping is still fragile for non-standard headers, and there is no saved-mapping memory or pre-commit diff preview.
NeededAI-assisted mapping (send headers + sample rows, get canonical mapping; POST /ai/import-preview exists as a starting point). Saved mappings by (user, source_signature). Diff preview before updating existing records. Explicit confirmation dialog before overwriting financial fields.

4. PDF Contract Ingestion

Detail
---------
CurrentBuilt. PDF upload against a circuit (POST /circuits/{id}/agreement-extractions), text extraction with OCR fallback, AI structured field extraction (POST /ai/extract-pdf), stored extraction records, and an apply-to-record flow. AI provider is pluggable (AI_PROVIDER, default deterministic/no-op).
ImpactContracts can be ingested from PDF rather than keyed by hand.
NeededObject storage (S3/MinIO) instead of local filesystem paths. Richer confidence scoring with source quotes and page numbers. Hardened side-by-side approval UI with mandatory human approval for MRC, ETF, and term fields before commit.

5. Renewal Engine

Detail
---------
CurrentRenewal states computed on-the-fly in API/frontend (/timeline/renewal-pipeline). Weekly SMTP renewal report + activity digest now ship via an in-process asyncio scheduler in the API (not Celery), with send-now, preview, and settings endpoints. States are still not persisted.
ImpactStakeholders get a proactive weekly email, but there is no per-transition alerting or decision workflow, and nothing is persisted for historical state tracking.
NeededPersist renewal states (stable → watch → active → critical → overdue → decided) via a scheduled job or materialized state table. Per-transition Slack/Monday.com notifications. Decision workflow UI (renew / negotiate / terminate / port). DocuSeal termination notice generation. Test-mode fast-forward for QA.
State machinestable (>180d) → watch (90–180d) → active (30–90d) → critical (<30d) → overdue (past deadline) → decided

6. Dashboard & Financial Accuracy

Detail
---------
CurrentCircuit-level modeled MRR uses MRC * 1.35 placeholder multiplier. Infrastructure detail now has subtended links, direct/downstream revenue and cost rollups, relationship effective dates, and circuit-linked attribution records.
ImpactCircuit margin remains illustrative until Sonar revenue is connected. Infrastructure economics can be modeled manually now, but allocation methods, period reporting, and actual invoice/revenue integrations are still needed for production financial reporting.
NeededSonar integration to pull actual customer revenue attribution. Real margin calculation using customer MRR, carrier MRC, facility MRC, transport allocation, and invoice actuals. Full infrastructure waterfall view by asset, parent/child relationship, market, provider, service type, and accounting period. ETF exposure formulas and renewal projection forecasts using contract escalators.

7. Map Enhancements

Detail
---------
CurrentA→Z lines with provider coloring and bandwidth thickness. Provider/type/status filters.
ImpactMap is useful but isolated from table view. No external data overlays.
NeededPolygon/lasso selection tool. Shared filter state with circuit table. Wisdm tower layer overlay. Sonar property/coverage layer overlay. Tile hosting decision (MapTiler vs. self-hosted). Cluster markers for dense endpoint areas.

8. Topology Enhancements

Detail
---------
CurrentEndpoint graph with logical/geographic layouts, SPOF detection by node degree.
ImpactLayout resets on reload. No true networking detail.
NeededDrag/drop layout with save per user and shared default. True networking fields: VLANs, BGP sessions, router interfaces, handoff ports, IP blocks. Better redundancy modeling (path diversity, not just node degree).

9. Financial / P&L View

Detail
---------
CurrentImplemented with per-circuit modeled P&L, carrier spend, margin, ETF exposure, and the first infrastructure subtended-link economics model.
NeededSonar revenue attribution, invoice actuals, carrier/customer/market/service rollups, infrastructure waterfall reports, renewal projection forecast, allocation calculators, and export to XLSX.

10. Address Lookup

Detail
---------
CurrentImplemented text search across circuit, carrier, endpoint, city, state, and address fields.
NeededIntegration with Xiber Service Address Availability Checker. Nearby endpoint/circuit search by radius. Quote-history cost-to-serve estimate.

11. Mobile Field View

Detail
---------
CurrentImplemented responsive field view with search, one-tap NOC call, copy circuit ID, and map app links.
NeededAdd infrastructure asset support, recent events, paired-circuit context, and offline-friendly behavior.

12. Invoice Ingestion

Detail
---------
CurrentInvoice and InvoiceLineItem schemas exist. No ingestion pipeline.
NeededMailbox polling (M365 Graph) or manual upload. PDF invoice parsing with line item extraction. Automatic matching to circuit by carrier circuit ID. Variance detection (invoiced MRC vs. contracted MRC). Auto-create Monday.com task for finance team on variance.

13. Vendor Portal Connectors

Detail
---------
CurrentNot implemented.
NeededLumen Control Center API connector. Zayo Tranzact API connector. Cogent portal connector. Vault/Doppler credential storage. Playwright scraping fallback where APIs are unavailable.

14. MCP Full Coverage

Detail
---------
CurrentToken-aware read/context tools exist for search, circuits, infrastructure, customers, RF links, quotes, quote draft queue, carrier summary, renewal pipeline, and site document/photo metadata. Quote draft MCP tools can stage vendor quotes for human review without committing them to quote history.
Neededget_circuit_pl, get_outage_history, broader write tools with explicit agent confirmation flow, and XOS MCP gateway registration/runtime management.

PhaseFocusWhy First
1Real Entra authenticationCannot deploy without identity. Blocks audit logging.
2Audit loggingRequired for compliance and accountability.
3Renewal engine + notificationsHighest business value — prevents missed deadlines and auto-renew traps.
4Contract CRUD + PDF ingestion hardening (object storage, confidence, approval UI)Ingestion pipeline exists; harden storage and human-approval before relying on it.
5Financial/P&L + Sonar integration + infrastructure waterfallReal margin visibility, accurate business intelligence across circuits, structures, child facilities, and customer endpoints.
6Import enhancements (AI mapping, editor)Reduces friction for bulk data onboarding.
7Invoice ingestion + variance detectionCatches billing errors, automates finance workflows.
8MCP full coverageEnables XOS agents to query NetOS data for automated reporting and decisions.
9Map + topology enhancementsImproved operational visualization.
10Mobile, address lookup, exportsQuality-of-life features for field and sales teams.
11Vendor portal connectorsAutomated circuit status sync from carrier portals.

Technical Debt

ItemNotes
Celery / RedisNo Celery app or worker exists; scheduled work (renewal report, activity digest) runs in an in-process asyncio loop inside the API. Redis is provisioned in the dev stack but effectively dormant — no broker/queue or cache use yet. A real worker is still needed before heavier background jobs (invoice polling, persisted renewal states).
pgvectorExtension installed but no embeddings generated yet. Future use for semantic circuit search.
Error handlingErrors follow FastAPI {"detail": ...} with 401/403/404/409/422; some edge cases can still surface generic 500s.
Test coverage~140 API integration tests (pytest + httpx) covering RBAC, field masking, attribution/redundancy rules, imports, documents, and economics. Frontend has typecheck/lint/build gates. Coverage of import edge cases and renewal logic could still deepen.
CI/CDStill no pipeline (.github/ absent). Gates are run locally/manually. Need GitHub Actions or similar for lint, typecheck, test, build, deploy.