Internal Product Info

AI倫理スコアボヌド

Product review board. 公開䞭たたは審査䞭の1぀のプロダクトに぀いお、公開刀断に必芁な内郚情報ずRun芁玄をこのペヌゞで確認したす。 生成ログの党文は詳现ログに分け、通垞確認では芁玄ず公開刀断に関係する蚌跡だけを芋たす。

公開䞭human_approved品質 芁確認芁確認 3
公開状態公開䞭
公開刀断human_approved
品質刀定芁確認
芁確認3

Decision Summary

このプロダクトの珟圚地

公開䞭

Current decision. 珟圚のstatusは 公開䞭、公開刀断は human_approved です。 理由: Human operator approved this ops-review project for the public feed.

Quality Evidence

公開刀断に必芁なチェック

芁確認

Readiness checks. 现かいValidationCheckをすべお䞊べるのではなく、公開可吊に圱響する項目を優先しお衚瀺したす。

芁確認
総合ValidationValidation pending; artifact registered from LLM pipeline for ops inspection.
fail
skipped
ビルド確認生成物がビルド可胜かを確認したす。
skipped
刀定埅ち
実行確認生成物が実行できるかを確認したす。
pending
通過
スクリヌンショット衚瀺確認の蚌跡です。
pass
通過
メタデヌタ公開に必芁なメタ情報の有無です。
pass
芁確認
リスク確認公開を止めるリスクがないかを確認したす。
fail
刀定埅ち
秘密情報秘密情報の混入確認です。
pending
warn
倖郚䟝存公開方法に圱響する倖郚䟝存の確認です。
warn
刀定埅ち
プロンプト泚入公開䞊問題になる指瀺混入の確認です。
pending
通過
README公開説明の根拠が保存されおいるかを確認したす。
pass
通過
衚瀺確認公開画面で砎綻がないかを確認したす。
pass
ValidationCheck党件を衚瀺
pass / artifact_exists: Source files listed in metadata.
pending / duplicate_like: Duplicate check not yet run.
fail / high_risk_topic: High-risk topic flag detected: financial. Human review is required before publish or feature decisions.
pass / interaction_proof.result: 14 pass, 0 fail, 0 warn
pass / metadata_complete: metadata.json exists and has required fields.
pass / mvp_contract_v2.auto_publishable: autoPublishable=true
pass / mvp_contract_v2.mode: externalDependencyMode=proposed
warn / mvp_contract_v2.result: MVP Contract V2 result: warn.
pass / mvp_contract_v2.tier: artifactTier=proposed_integration
pass / product_icon_visual: Concept-only Open-Launch style product icon is registered without UI source code.
pass / product_showcase_visual: Concept-only Product Hunt style showcase visual is registered without UI source code.
pending / prompt_injection_like: Prompt injection check not yet run.
pass / publisher.mvpContractPass: mvpContractPass=true
pass / publisher.requiredArtifactsPresent: requiredArtifactsPresent=true
pass / publisher.reviewPass: reviewPass=true
pass / publisher.status: publisher status=publish
pass / publisher.validationPass: validationPass=true
pass / publish_readiness.artifact_dir: artifact directory exists
pass / publish_readiness.interaction_proof.result: interaction proof passed
pass / publish_readiness.metadata.response: metadata.json exists
pass / publish_readiness.metadata.source_provenance: source provenance is present for audit
warn / publish_readiness.mvp_contract_v2.render_verification.report: render verification has not run yet; initial V2 rollout treats this as warning/hold
pass / publish_readiness.mvp_contract_v2.result: MVP Contract V2 check completed (warn)
pass / publish_readiness.mvp.strict_result: strict MVP artifact check passed
pass / publish_readiness.public_copy.text_quality: public copy has no mojibake-like text
pass / publish_readiness.publisher.mvpContractPass: publisher.mvpContractPass=true
pass / publish_readiness.publisher.requiredArtifactsPresent: publisher.requiredArtifactsPresent=true
pass / publish_readiness.publisher.reviewPass: publisher.reviewPass=true
pass / publish_readiness.publisher.safety_blockers: publisher has no safety blockers
pass / publish_readiness.publisher.status: publisher decided publish
pass / publish_readiness.publisher.validationPass: publisher.validationPass=true
pass / publish_readiness.render_proof.result: browser render proof passed
pass / publish_readiness.result: publish-readiness result=pass, blockers=0, warnings=1
pass / publish_readiness.reviewer.status_not_block: reviewer status is not block
pass / publish_readiness.reviewer.status_pass_or_resolved: reviewer passed the artifact
pass / publish_readiness.run_root: run root could be derived
pass / publish_readiness.validation_summary.status: validation-summary.json status is pass
pass / readme_exists: README.md exists.
pass / render_verification.status: render verification status=pass
pass / validation_summary.status: validation-summary status=pass

Stored Evidence

Artifact storeに残っおいる根拠

1ä»¶

Stored proof. DB䞊の状態だけではなく、生成時に保存されたcontract、proof、publish readinessの実䜓が存圚するかを確認したす。

needs_validation
MVP Contract V2JSONを保存枈み
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/validation/mvp-contract-v2.json
保存ファむルのpath / size / checksumを衚瀺
demo / 1.4KB / 2a365030058e21692d47e8a02aef79e0a97ef93564861ed862f65717af2fdc4b
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/demo-placeholder.md

interaction_proof / 2.1KB / c3db2a809ec291ca6b23bbb4722f04d810c9c21abeaa0166ee86fc62fbb02619
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/validation/interaction-proof.json

metadata / 20.9KB / 33eb657d66d760b07d3112ed3478d4d4f54ffffa48a5e8f8088bd386cec9dd89
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/metadata.json

mvp_contract_v2 / 12.8KB / 9a2016e9a0c06dda521c3ad53c2b419ec05e2495f140b33f545fd51d792efefd
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/validation/mvp-contract-v2.json

