Structure-Aware Transformers for Hierarchical Authorization in Personal AI Agents

Dongyu Cui, Jie Ding, Xuan BiarXiv 2026

TL;DR

Personal AI agents either annoy us with endless permission pop-ups or terrify us by executing risky, unauthorized actions. This paper introduces PATH, a Transformer architecture that predicts personalized user permission preferences so users can review and approve sensible batches of actions at once. By baking permission dependencies directly into its attention masks and probability math, PATH learns from sparse user history while guaranteeing zero logical contradictions in its predictions.

What Problem Does This Paper Address?

Giving an AI agent autonomy is a balancing act. Restrict it too much, and you suffer from "approval fatigue"; give it blanket permissions, and it might accidentally delete emails or leak credentials. Existing safety tools rely on rigid, one-size-fits-all rules, ignoring the fact that your risk tolerance for an AI buying groceries might be very different from mine.

Predicting personalized permissions is tricky for two reasons:

  1. Hierarchical Dependencies: Permissions form a Directed Acyclic Graph (DAG)—a flowchart without loops—where granting a specific "child" action requires granting its "parent" prerequisites.
  2. Extreme Sparsity: No human has the bandwidth to pre-configure permissions for every file and API on their device. Models must learn from incomplete, partially observed user decisions.
Figure 1: An illustrative hierarchical authorization DAG for a coding agent. Nodes represent ac- tions, and directed edges indicate authorization dependencies. Authorizing a child action requires authorization for all its parent actions. In this example, running the Python script requires permis- sion to read both the script and its input data, while editing permissions are not required.

Standard multi-label classifiers often predict nodes independently, leading to structural violations—like predicting a user will allow an agent to "Run Python Script" while denying permission to "Read Input Data." Fixing these contradictions after the fact via post-processing is ambiguous and hurts accuracy.

Methods

The authors formulate permission prediction as mapping user features to a partially observed DAG, proposing the Parent-gated Authorization Transformer for Hierarchies (PATH).

Figure 2: An illustration of a structured prediction problem: learning hierarchical authorization output (Yi) from observed user features (Xi). A green node denotes an authorized AI action (i.e., Yij = 1), a red node denotes a denied AI action (i.e., Yij = 0), and a gray node denotes an unobserved authorization decision. If a node is denied, all its descendants must also be denied.

While PATH uses standard MLP encoders, binary cross-entropy loss (computed only over observed labels), and a standard Transformer backbone, it introduces three structural innovations:

  • Depth-Level Embeddings: Each permission token combines a user embedding, a specific node embedding, and a depth embedding (how far the action is from the root). Sharing depth embeddings helps the model pool information across similar hierarchy levels, combating data sparsity and capturing correlations among peer actions.
  • Ancestor Attention Mask: Instead of letting every permission node attend to every other node, PATH applies a custom mask so a node can only attend to itself and its ancestors in the DAG. Information flows strictly along valid dependency paths.
  • Parent-Gated Probability: Rather than predicting raw marginal probabilities directly, the Transformer outputs a conditional base score $q_{ij}$ (the probability of granting permission $j$ given its ancestors are granted). The final probability $\hat{p}_{ij}$ is computed recursively via the probability chain rule by multiplying $q_{ij}$ by the final probabilities of all its parent nodes. If any parent's probability drops to zero, the child's probability automatically becomes zero.

The authors also back this architecture with finite-sample risk bounds, proving statistical consistency even when training labels are partially observed.

Datasets

PATH is evaluated across four setups with high rates of missing (unobserved) labels:

  1. Simulations 1 & 2: Synthetic 2,000-user datasets over a 171-node enterprise permission DAG (65% missingness), testing conditionally independent decisions and latent-factor correlated decisions, respectively.
  2. AI-Generated Synthetic User Study: A new benchmark of 500 user profiles and sequential questionnaire responses generated via ChatGPT 5.5 across a 167-node personal assistant DAG (83.04% missingness, as simulated users could skip questions or stop early).
  3. Real User Authorization Data: A public benchmark (Wu et al., 2026) of 201 real human participants answering data-sharing prompts across 8 domains (447 nodes, 78.18% missingness). The 150-user training split was augmented with 500 ChatGPT-generated synthetic records.

Key Insights and Ideas

  • Post-processing is a trap: When baseline models make logically inconsistent predictions and are forced into compliance via post-processing (e.g., flipping unauthorized children to 0), their overall ranking quality (AUC) consistently drops. Building constraints directly into the forward pass avoids this trade-off.
  • Modeling the chain rule beats clamping outputs: Competing constraint-based neural networks (like C-HMCNN) also achieve zero violations using max-constraint layers, and Chain Classifiers do so sequentially, but PATH outperforms both. Why? Because combining ancestor-masked attention with parent-gated multiplication forces the network to natively learn conditional probability dependencies across all nodes simultaneously.

Key Results

Across all experiments, PATH achieves 0.0000 structural violations by construction, without post-processing:

  • Simulations: PATH achieved the highest AUC in both independent (0.9013) and correlated (0.8828) settings ($p < 10^{-4}$ against all baselines). Meanwhile, post-processing an Independent Classifier caused its AUC to drop from 0.8801 to 0.8427.
  • AI-Generated Users: PATH led all methods in both AUC (0.7692) and F1 score (0.7560), whereas standard deep hierarchical baselines like HMCN-F suffered a 14.21% structural violation rate prior to post-processing.
  • Real Data: PATH achieved the highest F1 score (0.4060 vs. 0.2864 for C-HMCNN and 0.3596 for Independent Classifiers) while matching the top baseline in AUC (0.6773 vs. 0.6778).

Limitations and Future Work

  • Fixed, Known Hierarchies: PATH assumes the permission DAG is completely known and static across all users. It cannot discover unknown action dependencies on the fly.
  • Static User Profiles: The current model relies on tabular user features rather than dynamic context. For future work, the authors plan to incorporate multimodal inputs and rich user-agent interaction histories, and deploy the system on industry-scale datasets inside real AI products.

Summary updated

Abstract

Personal AI agents can carry out complex, multi-step tasks on users' behalf, but doing so often involves numerous permission requests. Manually reviewing each request is time-consuming, while indiscriminate approval poses privacy and security risks. Predicting users' authorization preferences offers a way to reduce this burden while preserving user control. However, authorization prediction is challenging because permission requests are often hierarchical and observed user decisions are sparse and potentially correlated. To address these challenges, We propose the Parent-gated Authorization Transformer for Hierarchies (PATH) to predict users' authorization preferences for personal AI agents. PATH is a novel neural network architecture that combines hierarchy-aware attention masks with a parent-gated probability formulation to ensure hierarchy-consistent predictions. Hierarchy-level embeddings further support learning from sparse observations and patterns shared within each authorization level. We establish finite-sample risk bounds and provide sufficient conditions for consistent authorization probability estimation and algorithmic convergence. Experiments on simulated data, AI-generated user profiles, and real user authorization data demonstrate strong predictive performance with zero hierarchy violations.
BibTeX
@misc{cui2026structure,
  author = {Dongyu Cui and Jie Ding and Xuan Bi},
  title = {{Structure-Aware Transformers for Hierarchical Authorization in Personal AI Agents}},
  year = {2026},
  eprint = {2611.32018},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2611.32018},
}
Figure