recalltrace-openenv / README.md
Majen's picture
Initial submission
4d13031 verified
|
Raw History Blame Contribute Delete
2.93 kB
metadata
title: RecallTrace OpenEnv
emoji: 🚨
colorFrom: red
colorTo: blue
sdk: docker
app_port: 7860

πŸš€ RecallTrace OpenEnv

RecallTrace is a real-world AI environment designed for product recall tracing and precision containment.

It simulates how companies handle:

  • contaminated product recalls
  • supply chain tracing
  • selective quarantine decisions

This environment evaluates agent reasoning + decision-making, not just correctness.


🧠 What This Environment Does

Given a recall notice (e.g., "Lot A is contaminated"), the agent must:

  1. Trace where the product went
  2. Identify affected nodes (warehouses, stores)
  3. Handle relabeling / transformations
  4. Quarantine only unsafe inventory
  5. Avoid blocking safe stock
  6. Notify affected entities
  7. Finalize with correct containment

🎯 Why This Is Important

This is a real industry problem seen in:

  • food recalls
  • pharma defects
  • logistics failures

Challenges include:

  • Graph traversal
  • Partial observability
  • Lot transformations
  • Mixed inventory reasoning
  • Precision decision-making

🧩 Tasks (Scenarios)

πŸ”Ή Easy β€” Direct Recall

  • Single contaminated lot
  • Straight supply chain
  • Goal: trace and quarantine correctly

πŸ”Ή Medium β€” Relabeled Inventory

  • Lot gets renamed (LotA β†’ LotA1)
  • Goal: track transformations and quarantine

πŸ”Ή Hard β€” Mixed Inventory

  • Contaminated + safe stock mixed
  • Goal: isolate unsafe quantity without over-blocking

βš™οΈ Action Space

Action Description
inspect_node View inventory at a node
trace_lot Follow product lineage
quarantine Block unsafe stock
notify Inform affected nodes
finalize End task

πŸ“¦ Observation Structure

Each step returns:

  • recall_notice
  • inventory
  • action history
  • trace results
  • inspection data

πŸ† Reward & Grading

Reward System

    • Correct tracing
    • Correct quarantine
    • Correct notification
  • βˆ’ Wrong node
  • βˆ’ Over-quarantine
  • βˆ’ Missed unsafe stock

Final Score

Range: 0.0 β†’ 1.0

Based on:

  • accuracy
  • precision
  • efficiency

🧱 Project Structure

recalltrace-openenv/
β”‚
β”œβ”€β”€ env/                # Environment logic
β”‚   β”œβ”€β”€ env.py
β”‚   └── __init__.py
β”‚
β”œβ”€β”€ scenario/           # Scenario generation
β”‚   └── scenario.py
β”‚
β”œβ”€β”€ grader/             # Evaluation + reward
β”‚   └── grader.py
β”‚
β”œβ”€β”€ inference/          # Agent simulation
β”‚   └── inference.py
β”‚
β”œβ”€β”€ config/
β”‚   └── openenv.yaml
β”‚
β”œβ”€β”€ Dockerfile
β”œβ”€β”€ requirements.txt
β”œβ”€β”€ README.md