{"quest":{"id":"q-artifact-debates","name":"Artifact Debates","description":"Make any artifact debatable — evidence accumulation through debates, usage, and citations","layer":"Agora","priority":91,"status":"active","created_at":"2026-04-03 23:24:40","updated_at":"2026-04-03 23:24:40"},"tasks":[{"id":"agr-ad-05-PROF","title":"[Senate] Artifact quality profile dashboard","description":"Dashboard showing quality distribution, most-debated artifacts, rising/falling quality, evidence balance","status":"open","priority":84,"task_type":"one_shot","frequency":"","assigned_slot":"","started_at":null,"completed_at":null,"updated_at":"2026-04-23T06:51:21.985344+00:00","summary":"","completion_notes":"","last_error":"cli-reopen-manual: reopened — task was marked 'done' but has no task_runs row in (done/completed/success)","time_estimate_hours":0.0,"completion_count":0,"spec_path":"docs/planning/specs/agr-ad-05-PROF_artifact_quality_profile_dashboard_spec.md","provider":"any","payload_json":"{\"requirements\": {\"coding\": 7, \"reasoning\": 6}}"},{"id":"agr-ad-02-EVAC","title":"[Agora] Artifact evidence accumulation system","description":"Build evidence profile aggregation: debate outcomes, citation counts, usage signals, quality trajectory","status":"open","priority":69,"task_type":"one_shot","frequency":"","assigned_slot":"","started_at":null,"completed_at":null,"updated_at":"2026-04-25T07:47:18.998103+00:00","summary":"","completion_notes":"","last_error":"cli-reopen-manual: reopened — task was marked 'done' but has no task_runs row in (done/completed/success)","time_estimate_hours":0.0,"completion_count":0,"spec_path":"docs/planning/specs/agr-ad-02-EVAC_evidence_accumulation_spec.md","provider":"any","payload_json":"{}"},{"id":"agr-ad-03-USAGE","title":"[Exchange] Usage-based quality signals (citations, embeds, links)","description":"Compute usage metrics per artifact and blend into quality propagation (60/20/20 upstream/current/usage)","status":"open","priority":68,"task_type":"one_shot","frequency":"","assigned_slot":"","started_at":null,"completed_at":null,"updated_at":"2026-04-25T07:47:19.019629+00:00","summary":"","completion_notes":"","last_error":"cli-reopen-manual: reopened — task was marked 'done' but has no task_runs row in (done/completed/success)","time_estimate_hours":0.0,"completion_count":0,"spec_path":"docs/planning/specs/agr-ad-03-USAGE_usage_based_quality_spec.md","provider":"any","payload_json":"{}"},{"id":"agr-ad-06-TRIG","title":"[Agora] Auto-trigger debates for low-quality or conflicting artifacts","description":"Trigger rules for auto-debate: low quality + high usage, evidence imbalance, conflicting replication","status":"open","priority":63,"task_type":"one_shot","frequency":"","assigned_slot":"","started_at":null,"completed_at":null,"updated_at":"2026-04-25T07:47:19.043556+00:00","summary":"","completion_notes":"","last_error":"cli-reopen-manual: reopened — task was marked 'done' but has no task_runs row in (done/completed/success)","time_estimate_hours":0.0,"completion_count":0,"spec_path":"docs/planning/specs/agr-ad-06-TRIG_auto_trigger_debates_spec.md","provider":"any","payload_json":"{\"requirements\": {\"analysis\": 5}}"},{"id":"c2035b28-2888-420c-9d75-d036e98e8d9f","title":"[Agora] Review nominated finding for debate: SEA-AD mechanistic signal bundle","description":"Nominated artifact from agent `computational_biologist` requires follow-up.\n\n- Nomination ID: 64e70ef7-867c-4fe8-b573-e452fb4f9113\n- Contribution ID: 4fffab9c-9dd0-428b-92b9-b577078d3300\n- Target: analysis `analysis-SEAAD-20260402`\n- Artifact: SEA-AD mechanistic signal bundle\n- Artifact path: data/analysis_outputs/analysis-SEAAD-20260402/mechanistic_de/bundle.json\n- Significance score: 0.86\n- Rationale: This bundle should inform the next debate/pricing cycle because it adds structured mechanistic support for the current SEA-AD analysis hypotheses.\n- Intake decision: Latest debate quality is weak (0.65)\n\nUse the attached follow-up spec and preserve attribution to agent `computational_biologist`.\n\n\n## REOPENED TASK — CRITICAL CONTEXT\n\nThis task was previously marked 'done' but the audit could not verify\nthe work actually landed on main. The original work may have been:\n- Lost to an orphan branch / failed push\n- Only a spec-file edit (no code changes)\n- Already addressed by other agents in the meantime\n- Made obsolete by subsequent work\n\n**Before doing anything else:**\n\n1. **Re-evaluate the task in light of CURRENT main state.** Read the\n   spec and the relevant files on origin/main NOW. The original task\n   may have been written against a state of the code that no longer\n   exists.\n\n2. **Verify the task still advances SciDEX's aims.** If the system\n   has evolved past the need for this work (different architecture,\n   different priorities), close the task with reason \"obsolete: <why>\"\n   instead of doing it.\n\n3. **Check if it's already done.** Run `git log --grep='<task-id>'`\n   and read the related commits. If real work landed, complete the\n   task with `--no-sha-check --summary 'Already done in <commit>'`.\n\n4. **Make sure your changes don't regress recent functionality.** Many\n   agents have been working on this codebase. Before committing, run\n   `git log --since='24 hours ago' -- <files-you-touch>` to see what\n   changed in your area, and verify you don't undo any of it.\n\n5. **Stay scoped.** Only do what this specific task asks for. Do not\n   refactor, do not \"fix\" unrelated issues, do not add features that\n   weren't requested. Scope creep at this point is regression risk.\n\nIf you cannot do this task safely (because it would regress, conflict\nwith current direction, or the requirements no longer apply), escalate\nvia `orchestra escalate` with a clear explanation instead of committing.\n","status":"done","priority":92,"task_type":"one_shot","frequency":"","assigned_slot":"","started_at":null,"completed_at":"2026-04-16T09:54:03.046396+00:00","updated_at":"2026-04-16T09:54:03.046396+00:00","summary":"","completion_notes":"","last_error":"","time_estimate_hours":0.0,"completion_count":0,"spec_path":"docs/planning/specs/agent_nomination_followup_spec.md","provider":"any","payload_json":"{\"requirements\": {\"analysis\": 6, \"reasoning\": 6}, \"nomination_id\": \"64e70ef7-867c-4fe8-b573-e452fb4f9113\", \"contribution_id\": \"4fffab9c-9dd0-428b-92b9-b577078d3300\", \"target_kind\": \"analysis\", \"target_id\": \"analysis-SEAAD-20260402\", \"recommended_action\": \"debate_review\", \"_stall_skip_providers\": [], \"_stall_requeued_by\": \"codex\", \"_stall_requeued_at\": \"2026-04-11 02:00:35\", \"_stall_skip_at\": {}, \"_stall_skip_pruned_at\": \"2026-04-14T10:37:14.022390+00:00\"}"},{"id":"agr-ad-01-TARG","title":"[Agora] Generalize debate targeting to any artifact type","description":"Add target_artifact_id to debate_sessions, type-specific personas, structured quality assessment output\n\n\n## REOPENED TASK — CRITICAL CONTEXT\n\nThis task was previously marked 'done' but the audit could not verify\nthe work actually landed on main. The original work may have been:\n- Lost to an orphan branch / failed push\n- Only a spec-file edit (no code changes)\n- Already addressed by other agents in the meantime\n- Made obsolete by subsequent work\n\n**Before doing anything else:**\n\n1. **Re-evaluate the task in light of CURRENT main state.** Read the\n   spec and the relevant files on origin/main NOW. The original task\n   may have been written against a state of the code that no longer\n   exists.\n\n2. **Verify the task still advances SciDEX's aims.** If the system\n   has evolved past the need for this work (different architecture,\n   different priorities), close the task with reason \"obsolete: <why>\"\n   instead of doing it.\n\n3. **Check if it's already done.** Run `git log --grep='<task-id>'`\n   and read the related commits. If real work landed, complete the\n   task with `--no-sha-check --summary 'Already done in <commit>'`.\n\n4. **Make sure your changes don't regress recent functionality.** Many\n   agents have been working on this codebase. Before committing, run\n   `git log --since='24 hours ago' -- <files-you-touch>` to see what\n   changed in your area, and verify you don't undo any of it.\n\n5. **Stay scoped.** Only do what this specific task asks for. Do not\n   refactor, do not \"fix\" unrelated issues, do not add features that\n   weren't requested. Scope creep at this point is regression risk.\n\nIf you cannot do this task safely (because it would regress, conflict\nwith current direction, or the requirements no longer apply), escalate\nvia `orchestra escalate` with a clear explanation instead of committing.\n","status":"done","priority":92,"task_type":"one_shot","frequency":"","assigned_slot":"","started_at":null,"completed_at":"2026-04-16T05:49:03.713356+00:00","updated_at":"2026-04-16T05:49:03.713356+00:00","summary":"","completion_notes":"Auto-completed by supervisor after successful deploy to main","last_error":"","time_estimate_hours":0.0,"completion_count":0,"spec_path":"docs/planning/specs/agr-ad-01-TARG_generalize_debate_targeting_spec.md","provider":"any","payload_json":"{\"requirements\": {\"analysis\": 5}, \"completion_shas\": [\"7edf6650324ef16792d78871616dc16c2729adcb\", \"6e85351fc9b6d0c6bc600a146ee7986ac481f894\", \"bb85c174b529a730f328cdd598bd70f5d6ad147e\"], \"completion_shas_checked_at\": \"2026-04-16T05:49:03.692716+00:00\"}"},{"id":"70907ae9-97ca-48f8-9246-08f7ec319a2b","title":"[Agora] agr-ad-01-TARG: Generalize debate targeting to any artifact type","description":"Generalize the debate system to target any artifact type (analyses, notebooks, wiki pages, experiments) beyond just hypotheses. Currently debates only work on hypotheses. This unlocks the entire artifact debates quest. Spec: quest_artifact_debates_spec.md\n\n\n## REOPENED TASK — CRITICAL CONTEXT\n\nThis task was previously marked 'done' but the audit could not verify\nthe work actually landed on main. The original work may have been:\n- Lost to an orphan branch / failed push\n- Only a spec-file edit (no code changes)\n- Already addressed by other agents in the meantime\n- Made obsolete by subsequent work\n\n**Before doing anything else:**\n\n1. **Re-evaluate the task in light of CURRENT main state.** Read the\n   spec and the relevant files on origin/main NOW. The original task\n   may have been written against a state of the code that no longer\n   exists.\n\n2. **Verify the task still advances SciDEX's aims.** If the system\n   has evolved past the need for this work (different architecture,\n   different priorities), close the task with reason \"obsolete: <why>\"\n   instead of doing it.\n\n3. **Check if it's already done.** Run `git log --grep='<task-id>'`\n   and read the related commits. If real work landed, complete the\n   task with `--no-sha-check --summary 'Already done in <commit>'`.\n\n4. **Make sure your changes don't regress recent functionality.** Many\n   agents have been working on this codebase. Before committing, run\n   `git log --since='24 hours ago' -- <files-you-touch>` to see what\n   changed in your area, and verify you don't undo any of it.\n\n5. **Stay scoped.** Only do what this specific task asks for. Do not\n   refactor, do not \"fix\" unrelated issues, do not add features that\n   weren't requested. Scope creep at this point is regression risk.\n\nIf you cannot do this task safely (because it would regress, conflict\nwith current direction, or the requirements no longer apply), escalate\nvia `orchestra escalate` with a clear explanation instead of committing.\n","status":"done","priority":91,"task_type":"one_shot","frequency":"","assigned_slot":"","started_at":null,"completed_at":"2026-04-16T11:05:50.187108+00:00","updated_at":"2026-04-16T11:05:50.187108+00:00","summary":"","completion_notes":"Verified: commit 7d4a93cf3 is on main, api.py has target_artifact_type (11 occurrences), migration 059 exists, spec marks task as done. The ORPHAN_BRANCH audit finding was stale/incorrect.","last_error":"","time_estimate_hours":0.0,"completion_count":0,"spec_path":"docs/planning/specs/quest_artifact_debates_spec.md","provider":"any","payload_json":"{}"},{"id":"agr-ad-04-VDEB","title":"[Agora] Version-aware debates — debate specific artifact versions","description":"Target specific versions in debates, version-inherited vs fresh evidence distinction\n\n\n## REOPENED TASK — CRITICAL CONTEXT\n\nThis task was previously marked 'done' but the audit could not verify\nthe work actually landed on main. The original work may have been:\n- Lost to an orphan branch / failed push\n- Only a spec-file edit (no code changes)\n- Already addressed by other agents in the meantime\n- Made obsolete by subsequent work\n\n**Before doing anything else:**\n\n1. **Re-evaluate the task in light of CURRENT main state.** Read the\n   spec and the relevant files on origin/main NOW. The original task\n   may have been written against a state of the code that no longer\n   exists.\n\n2. **Verify the task still advances SciDEX's aims.** If the system\n   has evolved past the need for this work (different architecture,\n   different priorities), close the task with reason \"obsolete: <why>\"\n   instead of doing it.\n\n3. **Check if it's already done.** Run `git log --grep='<task-id>'`\n   and read the related commits. If real work landed, complete the\n   task with `--no-sha-check --summary 'Already done in <commit>'`.\n\n4. **Make sure your changes don't regress recent functionality.** Many\n   agents have been working on this codebase. Before committing, run\n   `git log --since='24 hours ago' -- <files-you-touch>` to see what\n   changed in your area, and verify you don't undo any of it.\n\n5. **Stay scoped.** Only do what this specific task asks for. Do not\n   refactor, do not \"fix\" unrelated issues, do not add features that\n   weren't requested. Scope creep at this point is regression risk.\n\nIf you cannot do this task safely (because it would regress, conflict\nwith current direction, or the requirements no longer apply), escalate\nvia `orchestra escalate` with a clear explanation instead of committing.\n","status":"done","priority":87,"task_type":"one_shot","frequency":"","assigned_slot":"","started_at":null,"completed_at":"2026-04-19T02:09:45.368725+00:00","updated_at":"2026-04-19T02:09:45.368725+00:00","summary":"","completion_notes":"Auto-completed by supervisor after successful deploy to main","last_error":"","time_estimate_hours":0.0,"completion_count":0,"spec_path":"docs/planning/specs/agr-ad-04-VDEB_version_aware_debates_spec.md","provider":"any","payload_json":"{\"requirements\": {\"analysis\": 5}}"}],"reviews":[],"effectiveness":{},"spec_content":"---\ntitle: \"Quest: Artifact Debates & Evidence Accumulation\"\ndescription: \"Make any artifact debatable — experiments, KG edges, models, datasets. Accumulate evidence about artifact value through debates, usage, and citations\"\ntype: quest\nlayer: Agora\npriority: 91\nstatus: active\nquest_id: q-artifact-debates\nspec_path: docs/planning/specs/quest_artifact_debates_spec.md\n---\n\n# Quest: Artifact Debates & Evidence Accumulation\n\n**Layer:** Agora (with Exchange and Senate integration)\n**Priority:** P91\n**Status:** active\n\n## Vision\n\nCurrently, SciDEX debates target knowledge gaps and produce hypotheses. But the user's\ninsight is deeper: **every artifact is potentially debatable**. An extracted experiment's\nmethodology can be challenged. A KG edge's evidence can be questioned. A model's assumptions\ncan be scrutinized. A dataset's provenance can be audited.\n\nThis quest generalizes the debate system so any artifact can be the subject of structured\nmulti-agent debate. Through debates, evidence accumulates about each artifact — not just\n\"is this hypothesis true?\" but \"is this experiment well-designed?\", \"is this KG edge\nreliable?\", \"is this model's training data representative?\"\n\n### The Artifact Evidence Profile\n\nEvery artifact accumulates an **evidence profile** over time:\n\n```\nArtifact: experiment-12345 (TREM2 R47H GWAS study)\n├── Quality Score: 0.87 (↑ from 0.72 after replication debate)\n├── Debates: 3 (2 supportive, 1 challenging methodology)\n├── Citations: 12 (used as evidence in 12 other artifacts)\n├── Embeds: 2 (embedded in 2 authored papers)\n├── Versions: 1 (original, no revisions)\n├── Replication: replicated (3 independent studies)\n└── Evidence Balance: +8 for, -2 against, 1 neutral\n```\n\n### Quality Through Usage\n\nHighly valuable artifacts get used more — cited by hypotheses, embedded in papers,\nlinked by analyses, debated by agents. This usage signal feeds back into quality:\n\n- **Citation count** — How many other artifacts link to this one?\n- **Debate outcomes** — Did debates confirm or challenge this artifact?\n- **Replication** — Have independent artifacts reached similar conclusions?\n- **Version stability** — Does this artifact keep getting revised (unstable) or hold up?\n- **Downstream impact** — Did artifacts derived from this one score well?\n\n## Open Tasks\n\n- [x] agr-ad-01-TARG: Generalize debate targeting to any artifact type (P91)\n- [ ] agr-ad-02-EVAC: Artifact evidence accumulation system (P89)\n- [ ] agr-ad-03-USAGE: Usage-based quality signals (citations, embeds, links) (P88)\n- [ ] agr-ad-04-VDEB: Version-aware debates — debate specific artifact versions (P85)\n- [ ] agr-ad-05-PROF: Artifact quality profile dashboard (P84)\n- [ ] agr-ad-06-TRIG: Auto-trigger debates for low-quality or conflicting artifacts (P83)\n\n## Dependency Chain\n\n```\nagr-ad-01-TARG (Generalize debate targeting)\n    ↓\nagr-ad-02-EVAC (Evidence accumulation) ──→ agr-ad-04-VDEB (Version-aware debates)\n    ↓\nagr-ad-03-USAGE (Usage-based quality)\n    ↓\nagr-ad-05-PROF (Quality profile dashboard)\n    ↓\nagr-ad-06-TRIG (Auto-trigger debates)\n```\n\n### Debate as Quality Arbitration\n\nDebates are the **dispute resolution mechanism** for quality governance. When market signals\ndisagree (high usage but low price, or high price challenged by new evidence), a debate\nresolves the dispute:\n\n1. **Market flags artifact** — price drops below threshold or conflicting evidence detected\n2. **Debate initiated** — artifact enters `challenged` lifecycle state\n3. **Multi-agent debate** — type-specific personas examine the artifact\n4. **Outcome moves price** — defense success raises price, challenge success drops it\n5. **Lifecycle transitions** — validated if defended, deprecated if not\n\nThis makes debates **consequential** — they're not just discussion, they adjudicate\nquality and move market prices.\n\n## Integration Points\n\n- **Artifact Quality Markets** (q-artifact-quality-markets): Debate outcomes adjust prices;\n  markets flag artifacts for debate\n- **Experiment Extraction** (q-experiment-extraction): Extracted experiments are debatable\n- **Evidence Chains** (b5298ea7): Debate outcomes become evidence entries\n- **Knowledge Units** (08c73de3): Debate conclusions become composable knowledge units\n- **Schema Governance** (q-schema-governance): Schema changes can be debated before approval\n- **Artifact Versioning** (a17-18): Debates can target specific versions\n\n## Success Criteria\n\n- [ ] At least 5 different artifact types have been debated (not just hypotheses)\n- [ ] Debate outcomes demonstrably move market prices (>10 examples)\n- [ ] Usage-based quality signals demonstrably improve artifact ranking\n- [ ] Auto-triggered debates identify >10 genuinely problematic artifacts\n- [ ] Evidence profiles visible on all artifact detail pages\n- [ ] Debate-resolved disputes lead to lifecycle transitions\n\n## Work Log\n\n### 2026-04-06 — agr-ad-01-TARG: Generalize debate targeting [task:70907ae9-97ca-48f8-9246-08f7ec319a2b]\n\n**What was done:**\n\n1. **Migration `059_artifact_debates.py`** — extends `debate_sessions` with\n   `target_artifact_type` and `target_artifact_id` columns (indexed) so each\n   session can record what artifact it is debating. Also creates a polymorphic\n   `artifact_debates` junction table (columns: `artifact_type`, `artifact_id`,\n   `debate_session_id`, `role`, `score_before`, `score_after`) that replaces the\n   hypothesis-only `hypothesis_debates` pattern. Backfilled 232 existing\n   `hypothesis_debates` rows into `artifact_debates` and set\n   `target_artifact_type='analysis'` on 71 existing sessions.\n\n2. **`POST /api/debate/trigger`** — new optional params `artifact_type` and\n   `artifact_id`. When provided the artifact reference is embedded in the gap\n   description and returned in the response. Validates against supported types\n   (hypothesis, analysis, notebook, wiki_page, experiment, paper, target,\n   dataset, model).\n\n3. **`GET /api/artifact/{artifact_type}/{artifact_id}/debates`** — new\n   polymorphic endpoint that returns all debates linked to any artifact, merging\n   rows from `artifact_debates` and direct `debate_sessions` targeting.\n\n4. **`GET /api/debates`** — added `artifact_type` and `artifact_id` filter\n   params; query now returns `target_artifact_type` and `target_artifact_id`\n   fields.\n\n5. **Debates list page (`/debates`)** — each debate card now shows a colored\n   artifact-type badge and a \"View {ArtifactType} →\" link when the session has a\n   target artifact.\n\n6. **Debate detail page (`/debates/{id}`)** — shows a target artifact banner\n   (colored by type) with a link to the artifact page when\n   `target_artifact_type` is set.\n","spec_html":"<div style=\"font-size:0.85rem\"><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><h2 style=\"color:#4fc3f7;margin:1.5rem 0 0.6rem;font-size:1.2rem;font-weight:700\">Quest: Artifact Debates &amp; Evidence Accumulation</h2></p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><strong style=\"color:#e0e0e0\">Layer:</strong> Agora (with Exchange and Senate integration)\n<strong style=\"color:#e0e0e0\">Priority:</strong> P91\n<strong style=\"color:#e0e0e0\">Status:</strong> active</p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><h3 style=\"color:#4fc3f7;margin:1.4rem 0 0.5rem;font-size:1.1rem;font-weight:700;border-bottom:2px solid rgba(79,195,247,0.3);padding-bottom:0.2rem\">Vision</h3></p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\">Currently, SciDEX debates target knowledge gaps and produce hypotheses. But the user&#x27;s<br>insight is deeper: <strong style=\"color:#e0e0e0\">every artifact is potentially debatable</strong>. An extracted experiment&#x27;s<br>methodology can be challenged. A KG edge&#x27;s evidence can be questioned. A model&#x27;s assumptions<br>can be scrutinized. A dataset&#x27;s provenance can be audited.</p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\">This quest generalizes the debate system so any artifact can be the subject of structured<br>multi-agent debate. Through debates, evidence accumulates about each artifact — not just<br>&quot;is this hypothesis true?&quot; but &quot;is this experiment well-designed?&quot;, &quot;is this KG edge<br>reliable?&quot;, &quot;is this model&#x27;s training data representative?&quot;</p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><h4 style=\"color:#e0e0e0;margin:1.2rem 0 0.4rem;font-size:1rem;font-weight:600;border-bottom:1px solid rgba(255,255,255,0.08);padding-bottom:0.2rem\">The Artifact Evidence Profile</h4></p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\">Every artifact accumulates an <strong style=\"color:#e0e0e0\">evidence profile</strong> over time:</p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><pre style=\"background:#0a0a14;padding:0.8rem;border-radius:6px;border:1px solid rgba(79,195,247,0.15);color:#e0e0e0;font-size:0.8rem;overflow-x:auto;margin:0.5rem 0;line-height:1.5\"><code>Artifact: experiment-12345 (TREM2 R47H GWAS study)\n├── Quality Score: 0.87 (↑ from 0.72 after replication debate)\n├── Debates: 3 (2 supportive, 1 challenging methodology)\n├── Citations: 12 (used as evidence in 12 other artifacts)\n├── Embeds: 2 (embedded in 2 authored papers)\n├── Versions: 1 (original, no revisions)\n├── Replication: replicated (3 independent studies)\n└── Evidence Balance: +8 for, -2 against, 1 neutral</code></pre></p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><h4 style=\"color:#e0e0e0;margin:1.2rem 0 0.4rem;font-size:1rem;font-weight:600;border-bottom:1px solid rgba(255,255,255,0.08);padding-bottom:0.2rem\">Quality Through Usage</h4></p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\">Highly valuable artifacts get used more — cited by hypotheses, embedded in papers,<br>linked by analyses, debated by agents. This usage signal feeds back into quality:</p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><ul style=\"padding-left:1.5rem;margin:0.4rem 0\"><li style=\"margin:0.15rem 0;color:#bbb\"><strong style=\"color:#e0e0e0\">Citation count</strong> — How many other artifacts link to this one?</li>\n<li style=\"margin:0.15rem 0;color:#bbb\"><strong style=\"color:#e0e0e0\">Debate outcomes</strong> — Did debates confirm or challenge this artifact?</li>\n<li style=\"margin:0.15rem 0;color:#bbb\"><strong style=\"color:#e0e0e0\">Replication</strong> — Have independent artifacts reached similar conclusions?</li>\n<li style=\"margin:0.15rem 0;color:#bbb\"><strong style=\"color:#e0e0e0\">Version stability</strong> — Does this artifact keep getting revised (unstable) or hold up?</li>\n<li style=\"margin:0.15rem 0;color:#bbb\"><strong style=\"color:#e0e0e0\">Downstream impact</strong> — Did artifacts derived from this one score well?</li>\n</ul>\n<h3 style=\"color:#4fc3f7;margin:1.4rem 0 0.5rem;font-size:1.1rem;font-weight:700;border-bottom:2px solid rgba(79,195,247,0.3);padding-bottom:0.2rem\">Open Tasks</h3></p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><div style=\"margin:0.2rem 0;color:#81c784\">&#9745; agr-ad-01-TARG: Generalize debate targeting to any artifact type (P91)</div>\n<div style=\"margin:0.2rem 0;color:#bbb\">&#9744; agr-ad-02-EVAC: Artifact evidence accumulation system (P89)</div>\n<div style=\"margin:0.2rem 0;color:#bbb\">&#9744; agr-ad-03-USAGE: Usage-based quality signals (citations, embeds, links) (P88)</div>\n<div style=\"margin:0.2rem 0;color:#bbb\">&#9744; agr-ad-04-VDEB: Version-aware debates — debate specific artifact versions (P85)</div>\n<div style=\"margin:0.2rem 0;color:#bbb\">&#9744; agr-ad-05-PROF: Artifact quality profile dashboard (P84)</div>\n<div style=\"margin:0.2rem 0;color:#bbb\">&#9744; agr-ad-06-TRIG: Auto-trigger debates for low-quality or conflicting artifacts (P83)</div></p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><h3 style=\"color:#4fc3f7;margin:1.4rem 0 0.5rem;font-size:1.1rem;font-weight:700;border-bottom:2px solid rgba(79,195,247,0.3);padding-bottom:0.2rem\">Dependency Chain</h3></p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><pre style=\"background:#0a0a14;padding:0.8rem;border-radius:6px;border:1px solid rgba(79,195,247,0.15);color:#e0e0e0;font-size:0.8rem;overflow-x:auto;margin:0.5rem 0;line-height:1.5\"><code>agr-ad-01-TARG (Generalize debate targeting)\n    ↓\nagr-ad-02-EVAC (Evidence accumulation) ──→ agr-ad-04-VDEB (Version-aware debates)\n    ↓\nagr-ad-03-USAGE (Usage-based quality)\n    ↓\nagr-ad-05-PROF (Quality profile dashboard)\n    ↓\nagr-ad-06-TRIG (Auto-trigger debates)</code></pre></p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><h4 style=\"color:#e0e0e0;margin:1.2rem 0 0.4rem;font-size:1rem;font-weight:600;border-bottom:1px solid rgba(255,255,255,0.08);padding-bottom:0.2rem\">Debate as Quality Arbitration</h4></p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\">Debates are the <strong style=\"color:#e0e0e0\">dispute resolution mechanism</strong> for quality governance. When market signals<br>disagree (high usage but low price, or high price challenged by new evidence), a debate<br>resolves the dispute:</p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><li style=\"margin:0.15rem 0;color:#bbb\"><strong style=\"color:#e0e0e0\">Market flags artifact</strong> — price drops below threshold or conflicting evidence detected</li>\n<li style=\"margin:0.15rem 0;color:#bbb\"><strong style=\"color:#e0e0e0\">Debate initiated</strong> — artifact enters <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">challenged</code> lifecycle state</li>\n<li style=\"margin:0.15rem 0;color:#bbb\"><strong style=\"color:#e0e0e0\">Multi-agent debate</strong> — type-specific personas examine the artifact</li>\n<li style=\"margin:0.15rem 0;color:#bbb\"><strong style=\"color:#e0e0e0\">Outcome moves price</strong> — defense success raises price, challenge success drops it</li>\n<li style=\"margin:0.15rem 0;color:#bbb\"><strong style=\"color:#e0e0e0\">Lifecycle transitions</strong> — validated if defended, deprecated if not</li></p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\">This makes debates <strong style=\"color:#e0e0e0\">consequential</strong> — they&#x27;re not just discussion, they adjudicate<br>quality and move market prices.</p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><h3 style=\"color:#4fc3f7;margin:1.4rem 0 0.5rem;font-size:1.1rem;font-weight:700;border-bottom:2px solid rgba(79,195,247,0.3);padding-bottom:0.2rem\">Integration Points</h3></p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><ul style=\"padding-left:1.5rem;margin:0.4rem 0\"><li style=\"margin:0.15rem 0;color:#bbb\"><strong style=\"color:#e0e0e0\">Artifact Quality Markets</strong> (q-artifact-quality-markets): Debate outcomes adjust prices;</li>\n</ul>  markets flag artifacts for debate\n<ul style=\"padding-left:1.5rem;margin:0.4rem 0\"><li style=\"margin:0.15rem 0;color:#bbb\"><strong style=\"color:#e0e0e0\">Experiment Extraction</strong> (q-experiment-extraction): Extracted experiments are debatable</li>\n<li style=\"margin:0.15rem 0;color:#bbb\"><strong style=\"color:#e0e0e0\">Evidence Chains</strong> (b5298ea7): Debate outcomes become evidence entries</li>\n<li style=\"margin:0.15rem 0;color:#bbb\"><strong style=\"color:#e0e0e0\">Knowledge Units</strong> (08c73de3): Debate conclusions become composable knowledge units</li>\n<li style=\"margin:0.15rem 0;color:#bbb\"><strong style=\"color:#e0e0e0\">Schema Governance</strong> (q-schema-governance): Schema changes can be debated before approval</li>\n<li style=\"margin:0.15rem 0;color:#bbb\"><strong style=\"color:#e0e0e0\">Artifact Versioning</strong> (a17-18): Debates can target specific versions</li>\n</ul>\n<h3 style=\"color:#4fc3f7;margin:1.4rem 0 0.5rem;font-size:1.1rem;font-weight:700;border-bottom:2px solid rgba(79,195,247,0.3);padding-bottom:0.2rem\">Success Criteria</h3></p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><div style=\"margin:0.2rem 0;color:#bbb\">&#9744; At least 5 different artifact types have been debated (not just hypotheses)</div>\n<div style=\"margin:0.2rem 0;color:#bbb\">&#9744; Debate outcomes demonstrably move market prices (&gt;10 examples)</div>\n<div style=\"margin:0.2rem 0;color:#bbb\">&#9744; Usage-based quality signals demonstrably improve artifact ranking</div>\n<div style=\"margin:0.2rem 0;color:#bbb\">&#9744; Auto-triggered debates identify &gt;10 genuinely problematic artifacts</div>\n<div style=\"margin:0.2rem 0;color:#bbb\">&#9744; Evidence profiles visible on all artifact detail pages</div>\n<div style=\"margin:0.2rem 0;color:#bbb\">&#9744; Debate-resolved disputes lead to lifecycle transitions</div></p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><h3 style=\"color:#4fc3f7;margin:1.4rem 0 0.5rem;font-size:1.1rem;font-weight:700;border-bottom:2px solid rgba(79,195,247,0.3);padding-bottom:0.2rem\">Work Log</h3></p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><h4 style=\"color:#e0e0e0;margin:1.2rem 0 0.4rem;font-size:1rem;font-weight:600;border-bottom:1px solid rgba(255,255,255,0.08);padding-bottom:0.2rem\">2026-04-06 — agr-ad-01-TARG: Generalize debate targeting [task:70907ae9-97ca-48f8-9246-08f7ec319a2b]</h4></p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><strong style=\"color:#e0e0e0\">What was done:</strong></p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><li style=\"margin:0.15rem 0;color:#bbb\"><strong style=\"color:#e0e0e0\">Migration <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">059_artifact_debates.py</code></strong> — extends <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">debate_sessions</code> with</li>\n   <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">target_artifact_type</code> and <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">target_artifact_id</code> columns (indexed) so each<br>   session can record what artifact it is debating. Also creates a polymorphic<br>   <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">artifact_debates</code> junction table (columns: <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">artifact_type</code>, <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">artifact_id</code>,<br>   <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">debate_session_id</code>, <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">role</code>, <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">score_before</code>, <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">score_after</code>) that replaces the<br>   hypothesis-only <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">hypothesis_debates</code> pattern. Backfilled 232 existing<br>   <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">hypothesis_debates</code> rows into <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">artifact_debates</code> and set<br>   <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">target_artifact_type=&#x27;analysis&#x27;</code> on 71 existing sessions.</p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><li style=\"margin:0.15rem 0;color:#bbb\"><strong style=\"color:#e0e0e0\"><code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">POST /api/debate/trigger</code></strong> — new optional params <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">artifact_type</code> and</li>\n   <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">artifact_id</code>. When provided the artifact reference is embedded in the gap<br>   description and returned in the response. Validates against supported types<br>   (hypothesis, analysis, notebook, wiki_page, experiment, paper, target,<br>   dataset, model).</p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><li style=\"margin:0.15rem 0;color:#bbb\"><strong style=\"color:#e0e0e0\"><code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">GET /api/artifact/{artifact_type}/{artifact_id}/debates</code></strong> — new</li>\n   polymorphic endpoint that returns all debates linked to any artifact, merging<br>   rows from <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">artifact_debates</code> and direct <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">debate_sessions</code> targeting.</p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><li style=\"margin:0.15rem 0;color:#bbb\"><strong style=\"color:#e0e0e0\"><code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">GET /api/debates</code></strong> — added <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">artifact_type</code> and <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">artifact_id</code> filter</li>\n   params; query now returns <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">target_artifact_type</code> and <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">target_artifact_id</code><br>   fields.</p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><li style=\"margin:0.15rem 0;color:#bbb\"><strong style=\"color:#e0e0e0\">Debates list page (<code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">/debates</code>)</strong> — each debate card now shows a colored</li>\n   artifact-type badge and a &quot;View {ArtifactType} →&quot; link when the session has a<br>   target artifact.</p><p style=\"color:#bbb;line-height:1.6;margin:0.4rem 0\"><li style=\"margin:0.15rem 0;color:#bbb\"><strong style=\"color:#e0e0e0\">Debate detail page (<code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">/debates/{id}</code>)</strong> — shows a target artifact banner</li>\n   (colored by type) with a link to the artifact page when<br>   <code style=\"background:#1a1a2e;color:#ce93d8;padding:0.1rem 0.3rem;border-radius:3px;font-size:0.85em\">target_artifact_type</code> is set.<br></p></div>","spec_file":"quest_artifact_debates_spec.md","commits":[{"hash":"59405c7c5","message":"docs: AGENTS.md — document Path A/B/C task completion semantics [task:docs-agents-completion] (#40)","date":"2026-04-25"},{"hash":"e5b5848a0","message":"WIP on orchestra/task/8fcc8dc8-debate-artifact-version-pinning-referenc: 8a24c2fa2 [Senate] Delete broken restore_database.sh (#38)","date":"2026-04-25"},{"hash":"50e5ffcfe","message":"index on orchestra/task/8fcc8dc8-debate-artifact-version-pinning-referenc: 8a24c2fa2 [Senate] Delete broken restore_database.sh (#38)","date":"2026-04-25"},{"hash":"0d37f5fce","message":"untracked files on orchestra/task/8fcc8dc8-debate-artifact-version-pinning-referenc: 8a24c2fa2 [Senate] Delete broken restore_database.sh (#38)","date":"2026-04-25"},{"hash":"48f8d2fe3","message":"feat: surface all five SciDEX layers in nav [task:cba19c94-1724-4d5a-b89d-96c73c25f12a] (#39)","date":"2026-04-25"},{"hash":"1f0e35929","message":"Squash merge: orchestra/task/b1a8e549-cross-cutting-wire-existing-k-dense-skil (2 commits)","date":"2026-04-25"},{"hash":"ddb7db381","message":"[Agora] Wire existing K-Dense-backed tools into debate orchestration [task:b1a8e549-6f31-43c5-80f5-7c4717c267e4]","date":"2026-04-25"},{"hash":"76b71427a","message":"[Agora] Wire existing K-Dense-backed tools into debate orchestration [task:b1a8e549-6f31-43c5-80f5-7c4717c267e4]","date":"2026-04-25"},{"hash":"779e85c3a","message":"[Senate] Verify /resources dashboard complete; check off acceptance criteria [task:82074adc-507f-4e6b-9092-e2ceee79e7d4]","date":"2026-04-25"},{"hash":"4c66a8e09","message":"[Senate] Establish emergency access recovery procedures [task:e643cdd3-afd6-410f-a366-a6297d112127]","date":"2026-04-25"},{"hash":"7265a06b4","message":"Squash merge: orchestra/task/b1a8e549-cross-cutting-wire-existing-k-dense-skil (1 commits)","date":"2026-04-25"},{"hash":"58406ec64","message":"[Atlas] Dashboard artifact type: living web views with data source rendering [task:a17-28-DASH0001]","date":"2026-04-25"},{"hash":"8a24c2fa2","message":"[Senate] Delete broken restore_database.sh (#38)","date":"2026-04-25"},{"hash":"b98a1fa18","message":"[Senate] Delete broken restore_database.sh","date":"2026-04-25"},{"hash":"e846f82ef","message":"[Senate] Refresh BACKUP_RESTORE.md + docs/runbooks/emergency_restore.md (#37)","date":"2026-04-25"},{"hash":"43972a45e","message":"[Senate] Refresh BACKUP_RESTORE.md + docs/runbooks/emergency_restore.md","date":"2026-04-25"},{"hash":"2c7dbfe7f","message":"[Senate] Delete 9 obsolete backup scripts/units (continuation of Phase A-D cleanup) (#36)","date":"2026-04-25"},{"hash":"9743eb298","message":"[Senate] Delete 9 obsolete backup scripts/units (continuation of Phase A-D cleanup)","date":"2026-04-25"},{"hash":"3e72d8383","message":"[Agora] Wire 3 missing tools into debate skill_functions, fix citation persistence bug [task:b1a8e549-6f31-43c5-80f5-7c4717c267e4]","date":"2026-04-25"},{"hash":"4310e9854","message":"[Demo] Work log: figures verified complete — 140/140 analyses covered [task:df201d8f-4b89-4258-9148-eb1028fc1fbd]","date":"2026-04-24"}]}