Report Agent App Overview
Generate custom workforce reports by describing what you need in plain English β the AI handles the query building, data retrieval, chart selection, and export formatting automatically.
What is the Report Agent?
The Report Agent is an AI-powered reporting assistant inside MangoApps Workforce. Instead of building reports manually through complex query builders or spreadsheets, managers and admins describe the data they need in natural language β βShow me headcount by departmentβ or βGenerate an attendance report for this monthβ β and the agent instantly produces formatted tables, auto-selected charts, and exportable data.
Under the hood, the agent uses semantic search and LLM-powered query parsing to match requests to the right data domain, translate natural language into structured query DSLs, execute the query against live business data, and render rich HTML previews. Reports can be saved for reuse, shared with colleagues, scheduled for automatic delivery, and exported in multiple formats.
The Report Agent integrates directly with Ask AI β any report generated in the Ask AI sidebar can be opened as a full report, saved to the library, or refined through conversational follow-ups.
Core Value Proposition:
- π€ Natural Language Queries β Describe data needs in plain English; the AI translates to structured queries automatically
- π Auto-Visualizations β Charts (bar, line, pie, doughnut, area) are suggested and rendered based on the data shape
- πΎ Saved Report Library β Save, favorite, duplicate, and share reports with team members
- β° Scheduled Delivery β Automate recurring reports via email, webhook, or SFTP on daily, weekly, monthly, or quarterly cadences
At a Glance
| π€ Natural Language | π Auto-Charts | πΎ Saved Reports | π€ Multi-Format Export |
|---|---|---|---|
| Ask in plain English, get structured data | Bar, line, pie, doughnut, area, table | Save, favorite, share, duplicate | CSV, Excel, PDF, JSON |
| β° Scheduled Reports | π 5 Data Domains | π Ask AI Integration | π± Mobile Support |
|---|---|---|---|
| Daily, weekly, monthly, quarterly | Employee, attendance, shifts, performance, service desk | Generate reports from sidebar chat | View, run, and favorite on mobile |
Perfect For:
- π₯ Managers β Get quick team analytics: headcount, attendance trends, shift coverage, performance ratings
- π’ HR / Admin β Run workforce reports, configure data domains, manage sharing policies, schedule compliance reports
- π Analysts β Save frequently-used report configurations, export data in bulk, automate recurring deliveries
How It Works
Report Generation Flow
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β REPORT GENERATION FLOW β
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β β
β ββββββββββββ ββββββββββββββββ ββββββββββββββββ βββββββββββββ β
β β QUERY ββββΆβ AI PARSING ββββΆβ EXECUTE ββββΆβ RENDER β β
β β Input β β & Matching β β Query β β Results β β
β ββββββββββββ ββββββββββββββββ ββββββββββββββββ βββββββββββββ β
β β β β β β
β User types a Semantic search Query DSL is Table + β
β natural language matches to best executed against chart HTML β
β description data domain tool live business rendered β
β + LLM parses DSL data with stats β
β β
β ββββββββββββ ββββββββββββββββ ββββββββββββββββ βββββββββββββ β
β β REFINE ββββΆβ SAVE ββββΆβ EXPORT ββββΆβ SCHEDULE β β
β β Report β β Report β β Download β β Delivery β β
β ββββββββββββ ββββββββββββββββ ββββββββββββββββ βββββββββββββ β
β β β β β β
β "Filter for Save to library CSV, Excel, Daily/weekly/ β
β Engineering" with visibility PDF, or JSON monthly auto- β
β modifies the settings download delivery via β
β previous query (private/shared) email/webhook β
β β
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Ask AI Integration
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β ASK AI β REPORT AGENT β
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β β
β βββββββββββββββ ββββββββββββββββ ββββββββββββββββββββββββ β
β β Ask AI βββββΆβ Context βββββΆβ Reporting Agent β β
β β Sidebar β β Router β β (Agentic LLM) β β
β βββββββββββββββ ββββββββββββββββ ββββββββββββββββββββββββ β
β β β β β
β User asks a Router detects Agent picks the β
β reporting reporting intent right tool, parses β
β question and delegates query, executes β
β β
β β β β β
β βΌ βΌ βΌ β
β βββββββββββββββ ββββββββββββββββ ββββββββββββββββββββββββ β
β β HTML ββββββ Render ββββββ Query Result β β
β β Preview β β Service β β (data + chart) β β
β βββββββββββββββ ββββββββββββββββ ββββββββββββββββββββββββ β
β β β
β Preview shows table, chart, row count, and action buttons: β
β [Open Full Report] [Save Report] [Export CSV] β
β β
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Key Features
π€ Natural Language Report Generation
Describe the data you need in plain English and the AI agent translates your request into a structured query, selects the appropriate data domain, and executes it against live business data.
| Capability | Description |
|---|---|
| Semantic Query Matching | Uses pgvector embeddings and keyword indexing to match queries to the best reporting tool across five data domains |
| LLM-Powered Parsing | GPT-4o-mini translates natural language into structured query DSLs with columns, filters, grouping, metrics, and sorting |
| Natural Date Normalization | Understands phrases like βthis quarter,β βlast 30 days,β βsince Januaryβ and converts them to date ranges |
| Conversational Refinement | Follow up with βfilter for Engineeringβ or βgroup by location insteadβ to modify the previous report without starting over |
| Error Recovery | Provides user-friendly suggestions when a query canβt be matched or parsed |
Example Queries:
- βShow me headcount by departmentβ
- βGenerate an attendance report for this monthβ
- βWhat are the top performers this quarter?β
- βList shifts with coverage gaps next weekβ
- βShow open service desk tickets by priorityβ
Use Case β Quick Team Analytics:
A manager opens Ask AI and types βShow me hours worked by employee this month.β The agent matches to the attendance domain, parses the date range, and returns a table with employee names, total hours, and overtime β plus a suggested bar chart. The manager clicks βOpen Full Reportβ to see the complete data set and exports it to Excel.
π‘ Pro Tip: Use conversational follow-ups to refine reports. After getting headcount by department, type βnow filter for just Engineering and sort by tenureβ β the agent modifies the existing query rather than starting from scratch.
π Chart Visualization
The Report Agent automatically suggests and renders chart types based on the data structure. Charts are rendered using Chart.js in both the Ask AI preview and the full report view.
| Chart Type | Best For |
|---|---|
| Bar Chart | Comparing values across categories (headcount by department, hours by team) |
| Line Chart | Trends over time (attendance over weeks, performance scores by quarter) |
| Pie / Doughnut | Proportional breakdowns (department distribution, status composition) |
| Area Chart | Cumulative trends with filled regions |
| Table View | Detailed row-level data with sortable columns |
| Capability | Description |
|---|---|
| Auto-Suggest | Chart type is inferred from query shape (grouping + metrics = bar, time series = line, proportions = pie) |
| Chart Themes | Three built-in themes: Modern, Classic, Minimal β configurable per business |
| PDF Charts | Native Prawn-drawn charts in PDF exports (not screenshots β true vector graphics) |
| Preview in Ask AI | Compact chart + table preview rendered inline in the Ask AI sidebar |
πΎ Saved Reports Library
Save any generated report to your personal library for quick re-runs, sharing, and scheduling.
| Capability | Description |
|---|---|
| Save from Ask AI | One click to save a report generated in the Ask AI sidebar to your library |
| Save from Preview | Reports opened via βOpen Full Reportβ can be saved with a name, description, and visibility |
| Re-Run on Demand | Run any saved report to get fresh data with the same query configuration |
| Favorites | Mark frequently-used reports as favorites for quick access |
| Duplicate | Clone any report (including shared reports) to create a customized copy |
| Templates | Admins can mark reports as templates that appear in the template gallery |
| Search & Filter | Filter reports by ownership (mine, shared, favorites), data domain, or search by name |
| Sorting | Sort by name, creation date, last updated, or run count |
| Pagination | Reports list paginates at 20 per page |
Visibility Levels:
| Level | Who Can See |
|---|---|
| Private | Only the report creator |
| Shared | Creator + specific users added by ID |
| Public | All users in the business with report access |
π₯ Report Sharing
Share reports with colleagues so they can view and run them without recreating the query configuration.
| Capability | Description |
|---|---|
| Share with Users | Add specific users by searching within the business β shared users get view + run access |
| Unshare | Remove individual users from a shared reportβs access list |
| Automatic Visibility | Sharing automatically sets the report visibility to βsharedβ |
| Auto-Revert | Removing the last shared user automatically reverts visibility to βprivateβ |
| Admin Override | Business admins can access all reports regardless of visibility settings |
π‘ Pro Tip: Share a report with your entire teamβs managers so everyone can run the same βWeekly Team Attendanceβ report with fresh data each time.
π€ Multi-Format Export
Export reports in four formats with configurable business-level controls for which formats are available.
| Format | Description |
|---|---|
| CSV | Standard comma-separated values with quoted fields and UTF-8 encoding |
| Excel | CSV with UTF-8 BOM for Excel compatibility, title row, metadata row, and truncation notices for large datasets (100K+ rows) |
| Professional PDF with business branding, summary metrics, native Prawn-drawn charts (bar, line, pie), and paginated data table (up to 500 rows) | |
| JSON | Structured JSON with column metadata, typed data, and optional pretty-printing |
| Capability | Description |
|---|---|
| Per-Format Toggle | Admins can enable/disable CSV, Excel, and PDF exports independently |
| Row Limits | Configurable maximum rows per query (default: 10,000) prevents runaway queries |
| Date Formatting | Dates formatted as YYYY-MM-DD, datetimes as YYYY-MM-DD HH:MM |
| Boolean Formatting | Boolean values display as βYesβ / βNoβ in exports |
| Array Handling | Array values are joined with commas in CSV/Excel exports |
β° Scheduled Reports
Automate recurring report generation and delivery on configurable schedules.
| Capability | Description |
|---|---|
| Schedule Types | Daily, weekly (pick day of week), monthly (pick day of month), quarterly |
| Delivery Methods | Email (with attachment), webhook (HTTPS POST with JSON payload), or download-only |
| Export Formats | CSV, Excel, PDF, or JSON β selected per scheduled report |
| Timezone Support | Schedule times honor the userβs configured timezone |
| Link to Saved Reports | Optionally link a scheduled report to an existing saved report β query DSL auto-populates |
| Enable / Disable | Toggle scheduled reports on or off without deleting them |
| Run Now | Manually trigger an immediate run of any scheduled report |
| Auto-Disable | Reports are automatically disabled after 5 consecutive failures to prevent noise |
| Failure Notifications | Email notification sent to the report owner when a scheduled run fails |
| Disabled Notifications | Email notification when a report is auto-disabled due to excessive failures |
| Idempotency | Job skips execution if the report ran within the last 5 minutes to prevent duplicates |
| Retry with Backoff | Failed jobs retry up to 3 times with exponential backoff |
Delivery Methods in Detail:
| Method | How It Works |
|---|---|
| Sends the exported file as an attachment to one or more email recipients. Validates email format on save. | |
| Webhook | POSTs a JSON payload (report ID, name, Base64-encoded file, timestamp) to a public HTTPS endpoint. Supports custom Authorization headers. Private IPs are blocked for security. |
| Download | Generates and stores the report β no external delivery. Useful for audit trails. |
Use Case β Automated Weekly Headcount Report:
An HR admin creates a saved report for βHeadcount by Departmentβ and schedules it for every Monday at 8:00 AM. The report runs automatically, exports as Excel, and is emailed to the HR distribution list. If the report fails three weeks in a row, it auto-disables and notifies the admin.
π Five Data Domains
The Report Agent supports five distinct data domains, each backed by a dedicated reporting tool with domain-specific columns, metrics, filters, and grouping options.
| Domain | Tool Class | Example Queries |
|---|---|---|
| Employee | EmployeeReportingTool |
Headcount by department, tenure distribution, hire trends, demographics |
| Attendance | AttendanceReportingTool |
Hours worked, overtime analysis, late arrivals, absence patterns |
| Shifts | ShiftsReportingTool |
Shift coverage, scheduling gaps, assignment counts, staffing levels |
| Performance | PerformanceReportingTool |
Rating distributions, goal completion, top performers, review status |
| Service Desk | ServiceDeskReportingTool |
Ticket volumes, SLA compliance, resolution times, satisfaction scores |
Each domain can be independently enabled or disabled per business through the admin settings. When a domain is disabled, its reports are hidden from the library and the agent wonβt match queries to it.
π± Mobile Support
The Report Agent includes mobile web views for on-the-go report access inside the native MangoApps iOS/Android app.
| Capability | Description |
|---|---|
| Reports List | Browse saved reports with filter (mine, shared, favorites), search, and infinite scroll |
| Report Detail | View report metadata, last run summary, and run history |
| Run Reports | Execute any accessible report and see the row count result |
| Toggle Favorites | Mark/unmark reports as favorites directly from the mobile list |
| Scheduled Reports | View list of scheduled reports with status, filter by enabled/disabled |
| Scheduled Detail | View schedule configuration and last run summary |
βοΈ Admin Settings
Administrators configure the Report Agent through a dedicated settings page with granular controls.
| Setting Group | Options |
|---|---|
| Agent Toggle | Enable/disable the reporting agent globally for the business |
| Chart Configuration | Default chart theme (Modern, Classic, Minimal), auto-suggest charts toggle |
| Data Domains | Enable/disable each of the 5 data domains independently |
| Report Sharing | Enable/disable saved reports, enable/disable report sharing, max saved reports per user (default: 50) |
| Export Options | Toggle CSV, Excel, and PDF export formats independently |
| Performance Limits | Max rows per query (default: 10,000), preview rows in Ask AI (5/10/15/20), query caching toggle and TTL |
| Analytics & Feedback | Detailed audit log, collect user feedback, show AI reasoning toggles |
Interaction Tracking & Analytics
Every interaction with the Report Agent is tracked for analytics, debugging, and learning.
| Metric | Description |
|---|---|
| Reports Run | Count of reports executed by the current user this month |
| Saved Reports | Total saved reports owned by the current user |
| Avg Response Time | Average agent response time over the last 30 days |
| Popular Tools | Most-used data domains in the last 30 days across the business |
| Success Rate | Percentage of successful report generations over a configurable period |
| Daily Usage | Day-by-day interaction counts for trend analysis |
| Common Queries | Most frequently asked report queries for template suggestions |
The dashboard shows recent reports, shared reports, popular data domains, and quick usage stats at a glance.
Architecture Overview
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
β REPORT AGENT ARCHITECTURE β
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ€
β β
β Entry Points: β
β βββββββββββββ βββββββββββββββββ βββββββββββββββ β
β β Ask AI β β Report Agent β β Scheduled β β
β β Sidebar β β Dashboard β β Report Job β β
β βββββββ¬ββββββ ββββββββ¬βββββββββ ββββββββ¬βββββββ β
β β β β β
β βΌ βΌ βΌ β
β ββββββββββββββββββββββββββββββββββββββββββββββββ β
β β Agents::ReportingAgent β β
β β - handle_request() β execute_with_tools() β β
β β - Tools: generate, refine, export, list β β
β βββββββββββββββββββββ¬βββββββββββββββββββββββββββ β
β β β
β βββββββββββββββΌββββββββββββββ β
β βΌ βΌ βΌ β
β βββββββββββββ βββββββββββββ ββββββββββββββ β
β β Semantic β β Enhanced β β Report β β
β β Report β β Query β β Schema β β
β β Matcher β β Parser β β Embeddings β β
β βββββββββββββ βββββββββββββ ββββββββββββββ β
β β β β β
β βΌ βΌ βΌ β
β ββββββββββββββββββββββββββββββββββββββββββββ β
β β Reporting Tool (per domain) β β
β β Employee | Attendance | Shifts | β β
β β Performance | Service Desk β β
β ββββββββββββββββββββββ¬ββββββββββββββββββββββ β
β β β
β ββββββββββββββββΌβββββββββββββββ β
β βΌ βΌ βΌ β
β βββββββββββββ βββββββββββββ βββββββββββββ β
β β HTML β β Export β β PDF β β
β β Renderer β β Service β β Generator β β
β βββββββββββββ βββββββββββββ βββββββββββββ β
β β
ββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
Access Control
| Role | Capabilities |
|---|---|
| Super Admin | Full access: all reports, all settings, all scheduled reports, all domains |
| Admin | Full access: all reports, settings, scheduled reports, all domains |
| Manager | Generate reports, save/share/export, create scheduled reports, view team data |
| Member | No access by default. Can be granted via allowed_roles configuration |
Reports enforce strict business scoping β all queries filter by the current business, and cross-business data access is prevented at both the model and controller layers. Shared reports verify access at both the query scope level and individual record level.
Navigation
The Report Agent app includes a sidebar with four navigation tabs:
| Tab | Icon | Description | Access |
|---|---|---|---|
| Dashboard | fa-chart-pie |
Overview with recent reports, shared reports, popular tools, usage stats | All authorized users |
| Reports | fa-file-alt |
Saved custom reports library with search, filter, and sort | All authorized users |
| Scheduled Reports | fa-calendar-check |
Automated report delivery management | Managers and above |
| Settings | fa-cog |
App configuration and domain controls | Admins only |
Tips & Best Practices
- Start broad, then refine β Ask for a general report first (βheadcount by departmentβ), then use follow-up messages to add filters, change grouping, or narrow the date range
- Save frequently-used reports β Save any report you run more than once. Re-running a saved report is faster than re-typing the query
- Use scheduled reports for compliance β Set up weekly or monthly reports for attendance, performance reviews, or staffing levels and have them delivered automatically
- Leverage sharing β Share standard reports (like βMonthly Headcountβ) with your management team so everyone uses the same data definition
- Export strategically β Use CSV for data analysis in spreadsheets, PDF for stakeholder presentations, JSON for integrations
- Check the dashboard β The dashboard shows your most popular data domains and recent activity, helping you discover what reports your team runs most
Related Features
| Feature | Relationship |
|---|---|
| Ask AI | Report Agent is accessible through the Ask AI sidebar β generate reports conversationally |
| Workforce Bots | Bots can reference reporting data in automated workflows |
| Employee Data Management | Employee domain reports pull from the employee data module |
| Time & Attendance | Attendance domain reports pull from time tracking data |
| Shift Scheduling | Shifts domain reports pull from scheduling data |
| Performance Management | Performance domain reports pull from review and goal data |
| Service Desk | Service desk domain reports pull from ticket and SLA data |