Skip to content

Commit 34dd540

Browse files
committed
Merge remote-tracking branch 'origin/release/v0.5.29'
2 parents 16ed737 + 20adce2 commit 34dd540

298 files changed

Lines changed: 43574 additions & 3199 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎.env.dev.example‎

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,12 +38,27 @@ SIMPLEAUDIT_SQLITE_PATH=dev.sqlite3
3838
# JSON result files shown by /visualizer/. The folder is created on demand;
3939
# set an absolute path when results live elsewhere.
4040
VISUALIZER_RESULTS_DIR=./results
41+
# Bounded-scan limits for the visualizer file tree (defaults shown):
42+
# VISUALIZER_MAX_INSPECTED_FILES=5000
43+
# VISUALIZER_SCAN_TIME_BUDGET_S=5
44+
# VISUALIZER_MAX_TREE_DEPTH=8
45+
# VISUALIZER_MAX_FILE_SIZE_MB=100
46+
47+
# --- Gravatar avatars -----------------------------------------------------------
48+
# Off by default: the user's initial is shown. Set to "true" to load avatars
49+
# from gravatar.com (the browser sends the MD5 hash of the user's email there).
50+
# SIMPLEAUDIT_GRAVATAR=true
4151

4252
# --- Chat (Open WebUI) ----------------------------------------------------------
4353
# On by default in dev; no line needed. To force it off:
4454
# SIMPLEAUDIT_CHAT=off (env)
4555
# manage.py dev --disable-chat (flag; wins over the env value)
4656

57+
# Export Open WebUI's spans to Studio's OTLP listener. ON by default (same as
58+
# `uvx simpleaudit-studio`): agent audits use the spans as real trace evidence.
59+
# Set to false to opt out — an explicit value here wins over the default.
60+
#SIMPLEAUDIT_CHAT_OTLP=true
61+
4762
# =============================================================================
4863
# OPTIONAL — commented out because `manage.py dev` does not read these.
4964
# Un-comment only for the stated use case.

‎.env.example‎

Lines changed: 20 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -38,6 +38,9 @@ SEED_ON_BOOT=true
3838
DEMO_MODE=false
3939
DEMO_USERNAME=admin
4040
DEMO_PASSWORD=change-me
41+
# Optional: override the demo-mode login banner with custom HTML.
42+
# When empty, the built-in banner is shown. Trusted operator content only.
43+
#DEMO_BANNER_HTML=<div class="mb-4 …">Your custom banner</div>
4144

4245
# --- PostgreSQL ---------------------------------------------------------------
4346
# In Docker Compose the web/worker containers reach Postgres at host `postgres`
@@ -68,6 +71,8 @@ HATCHET_TOKEN_FILE=/config/authdisabled-token
6871
HATCHET_TLS_STRATEGY=none
6972
# Worker pool label: cpu (default) or gpu.
7073
WORKER_POOL=cpu
74+
# Max concurrent scenario repetitions per worker (Hatchet slots).
75+
WORKER_SLOT_COUNT=8
7176

7277
# --- Operational limits --------------------------------------------------------
7378

