What it does
Pythagoras CIS gives you a structured workspace for company operations without relying on background scraping. Manual syncs feed the active workspace and preserve observed daily company costs, employee wages, and raw Employee Efficiency history against the corrected 18:10 TCT company-day boundary.
Web Dashboard
Open company information, reports, Staff history, and the same entitlement-aware Employee Efficiency graphs outside Torn. API keys are verified per request, retained only in browser session storage, and never written to the CIS database.
Open the CIS dashboard
Documentation
The FAQ covers installation, API access, licensing, reporting, troubleshooting, and support. It is the best place to start when setting up the project.
Read the FAQ
Support
For updates, support, and project discussion, use the Discord server. That is also where you can follow changes, get setup help, and handle licensing.
Open Discord
Community Feedback
“Hoooooly ****, this way outdoes my spreadsheet! Gotta send me this for real, I don’t know how you do it honestly.”
- Kenya [1852085]
“Looks intense. Appreciate your work. It doesn’t look easy to be made.”
- MrConservative [2257918]
Thank You
Special thanks to everyone supporting the project, testing builds, and sending feedback.
Licensing
Licensing for Pythagoras Project - CIS is handled through my Discord server.
First make sure you are verified in the server. Then go to #bot-commands, talk to The Stig, and run /buylicense.
Paid plans are time-limited only: 1 month, 3 months, 6 months, or 12 months. Free workspaces save data but show the last 7 days until upgraded.
Development log
Changelog
Pythagoras Project - CIS is still in active buildout, but this page now tracks numbered supporter builds from the live cloud workspace release line.
v3.0.4b - Exact training counts in News
- Company News now reconciles training rows against Torn's exact action log by employee and date.
- Grouped News shows the exact daily total instead of the timestamp-collapsed company-news count.
- Raw News shows every unique Torn training action after sync, including same-second actions.
- Previously saved exact totals immediately replace lossy News rows with an accurate daily summary.
v3.0.4 - Mobile settings and exact training counts
- Settings forms now collapse to full-width phone columns without narrow implicit grid tracks.
- Training log sync combines company news with Torn's exact company training-action log.
- Unique action IDs recover same-second trains while daily totals merge without double-counting.
- Exact rows survive cloud reloads and immediately correct linked Training Ledger usage.
v3.0.3 - Employee Efficiency component trends
- Employee Efficiency history now runs newest to oldest, keeping the latest completed Torn company day closest to employee names.
- Added a current-employee selector: All keeps the team heatmap, while an individual employee shows all nine raw EE components as dated lines.
- Added a 7-day range alongside 14, 30, 90, and all-time; free accounts are strictly limited to their latest seven company days.
- The employee choice is session-only and resets to All current employees after reload.
- The standalone dashboard now exposes the same company-scoped, entitlement-aware Employee Efficiency views.
v3.0.2 - Daily operating-cost and Employee Efficiency history
- Employees and Business sync preserve one VM-backed row per employee and completed Torn company day.
- Daily employee rows retain Wage, total EE, and every raw signed EE component.
- Daily company rows retain the observed Advertisement Budget instead of projecting the latest value backwards.
- The company-day boundary records July 21 18:10 through July 22 18:09 as July 22.
v2.9.8 - Persistence and operations polish
- Wage, stock, collapse, and graph-scale changes now survive fast navigation and refreshes through immediate capture and GM-backed recovery.
- Legacy news duplicates and bracketed zero advertising-budget history are repaired during state normalization.
- Daily wage and advertising totals now travel with business/report database sync payloads.
- Staff, Training Schedule, notification rules, Auto Mode, discount rules, orders, toasts, and Timeline cards received a coordinated data and layout pass.
v2.9.7 - Training queue standards
- Training setup now includes a Queue standard controller for Director chooses, Full staff rotation, Lower stats first, Closest under assigned role, and Role need first.
- Paid staff with remaining paid trains stay prioritized by default through the Paid orders first toggle.
- Full staff rotation now cycles eligible sponsored/free staff across generated days before repeating the same people.
- Director chooses now keeps sponsored/free slots open until the director manually selects staff.
- Build calendar now saves the generated active queue into planner state, local planner cache, and the cloud workspace mirror path.
v2.9.3 - Training news grouping fix
- Torn company-news event IDs are now the source of truth for training dedupe.
- Duplicate copies of the same Torn news event count once, while different Torn news IDs for the same employee can still count as real multiple training events.
- Legacy or generated training rows with no source event ID still use employee, position, visible minute, and raw train count as a cleanup fallback.
- Grouped Timeline no longer merges named employees into the first matching same-minute role/count bucket.
- Same-minute one-train events for different employees now stay as separate grouped rows.
v2.9.2 - Balance sync stability
- Advertising budget history now records Torn API V2 profile values as explicit dated rows and ignores older unmarked zero rows in Balance.
- The Pythagoras API now returns ad-budget raw metadata and rejects unmarked zero ad-budget rows, while still allowing future explicit zeroes from updated clients.
- Balance wages now use current synced employee wages and saved wage history only; wage estimates are no longer included in Balance profit.
- Notification hide/dismiss choices now persist locally until the next 18:10 TCT business reset, even after a page refresh.
- Weekly operating performance graphs now use adaptive Y-axis tick spacing so weekly labels do not overcrowd.
- Services Sold now explains that Torn's stock endpoint does not specify whether
sold_amount is daily, weekly, monthly, or lifetime.
- The title bar now shows the userscript version and compact Sync buttons beside it.
v2.9.1 - Stock settings persistence
- Stock card restock toggles, warning thresholds, warning modes, and restock quantities now save to a dedicated stock settings map.
- Stock settings update the 24-hour sync cache immediately on input/change, so fast Torn page switches and refreshes keep the latest values.
- Stock sync, suggested restock, stock import/export, and legacy migration now preserve stock settings instead of falling back to default row values.
v2.9.0 - API DNS Update
- Updated the CIS release line to the working API host at
https://pp-api.sokin.xyz.
v2.8.12 - Advertising budget history
- Business/Profile sync records Torn API V2
advertisement_budget as dated advertising-budget history.
- Balance uses the latest observed advertising budget on or before each report date.
- The Pythagoras API stores advertising-budget history separately from latest company settings.
v2.8.11 - Risk strike persistence and data-flow cleanup
- Visible risk notifications now record same-day strike history on the member record instead of only appearing as alerts.
- Staff snapshots sent to the Pythagoras API now include strike-history data.
- Current Staff now filters stale database snapshots when a member has a valid left date after hire date.
- Mechanic Shop sponsored/free training favors the lowest known working stats first and avoids repeating the same projected pick.
- Business Profile daily and weekly values fall back to synced report rows when direct profile values are empty.
- Balance no longer copies today's ad budget, rating, wages, or staff count backward into historical dates.
v2.8.10 - Staff load guardrail and Mechanic Shop training rotation
- Cloud and database member loading now treats a valid left date on or after hire date as past staff before the current staff list is built.
- Mechanic Shop auto training ranks free and sponsored slots by lowest known total working stats first.
- Projected sponsored picks now carry a training penalty so one staff member cannot dominate the same slot all week.
v2.8.9 - Staff departure guard and Balance cleanup
- Company news left and fired events now override stale current-staff snapshots unless a newer hire event exists.
- Employee sync now runs full staff dedupe after merging API rows.
- Balance ledger and generated balance reports no longer show the unreliable Employees column.
v2.8.7 - Loading, rate limits, and Balance fixes
- Torn API calls now run through a shared throttle queue to reduce account-wide rate-limit bursts.
- Startup renders the panel before rebuilding stored timeline analytics so loading does not appear frozen on large histories.
- Business Profile daily and weekly income/customer rows fall back to synced daily report data.
- The userscript loads only on
companies.php and runs at document-end for faster page startup.
v2.6.0 - Cloud workspace architecture
- Persistent CIS data is moving to server-side PostgreSQL workspaces with company ID isolation and entitlement-filtered reads.
- The userscript keeps only API key, user ID, username, and company ID locally.
- Lifetime licences have been removed; Supporter, Company Boost, and Ultimate now use 1m, 3m, 6m, or 12m plans.
- Free users can still sync and save data, but visible history is limited to the last 7 days until upgraded.
v2.4.5 - Free cloud storage with 7-day reload
- Free users can now save full workspace history to the Pythagoras API or database path using Torn API key verification.
- Free reloads now return the last 7 days into the script until the user upgrades.
- The data workspace now explains that the Torn API key is used only over HTTPS for user or company verification and is not stored by the backend.
v2.4.4 - Free 7-day local persistence
- Free users now keep a rolling 7-day local data slice across refreshes instead of falling back to an empty bootstrap.
- Current company profile, current staff or directors, settings, and recent timestamped rows are retained locally without a licence key.
- Licensed users continue to use the lightweight local bootstrap plus API or database-backed cloud workspace history.
v2.4.3 - Supporter cloud history and clearer data actions
- Supporter licences can now use API or database-backed cloud workspaces and history load or save flows.
- Data actions now say exactly what they export or import: selected JSON backup, selected HTML report, and selected newsletter HTML.
- Locked data actions now show a licence explanation instead of failing silently.
- Signed backend entitlements, stale-licence cleanup, director-profile dedupe, and older-news throttling are included from the recent hardening builds.
v2.1.10 - Database-authoritative premium checks
- Configured licence-API builds now require API or database verification before premium features unlock.
- Local signature and legacy-key fallback are disabled whenever a licence API URL is configured.
- Saved licence keys are refreshed against the API before the first UI render so revoked or missing rows do not keep premium controls active from stale local cache.