发布

  • [OPIK-4094] [SDK] Optimizer SDK reintroduce MCP tool use and optimization (#5056)

    frostbyte_neo 发布于 2026-02-24 13:41:49 +00:00

    • refactor: mcp tool calling utils

    • refactor: restore prompt segment util

    • Update __init__.py

    • test: add mcp tests

    • Create test_mcp_remote_live.py

    • feat(mcp): update functions and sepc

    • docs: readme

    • feat: mcp tool calling libraries

    • chore: wiring

    • chore: update exampels

    • chore: update tests

    • chore: missing stubs

    • chore: mypy and state

    • chore: move prompts to util

    • chore: fixed schema validation for tool optimization

    • chore: mcp reporting display

    • fix: optimizer limits

    • Update toolcalling.py

    • chore: tests and formatters

    • chore: rename API and fix tests for mcp optimization

    • Update test_tool_factory.py

    • Update tool_factory.py

    • docs: tool optimization

    • Update test_prompt_segments.py

    • test: tool optimization

    • chore: tool optimization utils

    • Update tool_factory.py

    • chore: move tests

    • Update test_mcp_remote_live.py

    • feat: support tool optimization in evolutionary optimizer

    • chore: improve api for evo on tools

    • chore: evo toolops

    • feat: tool optimization few-shot

    • chore: api routing for tool optimization for evo

    • Update meta_prompt_optimizer.py

    • Update parameter_optimizer.py

    • Update base_optimizer.py

    • feat: tool optimization gepa + hrpo

    • chore: toolcalling

    • chore: lint

    • refactor: tool operations

    • chore: docstrings for tool use

    • Update mutation_ops.py

    • chore: docs updates

    • fix(optimizer): wire GEPA tool-use and role flag validation

    • fix(evolutionary): isolate child tool metadata and degrade on tool update errors

    • fix(agent): handle malformed tool-call arguments gracefully

    • fix(llm): enforce OpenAI strict structured-output schema rules

    • test(evolutionary): align semantic mutation fallback assertions

    • refactor(llm): centralize OpenAI response_format injection

    • fix(toolcalling): harden logging, selector mapping, and approval gates

    • refactor(display): unify tool summary rendering

    • chore(tests): satisfy pre-commit typing and formatting

    • fix(optimizer): degrade GEPA tool optimization and tighten flags

    • refactor(tests): mirror toolcalling test paths and remove chat_prompt duplication

    • docs(optimization): clarify MCP format mapping and GEPA tool limits

    • fix(ci): restore openai strict schema requirements

    Move optional mcp SDK load test from unit to library_integration/mcp and remove broad exception wrapping in tool description candidate generation.

    • test(llm-calls): assert parsed structured output fields

    • feat(scripts): add remote MCP optimizer smoke scripts

    • chore(scripts): throttle remote MCP smoke runs

    • fix(security): remove sensitive identifiers from tool logs

    • chore(scripts): fail fast on optimizer smoke errors

    • refactor(scripts): centralize mcp tool description extraction

    • docs(scripts): clarify context7 metric behavior

    • fix(toolcalling): harden selector resolution and approval parsing

    • fix(api): preserve caller response_format and validate mcp mappings

    • refactor(toolcalling): split selector and rendering ops

    • feat(smoke): assert tool-signature optimization attempts

    • fix(toolcalling): align schema nullability and forward remote auth

    • feat(smoke): enforce single-item runs and prompt-change checks

    • fix(toolcalling): register mcp alias and close failed remote sessions

    • fix(smoke): keep context7 smoke dataset as Dataset instance

    • fix(reporting): add tqdm postfix compatibility for evaluator

    • feat(toolcalling): validate mcp output schemas and wire output overrides

    • chore(scripts): remove all-optimizer remote mcp smoke script

    • fix(reporting): drop duplicate tqdm set_postfix override

    • chore(opik-optimizer): remove unused npm manifest files

    • chore: various examples

    • python-sdk: source default evaluation model from OpikConfig

    • Revert "python-sdk: source default evaluation model from OpikConfig"

    This reverts commit b641b51df9.

    • Update sdks/opik_optimizer/README.md

    Co-authored-by: baz-reviewer[bot] <174234987+baz-reviewer[bot]@users.noreply.github.com>

    • Update sdks/opik_optimizer/scripts/optimize_user_only_example.py

    Co-authored-by: baz-reviewer[bot] <174234987+baz-reviewer[bot]@users.noreply.github.com>

    • chore(scripts): apply pre-commit lint and formatting fixes

    • fix(few-shot): preserve multimodal content-part structure

    • test(few-shot): expand multimodal regression coverage

    • docs(optimization): align role-only examples with docs policy

    • fix(scripts): guard context7 metric against null model output

    • refactor(few-shot): extract multimodal-preservation helper and align docs/script logging

    • fix(few-shot): preserve non-empty multimodal text fallback

    • refactor(multimodal): centralize message-structure preservation helper

    • refactor(toolcalling): collapse component helpers and relocate tool description extraction

    • feat(api): accept cursor MCP config directly in ChatPrompt tools

    • chore(types): fix mypy annotations in scripts and tests

    • chore(examples): remove manual Cursor MCP conversion in user-facing usage

    • docs(readme): align cursor MCP tools usage with automatic ChatPrompt normalization

    • fix(multimodal): harden FSBO content fallback and strengthen tool tests

    • Update tool_optimization.mdx

    • Update generate_fern_docs.py

    • Update tool_optimization.mdx

    • Update prompt_segments_jinja_example.py

    • fix(python-sdk): keep v2 json encoders without pydantic.v1 imports

    • Revert "fix(python-sdk): keep v2 json encoders without pydantic.v1 imports"

    This reverts commit 0796ae201c.

    • docs(optimization): remove jinja role-enforcement examples

    • docs(readme): remove beta wording for MCP optimizer sections


    Co-authored-by: baz-reviewer[bot] <174234987+baz-reviewer[bot]@users.noreply.github.com>

    下载附件