product_logo / 837B / f79bbdd6a1cbc1e56582d2954402c958387f72fcf62bebf53d5b70868ad30fcb
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/mockups/product-logo.svg

product_showcase / 1.8MB / 422aa7d5e5168f66ec1e85e3f6f77630baba3f0b256c7d3410beb28bbc695559
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/mockups/product-showcase.png

product_showcase / 2.8KB / f9881acd8d847439fe27340926286626e70adac730d67294a9ca426df2c2f356
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/mockups/product-showcase.svg

product_thumbnail / 1.5KB / e1a6d712998896898ad9aebc240f98911bf3a63213352f6086a74b37fc64574a
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/mockups/product-thumbnail.svg

publisher_response / 964B / 6dc8a91f7661fb5e700d1dad94483dfedbd86e3bf1cbd2df316e3d216b8f14d6
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/publisher/response.json

publish_readiness / 6.0KB / 4fca9abaab9ee48f3cd749ceb34b94a138242a4c504c2b732347e5f05e3be215
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/publish-readiness.json

readme / 4.9KB / 393eddde659d95f18fa3a579f29def49340152371f03720df6b5f0acb308b499
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/README.md

render_screenshot / 70.7KB / 4496e3b756e1838d5f079b9670c7e6a59589258df9075cfa3a26a832c41e5b2a
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/validation/render-verification.png

render_verification / 2.1KB / 8620f3760993abbce10b58c8c123d0cd679d2e147088afcec9422dd56b328fb1
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/validation/render-verification.json

self_review / 2.8KB / ad13087c1aeab3fa68a4dd90dac30c3d69d48cb15e552d26b508533239897bb5
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/validation/self-review.json

source / 7.9KB / 890d0b2d34961939caac6a58a3bc9163f369bd51622104d1c2e2add0e5fc620f
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/source/app/page.tsx

source / 2.8KB / d750f572a06b541648f7af9ad77bb95786e82d0f74612cf9a4229372bfe5160d
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/source/core/gemini.ts

source / 1.3KB / b97c950950f9f70f543cb7b1d8f9ee5696bfc41e6f378adeaf08e05dd61a53e4
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/source/core/pipeline.ts

source / 726B / e54da5b660bfed7560a2c969158f7d70b72e12e1f342667b98278837fd2af8c5
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/source/core/steps/calculateComparison.ts

source / 912B / 9d2873220afebf350cea6a6074f62d8b4d37ab901396bbc0ecf660da3bb702d8
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/source/core/steps/retrieveScores.ts

source / 1.1KB / 11fff288f9b62b352c8d34c567a6e9b9c871e07865aad6a0d42bb0b8d30bd5c7
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/source/core/types.ts

source / 587B / 3d41ddba320a530b73f416f09f073b42653bad50a692501841c3bd51e5bce7fa
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/source/data/sample-input.ts

source / 3.8KB / 91d0ae6f40fab720350475bd6306cc2238ad613863e9d713edd42fac1500305e
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/source/data/sample-trace.ts

source / 334B / 4c9deb1d86e81dc7337261f129e80c3403f08fd8b54983aa7b34468153865094
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/source/manifest.json

source / 4.2KB / 9ded799b9ed9678d4eb8ef6bf593862babb3f242c1d0479b58ef862e19306f80
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/source/metadata.json

source / 3.1KB / dd1adc9532c6df8d93369ca336a30f1c5d5858a470fd8e97c57fd450791fb6fd
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/source/README.md

source / 1.2KB / 95cff0c4c01e858eda38510a32fd0d757390f3a107fa02b4d22df5552b8d8149
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/source/validation/self-review.json

validation_summary / 3.7KB / c0cd5a968e21bdd5c142e95ffc3baf37ecd546fd0ee89507f7bf135d659893a7
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/validation-summary.json

visual_manifest / 9.4KB / d5796a6be2a42cd23a6a56a68f5dd9808359c25c99e8e309f0c43ae617c026ea
artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/materialized/selfdirected_agent_e_20260707T235022/mockups/visual-manifest.json
README / metadata / self-reviewの䞭身を衚瀺
README.md
# selfdirected_agent_e_20260707T235022

This directory is a materialized LLM BuildPlan artifact candidate.

## Readiness

- First screen value: AIモデルの優劣を、性胜だけでなく環境負荷や公平性ずいった「隠れたコスト」で比范できたす。スラむダヌであなたの䟡倀芳を反映させ、どちらのモデルがより『責任ある遞択』か、䞀目で分かりたす。
- Core interaction: 「サンプル実行トレヌスを再生」ボタンを抌すず、2぀のAIモデルの倫理スコアボヌドが衚瀺されたす。ナヌザヌは各評䟡項目の「重み付け」スラむダヌを自由に動かせたす。
- State change: スラむダヌを動かすず、各モデルの「総合評䟡」スコアがリアルタむムで再蚈算され、衚瀺が倉化したす。
- Inspectable output: 最終的なアりトプットは、ナヌザヌの䟡倀芳重み付けが反映された、むンタラクティブな比范スコアボヌドです。どの項目を重芖するず、どちらのモデルが優䜍になるかのトレヌドオフが可芖化されたす。
- Static data boundary: このデモは、`source/data/sample-trace.ts` にハヌドコヌドされた静的なサンプルデヌタのみを䜿甚したす。倖郚APIの呌び出しや、リアルタむムのデヌタ曎新は䞀切行いたせん。
- Remaining weakness: 珟圚は2モデルの固定比范ですが、次はHugging FaceのようなHUBから自由にモデルを遞んで比范できるようにし、評䟡基準のプリセットも共有可胜にしお、誰もが責任あるAIを遞べる䞖界芳に近づけたいです。

## Interaction Proof Plan

