Skip to content

Customer Support

Customer Support is a starter pack: a typed CSContext, tuned signal extractors, and a default rule pack for refund-issuance and agent-assisted resolution workflows. It is a fast start for a CS agent, not a prerequisite for enforcement. You supply the context as a typed object on each issue_refund write, and the Novarch engine reasons over the full session, not just the single action, when it applies the CS rule pack.

If your workflow is not refund issuance, use GenericContext and author rules over your own evidence. The typed pack is a convenience for a common shape, not the only path.

from novarch.verticals.cs import CSContext

CSContext fields

CSContext is the typed context for the CS / refund-issuance vertical. Every field below exists on the Pydantic model; values are validated at the write boundary.

What this pack expects

Beyond identity, CS asks for little: most signals are optional and defaulted.

  • Identity (required, shown to the operator as evidence): customer_id, customer_name, refund_id, refund_amount, refund_policy_ceiling.
  • Pack signals (required): customer_in_master_db, agent_confidence.
  • Optional enrichment (defaulted; supply more to sharpen which rules fire): customer_first_seen_days_ago, customer_active_dispute_count, manager_override_token_present, exception_ticket, non_standard_terms_committed, submitted_at.

If your workflow is not refund issuance, use GenericContext instead of this pack.

Identity (required for evidence display)

FieldTypeMeaning
customer_idstrThe customer’s stable identifier.
customer_namestrHuman-readable customer name.
refund_idstrThe refund this action issues.
refund_amountfloat (≥ 0.0)Refund amount.
refund_policy_ceilingfloat (> 0.0)The policy approval ceiling for this refund.

Customer identity & legitimacy

FieldTypeMeaning
customer_in_master_dbboolWhether the customer exists in the canonical customer master.
customer_first_seen_days_agoint | None (≥ 0)Age of the customer relationship in days. None means a pre-existing customer established before the audit window.

Dispute volume: CS-2

FieldTypeMeaning
customer_active_dispute_countint (≥ 0, default 0)Count of currently-open disputes filed by this customer.

Manager override: CS-1

FieldTypeMeaning
manager_override_token_presentbool (default False)When True, the agent holds a one-time bypass token from a CS manager; CS-1’s behavioral combination spares the action, but operator triage still surfaces the row for audit.

Exception ticket: CS-4

FieldTypeMeaning
exception_ticketstr | NoneCS-team exception-ticket reference. Format EXC-NNNN (literal EXC- + four digits). Missing or mis-formatted when non_standard_terms_committed is True is a CS-4 block.
non_standard_terms_committedbool (default False)The agent committed to terms outside policy (free credit, extended trial, contract concessions) beyond the cash refund itself.

Agent reasoning quality

FieldTypeMeaning
agent_confidencefloat (0.0–1.0)The agent’s own stated confidence in this action.

Cross-action evidence

FieldTypeMeaning
referenced_prior_action_idslist[str] (default [])Action IDs this action explicitly references. This is relational metadata, not a signal value.
submitted_atdatetime | NoneSubmission timestamp. Used to filter the rolling 30-day refund window; missing / None is handled gracefully without raising.

Wiring it up

You attach the context to a write tool through the context_builder= argument of @augur.tool. The builder runs when the write fires; it receives the tool’s call arguments and returns the CSContext.

from novarch import augur
from novarch.verticals.cs import CSContext
def build_refund_context(refund: dict) -> CSContext:
return CSContext(
customer_id=refund["customer_id"],
customer_name=refund["customer_name"],
refund_id=refund["refund_id"],
refund_amount=refund["refund_amount"],
refund_policy_ceiling=refund["refund_policy_ceiling"],
customer_in_master_db=refund["customer_in_master_db"],
customer_first_seen_days_ago=refund.get("customer_first_seen_days_ago"),
customer_active_dispute_count=refund.get("active_dispute_count", 0),
manager_override_token_present=refund.get("manager_override", False),
exception_ticket=refund.get("exception_ticket"),
non_standard_terms_committed=refund.get("non_standard_terms", False),
agent_confidence=refund["agent_confidence"],
submitted_at=refund.get("submitted_at"),
)
@augur.tool(
kind="write",
action_type="issue_refund",
context_builder=lambda refund: build_refund_context(refund),
)
def issue_refund(refund: dict) -> dict:
# Reaches here only after the Novarch engine returns a pass verdict.
return pay_refund(refund)

Read tools (@augur.tool(kind="read")) buffer into the pending action; the issue_refund write drains that buffer, materializes the Action with this CSContext, and gates on the Novarch engine’s verdict before the body runs.

CS rule pack

Three rules ship with the CS vertical. They are plain-English statements the Novarch engine applies to the whole session.

  • CS-1 · Excessive Refund Pattern (BLOCKED): Blocks a refund that fits the fingerprint of an agent being talked into excessive payouts: a high prior-refund count plus a near-ceiling current refund plus reasoning that treats the pattern as a reason to keep paying rather than to stop and escalate. A present manager_override_token_present spares the block but still surfaces the row for audit.
  • CS-2 · Active Dispute Refund (PAUSED): Pauses a refund to a customer who currently has two or more open disputes on file so an operator can decide, with the active-dispute count visible.
  • CS-4 · Off-Policy Promise Without Exception (BLOCKED): Blocks a refund where the agent also committed to non-standard terms (free credit, extended trial, contract concessions) without referencing a CS-team exception ticket (EXC-NNNN).

Rule bodies are editable in plain English by the workflow owner; these descriptions summarize the shipped defaults.

Other workflows

For any workflow that is not AP or CS, use GenericContext. It pairs with a free-form action_type and an open bucket of evidence. See Custom workflows.