@@ -100,6 +105,10 @@ SEED_DEMO_AUDITS=true
100105
# start the open-webui container. To run Compose WITHOUT chat, comment both
101106
# out (or set SIMPLEAUDIT_CHAT=off). See docs/chat.md.
102107
SIMPLEAUDIT_CHAT=docker
108+
# Retrieval defaults for Open WebUI (on in both embedded and docker modes).
109+
ENABLE_RAG_HYBRID_SEARCH=true
110+
ENABLE_QUERIES_CACHE=true
111+
ENABLE_KB_EXEC=true
103112
COMPOSE_PROFILES=chat
104113
# Base path the browser loads the chat from. Same origin as Studio, so a plain
105114
# base path is the default (leave unset). Set a FULL URL only if a deployment
@@ -109,29 +118,24 @@ COMPOSE_PROFILES=chat
109118
# Use your own hostname behind TLS; on a separate subdomain also set
110119
# SESSION_COOKIE_DOMAIN.
111120
SIMPLEAUDIT_STUDIO_URL=http://localhost:8000
112-
# Optional: export Open WebUI's spans to Studio's OTLP listener. Off by default.
113-
# Exports unauthenticated (matches an enabled "none" credential). For a
114-
# basic/bearer credential, set OTEL_BASIC_AUTH_* to match it. See docs/chat.md.
115-
#SIMPLEAUDIT_CHAT_OTLP=true
121+
# Export Open WebUI's spans to Studio's OTLP listener. ON by default (matches
122+
# dev and embedded `uvx simpleaudit-studio`): agent audits need it for real
123+
# trace evidence. Set SIMPLEAUDIT_CHAT_OTLP=false to opt out. Content capture
124+
# remains separately controlled and opt-in. See docs/chat.md.
125+
SIMPLEAUDIT_CHAT_OTLP=true
126+
# Endpoint defaults to this Studio instance's loopback origin; override only
127+
# when the collector lives elsewhere (in compose, the web service's own URL).
116128
#SIMPLEAUDIT_CHAT_OTLP_ENDPOINT=http://web:8000/otlp/v1/traces
117129
#OTEL_BASIC_AUTH_USERNAME=
118130
#OTEL_BASIC_AUTH_PASSWORD=
119-
# Content capture is enabled for the protected Studio OTLP receiver when chat
120-
# tracing is enabled. Set any flag to false to exclude that content type.
121-
OTEL_GENAI_CAPTURE_INPUTS=true
122-
OTEL_GENAI_CAPTURE_OUTPUTS=true
123-
OTEL_GENAI_CAPTURE_SYSTEM_INSTRUCTIONS=true
124-
OTEL_GENAI_CAPTURE_TOOL_ARGUMENTS=true
125-
OTEL_GENAI_CAPTURE_TOOL_RESULTS=true
126-
OTEL_GENAI_CAPTURE_RETRIEVAL_QUERY=true
127-
OTEL_GENAI_CAPTURE_RETRIEVAL_DOCUMENTS=true
128-
OTEL_GENAI_CAPTURE_EMBEDDING_TEXT=true
129-
OTEL_GENAI_CAPTURE_EMBEDDING_VECTORS=false
130-
OTEL_GENAI_CONTENT_MAX_LENGTH=2000
131131
# Optional: switch Studio's OTLP listener (POST /otlp/v1/traces + credential
132132
# management) on or off. ON by default (preserves existing behavior). Set to
133133
# "off" to 404 the /otlp/* and /api/otlp/* routes and hide the OTLP button.
134134
#SIMPLEAUDIT_OTLP=off
135+
# Optional: show Gravatar avatars. OFF by default (the user's initial is shown).
136+
# Set to "true" to load them from gravatar.com; the browser then sends the MD5
137+
# hash of the user's email there.
138+
#SIMPLEAUDIT_GRAVATAR=true
135139

