Philosophical Dispositions as Behavioral Constraints for AI-Assisted Code Review: An Empirical Study
Kaushal Bansal · 2026
Read Philosophical Dispositions as Behavioral Constraints for AI-Assisted Code Review: An Empirical Study by Kaushal Bansal (2026) in the Tower of Babel, a free online library of public-domain works preserved in clean, searchable text. No sign-up. The full text is served as a plain-text file at a predictable URL, where text is present: https://antarctic-labs.com/tower-of-babel/arxiv-2605-23108.txt.
Introduction
Bansal constrains AI code reviewers through philosophical dispositions, style lenses from schools such as Pyrrhonist Skepticism, Navya-Nyaya logic, Diogenes' Cynicism, and Confucian ethics. Expert reviewer agents give uniform findings no matter the analysis type needed. Each lens is defined by what it refuses to do, carries a self-monitoring failure mode, and is run in sequence by role rules. On 50 pull requests across 7 repos, the system matched human readers 46 percent. It found unique findings at 75 percent. It gave no author false positives among 601 findings.
Catalog record
| CREATOR | Kaushal Bansal |
|---|---|
| YEAR | 2026 |
| COLLECTION | PAPERS |
| FORMAT | TXT |
| FILE SIZE | 44414 |
| LICENSE | http://creativecommons.org/licenses/by/4.0/ |
| RIGHTS | CC BY |
| SOURCE | arXiv |
Source: https://arxiv.org/abs/2605.23108
Browse the full library · About the Tower of Babel
Full text
The opening of the work, from the library's hosted text:
Philosophical Dispositions as Behavioral Constraints for AI-Assisted Code Review: An Empirical Study Kaushal Bansal Abstract AI-assisted code review tools typically operate as generic “expert reviewer” agents, producing homogeneous findings regardless of the analysis type needed. We present a system that constrains AI reviewer behavior through philosophical dispositions —coherent personality lenses grounded in specific epistemological traditions (Pyrrhonist Skepticism, Navya-Nyāya logic, Diogenes’ Cynicism, Confucian relational ethics) that direct attention to structurally different types of issues. Each disposition is defined apophatically (by what it refuses to do), equipped with a self-monitoring failure mode ( hamartia ), and orchestrated in sequence by role protocols. We evaluate this system on 50 merged pull requests across 7 repositories spanning 5 programming languages (Python, Go, C++, Java, Terraform), 5 organizations (2 enterprise, 3 open-source), and 2 temporal eras (pre-AI 2020, post-AI 2024–2026). The disposition system achieves 46% convergence with human reviewers (validating signal quality), identifies unique findings at a 75% rate, and produces no findings judged false-positive by the author across 601 total findings (inter-rater agreement was not assessed and remains a limitation). A controlled baseline comparison demonstrates that 51% of disposition findings are not produced by the same model using generic “expert reviewer” prompting, and these unique findings target structural, operational, and logical concerns rather than standard code-level issues. Preliminary cross-model validation (Claude Opus vs. GPT Codex 5.3-xhigh) on 3 PRs shows 100% framework-structure adherence with 39% finding-level agreement, suggesting the framework provides real behavioral constraint while preserving model-specific analytical perspective. I Introduction I-A The Constraint Problem in AI Agents AI agents operating in software engineering workflows face a fundamental constraint dilemma. On one extreme, fixed rule sets—sandboxes, guardrails, permission lists, rubrics—handle predicted cases cleanly but fail on novel situations. The more comprehensive the rule enumeration, the more internal conflicts emerge and the harder it becomes to maintain consistency. Rule sets do not generate behavior; they enumerate it. On the other extreme, surface-level role descriptions (“act as a security reviewer,” “be thorough and cautious”) produce outputs that look like the described role but are not grounded in generative principles. Under novel pressure—an unfamiliar code pattern, an ambiguous design choice—the role-play breaks because the agent has no internal logic to fall back on when the surface pattern does not apply. I-B The Human Analog: Character Humans solved this constraint problem through character —a coherent set of internalized principles that generates appropriate behavior without requiring a rule for every case. A person with good judgment in code review does not need a rubric entry for “check if resource renames have migrations”; their understanding of system integrity generates that check naturally. We identify three properties of character, synthesized from the virtue ethics literature [ 3 , 10 ] , that make it a superior constraint mechanism for AI agents: 1. Generative: A small set of principles produces appropriate behavior for unbounded novel situations. 2. Self-debugging: Deviations from character are detectable from within the tradition, not just from outside. The Stoic practice of premeditatio malorum [ 11 ] (pre-meditation on what could go wrong) means a Stoic who commits without imagining failure is detectably non-Stoic by Stoic standards. 3. Bounded but adaptive: Character produces predictable behavior within a range while remaining flexible to context. I-C Our Thesis We propose that AI agents can be given character in a meaningful, operational sense—not through surface role-play but through grounding in coherent philosophical traditions that provide generative principles, internal consistency checks, and explicit failure-mode awareness. We call these grounded personalities dispositions . I-D Contributions This paper makes three contributions: 1. Architecture: A system of 10 dispositions (pure single-lens personalities) orchestrated by 8 role protocols, each grounded in a philosophical tradition with 2,000+ years of development. Each disposition is defined apophatically (by refusals) and equipped with self-monitoring ( hamartia ). 2. Empirical evaluation: A retrospective study across 50 PRs demonstrating that the disposition framework achieves 46% convergence with human reviewers, 75% unique find rate, 0% false positives, and 51% differentiation from generic AI prompting. 3. Cross-model validation: Preliminary evidence (N=3) that the framework provides structural constraint independent of model architecture, with 100% categorical adherence and 39% finding-level agreement between Claude and GPT. II Related Work II-A AI-Assisted Code Review The application of large language models (LLMs) to automated code review has grown rapidly. Commercial systems include GitHub Copilot code review [ 9 ] and Amazon CodeGuru, among numerous “AI PR reviewer” products. Research prototypes have explored using pre-trained models for automated review comment generation [ 2 ] and review prioritization. These systems share a common design: they operate as single-perspective generic reviewers, applying the same analytical approach regardless of the type of issue. A generic reviewer treats naming concerns, logic errors, security vulnerabilities, and architectural problems through the same lens. Our work introduces structured multi-perspective analysis where each perspective is grounded in a distinct epistemological tradition, producing categorically different types of findings. II-B Constitutional AI and Principled Prompting Bai et al. [ 1 ] introduce Constitutional AI—principles that generate judgments, primarily focused on harm avoidance and safety. The constitutional approach demonstrates that principled constraints can shape LLM behavior meaningfully. Our work extends this insight from safety-focused constraining to behavioral shaping across all agent outputs . Each disposition’s refusals function as a behavioral constitution specific to a type of analysis, not just a safety boundary. II-C Multi-Agent Frameworks CrewAI [ 6 ] , MetaGPT [ 7 ] , and similar frameworks assign roles to agents. These role labels may activate rich latent representations—the phrase “Code Reviewer” is a key into a substantial region of model capability—but the resulting output remains undifferentiated. An agent assigned “Code Reviewer” produces generic reviews; it has no disposition that generates specific, coherent review behavior from underlying principles. Our architecture explicitly separates the role (an orchestration protocol defining which dispositions fire in what order) from the disposition (a generative personality grounded in philosophical tradition). II-D Philosophy in AI Systems Vallor [ 3 ] proposes virtue-based AI theoretically, arguing that AI systems should embody technomoral virtues. Hagendorff [ 8 ] surveys the meta-ethics of AI ethics approaches. Most relevantly, Sathish [ 4 ] demonstrates that fine-tuning LLMs on Navya-Nyāya reasoning stages achieves measurably higher semantic correctness, validating that non-Western epistemological frameworks produce improvements in LLM reasoning quality, not merely stylistic differences. II-E Structured Perspective Techniques De Bono’s Six Thinking Hats [ 5 ] applies named perspectives to problems. While we share the structural approach (multiple named lenses applied to the same artifact), our work provides substantially deeper grounding. Each disposition draws from millennia of stress-tested philosophical tradition with formal epistemological structure, internal coherence criteria, explicit failure modes ( hamartia ), and defined refusals. III System Design III-A Architecture Overview The system consists of two distinct layers: 1. Dispositions: Pure single-lens personalities, each grounded in a specific philosophical tradition. A disposition generates behavior from principles—it does not enumerate behavior from rules. 2. Roles: Orchestration protocols that sequence multiple dispositions on the same artifact. A role defines which dispositions fire, in what order , for what purpose . III-B Key Architectural Decisions Five design decisions distinguish this architecture from generic multi-agent approaches: 1. One disposition per pass. No multi-personality composition within a single analytical pass. Multiple perspectives are achieved through sequential orchestration , not