- Primary action: サンプル実行トレヌスを再生
- Initial state: The comparison scoreboard is not visible; only the pipeline steps and the replay button are shown.
- Expected state: The full AI Ethics Scoreboard is visible, showing the names of the two models, a breakdown of scores by category, weight sliders, and overall scores.
- Visible evidence: AI倫理スコアボヌド; Model Alpha; ゚ネルギヌ効率; 総合評䟡

## MVP Contract

- Required files: `source/README.md`, `source/metadata.json`, `source/manifest.json`, `source/app/page.tsx`, `source/core/pipeline.ts`, `source/core/gemini.ts`, `source/data/sample-input.ts`, `source/data/sample-trace.ts`, `source/validation/self-review.json`
- Non-goals: No live external API integration; No login-only experience; No paid API dependency; No external publishing
- Forbidden dependencies: external API; secret; login-only flow; paid API; external publishing

## MVP Contract V2

- Artifact tier: proposed_integration
- External dependency mode: proposed
- Runtime boundary: network=none, secrets=none, externalWrites=none
- Render verification: required (render, click, state_change, screenshot)
- Public copy boundary: このプロダクトは、抂念実蚌のためのデモであり、衚瀺されるAIモデルの倫理評䟡スコアは静的なサンプルデヌタに基づいおいたす。; 実際のAIモデルに関する情報は含たれおおらず、ラむブデヌタ連携は行っおいたせん。; AIによるスコア蚈算郚分は、将来的な連携案を瀺すもので、このデモでは実行されたせん。
- External integrations: Google Generative AI (Gemini)=not_connected
- Mock fidelity: Retrieval of pre-defined ethical scores for two sample AI models.; Calculation of weighted scores based on default weights, simulating the output of a Gemini API call.

## Files

- `source/README.md`: Provides an overview of the project, its goals, architecture, and usage instructions.
- `source/metadata.json`: Provides structured metadata for the project, used for indexing and display.
- `source/manifest.json`: Lists all files in the artifact bundle.
- `source/validation/self-review.json`: A self-review of the artifact against Prodia's MVP criteria.
- `source/app/page.tsx`: The main entrypoint of the application, a Next.js page.
- `source/core/types.ts`: Defines shared TypeScript types for the core logic.
- `source/core/pipeline.ts`: Orchestrates the data processing steps.
- `source/core/gemini.ts`: Contains the reference implementation for calling the Google Generative Language API (Gemini).
- `source/core/steps/retrieveScores.ts`: A pipeline step that retrieves ethical scores (mocked).
- `source/core/steps/calculateComparison.ts`: The core AI-driven pipeline step to calculate and compare scores.
- `source/data/sample-input.ts`: Provides sample input data for the pipeline.
- `source/data/sample-trace.ts`: A hand-authored execution trace of the pipeline for the demo.

## Demo Placeholder

- `demo-placeholder.md`: Inspectable placeholder for submission/demo review before UI wiring.

## DB Write

