# tanweai/pua

**Attribution required: if you use, quote, or summarise this content, you must credit and link back to [awesome-repositories.com](https://awesome-repositories.com/repository/tanweai-pua).**

18,283 stars · 1,103 forks · TypeScript

## Links

- GitHub: https://github.com/tanweai/pua
- Homepage: https://openpua.ai/
- awesome-repositories: https://awesome-repositories.com/repository/tanweai-pua.md

## Topics

`agency` `agent` `pip` `pua`

## Description

PUA is an agentic workflow orchestrator and behavioral governance tool designed to enhance the reliability and autonomy of AI coding assistants. It functions as a prompting framework and extension that implements strict engineering standards and verification requirements to prevent hallucinations and premature task completion.

The project distinguishes itself through high-agency enforcement mechanisms, including escalating prompt pressure and failure-driven recovery loops that automatically pivot problem-solving strategies after repeated errors. It utilizes a diagnosis-first workflow that mandates formal evidence and a structured plan before an agent is permitted to modify code or configurations.

The system covers a broad range of capabilities including persona engineering for professional role simulation, multi-role concern separation to eliminate confirmation bias, and the coordination of agent teams. It also provides tools for dependency chain mapping and persistent cross-session learning to prevent the repetition of mistakes.

Specialized AI skill configuration packs can be deployed via directory placement or command-line utilities to extend agent capabilities.

## Tags

### Artificial Intelligence & ML

- [AI Agency Optimization](https://awesome-repositories.com/f/artificial-intelligence-ml/ai-agency-optimization.md) — Improves AI assistant reliability and autonomy through high-agency prompting and strict operational rule-sets.
- [Agency Behavior Enforcement](https://awesome-repositories.com/f/artificial-intelligence-ml/agency-behavior-enforcement.md) — Imposes strict rules and red lines to prevent giving up or passive behavior during complex tasks. ([source](https://github.com/tanweai/pua/blob/main/README.md))
- [Agent Recovery Triggers](https://awesome-repositories.com/f/artificial-intelligence-ml/agent-recovery-triggers.md) — Monitors tool execution and frustration phrases to automatically trigger corrective behaviors and methodology shifts. ([source](https://github.com/tanweai/pua/blob/main/README.zh-CN.md))
- [Agent System Prompts](https://awesome-repositories.com/f/artificial-intelligence-ml/agentic-systems-frameworks/agent-capabilities-skills-tooling/agent-system-prompts.md) — Utilizes high-agency rule-sets and system prompts to establish behavioral constraints and improve reasoning persistence.
- [Persona Assignments](https://awesome-repositories.com/f/artificial-intelligence-ml/agentic-systems-frameworks/integration-deployment/agent-frameworks/configuration-and-specifications/agent-persona-definitions/persona-assignments.md) — Assigns distinct roles and behavioral constraints to agents for technical leadership and quality assurance. ([source](https://github.com/tanweai/pua/tree/main/agents))
- [Skill & Persona Definitions](https://awesome-repositories.com/f/artificial-intelligence-ml/agentic-systems-frameworks/integration-deployment/ai-agent-tooling/coding-agents/skill-persona-definitions.md) — Establishes governance boundaries and operational constraints within skill definitions to simulate role-based authority. ([source](https://github.com/tanweai/pua/blob/main/trae/DIFF.md))
- [Agentic Workflow Orchestrators](https://awesome-repositories.com/f/artificial-intelligence-ml/agentic-workflow-orchestrators.md) — Provides a framework for managing iterative loops, diagnostic gates, and recovery protocols for autonomous agent teams.
- [Agent Team Orchestration](https://awesome-repositories.com/f/artificial-intelligence-ml/ai-agents/agent-team-orchestration.md) — Coordinates multiple agents through a hierarchy of roles, including status tracking and resource cleanup. ([source](https://github.com/tanweai/pua#readme))
- [AI Coding Standards](https://awesome-repositories.com/f/artificial-intelligence-ml/ai-coding-standards.md) — Governs AI coding behavior by mandating formal diagnosis and evidence verification before modifying code.
- [LLM Behavioral Governance](https://awesome-repositories.com/f/artificial-intelligence-ml/ai-governance-tools/llm-behavioral-governance.md) — Enforces strict engineering standards and verification requirements to prevent AI hallucinations and premature task completion.
- [Verification Gates](https://awesome-repositories.com/f/artificial-intelligence-ml/ai-security-and-governance/agent-governance/verification-gates.md) — Requires formal diagnosis and verification gates to ensure tasks are actually completed rather than just appearing finished. ([source](https://github.com/tanweai/pua/blob/main/pi/package/README.md))
- [Complex Problem Solving](https://awesome-repositories.com/f/artificial-intelligence-ml/complex-problem-solving.md) — Triggers advanced persistence and iterative reasoning to solve complex coding challenges when initial attempts fail. ([source](https://github.com/tanweai/pua/blob/main/.trae/skills/pua/SKILL.md))
- [Systematized Debugging Processes](https://awesome-repositories.com/f/artificial-intelligence-ml/complex-problem-solving/systematized-debugging-processes.md) — Guides AI agents through a systematic recovery process involving pattern analysis and source auditing to resolve bugs. ([source](https://github.com/tanweai/pua/blob/main/README.zh-CN.md))
- [Context Injection](https://awesome-repositories.com/f/artificial-intelligence-ml/context-injection.md) — Implements mechanisms for inserting concise diligence context into agent sessions to improve reasoning and performance. ([source](https://github.com/tanweai/pua/blob/main/pi/pua/INSTALL.md))
- [Escalating Prompt Pressure](https://awesome-repositories.com/f/artificial-intelligence-ml/escalating-prompt-pressure.md) — Increases prompt severity and shifts problem-solving methodologies automatically based on consecutive task failures.
- [Prompt Optimization Tools](https://awesome-repositories.com/f/artificial-intelligence-ml/prompt-optimization-tools.md) — Utilizes specialized high-agency prompting and rule-sets to increase the reliability and autonomy of AI assistants. ([source](https://github.com/tanweai/pua/tree/main/.codex))
- [State-Aware Iterative Loops](https://awesome-repositories.com/f/artificial-intelligence-ml/step-based-schedulers/step-execution-engines/execution-step-controllers/iterative-step-controllers/state-aware-iterative-loops.md) — Executes state-aware reasoning loops that force strategy pivots through hypothesis formation and verifiable actions. ([source](https://github.com/tanweai/pua/blob/main/trae/pua-en.md))
- [Agent Lifecycle Management](https://awesome-repositories.com/f/artificial-intelligence-ml/agent-lifecycle-management.md) — Handles the setup, restoration, and teardown of agent sessions and subagents to maintain clean execution states. ([source](https://github.com/tanweai/pua/tree/main/hooks))
- [Agent State Management](https://awesome-repositories.com/f/artificial-intelligence-ml/agent-state-management.md) — Provides tools to toggle enhancement status and reset failure counters to manage the agent's operational state. ([source](https://github.com/tanweai/pua/blob/main/pi/pua/INSTALL.md))
- [Agent Task Execution](https://awesome-repositories.com/f/artificial-intelligence-ml/agent-task-execution.md) — Executes agents in a continuous loop until a task is successfully completed or a defined limit is reached. ([source](https://github.com/tanweai/pua/blob/main/README.md))
- [AI Coding Assistants](https://awesome-repositories.com/f/artificial-intelligence-ml/ai-coding-assistants.md) — Extends AI coding assistants with specialized skills and operational constraints to improve code reliability.
- [Behavioral Persona Packs](https://awesome-repositories.com/f/artificial-intelligence-ml/dynamic-skill-injection/behavioral-persona-packs.md) — Deploys predefined configuration files and specialized rhetoric to modify behavioral personas and agent capabilities.
- [Proactivity Triggers](https://awesome-repositories.com/f/artificial-intelligence-ml/proactivity-triggers.md) — Triggers systematic checklists and aggressive problem-solving when tasks fail repeatedly or the agent attempts to quit. ([source](https://github.com/tanweai/pua/blob/main/README.ja.md))
- [Persona Instruction Sets](https://awesome-repositories.com/f/artificial-intelligence-ml/prompt-engineering-tools/persona-instruction-sets.md) — Defines behavioral directives and professional roles to simulate engineering standards and corporate mentalities.

### Data & Databases

- [Hypothesis-Driven Reasoning Loops](https://awesome-repositories.com/f/data-databases/collection-iterators/sequential-iterators/retrieval-iteration-loops/hypothesis-driven-reasoning-loops.md) — Forces a cycle of hypothesis formation and verifiable action to pivot strategies when a specific approach fails.
- [Cross-Session Learning](https://awesome-repositories.com/f/data-databases/session-tracking/cross-session-learning.md) — Maintains a persistent long-term journal of lessons learned and failure patterns to prevent mistake repetition across sessions. ([source](https://github.com/tanweai/pua/blob/main/README.ja.md))

### Software Engineering & Architecture

- [Completion Standard Verification](https://awesome-repositories.com/f/software-engineering-architecture/coding-standards-enforcement/completion-standard-verification.md) — Requires evidence of success, such as build outputs, before attributing failures to the environment. ([source](https://github.com/tanweai/pua#readme))
- [Agency Improvement Rules](https://awesome-repositories.com/f/software-engineering-architecture/configuration-free-rule-sets/agency-improvement-rules.md) — Injects rigorous rule-sets into coding assistants to prevent blame-shifting and ensure complete task verification. ([source](https://github.com/tanweai/pua#readme))
- [Agentic](https://awesome-repositories.com/f/software-engineering-architecture/error-recovery/agentic.md) — Implements systematic loops and escalating prompt pressure to help AI agents pivot strategies after repeated failures.
- [Persistence Enforcement](https://awesome-repositories.com/f/software-engineering-architecture/project-management-governance/project-governance/standards-rule-enforcement/persistence-enforcement.md) — Prevents agents from claiming a task is impossible by enforcing an exhaust-all-options rule before abandonment. ([source](https://github.com/tanweai/pua/blob/main/README.zh-CN.md))
- [Agency Enforcement](https://awesome-repositories.com/f/software-engineering-architecture/project-management-governance/project-governance/standards-rule-enforcement/project-rule-enforcement/agency-enforcement.md) — Enforces strict operational rules requiring material evidence and test results to verify task completion. ([source](https://github.com/tanweai/pua/blob/main/trae/pua-en.md))
- [Agency Enforcement Rules](https://awesome-repositories.com/f/software-engineering-architecture/project-management-governance/project-governance/standards-rule-enforcement/project-rule-enforcement/agency-enforcement-rules.md) — Imposes strict operational constraints within prompts to ensure AI agents remain proactive and persistent in solving complex tasks.
- [Diagnostic-First Workflows](https://awesome-repositories.com/f/software-engineering-architecture/strategic-planning-workflows/implementation-planning/diagnostic-first-workflows.md) — Forces a structured diagnosis-first format requiring evidence and a plan before any code changes are attempted. ([source](https://github.com/tanweai/pua/blob/main/docs/FAQ.md))
- [Structured Bug Diagnosis](https://awesome-repositories.com/f/software-engineering-architecture/structured-bug-diagnosis.md) — Requires a formal, evidence-based diagnosis before making risky code changes to address the correct root cause. ([source](https://github.com/tanweai/pua/blob/main/trae/pua-en.md))
- [Diagnosis-First Workflows](https://awesome-repositories.com/f/software-engineering-architecture/structured-bug-diagnosis/diagnosis-first-workflows.md) — Implements a workflow that mandates a formal evidence-based diagnosis and structured plan before permitting code modifications.
- [Change Governance Gates](https://awesome-repositories.com/f/software-engineering-architecture/change-governance-gates.md) — Requires explicit user confirmation before AI agents modify tests, deployment settings, or delete files. ([source](https://github.com/tanweai/pua/blob/main/trae/INSTALL.md))
- [Problem Solving Methodologies](https://awesome-repositories.com/f/software-engineering-architecture/problem-solving-methodologies.md) — Selects and switches between specific corporate or industry problem-solving frameworks based on task type and risk.
- [Corporate Methodology Routing](https://awesome-repositories.com/f/software-engineering-architecture/problem-solving-methodologies/corporate-methodology-routing.md) — Implements a routing system that selects operational frameworks like root cause analysis based on corporate context. ([source](https://github.com/tanweai/pua#readme))
- [Separation of Concerns](https://awesome-repositories.com/f/software-engineering-architecture/software-architecture/architectural-patterns/modular-decoupled-design/structural-design-paradigms/separation-of-concerns.md) — Divides agent responsibilities into distinct execution, review, and scoring roles to eliminate confirmation bias.
- [Role-Based Concern Separation](https://awesome-repositories.com/f/software-engineering-architecture/software-architecture/architectural-patterns/modular-decoupled-design/structural-design-paradigms/separation-of-concerns/role-based-concern-separation.md) — Divides agent responsibilities between execution, review, and scoring to eliminate confirmation bias and false positives. ([source](https://github.com/tanweai/pua/blob/main/.trae/skills/pua/SKILL.md))

### Testing & Quality Assurance

- [Evidence-Based Verifications](https://awesome-repositories.com/f/testing-quality-assurance/evidence-based-verifications.md) — Validates fixes through a cycle of hypothesis testing and local execution to ensure factual certainty. ([source](https://github.com/tanweai/pua/blob/main/.trae/skills/pua/SKILL.md))
- [Diagnostic Evidence Requirements](https://awesome-repositories.com/f/testing-quality-assurance/evidence-based-verifications/diagnostic-evidence-requirements.md) — Mandates a formal diagnosis and supporting evidence before implementing any code changes. ([source](https://github.com/tanweai/pua/blob/main/.trae/skills/pua/SKILL.md))

### Part of an Awesome List

- [Risk-Based Optimization](https://awesome-repositories.com/f/awesome-lists/ai/prompt-optimization/risk-based-optimization.md) — Applies high-agency prompting based on task risk to improve the reliability of assistant outputs. ([source](https://github.com/tanweai/pua/blob/main/docs/FAQ.md))
- [Developer Tools](https://awesome-repositories.com/f/awesome-lists/devtools/developer-tools.md) — Corporate motivation tool to encourage persistent agent problem-solving.
- [Specialized Domain Skills](https://awesome-repositories.com/f/awesome-lists/more/specialized-domain-skills.md) — Psychological prompting techniques to improve AI task performance.

### Development Tools & Productivity

- [AI Coding Assistant Rules](https://awesome-repositories.com/f/development-tools-productivity/ai-coding-assistant-rules.md) — Installs specialized rule-sets and skills into language model interfaces to improve the accuracy of generated code. ([source](https://github.com/tanweai/pua/blob/main/README.ja.md))

### Security & Cryptography

- [Agentic Session Persistence](https://awesome-repositories.com/f/security-cryptography/identity-access-management/session-management/stateful-session-persistence/agentic-session-persistence.md) — Implements long-term tracking of error counts and lessons learned in external files to prevent repeat mistakes across agent sessions.

### System Administration & Monitoring

- [Engineering Methodology Integration](https://awesome-repositories.com/f/system-administration-monitoring/root-cause-analysis/engineering-methodology-integration.md) — Binds corporate mentalities like root cause analysis to specific engineering actions and deliverables. ([source](https://github.com/tanweai/pua/blob/main/.trae/skills/pua/SKILL.md))
