Skip to main content

Requirements Agent

Self-contained Spec Circuit requirements agent: multi-persona BMAD review → quality score → gap-driven refine → BRD → Markdown/PDF.

No Atlas / FastAPI / Mongo dependency. Configure LLMs in JSON, agent settings in YAML, run from CLI or Textual TUI.

Docs (shipped in the package):

req-agent docs              # paths to bundled files
req-agent docs --open       # architecture HTML in browser
req-agent docs --copy ./docs

Install & init

cd Requirement_Agent
pip install -e ".[dev]"

# Scaffold config in the current directory
req-agent init

# Or into ~/.config/requirements-agent/
req-agent init --global

npm launcher (optional)

The agent is Python. For npx / npm discoverability there is a thin wrapper in npm/:

cd npm && npm install && npm link
npx req-agent --help

Publish PyPI for the real package; publish npm only as the launcher (see npm/README.md).

One-shot release (same version on both registries; assumes you already ran twine/npm login):

./scripts/publish.sh           # current pyproject version
./scripts/publish.sh 0.2.0     # bump + publish
./scripts/publish.sh --dry-run # build only

init writes:

File Purpose
requirements-agent.yaml Agent settings (context, prompts, export, active LLM profile)
llms.json Named LLM profiles (multiple models/providers)
.env.example Env var cheat-sheet for API keys

Configure LLMs (llms.json)

{
  "default": "azure-gpt4o",
  "models": {
    "azure-gpt4o": {
      "provider": "azure",
      "model": "gpt-4o",
      "deployment": "gpt-4o",
      "endpoint": "https://YOUR.openai.azure.com/",
      "api_key_env": "RA_AZURE_API_KEY",
      "temperature": 0.3
    },
    "ollama-llama": {
      "provider": "ollama",
      "model": "llama3.2",
      "endpoint": "http://127.0.0.1:11434/v1"
    },
    "mock": { "provider": "mock", "model": "mock" }
  }
}

List profiles: req-agent models

Configure agent (requirements-agent.yaml)

llm:
  models_file: ./llms.json
  active: azure-gpt4o          # or override with --profile

context:
  providers: [folder]
  folder_paths: [./docs]

prompts:
  personas:
    architect:
      system_extra: "Emphasize zero-trust boundaries."

export:
  default_format: both
  out_dir: ./out

Examples: config.example.yaml, llms.example.json. Legacy TOML still loads if present.

Env overrides: RA_CONFIG, RA_LLMS_JSON, RA_LLM_PROFILE, RA_LLM_PROVIDER, RA_LLM_MODEL, RA_API_KEY / OPENAI_API_KEY / RA_AZURE_*.

CLI

# Preferred: open the shell, set everything in chat
req-agent start
# optional: -p azure-gpt5.4

# Inside the shell:
#   /title Identity Hub SSO
#   /brief ./brief.md
#   /ref ./contracts/
#   /analyse          (also /run)
#   /exit

# Same as start (flags are optional shortcuts)
req-agent run
req-agent run -t "Identity Hub SSO" -f ./brief.md --docs ./contracts/ -p azure-gpt5.4

# Headless / CI
req-agent run --title "..." --design-file brief.md --profile mock --plain --out ./out

# Continue against an existing report
req-agent chat -t "Identity Hub SSO" -f brief.md -r ./out/02-requirements-report.md --docs ./contracts/
# Or from the shell: /open ./out/02-requirements-report.md

req-agent refine --title "..." --design-file brief.md --report ./out/02-requirements-report.md \
  --list-sections
req-agent refine --title "..." --design-file brief.md --report ./out/02-requirements-report.md \
  --section "Non-functional" --message "Add p95 latency and availability targets"
# updates the same file immediately; optional --out to write elsewhere
req-agent refine -r ./out/02-requirements-report.md -t "..." -f brief.md -i   # interactive picker
req-agent consolidate --title "..." --design-file brief.md --report ./out/01-refined.md \
  --out ./out/02-requirements-report.md
req-agent export --report ./out/02-requirements-report.md --out ./out/report --format both

Context injection

Provider v1
folder --attach / --context-dir / folder_paths
rag Stub (phase 2)
mcp Stub (phase 2)

Personas

Eight BMAD roles (vendored bmad-core-spec): orchestrator → analyst → pm → po → architect → dev → qa → sm.

TUIOS

TUIOS is a terminal window manager (minimize m, close x, zoom z, workspaces, dock/rail, Inbox). Those controls are chrome around the pane, not widgets we draw inside req-agent.

Layer What it is
TUIOS Windows, minimize/close/zoom, agent rail, Inbox (learn tour)
req-agent shell Textual chat UI (60/40), Markdown, progress pane, /commands

Recommended: run the agent inside TUIOS so the rail shows state:

tuios                    # then in a pane:
req-agent start
# or: RA_TUIOS_HOOK=1 req-agent start

When detected (or with RA_TUIOS_HOOK=1), we report:

  • tuios set-agent-stateworking / needs_input (confirm) / idle / done / errored
  • OSC 9;4 progress % — shown in TUIOS title/progress where supported

Jump to a waiting agent with TUIOS Inbox keys (see Agents track). Hooks: tuios.dev/docs/hooks.

vs Atlas Requirements Architect

Same Spec Circuit brain and BMAD pack; Memory AI → local folder (future RAG/MCP); LLMs from llms.json instead of Mongo Settings. See REQUIREMENTS_ARCHITECT.md.

Release files for requirements-agent 1.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for requirements-agent 1.0.1
File Size Uploaded
requirements_agent-1.0.1.tar.gz 114.4 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for requirements-agent 1.0.1
File Interpreter ABI Platform
requirements_agent-1.0.1-py3-none-any.whl Python 3 none any Details

Total release size: 248.7 kB

Release files / requirements_agent-1.0.1.tar.gz

Download URL requirements_agent-1.0.1.tar.gz
Size 114.4 kB
Tags Source
SHA-256 checksum
How to use checksums
eaa7ad17c1f13c7ec4def26ee2fe2cb2a4df4f6607c3212b82286a6513e5cf9d
BLAKE2b-256 checksum
How to use checksums
8e01788e825ac349849113a67b8435b09193fca334dca98955cdb047b9e30ea9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.9.13

Release files / requirements_agent-1.0.1-py3-none-any.whl

Download URL requirements_agent-1.0.1-py3-none-any.whl
Size 134.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
df2fc097a9f7933aace971c0d4d5a58ed6df1561f57101d36f34b2d7327bab21
BLAKE2b-256 checksum
How to use checksums
61cee2c1793f5b21b01173532c465c2a4243c0e0a301f5ebf4c9c55482bbc305
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.9.13

Release history Release notifications | RSS feed

1.0.2

2 release files

This release

1.0.1 This release

2 release files

1.0.0

2 release files

0.0.22

2 release files

0.0.21

2 release files

0.0.20

2 release files

0.0.19

2 release files

0.0.18

2 release files

0.0.17

2 release files

0.0.16

2 release files

0.0.15

2 release files

0.0.14

2 release files

0.0.13

2 release files

0.0.12

2 release files

0.0.11

2 release files

0.0.10

2 release files

0.0.9

2 release files

0.0.8

2 release files

0.0.7

2 release files

0.0.6

2 release files

0.0.5

2 release files

0.0.4

2 release files

0.0.3

2 release files

0.0.2

2 release files

0.0.1

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page