Skip to content

[Due for payment 2026-11-12] [$175] [Rules Revamp] Release 5: AI-assisted rule creation and unsupported-request capture #92743

Closed

Description

@JmillsExpensify

Background

R1–R3 built a consistent, centralized, contextual deterministic rules foundation. This release makes supported rules easier to author with AI and gives us a direct signal on rules customers want that we do not yet support.

An admin describes the rule they want in natural language; we parse it into the structured criteria/action of the existing creation UI and present it for confirmation, so the saved rule stays deterministic and understandable. The AI translates intent into a draft rule; it does not enforce anything itself.

Scope

  • Add an AI-driven entry to the New rule flow: a prompt where the admin describes the desired rule.
  • Parse the prompt into the corresponding rule in the existing rules configuration UI for review and save.
  • Support creating one rule at a time.
  • Handle three non-happy paths via inline form errors under the prompt: unsupported rule, unintelligible input, and multiple rules in one prompt

Product and design details

Happy path: supported rule

Image

The New rule entry offers "Create a new rule — describe your rule and Concierge will build it." The admin types a prompt (e.g. "Ask for a description for all meals expenses above 1000 USD") and taps Next. A Build rule manually affordance remains for the deterministic flow.

We map the prompt to the right rule type and pre-fill the existing configuration UI — for the example above, the Require fields branch with Category = Meals and Entertainment, Amount above $1,000, and Description checked. The admin sees this populated, deterministic rule and confirms via Save rule. The final saved object is identical to one built manually.

One rule at a time: we support exactly one rule per prompt. If a prompt implies multiple rules, we do not build any of them for now; we surface the inline error described below and ask the admin to split them. This will be resolved in a future release.

Error handling (inline, under the prompt)

All three non-happy paths render as an inline error beneath the prompt field (red-dot indicator + message), consistent with the mocks. The prompt text is preserved, and Build rule manually and Next remain available so the admin can edit and retry or switch to the manual flow. These are not separate full pages.

  • Unsupported rule: the request is understood but the deterministic engine can't express it. Error copy names the unsupported area and notes it's on our radar, e.g. "Travel booking rules aren't supported yet — we're working on it. Please try a different rule for now." We capture the requested criteria/action and forward the request and use case to the product team for prioritization. Where relevant, we can also encourage the admin to create a custom agent that can enforce it.
Image
  • Unintelligible input: we can't parse the input into a legible rule. Error copy invites a clearer phrasing with an example, e.g. "Try phrasing your rule like: if expenses have a value over $100, then require a receipt."
Image
  • Multiple rules in one prompt: the prompt describes more than one rule. We build none and show, e.g. "One rule at a time, please — try describing a single rule, like: block gift card purchases." The admin edits the prompt down to a single rule and retries; they can create the rest after saving this one.
Image

Determinism and confirmation

AI only drafts; the admin always sees and confirms the structured rule before save. No rule is saved without an explicit confirmation step.

Examples

  • "Ask for a description for all meals expenses above 1000 USD" → pre-filled Require fields rule (Meals and Entertainment, above $1,000, Description checked) shown for confirmation, then saved.
  • "Block retail on all cards" → pre-filled Restrict card spend rule for confirmation.
  • "Block travel bookings if it's over $2,000" → inline unsupported-rule error ("Travel booking rules aren't supported yet…"); request captured and forwarded to product.
  • "dsadadsadafa" → inline unintelligible-input error with a phrasing example.
  • "Block gift cards and require receipts over $50" → inline multiple-rules error ("One rule at a time, please…"); nothing is built until the admin narrows to a single rule.
Issue OwnerCurrent Issue Owner: @mallenexpensify
Upwork Automation - Do Not Edit

Activity

  1. added
    InternalRequires API changes or must be handled by Expensify staff
    NewFeatureSomething to build that is a new item.
    on Jun 4, 2026
  2. melvin-bot commented on Jun 4, 2026

    @melvin-bot

    Current assignee @dubielzyk-expensify is eligible for the NewFeature assigner, not assigning anyone new.

  3. 74 remaining items

  4. Krishna2323 commented on Nov 9, 2026

    @Krishna2323
    Contributor

    Price increase request

    Proposed amount: $850 for my review of Release 5.

    Why the work exceeded the issue: The original issue covered one AI rule creation PR. However, the review expanded to include the original PR, a new design PR, and two follow-ups, spanning four PRs in total.

    Regressions caused by this PR: #103859, #103863, #103869, #103872, #103928, and #103930, all fixed in #104055.

    We put the feature behind the describeRule beta (#103896) while these issues were being fixed. AI rule creation has many edge cases that depend on the model's output, so I'd ask that we follow the usual approach for features like this and not deduct for these regressions.

    Optional

    Scope expansion: #103810 introduced a new flow: describing a rule from New rule, with an agent rule fallback.

    Files touched: 93 files, +2,984 / -382, across the rule editors, New rule page, and agent rule page.

    Multiple PRs:

    I'm closing the separate payment tracking for #103809 and #103810 so that all Release 5 payments are handled here.

    cc: @JmillsExpensify @yuwenmemon @JS00001

  5. JS00001 commented on Nov 10, 2026

    @JS00001
    Contributor

    👍🏻 makes sense to me

  6. JmillsExpensify commented on Nov 10, 2026

    @JmillsExpensify
    ContributorAuthor

    Yes, sounds good!

  7. added
    Awaiting PaymentAuto-added when associated PR is deployed to production
    and removed
    Skip PaymentSkips all the payment process steps for an issue. Use it for fixed-price projects.
    on Nov 12, 2026
  8. changed the title [-][$175] [Rules Revamp] Release 5: AI-assisted rule creation and unsupported-request capture[/-] [+][Due for payment 2026-11-12] [$175] [Rules Revamp] Release 5: AI-assisted rule creation and unsupported-request capture[/+] on Nov 12, 2026
  9. melvin-bot commented on Nov 12, 2026

    @melvin-bot

    Triggered auto assignment to @mallenexpensify (Awaiting Payment)

  10. JmillsExpensify commented on Nov 12, 2026

    @JmillsExpensify
    ContributorAuthor

    @mallenexpensify for payment summary, see this approved comment.

  11. melvin-bot commented on Nov 12, 2026

    @melvin-bot

    Payment Summary

    Resolving PRs:

    BugZero Checklist (@mallenexpensify)

    • I have confirmed assignees, roles, and Upwork contracts look correct
    • I have paid out Upwork contracts / manual NewDot requests
    • [BugZero Assignee] I have created a GH issue for creating/updating the regression test once above steps have been agreed upon
  12. mallenexpensify commented on Nov 13, 2026

    @mallenexpensify
    Contributor

    Payment Summary

    Contributor+: @Krishna2323 due $850 via NewDot

    I see @situchan mentioned above but it doesn't look like they're due payment, comment if they are.

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

Metadata

Metadata

Labels

Awaiting PaymentAuto-added when associated PR is deployed to productionInternalRequires API changes or must be handled by Expensify staffNewFeatureSomething to build that is a new item.ReviewingHas a PR in reviewWeeklyKSv2

Type

No type

Projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions