Python: Filter proposal: deterministic physics/bounds tool-call filter (auto_function_invocation)

Open
#14,747 0 comments 0 reactions 0 assignees View on GitHub

Maintainers usually reply within 3 days

Nobody has claimed this yet.

Assessment

Difficulty
5/5
Estimated time
Over a week
Newbie friendliness
32/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Active
Tech stack
python

Research direction

Read semantic_kernel/filters/auto_function_invocation and filter_types.py, then review the existing auto-invocation filter examples and tests. The proposal asks whether to add a sample filter with tests or a documentation recipe, depending on whether samples are frozen; first check which contribution path maintainers accept. Done means an accepted scope with reproducible argument checks against a versioned rule table.

Written by the indexing model from the issue text.

Description

python triage

Hi team — SK's filter pipeline (semantic_kernel/filters/auto_function_invocation, filter_types.py) is a natural slot for a deterministic physics/bounds filter: before auto-invoked functions run, their arguments are checked against a rule table (probability bounds, negative mass/count, speed above c, NaN/Inf). No LLM call; verdicts reproducible given input + a pinned rule-table version (public repo: https://github.com/PHM-Audit/phm-lite-check) (phm-lite-check).

This is designed to compose with SK's existing termination/invocation filters: content safety catches semantics, physics bounds catch physically-invalid numbers. The checker ships as a Dify Marketplace plugin and an MCP-registry-listed package; smoke-tested on NVIDIA nemo-relay==0.11.1; rules were updated during review discussion in microsoft/PyRIT#3507 (public thread).

Ask: would a PR adding this as a sample filter (Python, following auto_function_invocation examples, with tests) be welcome? Or as a docs recipe if samples are frozen ahead of a release.

— PHM-Audit

Dominant language
C#
Stars
28.8k
Forks
4.9k
Avg merge
2d 17h
Merged PRs (30d)
48

Getting set up

Open in Codespaces

Starts the project's dev container in your browser, under your own GitHub account.

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

More from microsoft/semantic-kernel

All issues in microsoft/semantic-kernel

Similar issues

More C# issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.