Skip to content

fix: COO brief accuracy -- skeleton templates, NPS source, ALICE windows, timestamps#2371

Closed
gabrielratner-debug wants to merge 153 commits into
nanocoai:mainfrom
gabrielratner-debug:claude/sharp-heisenberg-12bdc5
Closed

fix: COO brief accuracy -- skeleton templates, NPS source, ALICE windows, timestamps#2371
gabrielratner-debug wants to merge 153 commits into
nanocoai:mainfrom
gabrielratner-debug:claude/sharp-heisenberg-12bdc5

Conversation

@gabrielratner-debug
Copy link
Copy Markdown

Summary

  • Locked property detail and executive summary output to fixed fill-in skeletons -- prevents model from inventing extra sections (P&L tables, KPI header cards, full-month OTB tables)
  • Fixed NPS source filter: was 'Survey', data uses 'Revinate Surveys' -- was matching nothing and producing garbage NPS counts
  • Fixed mid-month forecast accuracy table: replaced raw MTD-vs-full-month comparison with Actual % of Fcst + Month Elapsed benchmark so the numbers are interpretable at any point in the month
  • Added 3:00am cache timestamps to P.Fcst and Duetto OTB headers so readers know figures reflect the 3am snapshot
  • Expanded ALICE from last-7d only to Last 7/30/60/90d windows; removed MTD/YTD counts (wrong by construction -- prefetch only caches recent data)
  • Added bundled Overall rating row to platform reviews table
  • Required exact computed values in narrative bullets -- no rounding or approximation

Test plan

  • Run /coo-prefetch then /coo-briefing and verify Austin section matches structure above
  • Confirm NPS shows ~39 survey responses and NPS ~+72 for L7d (vs 7 responses / +86 before fix)
  • Confirm 3c shows Actual % of Fcst column and Month Elapsed column, not raw delta
  • Confirm no P&L, KPI header, or full-month OTB sections appear in output
  • Confirm ALICE shows 4 rows (Last 7/30/60/90d) per property

🤖 Generated with Claude Code