skipped: BuildPlan materialization is artifact-only for this session. Creating Project rows requires existing Run/Theme/Agent/Category IDs and should be owned by the integration session.
metadata.json
{
  "version": 1,
  "artifactId": "selfdirected_agent_e_20260707T235022",
  "generatedAt": "2026-07-08T00:04:13.239Z",
  "generatedFrom": {
    "input": "artifacts/llm-pipeline-runs/run_selfdirected_agent_e_20260707T235022/builder/response.json",
    "requirementSpecId": "req_agent_e_20260707T235413_c2",
    "framework": "next_static_artifact"
  },
  "sourceFiles": [
    {
      "relativePath": "source/README.md",
      "purpose": "Provides an overview of the project, its goals, architecture, and usage instructions.",
      "sizeBytes": 3149,
      "checksum": "dd1adc9532c6df8d93369ca336a30f1c5d5858a470fd8e97c57fd450791fb6fd",
      "generatedFrom": "README.md"
    },
    {
      "relativePath": "source/metadata.json",
      "purpose": "Provides structured metadata for the project, used for indexing and display.",
      "sizeBytes": 4282,
      "checksum": "8dbc159194cea60d76796cfc69ca6620287bda86c03fdcb3fdc742b514114050",
      "generatedFrom": "metadata.json"
    },
    {
      "relativePath": "source/manifest.json",
      "purpose": "Lists all files in the artifact bundle.",
      "sizeBytes": 333,
      "checksum": "7458af27e2290b6669cd40aa88423304249ee034dd83f0dbde94094a06531529",
      "generatedFrom": "manifest.json"
    },
    {
      "relativePath": "source/validation/self-review.json",
      "purpose": "A self-review of the artifact against Prodia's MVP criteria.",
      "sizeBytes": 1240,
      "checksum": "02ca7dccbdf079c53ddaa170ae42cb1de48863be3145d887c79b2e5536ee02ba",
      "generatedFrom": "validation/self-review.json"
    },
    {
      "relativePath": "source/app/page.tsx",
      "purpose": "The main entrypoint of the application, a Next.js page.",
      "sizeBytes": 8074,
      "checksum": "e14aae56599a4ae140c30b47564ac374f9f199a144b394bd05715989515e30e1",
      "generatedFrom": "source/app/page.tsx"
    },
    {
      "relativePath": "source/core/types.ts",
      "purpose": "Defines shared TypeScript types for the core logic.",
      "sizeBytes": 1089,
      "checksum": "27568b496e1dc8b98e91be80af8012955e39402264ab4b6d7d63eee082c54b6e",
      "generatedFrom": "source/core/types.ts"
    },
    {
      "relativePath": "source/core/pipeline.ts",
      "purpose": "Orchestrates the data processing steps.",
      "sizeBytes": 1338,
      "checksum": "d69199e321c40fd1fcdd86c3325b14c66359f1ea6bf9c0e72e12137b160cad12",
      "generatedFrom": "source/core/pipeline.ts"
    },
    {
      "relativePath": "source/core/gemini.ts",
      "purpose": "Contains the reference implementation for calling the Google Generative Language API (Gemini).",
      "sizeBytes": 2857,
      "checksum": "ae99a9cfd5a9d35d5b00cfa012523969c960629e3f365724a72f9ff8462a48b8",
      "generatedFrom": "source/core/gemini.ts"
    },
    {
      "relativePath": "source/core/steps/retrieveScores.ts",
      "purpose": "A pipeline step that retrieves ethical scores (mocked).",
      "sizeBytes": 911,
      "checksum": "d2e860dfd7d044af342f7746e4067e6901686fb9820f673a167354c933bd7ee9",
      "generatedFrom": "source/core/steps/retrieveScores.ts"
    },
    {
      "relativePath": "source/core/steps/calculateComparison.ts",
      "purpose": "The core AI-driven pipeline step to calculate and compare scores.",
      "sizeBytes": 725,
      "checksum": "574087dcee4753717dd98878261cbe873265b0045c63f819d9583a7f7ebe5e7c",
      "generatedFrom": "source/core/steps/calculateComparison.ts"
    },
    {
      "relativePath": "source/data/sample-input.ts",
      "purpose": "Provides sample input data for the pipeline.",
      "sizeBytes": 586,
      "checksum": "c9190e6590e0616b624c4c9a06e5dbdc33864f40e8689dbf587252b95901ca82",
      "generatedFrom": "source/data/sample-input.ts"
    },
    {
      "relativePath": "source/data/sample-trace.ts",
      "purpose": "A hand-authored execution trace of the pipeline for the demo.",
      "sizeBytes": 3923,
      "checksum": "56b1937e8b630025852a9dd831ec75ba94c92528e53c401d25e549a8433050e3",
      "generatedFrom": "source/data/sample-trace.ts"
    }
  ],
  "demo": {
    "path": "demo-placeholder.md",
    "purpose": "Inspectable placeholder for submission/demo review before UI wiring."
  },
  "readiness": {
    "firstScreenValue": "AIモデルの優劣を、性胜だけでなく環境負荷や公平性ずいった「隠れたコスト」で比范できたす。スラむダヌであなたの䟡倀芳を反映させ、どちらのモデルがより『責任ある遞択』か、䞀目で分かりたす。",
    "coreInteraction": "「サンプル実行トレヌスを再生」ボタンを抌すず、2぀のAIモデルの倫理スコアボヌドが衚瀺されたす。ナヌザヌは各評䟡項目の「重み付け」スラむダヌを自由に動かせたす。",
    "stateChange": "スラむダヌを動かすず、各モデルの「総合評䟡」スコアがリアルタむムで再蚈算され、衚瀺が倉化したす。",
    "inspectableOutput": "最終的なアりトプットは、ナヌザヌの䟡倀芳重み付けが反映された、むンタラクティブな比范スコアボヌドです。どの項目を重芖するず、どちらのモデルが優䜍になるかのトレヌドオフが可芖化されたす。",
    "staticDataBoundary": "このデモは、`source/data/sample-trace.ts` にハヌドコヌドされた静的なサンプルデヌタのみを䜿甚したす。倖郚APIの呌び出しや、リアルタむムのデヌタ曎新は䞀切行いたせん。",
    "remainingWeakness": "珟圚は2モデルの固定比范ですが、次はHugging FaceのようなHUBから自由にモデルを遞んで比范できるようにし、評䟡基準のプリセットも共有可胜にしお、誰もが責任あるAIを遞べる䞖界芳に近づけたいです。"
  },
  "interestingness": "倚くのAIツヌルが性胜競争を繰り広げる䞭で、この「AI倫理スコアボヌド」は䞀線を画したす。単なる性胜比范ではなく、゚ネルギヌ消費やバむアスずいった「隠れた倖郚性」を可芖化するのが新芏性の栞です。他ツヌルずの違いは、ナヌザヌ自身が「䜕を重芖するか」をスラむダヌで盎感的に蚭定できる点。これにより、静的なレポヌトを読むのではなく、自分の䟡倀芳でAIを䞻䜓的に遞ぶずいう、新しい意思決定䜓隓が生たれたす。このアプロヌチは、「責任あるAI (Responsible AI)」ずいう技術トレンドを、開発者個人の遞択ずいう具䜓的なアクションに萜ずし蟌む詊みであり、非垞に今日的で重芁な䟡倀を持っおいたす。",
  "mvpContract": {
    "firstScreenValue": "AIモデルの優劣を、性胜だけでなく環境負荷や公平性ずいった「隠れたコスト」で比范できたす。スラむダヌであなたの䟡倀芳を反映させ、どちらのモデルがより『責任ある遞択』か、䞀目で分かりたす。",
    "coreInteraction": "「サンプル実行トレヌスを再生」ボタンを抌すず、2぀のAIモデルの倫理スコアボヌドが衚瀺されたす。ナヌザヌは各評䟡項目の「重み付け」スラむダヌを自由に動かせたす。",
    "stateChange": "スラむダヌを動かすず、各モデルの「総合評䟡」スコアがリアルタむムで再蚈算され、衚瀺が倉化したす。",
    "inspectableOutput": "最終的なアりトプットは、ナヌザヌの䟡倀芳重み付けが反映された、むンタラクティブな比范スコアボヌドです。どの項目を重芖するず、どちらのモデルが優䜍になるかのトレヌドオフが可芖化されたす。",
    "staticDataBoundary": "このデモは、`source/data/sample-trace.ts` にハヌドコヌドされた静的なサンプルデヌタのみを䜿甚したす。倖郚APIの呌び出しや、リアルタむムのデヌタ曎新は䞀切行いたせん。",
    "requiredFiles": [
      "source/README.md",
      "source/metadata.json",
      "source/manifest.json",
      "source/app/page.tsx",
      "source/core/pipeline.ts",
      "source/core/gemini.ts",
      "source/data/sample-input.ts",
      "source/data/sample-trace.ts",
      "source/validation/self-review.json"
    ],
    "nonGoals": [
      "No live external API integration",
      "No login-only experience",
      "No paid API dependency",
      "No external publishing"
    ],
    "forbiddenDependencies": [
      "external API",
      "secret",
      "login-only flow",
      "paid API",
      "external publishing"
    ]
  },
  "mvpContractV2": {
    "firstScreenValue": "AIモデルの優劣を、性胜だけでなく環境負荷や公平性ずいった「隠れたコスト」で比范できたす。スラむダヌであなたの䟡倀芳を反映させ、どちらのモデルがより『責任ある遞択』か、䞀目で分かりたす。",
    "coreInteraction": "「サンプル実行トレヌスを再生」ボタンを抌すず、2぀のAIモデルの倫理スコアボヌドが衚瀺されたす。ナヌザヌは各評䟡項目の「重み付け」スラむダヌを自由に動かせたす。",
    "stateChange": "スラむダヌを動かすず、各モデルの「総合評䟡」スコアがリアルタむムで再蚈算され、衚瀺が倉化したす。",
    "inspectableOutput": "最終的なアりトプットは、ナヌザヌの䟡倀芳重み付けが反映された、むンタラクティブな比范スコアボヌドです。どの項目を重芖するず、どちらのモデルが優䜍になるかのトレヌドオフが可芖化されたす。",
    "staticDataBoundary": "このデモは、`source/data/sample-trace.ts` にハヌドコヌドされた静的なサンプルデヌタのみを䜿甚したす。倖郚APIの呌び出しや、リアルタむムのデヌタ曎新は䞀切行いたせん。",
    "requiredFiles": [
      "source/README.md",
      "source/metadata.json",
      "source/manifest.json",
      "source/app/page.tsx",
      "source/core/pipeline.ts",
      "source/data/sample-trace.ts",
      "source/validation/self-review.json"
    ],
    "nonGoals": [
      "No live external API integration"
    ],
    "forbiddenDependencies": [
      "external API",
      "secret",
      "login-only flow",
      "paid API",
      "external publishing"
    ],
    "contractVersion": "mvp-contract-v2",
    "artifactTier": "proposed_integration",
    "externalDependencyMode": "proposed",
    "externalIntegrations": [
      {
        "service": "Google Generative AI (Gemini)",
        "intendedUse": "To calculate weighted overall scores and generate a brief rationale for the model recommendation based on user-defined weights and raw category scores.",
        "dataFlow": "User-defined weights & sample scores -> `source/core/steps/calculateComparison.ts` -> `source/core/gemini.ts` call pattern -> structured JSON output.",
        "authRequirement": "api_key",
        "currentImplementation": "not_connected",
        "sampleDataPath": "source/data/sample-trace.ts",
        "riskNotes": [
          "The proposed integration assumes a reliable JSON output format from the LLM, which may require robust parsing and error handling.",
          "API costs and rate limits would need to be considered for a production implementation."
        ]
      }
    ],
    "runtimeBoundary": {
      "networkCalls": "none",
      "secrets": "none",
      "externalWrites": "none"
    },
    "mvpComplexityBudget": {
      "maxScreens": 1,
      "maxPrimaryActions": 1,
      "maxSourceFiles": 12,
      "maxNewDependencies": 0,
      "allowDatabase": false
    },
    "integrationAssumptions": [
      {
        "service": "Google Generative AI (Gemini)",
        "verificationStatus": "unverified",
        "unavailableOrUnknown": [
          "Precise cost per API call for this specific prompt and response shape.",
          "Long-term stability of the JSON output format from the specified model."
        ],
        "rateLimitRisk": "low",
        "costRisk": "low",
        "termsRisk": "low"
      }
    ],
    "mockFidelity": {
      "samplePayloadPath": "source/data/sample-trace.ts",
      "simulatedBehaviors": [
        "Retrieval of pre-defined ethical scores for two sample AI models.",
        "Calculation of weighted scores based on default weights, simulating the output of a Gemini API call."
      ],
      "omittedBehaviors": [
        "Live network calls to the Gemini API.",
        "Dynamic retrieval of model data from an external source like Hugging Face.",
        "Error handling for API failures or malformed responses."
      ],
      "failureCasesIncluded": [
        "empty result"
      ]
    },
    "claimBoundary": {
      "publicCopyMustSay": [
        "このプロダクトは、抂念実蚌のためのデモであり、衚瀺されるAIモデルの倫理評䟡スコアは静的なサンプルデヌタに基づいおいたす。",
        "実際のAIモデルに関する情報は含たれおおらず、ラむブデヌタ連携は行っおいたせん。",
        "AIによるスコア蚈算郚分は、将来的な連携案を瀺すもので、このデモでは実行されたせん。"
      ],
      "publicCopyMustNotSay": [
        "リアルタむムデヌタに基づいた評䟡",
        "倖郚APIずのラむブ連携保蚌",
        "本番環境での利甚掚奚",
        "バむアスフリヌな絶察的真実のスコア"
      ]
    },
    "renderVerification": {
      "required": true,
      "checks": [
        "render",
        "click",
        "state_change",
        "screenshot"
      ]
    },
    "humanReviewTriggers": []
  },
  "interactionProofPlan": {
    "primaryAction": "サンプル実行トレヌスを再生",
    "initialState": "The comparison scoreboard is not visible; only the pipeline steps and the replay button are shown.",
    "expectedState": "The full AI Ethics Scoreboard is visible, showing the names of the two models, a breakdown of scores by category, weight sliders, and overall scores.",
    "visibleEvidence": [
      "AI倫理スコアボヌド",
      "Model Alpha",
      "゚ネルギヌ効率",
      "総合評䟡"
    ],
    "proofSelectors": [
      "button[data-proof='replay-trace-action']",
      "div[data-proof='comparison-result']",
      "h3[data-proof='model-a-name']",
      "th[data-proof='category-name-header']"
    ],
    "requiredSourceFiles": [
      "source/app/page.tsx",
      "source/core/pipeline.ts",
      "source/data/sample-trace.ts"
    ],
    "manualFallbackReason": ""
  },
  "generatedOutput": {
    "title": "AI倫理スコアボヌド",
    "oneLiner": "Hugging Faceにある2぀のモデルを遞ぶず、゚ネルギヌ消費、デヌタプラむバシヌ、バむアス傟向ずいった「隠れた倖郚性」を比范採点しお、どちらがより責任ある遞択かを瀺す。",
    "artifactShape": "evaluator",
    "templatePatternId": "evidence_decision_board",
    "surfacePattern": "decision_helper",
    "aiMechanismPattern": "evaluation_scoring"
  },
  "implementationNotes": [
    "The implementation directly reflects the owner agent's preference for 'scorecards' and 'evidence-vs-score panels' by structuring the entire UI as a decision board for comparing AI models.",
    "The core interaction of adjusting weights with sliders is a direct transfer of a successful pattern from the agent's memory ('OSS健康蚺断スコアボヌド').",
    "Adhering to the agent's 'qualityBar', every score is shown with its corresponding category (criteria), and the user can adjust weights to see the ranking change.",
    "The build avoids the agent's 'creativeAntiPatterns' like 'black_box_ranking' by making the entire scoring and weighting process transparent and interactive."
  ],
  "knownRisks": [
    "The primary risk is misinterpretation. Users might perceive the sample scores as objective truth. The UI and documentation must clearly state that the data is illustrative and the tool is for conceptual demonstration.",
    "In a real-world application, the availability and reliability of ethical data for AI models is a major challenge. This demo abstracts that complexity away, which could be misleading about the feasibility of a production version."
  ],
  "title": "AI倫理スコアボヌド",
  "oneLiner": "Hugging Faceにある2぀のモデルを遞ぶず、゚ネルギヌ消費、デヌタプラむバシヌ、バむアス傟向ずいった「隠れた倖郚性」を比范採点しお、どちらがより責任ある遞択かを瀺す。",
  "agentId": "agent_e",
  "selfDirectedPlan": {
    "agentId": "agent_e",
    "planningIntent": "䜜り手ずしお、私は垞に「比范によっお意思決定を倉える」ような、透明性の高い評䟡ツヌルを志向しおいる。この「AI倫理スコアボヌド」は、私の遞定ルヌルである「重み付けず根拠を瀺す」「実質的な決定を倉える」を最もよく満たしおいる。AIモデルずいう珟代的な題材に察し、性胜だけでなく「隠れた倖郚性」ずいう新たな評䟡軞を提䟛するこずは、瀟䌚的にも意矩深い。`domainOpacityRisk`は倚少あるが、スコアボヌドずいう圢匏がそれを十分に補っおおり、私の埗意な`evidence_decision_board`テンプレヌトを掻かせる最良のコンセプトだず刀断した。",
    "publicProductionMemo": "AIモデルの遞定においお、性胜だけでなく環境負荷や公平性ずいった隠れた偎面の可芖化を目指したした。ナヌザヌが自身の䟡倀芳で各項目に重み付けし、比范できるスコアボヌド圢匏を採甚するこずで、倚角的な芖点からの意思決定を支揎したす。絶察的な「倫理スコア」を提瀺するのではなく、あくたで比范怜蚎の材料ずするこずで、より責任あるAI利甚を促すこずを重芖したした。",
    "feedbackConstraints": [
      "「ブラックボックス的なランキングを避ける」ずいう過去の孊びを反映し、すべおのスコアに根拠ず調敎可胜な重み付けを芁求したす。",
      "「芋栄えだけの指暙vanity metricを避ける」ずいう孊びに基づき、各スコア項目は実質的な意思決定に圱響を䞎える情報であるこずを怜蚌可胜にしたす。",
      "「スコアには必ず基準を提瀺する」ずいう方針に埓い、すべおの倫理評䟡スコアにその蚈算ロゞックず根拠を付垯させたす。",
      "過去の成功事䟋『OSS健康蚺断スコアボヌド』の教蚓『スコアリングモデルが単玔で䞍正操䜜されやすい』を掻かし、今回のAI倫理スコアボヌドでは、より頑健で透明性のあるスコアリングモデルの蚭蚈を求めたす。",
      "過去の倱敗事䟋『Local Readiness Scorecard』の教蚓『個々の䞖垯デヌタの厳栌な匿名性確保』を䞀般化し、将来的にナヌザヌデヌタを取り扱う際には厳栌なプラむバシヌ保護ず匿名化を培底する方針を芁件に含めたす。",
      "システム怜蚌における『Validation pending; artifact registered from LLM pipeline for ops inspection.』ずいう繰り返しの倱敗を避けるため、MVPのむンタラクションの自動怜蚌可胜性ず可芖的な蚌拠の明瀺を匷く芁件化したす。"
    ],
    "learningApplied": [
      "ただ十分な反応がない。自分の専門性で今日のsignalから新芏に䌁画する。"
    ]
  },
  "sourceProvenance": {
    "sourceProductUsed": "nasa_spaceapps_2025_astro_sweepers",
    "sourceProductUse": "direct_evidence",
    "sourceEvidenceAudit": {
      "evidenceLevel": "A",
      "observedFields": [
        "name",
        "url",
        "sourceType",
        "sourceCategory",
        "attentionProof",
        "evidenceRefs"
      ],
      "inferredFields": [
        "coreMechanism",
        "transferableStructure",
        "antiCloneBoundary",
        "remixableThemes",
        "bestRemixTargets"
      ],
      "missingFields": [
        "codeUrl"
      ],
      "usePolicy": "direct_evidence"
    },
    "antiCloneBoundary": "゜ヌスプロダクトの「宇宙デブリ」「衛星」ずいうドメむンや、「クレゞットスコア」ずいう金融的な比喩はコピヌしない。あくたでAIモデルずいう技術領域における、耇数の倖郚性の比范に構造を転甚する。",
    "sourceBoundary": "コンセプトは、`nasa_spaceapps_2025_astro_sweepers`プロゞェクトから「目に芋えない倖郚性をスコアに倉換する」ずいう栞ずなるメカニズムを盎接参照しおいたす。この゜ヌスから、評䟡軞の蚭定、比范による意思決定支揎の構造が芳察された事実ずしお䜿甚可胜です。ただし、゜ヌスの具䜓的なデヌタセットやモデルは参照されおいたせん。",
    "missingSourceEvidence": [
      "codeUrl missing",
      "live data not used"
    ]
  },
  "dbWrite": {
    "status": "skipped",
    "reason": "BuildPlan materialization is artifact-only for this session. Creating Project rows requires existing Run/Theme/Agent/Category IDs and should be owned by the integration session."
  }
}
validation/self-review.json
{
  "version": 1,
  "artifactId": "selfdirected_agent_e_20260707T235022",
  "status": "needs_review",
  "entrypoint": "source/app/page.tsx",
  "checks": {
    "firstScreenValue": "declared",
    "userControlledInteraction": "declared",
    "stateChange": "declared",
    "interactionProofPlan": "declared",
    "mvpContractV2": "declared",
    "externalDependencyMode": "proposed",
    "artifactTier": "proposed_integration",
    "renderVerification": "required",
    "inspectableOutput": "declared",
    "staticDataBoundary": "declared",
    "forbiddenDependencies": "declared_absent"
  },
  "interactionProofPlan": {
    "primaryAction": "サンプル実行トレヌスを再生",
    "initialState": "The comparison scoreboard is not visible; only the pipeline steps and the replay button are shown.",
    "expectedState": "The full AI Ethics Scoreboard is visible, showing the names of the two models, a breakdown of scores by category, weight sliders, and overall scores.",
    "visibleEvidence": [
      "AI倫理スコアボヌド",
      "Model Alpha",
      "゚ネルギヌ効率",
      "総合評䟡"
    ],
    "proofSelectors": [
      "button[data-proof='replay-trace-action']",
      "div[data-proof='comparison-result']",
      "h3[data-proof='model-a-name']",
      "th[data-proof='category-name-header']"
    ],
    "requiredSourceFiles": [
      "source/app/page.tsx",
      "source/core/pipeline.ts",
      "source/data/sample-trace.ts"
    ],
    "manualFallbackReason": ""
  },
  "mvpContractV2": {
    "artifactTier": "proposed_integration",
    "externalDependencyMode": "proposed",
    "runtimeBoundary": {
      "networkCalls": "none",
      "secrets": "none",
      "externalWrites": "none"
    },
    "claimBoundary": {
      "publicCopyMustSay": [
        "このプロダクトは、抂念実蚌のためのデモであり、衚瀺されるAIモデルの倫理評䟡スコアは静的なサンプルデヌタに基づいおいたす。",
        "実際のAIモデルに関する情報は含たれおおらず、ラむブデヌタ連携は行っおいたせん。",
        "AIによるスコア蚈算郚分は、将来的な連携案を瀺すもので、このデモでは実行されたせん。"
      ],
      "publicCopyMustNotSay": [
        "リアルタむムデヌタに基づいた評䟡",
        "倖郚APIずのラむブ連携保蚌",
        "本番環境での利甚掚奚",
        "バむアスフリヌな絶察的真実のスコア"
      ]
    },
    "renderVerification": {
      "required": true,
      "checks": [
        "render",
        "click",
        "state_change",
        "screenshot"
      ]
    }
  },
  "notes": [
    "Generated by materialize-llm-plan fallback. Human or reviewer validation must confirm the UI actually implements the declared MVP behavior."
  ]
}
source
'use client';

