Skip to content

SDK-43: Add LLM unlearning models support#187

Merged
benglewis merged 28 commits into
mainfrom
codex/2026-01-13/linear-mention-sdk-43-add-support-for-unlearning-for-llm
Jan 25, 2026
Merged

SDK-43: Add LLM unlearning models support#187
benglewis merged 28 commits into
mainfrom
codex/2026-01-13/linear-mention-sdk-43-add-support-for-unlearning-for-llm

Conversation

@benglewis
Copy link
Copy Markdown
Contributor

@benglewis benglewis commented Jan 13, 2026


Codex Task


Note

Introduces a typed LLM unlearning SDK surface and exports it.

  • Add hirundo/unlearning_llm.py implementing LlmModel (create/get/list/update/delete with from_response parsing), model sources (HuggingFaceTransformersModel, LocalTransformersModel), and run orchestration via LlmUnlearningRun (launch, cancel, rename, archive, restore, list)
  • Define target behaviors/utilities (BiasBehavior, HallucinationBehavior, SecurityBehavior, CustomBehavior) and dataset descriptors for custom utilities
  • Export new symbols in __init__.py and bump __version__ to 0.1.22

Written by Cursor Bugbot for commit 28b6c1c. Configure here.

Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Comment @cursor review or bugbot run to trigger another review on this PR

Comment thread hirundo/unlearning_llm.py
Comment thread hirundo/unlearning_llm.py Outdated
@benglewis benglewis changed the title SDK-43: Refine LLM unlearning models — explicit response parsing & remove approve helper SDK-43: Add LLM unlearning models support Jan 13, 2026
@benglewis

This comment was marked as resolved.

@chatgpt-codex-connector

This comment was marked as outdated.

@benglewis

This comment was marked as resolved.

@chatgpt-codex-connector

This comment was marked as outdated.

benglewis and others added 5 commits January 14, 2026 00:19
…sdk-43-add-support-for-unlearning-for-llm' into codex/2026-01-13/linear-mention-sdk-43-add-support-for-unlearning-for-llm
…sdk-43-add-support-for-unlearning-for-llm' into codex/2026-01-13/linear-mention-sdk-43-add-support-for-unlearning-for-llm
…upport-for-unlearning-for-llm

# Conflicts:
#	tests/dataset_qa_shared.py
Python version was upgraded to Python 3.10 and new syntax can now be used
@benglewis benglewis self-assigned this Jan 13, 2026
@benglewis benglewis marked this pull request as ready for review January 21, 2026 21:21
Copy link
Copy Markdown

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: 17f756ef21

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

Comment thread hirundo/_run_checking.py Outdated
Comment thread hirundo/_run_checking.py Outdated
@github-merge-queue github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Jan 22, 2026
mishana
mishana previously approved these changes Jan 22, 2026
@benglewis benglewis added this pull request to the merge queue Jan 22, 2026
github-merge-queue Bot pushed a commit that referenced this pull request Jan 22, 2026
* Refine LLM unlearning models

* Move `get_unique_id` to a new `testing_utils` file

* Add small / Smol test

Pun intended

* Switch to `nvidia/Nemotron-Flash-1B` since it turns out that SmolLM2-135M model is not a chat model

* Fix unlearning LLM run typing

* Refine LLM run list typing

* Type unlearning run list responses

* Handle empty target utilities explicitly

* Fix Ruff lint errors and basedpyright errors

Python version was upgraded to Python 3.10 and new syntax can now be used

* Add `check_run` and `acheck_run` (and `check_run_by_id` and `acheck_run_by_id`) for unlearning LLM behavior

* Reduce duplicate code

* LLM behavior unlearning test and loading of transformers Pipeline

* Fix `numpy` version error

* Fix requirements files

* Fix retries when HTTP SSE request fails

* Fix Misha's PR comment

* Fix ChatGPT PR review comments

* Fix Gemini's PR comment

* Fix bug in `deleted_at` field for `OutputUnlearningLlmRun`

Found while testing `.list()`

* Rename `get_pipeline_for_run` to `get_hf_pipeline_for_run`

* Fix `MODEL_FOR_IMAGE_TEXT_TO_TEXT_MAPPING_NAMES` being used instead of `MODEL_FOR_VISION_2_SEQ_MAPPING_NAMES`

* Fix pydantic error due to class not really being imported at runtime
@github-merge-queue github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Jan 22, 2026
mishana
mishana previously approved these changes Jan 22, 2026
@benglewis benglewis added this pull request to the merge queue Jan 22, 2026
@github-merge-queue github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Jan 22, 2026
…M behavior unlearning

Currently only `test2` does
@benglewis benglewis enabled auto-merge January 22, 2026 22:55
@benglewis benglewis added this pull request to the merge queue Jan 22, 2026
@github-merge-queue github-merge-queue Bot removed this pull request from the merge queue due to failed status checks Jan 23, 2026
@benglewis benglewis added this pull request to the merge queue Jan 25, 2026
mishana
mishana previously approved these changes Jan 25, 2026
@benglewis benglewis removed this pull request from the merge queue due to a manual request Jan 25, 2026
@benglewis benglewis enabled auto-merge January 25, 2026 21:11
@benglewis benglewis added this pull request to the merge queue Jan 25, 2026
Merged via the queue into main with commit d3ab168 Jan 25, 2026
29 checks passed
@benglewis benglewis deleted the codex/2026-01-13/linear-mention-sdk-43-add-support-for-unlearning-for-llm branch January 26, 2026 07:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants