Skip to content

feat: Update LangChain runners to implement Runner protocol returning RunnerResult#150

Draft
jsonbailey wants to merge 1 commit intojb/aic-2388/openai-runner-protocolfrom
jb/aic-2388/langchain-runner-protocol
Draft

feat: Update LangChain runners to implement Runner protocol returning RunnerResult#150
jsonbailey wants to merge 1 commit intojb/aic-2388/openai-runner-protocolfrom
jb/aic-2388/langchain-runner-protocol

Conversation

@jsonbailey
Copy link
Copy Markdown
Contributor

Summary

  • LangChainModelRunner.run() implements the unified Runner protocol; returns RunnerResult with content, metrics, raw, and parsed fields. Structured output is supported via the output_type parameter.
  • LangChainAgentRunner.run() updated to return RunnerResult; populates tool_calls in LDAIMetrics from observed tool call names in the message response.
  • Legacy invoke_model() and invoke_structured_model() retained as deprecated adapters that delegate to run() for backward compatibility.

Stacking

Stacked on top of jb/aic-2388/openai-runner-protocol (PR #149).

Test plan

  • make test-langchain — all 81 LangChain provider tests pass
  • make test — all 261 tests across server-ai, langchain, and openai packages pass

🤖 Generated with Claude Code

… RunnerResult

- LangChainModelRunner.run() implements the unified Runner protocol; returns RunnerResult
  with content, metrics (LDAIMetrics), raw, and parsed fields. Structured output is
  supported via the output_type parameter.
- LangChainAgentRunner.run() updated to return RunnerResult; populates tool_calls in
  LDAIMetrics from observed tool_calls in message responses.
- Legacy invoke_model() and invoke_structured_model() retained as deprecated adapters
  that delegate to run() and wrap results into ModelResponse / StructuredResponse for
  backward compatibility.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant