Table of Contents
Fetching ...

From Goals to Aspects, Revisited: An NFR Pattern Language for Agentic AI Systems

Yijun Yu

TL;DR

A pattern language of 12 reusable patterns organized across four NFR categories, each mapping an i* goal model to a concrete aspect implementation using an AOP framework for Rust, offers a principled approach for engineering reliable agentic AI systems through early identification of crosscutting concerns.

Abstract

Agentic AI systems exhibit numerous crosscutting concerns -- security, observability, cost management, fault tolerance -- that are poorly modularized in current implementations, contributing to the high failure rate of AI projects in reaching production. The goals-to-aspects methodology proposed at RE 2004 demonstrated that aspects can be systematically discovered from i* goal models by identifying non-functional soft-goals that crosscut functional goals. This paper revisits and extends that methodology to the agentic AI domain. We present a pattern language of 12 reusable patterns organized across four NFR categories (security, reliability, observability, cost management), each mapping an i* goal model to a concrete aspect implementation using an AOP framework for Rust. Four patterns address agent-specific crosscutting concerns absent from traditional AOP literature: tool-scope sandboxing, prompt injection detection, token budget management, and action audit trails. We extend the V-graph model to capture how agent tasks simultaneously contribute to functional goals and non-functional soft-goals. We validate the pattern language through a case study analyzing an open-source autonomous agent framework, demonstrating how goal-driven aspect discovery systematically identifies and modularizes crosscutting concerns. The pattern language offers a principled approach for engineering reliable agentic AI systems through early identification of crosscutting concerns.

From Goals to Aspects, Revisited: An NFR Pattern Language for Agentic AI Systems

TL;DR

A pattern language of 12 reusable patterns organized across four NFR categories, each mapping an i* goal model to a concrete aspect implementation using an AOP framework for Rust, offers a principled approach for engineering reliable agentic AI systems through early identification of crosscutting concerns.

Abstract

Agentic AI systems exhibit numerous crosscutting concerns -- security, observability, cost management, fault tolerance -- that are poorly modularized in current implementations, contributing to the high failure rate of AI projects in reaching production. The goals-to-aspects methodology proposed at RE 2004 demonstrated that aspects can be systematically discovered from i* goal models by identifying non-functional soft-goals that crosscut functional goals. This paper revisits and extends that methodology to the agentic AI domain. We present a pattern language of 12 reusable patterns organized across four NFR categories (security, reliability, observability, cost management), each mapping an i* goal model to a concrete aspect implementation using an AOP framework for Rust. Four patterns address agent-specific crosscutting concerns absent from traditional AOP literature: tool-scope sandboxing, prompt injection detection, token budget management, and action audit trails. We extend the V-graph model to capture how agent tasks simultaneously contribute to functional goals and non-functional soft-goals. We validate the pattern language through a case study analyzing an open-source autonomous agent framework, demonstrating how goal-driven aspect discovery systematically identifies and modularizes crosscutting concerns. The pattern language offers a principled approach for engineering reliable agentic AI systems through early identification of crosscutting concerns.
Paper Structure (31 sections, 7 figures, 6 tables)

This paper contains 31 sections, 7 figures, 6 tables.

Figures (7)

  • Figure 1: Overlapping V-graphs for agents: the "Call LLM" task negatively impacts four NFR softgoals (red dashed arrows), each revealing a crosscutting concern requiring a mitigating aspect.
  • Figure 2: Three-phase methodology for discovering aspects from agent goal models.
  • Figure 3: Pattern relationships: solid arrows show prerequisites, dashed arrows show composition relationships. Patterns marked $\star$ are novel.
  • Figure 4: ZeroClaw codebase growth (LOC, bars) and community adoption (GitHub stars, line) across four analysis snapshots. The framework grew 3.4$\times$ in seven days while accumulating 18,000 GitHub stars, indicating that the crosscutting concerns identified here affect a rapidly growing, widely-adopted system.
  • Figure 5: Strategic Dependency model for ZeroClaw with five actors and their goal dependencies.
  • ...and 2 more figures

Theorems & Definitions (2)

  • Definition 1: V-graph for Agents
  • Definition 2: Crosscutting Density