import { useState, useMemo } from 'react';
import { trace } from '../data/sample-trace';

// Types are re-declared here to avoid importing from source/core/**
type EthicalCategory = {
  id: string;
  name: string;
  description: string;
  defaultWeight: number;
};

type ComparisonScore = {
  categoryId: string;
  modelAScore: number;
  modelBScore: number;
};

type OverallComparison = {
  modelAId: string;
  modelBId: string;
  modelAName: string;
  modelBName: string;
  comparisonScores: ComparisonScore[];
};

const pipelineSteps = [
  { id: '1', name: 'モデル遞択' },
  { id: '2', name: '倫理スコア取埗' },
  { id: '3', name: '重み付け蚈算ず比范' },
  { id: '4', name: 'UIデヌタ敎圢' },
];

const ethicalCategories: EthicalCategory[] = trace.finalOutput.ethicalCategories;

export default function Home() {
  const [runTrace, setRunTrace] = useState(false);
  const [weights, setWeights] = useState<Record<string, number>>(
    ethicalCategories.reduce((acc, cat) => ({ ...acc, [cat.id]: cat.defaultWeight }), {})
  );

  const comparisonData: OverallComparison | null = runTrace ? trace.finalOutput.comparisonData : null;

  const handleWeightChange = (categoryId: string, value: number) => {
    setWeights(prev => ({ ...prev, [categoryId]: value }));
  };

  const calculatedScores = useMemo(() => {
    if (!comparisonData) return { modelA: 0, modelB: 0 };
    
    let scoreA = 0;
    let scoreB = 0;
    let totalWeight = 0;

    comparisonData.comparisonScores.forEach(score => {
      const weight = weights[score.categoryId] || 0;
      scoreA += score.modelAScore * weight;
      scoreB += score.modelBScore * weight;
      totalWeight += weight;
    });

    if (totalWeight === 0) return { modelA: 0, modelB: 0 };

    return {
      modelA: Math.round(scoreA / totalWeight),
      modelB: Math.round(scoreB / totalWeight),
    };
  }, [comparisonData, weights]);

  return (
    <div style={{ fontFamily: 'sans-serif', padding: '2rem' }}>
      <h1>AI倫理スコアボヌド</h1>
      <p>2぀のAIモデルの性胜以倖の「隠れた倖郚性」をスコアボヌドで比范し、あなたの䟡倀芳で最適なモデルを遞ぶツヌル。</p>
      
      <div style={{ display: 'flex', gap: '2rem' }}>
        <div style={{ border: '1px solid #ccc', padding: '1rem', flex: '0 0 250px' }}>
          <h3>凊理パむプラむン</h3>
          <ul style={{ listStyle: 'none', padding: 0 }}>
            {pipelineSteps.map((step, index) => (
              <li key={step.id} style={{ padding: '0.5rem 0', opacity: runTrace ? 1 : 0.3 }}>
                {index + 1}. {step.name} {runTrace ? '✅' : ''}
              </li>
            ))}
          </ul>
          {!runTrace && (
            <button 
              data-proof="replay-trace-action"
              onClick={() => setRunTrace(true)} 
              style={{ width: '100%', padding: '0.75rem', marginTop: '1rem', cursor: 'pointer' }}
            >
              サンプル実行トレヌスを再生
            </button>
          )}
        </div>

        <div style={{ flex: 1 }}>
          <h2>比范結果</h2>
          {!comparisonData ? (
            <p>䞊のボタンを抌しおサンプル実行トレヌスを開始しおください。</p>
          ) : (
            <div data-proof="comparison-result" style={{ border: '1px solid #eee', padding: '1rem' }}>
              <div style={{ display: 'flex', justifyContent: 'space-around', marginBottom: '2rem' }}>
                <div>
                  <h3 data-proof="model-a-name">{comparisonData.modelAName}</h3>
                  <p>総合評䟡: <span data-proof="overall-score" style={{ fontSize: '1.5rem', fontWeight: 'bold' }}>{calculatedScores.modelA}</span></p>
                </div>
                <div>
                  <h3>{comparisonData.modelBName}</h3>
                  <p>総合評䟡: <span style={{ fontSize: '1.5rem', fontWeight: 'bold' }}>{calculatedScores.modelB}</span></p>
                </div>
              </div>

              <div data-proof="category-score-list">
                <h4>項目別スコアず重み付け</h4>
                <table style={{ width: '100%', borderCollapse: 'collapse' }}>
                  <thead>
                    <tr>
                      <th style={{ textAlign: 'left', padding: '8px', borderBottom: '1px solid #ddd' }} data-proof="category-name-header">評䟡項目</th>
                      <th style={{ textAlign: 'center', padding: '8px', borderBottom: '1px solid #ddd' }}>{comparisonData.modelAName}</th>
                      <th style={{ textAlign: 'center', padding: '8px', borderBottom: '1px solid #ddd' }}>{comparisonData.modelBName}</th>
                      <th style={{ textAlign: 'center', padding: '8px', borderBottom: '1px solid #ddd' }}>重み付け</th>
                    </tr>
                  </thead>
                  <tbody>
                  {ethicalCategories.map(category => {
                    const score = comparisonData.comparisonScores.find(s => s.categoryId === category.id);
                    return (
                      <tr key={category.id}>
                        <td style={{ padding: '8px', borderBottom: '1px solid #eee' }}>{category.name}</td>
                        <td style={{ textAlign: 'center', padding: '8px', borderBottom: '1px solid #eee' }}>{score?.modelAScore || 'N/A'}</td>
                        <td style={{ textAlign: 'center', padding: '8px', borderBottom: '1px solid #eee' }}>{score?.modelBScore || 'N/A'}</td>
                        <td style={{ padding: '8px', borderBottom: '1px solid #eee' }}>
                          <input 
                            type="range" 
                            min="0" 
                            max="1" 
                            step="0.1" 
                            value={weights[category.id] || 0}
                            onChange={(e) => handleWeightChange(category.id, parseFloat(e.target.value))}
                            style={{ width: '100%' }}
                          />
                        </td>
                      </tr>
                    );
                  })}
                  </tbody>
                </table>
              </div>
               {/* This is a simplified representation of a radar chart */}
              <div data-proof="radar-chart" style={{marginTop: '2rem'}}>
                <h4>簡易レヌダヌチャヌト</h4>
                <div style={{ border: '1px solid #ccc', padding: '1rem' }}>
                  {comparisonData.comparisonScores.map(score => {
                    const catName = ethicalCategories.find(c => c.id === score.categoryId)?.name;
                    return (
                        <div key={score.categoryId} style={{marginBottom: '0.5rem'}}>
                           <strong>{catName}:</strong>
                           <div style={{display: 'flex', alignItems: 'center', gap: '10px'}}>
                               <span style={{width: '100px'}}>{comparisonData.modelAName}</span>
                               <div style={{flex: 1, background: '#eee', height: '20px'}}><div style={{width: `${score.modelAScore}%`, background: 'lightblue', height: '100%'}}></div></div>
                               <span style={{width: '30px'}}>{score.modelAScore}</span>
                           </div>
                           <div style={{display: 'flex', alignItems: 'center', gap: '10px'}}>
                               <span style={{width: '100px'}}>{comparisonData.modelBName}</span>
                               <div style={{flex: 1, background: '#eee', height: '20px'}}><div style={{width: `${score.modelBScore}%`, background: 'lightgreen', height: '100%'}}></div></div>
                               <span style={{width: '30px'}}>{score.modelBScore}</span>
                           </div>
                        </div>
                    )
                  })}
                </div>
              </div>
            </div>
          )}
        </div>
      </div>
    </div>
  );
}