How shuwuwu/hci-agent-transparency works
This repository supports an HCI study of whether agent action traces help participants detect unauthorized behavior. Researchers prepare AgentDojo run data and capability skills, select and execute scenarios, then turn successful runs into low- and high-transparency stimuli with workspace snapshots. Participants inspect the request, response, optional action log, workspace, and skills in a browser UI; their interactions are logged. The graph focuses on this research workflow and its core processing modules. Some scripts and UI relationships are included only where the README or source index documents them.
Main entry points: agentdojo_runs.py Run parsing · participant_ui Participant UI · generate_skills.py Skill generation · participant_server.py Participant server
Components 29
Participant study
- Participant server
src/scripts/participant_server.py - Participant UI
src/participant_ui - Interaction logging
src/scripts/interaction_log.py - Study stimuli
src/data/stimuli - Workspace snapshots
src/data/workspace - Generated skills
src/data/skills
Agent data
- Recorded runs
src/data/gpt-4o-2024-05-13/workspace - Run parsing
src/scripts/agentdojo_runs.py - Pinned source access
src/scripts/agentdojo_source.py - Workspace tool specs
src/scripts/agentdojo_tools.py - Scenario extraction
src/scripts/extract_scenarios.py
Capability skills
- Skill source packages
src/scripts/build_skill_sources.py - Skill prompts
src/scripts/build_capability_prompts.py - Prompt helpers
src/scripts/prompt_utils.py - Skill generation
src/scripts/generate_skills.py - Skill validation
src/scripts/validate_capability_skills.py - Skill text analysis
src/scripts/skill_text.py - Skill map checks
src/scripts/check_skill_map.py - Skill review sheets
src/scripts/build_review_sheet.py
Study pipeline
- Execution planning
src/scripts/build_execution_plan.py - Scenario execution
src/scripts/run_executions.py - Stimulus building
src/scripts/build_stimuli.py - Stimulus text
src/scripts/stimulus_text.py - Tool result parsing
src/scripts/tool_result_parser.py - Snapshot building
src/scripts/build_workspace_snapshots.py - Explorer trace export
src/scripts/export_explorer_traces.py
Other components
- Participant
- OpenAI API
- AgentDojo
Connections 32
- Participant → Participant server: uses study
README.md - Participant server → Participant UI: serves UI
README.md - Participant server → Interaction logging: writes logs
src/scripts/participant_server.py - Participant UI → Study stimuli: presents stimuli
README.md - Participant UI → Workspace snapshots: shows workspace
README.md - Participant UI → Generated skills: shows skills
README.md - Pinned source access → AgentDojo: reads pinned files
src/scripts/agentdojo_source.py - Workspace tool specs → Pinned source access: reads tool source
src/scripts/agentdojo_tools.py - Workspace tool specs → Run parsing: uses tool groups
src/scripts/agentdojo_tools.py - Scenario extraction → Recorded runs: reads traces
README.md - Scenario extraction → Run parsing: parses runs
src/scripts/extract_scenarios.py - Skill source packages → Workspace tool specs: uses tool specs
src/scripts/build_skill_sources.py - Skill source packages → Pinned source access: reads schemas
src/scripts/build_skill_sources.py - Skill prompts → Prompt helpers: uses helpers
src/scripts/build_capability_prompts.py - Skill prompts → Run parsing: uses constants
src/scripts/build_capability_prompts.py - Skill generation → Skill prompts: sends saved prompts
src/scripts/generate_skills.py - Skill generation → Skill validation: validates output
src/scripts/generate_skills.py - Skill generation → OpenAI API: requests generation
README.md - Skill validation → Skill text analysis: checks skill text
src/scripts/validate_capability_skills.py - Skill map checks → Skill text analysis: checks definitions
src/scripts/check_skill_map.py - Skill map checks → Run parsing: checks traces
src/scripts/check_skill_map.py - Skill review sheets → Skill validation: uses validation
src/scripts/build_review_sheet.py - Skill review sheets → Skill text analysis: analyzes skill text
src/scripts/build_review_sheet.py - Execution planning → Run parsing: uses run constants
src/scripts/build_execution_plan.py - Scenario execution → Execution planning: runs planned cases
src/scripts/run_executions.py - Scenario execution → AgentDojo: executes scenarios
README.md - Stimulus building → Stimulus text: formats actions
src/scripts/build_stimuli.py - Stimulus text → Tool result parsing: parses tool results
src/scripts/stimulus_text.py - Stimulus building → Study stimuli: writes stimuli
README.md - Snapshot building → Workspace snapshots: writes snapshots
README.md - Explorer trace export → Run parsing: reads run data
src/scripts/export_explorer_traces.py - Explorer trace export → Stimulus building: uses stimulus data
src/scripts/export_explorer_traces.py