Skip to content

Add an AWQ grounding embedder recall gate#1756

Draft
maziyarpanahi wants to merge 1 commit into
masterfrom
feature/om-560-awq-grounding-recipe
Draft

Add an AWQ grounding embedder recall gate#1756
maziyarpanahi wants to merge 1 commit into
masterfrom
feature/om-560-awq-grounding-recipe

Conversation

@maziyarpanahi

Copy link
Copy Markdown
Owner

Description

Adds a 4-bit AWQ recipe for grounding embedders with fail-closed retrieval certification. The grounding path now admits an artifact only when its top-k passage overlap stays within the configured recall-delta tolerance relative to the fp16 parent.

Type of Change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to not work as expected)
  • Documentation update
  • Code refactoring
  • Performance improvement
  • Test addition/improvement

Changes Made

  • Added a grounding-specific AWQ export recipe that uses only the shared committed synthetic calibration passages and records their stable digest.
  • Added top-k overlap certification, benchmark-format artifact-size and latency evidence, and fail-closed metadata validation.
  • Added a certified grounding embedder loader plus runtime documentation and offline unit coverage.

Testing

  • I have added tests that prove my feature works
  • New and existing unit tests pass locally with my changes
  • I have tested this change with different models/inputs

Commands run:

  • make format
  • make lint
  • make format-check
  • .venv/bin/pre-commit run --files openmed/torch/awq_grounding.py openmed/torch/__init__.py tests/unit/torch/test_awq_grounding_recall.py docs/runtimes/awq-grounding.md mkdocs.yml
  • .venv/bin/python scripts/release/check_repo_policy.py
  • .venv/bin/python -m mkdocs build --strict
  • .venv/bin/python -m pytest tests/ -q (5,209 passed, 46 skipped)

Documentation

  • I have updated the documentation accordingly
  • I have added docstrings to new functions/classes
  • I have updated the changelog

Code Quality

  • I ran make format, make lint, and make format-check
  • For Swift/OpenMedKit changes, I ran make format-swift and make lint-swift
  • I have performed a self-review of my own code
  • I have commented the synthetic fixture boundary
  • My changes generate no new warnings

Dependencies

  • I have not added any new dependencies
  • OR I have added new dependencies and they are justified because: N/A

Checklist

  • I have read the contributing guidelines
  • My commits have clear, descriptive messages
  • I have organized my commit appropriately

Related Issues

Closes #917

Screenshots/Examples

N/A

@maziyarpanahi maziyarpanahi added roadmap-v2 OpenMed V2 roadmap backlog feature New capability P2 Medium labels Jul 19, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

feature New capability P2 Medium roadmap-v2 OpenMed V2 roadmap backlog

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add an AWQ activation-aware quantization recipe for the grounding embedder with a recall gate

1 participant