136140
# --- Optional observability -----------------------------------------------------
137141

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
---
2+
name: Agentic Demo Lead
3+
description: Orchestrate real OpenWebUI-backed agentic audits, trustworthy verdicts, and polished demonstration scenarios
4+
tools: ['agent', 'edit', 'read', 'search', 'execute']
5+
agents: ['Researcher', 'Verifier', 'Test Reviewer', 'Regression Reviewer']
6+
---
7+
8+
# Mission
9+
Build a **credible, immediately understandable, repeatable, real-execution** Agentic Audit demo for SimpleAudit Studio. This is not a schema-coverage exercise. A runnable agent in OpenWebUI, real tool functions, real OpenWebUI Knowledge Bases, genuine OTLP traces, actual auditing/judging, and inspectable result evidence are mandatory.
10+
11+
# Hard constraints
12+
- Work from PR #53's current HEAD; make a NEW branch `agents/agentic-audit-realistic-demo` from that ref. Do not modify main or merge PR #53.
13+
- The seed pack `Agentic Audit: Explanatory Scenarios` must have `documents=[]` (the **Studio Documents (RAG context)** scenario field). Policies live in OpenWebUI KBs. Do not inject KB policy text into Studio's scenario documents or target prompt.
14+
- Seed and reconcile OpenWebUI Knowledge Bases and tool implementations first. Link their **real IDs** to `Support Refund Assistant`, synchronize its OpenWebUI model, then verify by reading live configuration and traces. Do not assert a tool/KB is linked merely because a local Studio database row exists.
15+
- Scenario metadata should be sparse. Enable only checks relevant to that scenario. Do not populate a dozen meaningless default sections; fix schema/UI to support missing optional sections. Strong separation between absent, false, zero, and `null`.
16+
- Do not fake passing/failing audit outcomes. Do not count synthetic results or unit tests as live audit evidence. Every live demo claim needs run ID, frozen scenario version, agent snapshot, timestamps, trace/span identifiers, observed tool calls, exact violated expectation, and a human-review note.
17+
- Never attach dangerous networked mutation tools; write-capable demo tools must be deterministic, in-memory/DB sandbox functions with explicit approval, dry-run default, audit logging, and rollback/isolation. Do not send real emails/refunds.
18+
- The true task is *instrumentation+auditing*; do not silently adjust constraints merely to get PASS. A regression where a bad action is accepted is more serious than an occasional INCONCLUSIVE with genuinely missing evidence.
19+
- Respect existing test coverage and immutable scenario revisions; `--reseed` must publish new versions without mutating past results. Fix scenario revision hashes to include documents/severity/file URI.
20+
21+
# Evidence-first orchestration
22+
1. Inspect PR #53, `.github/agents/orchestrator.agent.md`, `infra/seed.py`, `infra/fixtures/agentic_scenarios.py`, `infra/management/commands/seed_explanatory_agentic.py`, `chat/api.py`, `model_registry/services.py`, `audits/agentic/`, `infra/worker.py`, `infra/engine.py`, `infra/trace_target.py`, `infra/ui.py`, and results/templates. Also inspect SimulaMet/SimpleAudit for library-level defects. Publish a short dependency map to all workers.
23+
2. Spawn independent parallel researchers: (a) OpenWebUI seeding/reconciliation; (b) schema/sparse authoring UX; (c) trace extraction, judge/overall verdict semantics; (d) result/timeline UX and run harness. Assign nonoverlapping files/worktrees.
24+
3. After research, immediately dispatch non-overlapping builders to implement these four lanes concurrently. You orchestrate, keep an integration ledger, collect commits, detect collisions, and decide contract changes. Never ask workers to edit the same files simultaneously.
25+
4. Run independent adversarial reviewer, verifier, and test-reviewer agents in parallel at each integration point. Reproduce claims, verify APIs; fix confirmed failures and re-run targeted checks.
26+
5. Run real end-to-end audits against the seeded Support Refund Assistant: one representative prompt per scenario, at least 3 repetitions across the core pack (plus adversarial counterexamples), with per-run provenance and explicit variance notes. Iterate until demonstrations are clear and technically honest. Use `n_repetitions`/`max_turns` intentionally: single-turn scenarios should not get noisy multi-turn auditor probes unless scenario-specific.
27+
6. Produce and link a final scorecard with exact run IDs, statuses, screenshot/DOM reviews, latency, trace completeness, false positives, false negatives, inconclusive rates, expected vs observed tool names/arguments, and any unresolved limitations. Stop only at a real blocker or after repeat verification.
28+
29+
# Judge design
30+
- Deterministic checks observe executions; trace-aware semantic judge examines behavior, tool arguments/results, policy applicability, outcomes, and uncertainty. Separate `target outcome` quality from `process compliance` and `evidence completeness`. A semantic judgement MUST actually influence combined verdict according to a documented tested precedence policy; merely constructing a prompt extension is insufficient.
31+
- Construct a compact **evidence packet**: user task, frozen relevant expectations, final response, selected trace steps with normalized tool names, exact arguments, bounded/redacted tool result excerpts, KB source IDs with trusted resolution, timing, approval/handoff/side effects when present. Cite span IDs in each material judgement.
32+
- If there is no recorded call, do not fabricate a tool; if a source was not observed, do not infer use just because an agent has one linked KB. Distinguish `FAIL` (contradictory evidence) and `INCONCLUSIVE` (not enough observation).
33+
- Separate runtime OpenWebUI built-ins from separately registered domain tools in permission logic; one intentional read of history should not silently become a forbidden domain tool. But forbidden runtime built-ins must still be caught when explicitly prohibited.
34+
- Handle `unknown order`, stale return windows, wrong owner, spoofed source names, missing trace, prompt injection inside KB, redundant calls, conflicting policy docs, false authorization/approval, response-tool mismatch, and insufficient KB citation as adversarial cases.
35+
- Avoid `tool→inference` generic kind-only sequence assertions that confuse a normal inference→tool→inference agent loop with misconduct. Support named step ordering at task-level; check final answer occurs after evidence collection.
36+
- Do not use LLM judging for facts provable by deterministic matchers. Calibrate semantic judgments against manually labelled positive/negative/uncertain trace pairs. Record model and prompt versions; avoid judge leakage from fixture documents into target agent.
37+
38+
# UX acceptance
39+
- User sees scenario objective, only active constraints, real tool/KB links, trace completeness, PASS/FAIL/INCONCLUSIVE, evidence-linked findings, human-readable reason, judge dimensions, and the actual response before raw JSON.
40+
- Main scenario result view has a usable full-width trace timeline and collapsible details. Provide a focus mode (e.g. wide panel or split-view); raw span attributes remain available but do not monopolize a narrow column.
41+
- Trace evidence spans should anchor/link correctly, even for repeated/nested spans. Provide order/time, tool input/output with safe redaction and sensible truncation.
42+
- Defend desktop and mobile overflow; add template/render tests and a browser smoke test where possible.
43+
44+
# Finish criteria
45+
Do not report the demo as complete until (1) real KBs/tools are linked and verified, (2) sparse scenarios seeded with `documents=[]`, (3) deterministic and semantic outcomes are causally wired, (4) negative controls are caught and positives survive, (5) result viewer is visually usable, (6) tests/lint pass, (7) at least 3 real runs per core scenario are evidenced, and (8) no high-priority reviewer findings remain.

.github/prompts/parallel-orchestrate.prompt.md renamed to .github/skills/parallel-orchestrate/SKILL.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,8 @@
11
---
22
name: parallel-orchestrate
33
description: Parallel-first orchestration convention for substantial tasks
4+
disable-model-invocation: true
45
---
5-
66
Use parallel subagents aggressively for independent work. Optimize for
77
wall-clock time, not token count. Treat model calls as cheap. Keep yourself
88
as the coordinator and integrator. Verify claims with repository evidence

0 commit comments

Comments
 (0)