gavrielc and others added 30 commits March 8, 2026 22:48
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…penAI Whisper

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Syncs with upstream main (on schedule, dispatch, or push), then
merges main into all skill/* branches with build+test validation.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Gabriel Ratner and others added 23 commits April 21, 2026 17:43
…Forecast

Briefing: removed the current-year Actuals fetch (dataset -3) from the
P&L instructions. Columns are now Primary Forecast | Budget | vs Bud $ |
vs Bud % | LY | vs LY % for both months. Reduced calls from 48 to 36.

Prefetch: removed _act.csv fetch from both main parallel pass and retry
pass. Saves one API call per hotel (12 fewer calls at 3am).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Expanded the em dash prohibition to cover all dashes used as separators
in prose. Rule 4 now applies in every container session across all channels.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
coo-prefetch was OOM-killed (SIGKILL) mid-Snowflake queries after
completing all 36 ProfitSword files. 2GB cap insufficient for 12
parallel Python ProfitSword procs + Snowflake MCP loading large
YTD result sets. 4GB gives 2x headroom over actual peak.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Open items tracking simplified to Telegram only: removed Microsoft
ToDo rules from global CLAUDE.md, removed SQLite open_items section
from nanoclawrules.md. Outlook email bodies now truncated to 1500
chars to prevent container OOM from large HTML emails.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
revman@properhotel.com was CC'd on the April 22 briefing. The
existing "NO CC" instruction was not explicit enough about the
tool call parameters. Now bans cc/bcc parameters explicitly and
names the specific address as an example of what not to add.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…O briefing

- P&L: add Room Nights, Occupancy%, ADR, RevPAR KPI rows above each
  monthly table (RF0001/RMAVL/RF0003 ItemTags, computed values)
- Revinate: add per-platform ratings table (Google, Booking.com,
  Expedia, TripAdvisor) with MTD/YTD counts; TripAdvisor rank via
  WebSearch for each property
- Duetto Pace: Total/Transient/Group all three segments now required
- Colors: black default, red negative variance only, green positive only

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Daily mode now shows:
- P&L: KPI header (Occ/ADR/RevPAR) + full table every day, current
  month only (next month on Mondays only)
- Duetto: all three segments (Total/Transient/Group) every day
- Revinate: full platform ratings table every day (Google/Booking/
  Expedia/TripAdvisor with rank), plus new-since-yesterday callout

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
High glitch volume is good (staff encouraged to log everything).
Now watches for TYPE trends -- a specific issue category spiking
2x vs prior month baseline (plumbing, noise, AC, etc.). Removed
volume > 600 MTD threshold. Action items weight ALICE less.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Table: DUETTO_UPLOAD.RAW.LIGHTHOUSE_RATES (all 12 properties, daily
refresh at 5:20am, 365 days forward, LOS 1/2/3).

Prefetch: new query 3h fetches next 30 days LOS=1 own-hotel rows to
lighthouse.json.

Briefing: new section 4 (between Duetto Pace and ALICE) shows 14-day
rate positioning table: own rate, median comp, rank, my OTB%, market
OTB%, demand%, events. Flags: near-last rank on high-demand dates,
OTB gap vs market, sold-out in next 7 days, event/demand mismatches.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Gmail invalid_grant was propagating out of main() and crash-looping nanoclaw.
Wrap each channel.connect() in try/catch so one channel failure degrades
gracefully instead of taking down the whole process.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Captures all uncommitted local work (Slack monitor, EOD Slack, token
audit skills, model override, slack-monitor mount, config .env
fallbacks) as a clean checkpoint before merging upstream v2.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…piled takeaways

- Remove Resolved and Resolved% from ALICE section (Table 7 and per-property 3f)
- Add Top 3 Issues (not just Top 1) to ALICE table and computation
- Change email delivery from inline HTML to HTML file attachment
- Add Section 4: All Properties Takeaways compiled at bottom of report

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Email body now contains Portfolio Takeaways + All Properties Takeaways
so the key signals are readable without opening the attachment.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
For each property takeaway that signals a problem, generate a specific
action naming the right person to engage (Rowan for sales pace, Tracie
for RevMan/STR watchlist, Leah for ops/NPS, Luis for F&B, plus the
property GM/MD). Actions appear in section 3a, section 4, and email body.
Full routing table with all 12 GMs/MDs and 4 corporate owners included.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
STR CurrWk now anchors to Sunday of the week containing max_date via
(max_date.weekday() + 1) % 7 offset -- was a floating 7-day window.

Revinate: renamed NPS (mislabeled) to Recommend Score (0-10), added
true NPS row (Promoters >= 9 minus Detractors <= 6, as signed integer),
renamed Rating (0-5) to Rating (1-5). Table 6 updated to match.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Prefetch: STR Monthly query now selects "RANK" (double-quoted, SQL
reserved word) alongside indices. Briefing: YTD rank cells now read
from str_monthly.json instead of showing "--".

CurrWk/R28 rank still taken from latest-day in str_daily.json.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Prefetch: adds survey_topics (RAW_JSON:surveyTopics) to Revinate query.
Briefing: computes Survey Overall Exp (1-5) from surveyTopics.Overall
Experience ratingAnswer (survey source only), displayed as a separate
row from Platform Rating (1-5) which is the public star average.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
send-email MCP tool has no attachment support -- send complete HTML
report as email body instead of trying to attach a file.

Cache-miss guard: if manifest.json is absent, abort with send_message
instead of attempting live-fetch (which times out at 30 min).

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Prefetch: added execution rules to prevent agent from exiting early
on stale background notifications. Must write manifest AND send
Telegram before concluding.

Briefing: added Graph API Python fallback (scripts/email/send_email.py)
if mcp__outlook__send-email fails. Falls back automatically.

container-runner: also mounts Outlook token at /root/.outlook-mcp-tokens.json
so the Python fallback script finds it regardless of running user.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
MTD Forecast Accuracy now uses RF0003 Amt (Rooms Revenue) for both
actuals and forecast/budget comparisons. TOTOPRV was including F&B
and spa, inflating the gap vs Duetto rooms-only OTB.

Added note clarifying Leah Edwards dual role: GM Hotel June Malibu
(property actions) vs Corporate Director of Operations (portfolio
actions). Never "Managing Director".

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
…ows, timestamps

- Replace property detail and executive summary sections with locked
  fill-in skeletons to prevent model from improvising extra sections
  (P&L tables, full-month OTB tables, KPI header cards)
- Fix NPS filter: 'Revinate Surveys' not 'Survey' (was matching nothing,
  producing garbage counts and wrong NPS)
- Replace MTD-vs-full-month forecast comparison with Actual % of Fcst
  + Month Elapsed benchmark column so mid-month data is interpretable
- Add 3:00am cache timestamps to P.Fcst and Duetto sections so readers
  know figures may lag if forecast was updated after prefetch ran
- Expand ALICE from last-7d only to Last 7/30/60/90d windows; remove
  MTD/YTD counts which were wrong due to query scope mismatch
- Add Overall bundled rating row to platform reviews table
- Require exact computed values in narrative bullets (no rounding)

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@gabrielratner-debug
Copy link
Copy Markdown
Author

Superseded by cleaner branch off main -- no merge conflicts.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants