File tree Expand file tree Collapse file tree 6 files changed +1890
-1616
lines changed Expand file tree Collapse file tree 6 files changed +1890
-1616
lines changed Original file line number Diff line number Diff line change @@ -10,7 +10,7 @@ dev = [
10
10
" dirty-equals>=0.9.0" ,
11
11
" httpx>=0.28.1" ,
12
12
" inline-snapshot>=0.19.3" ,
13
- " mcp>=1.4.1 ; python_version >= '3.10'" ,
13
+ " mcp>=1.12.2 ; python_version >= '3.10'" ,
14
14
" micropip>=0.9.0; python_version >= '3.12'" ,
15
15
" pytest>=8.3.3" ,
16
16
" pytest-pretty>=1.2.0" ,
Original file line number Diff line number Diff line change @@ -106,19 +106,13 @@ The tools are injected into the global namespace automatically - no discovery fu
106
106
. array ( z . string ( ) )
107
107
. optional ( )
108
108
. describe ( 'List of available tools for injection (enables tool injection when provided)' ) ,
109
- tool_name_mapping : z
110
- . record ( z . string ( ) )
111
- . optional ( )
112
- . describe ( 'Mapping of python_name -> original_mcp_name for tool name conversion' ) ,
113
109
} ,
114
110
async ( {
115
111
python_code,
116
112
tools = [ ] ,
117
- tool_name_mapping = { } ,
118
113
} : {
119
114
python_code : string
120
115
tools ?: string [ ]
121
- tool_name_mapping ?: Record < string , string >
122
116
} ) => {
123
117
const logPromises : Promise < void > [ ] = [ ]
124
118
@@ -185,7 +179,6 @@ The tools are injected into the global namespace automatically - no discovery fu
185
179
{
186
180
enableToolInjection : true ,
187
181
availableTools : tools ,
188
- toolNameMapping : tool_name_mapping ,
189
182
timeoutSeconds : 30 ,
190
183
elicitationCallback,
191
184
} as ToolInjectionConfig ,
Original file line number Diff line number Diff line change @@ -13,7 +13,6 @@ export interface CodeFile {
13
13
export interface ToolInjectionConfig {
14
14
enableToolInjection : boolean
15
15
availableTools : string [ ]
16
- toolNameMapping ?: Record < string , string > // python_name -> original_mcp_name
17
16
timeoutSeconds : number
18
17
// deno-lint-ignore no-explicit-any
19
18
elicitationCallback ?: ( request : any ) => Promise < any >
@@ -158,7 +157,6 @@ function injectToolFunctions(
158
157
globals ,
159
158
config . availableTools ,
160
159
tool_callback ,
161
- config . toolNameMapping ,
162
160
)
163
161
164
162
log ( 'info' , `Tool injection complete. Available tools: ${ config . availableTools . join ( ', ' ) } ` )
Original file line number Diff line number Diff line change @@ -699,6 +699,8 @@ def __init__(
699
699
allow_sampling : bool = True ,
700
700
max_retries : int = 1 ,
701
701
sampling_model : models .Model | None = None ,
702
+ allow_elicitation : bool = True ,
703
+ elicitation_callback : ElicitationFnT | None = None ,
702
704
** kwargs : Any ,
703
705
):
704
706
# Handle deprecated sse_read_timeout parameter
@@ -727,6 +729,8 @@ def __init__(
727
729
self .allow_sampling = allow_sampling
728
730
self .max_retries = max_retries
729
731
self .sampling_model = sampling_model
732
+ self .allow_elicitation = allow_elicitation
733
+ self .elicitation_callback = elicitation_callback
730
734
self .read_timeout = read_timeout
731
735
732
736
@property
Original file line number Diff line number Diff line change @@ -77,7 +77,7 @@ tavily = ["tavily-python>=0.5.0"]
77
77
# CLI
78
78
cli = [" rich>=13" , " prompt-toolkit>=3" , " argcomplete>=3.5.0" ]
79
79
# MCP
80
- mcp = [" mcp>=1.11.0 ; python_version >= '3.10'" ]
80
+ mcp = [" mcp>=1.12.2 ; python_version >= '3.10'" ]
81
81
# Evals
82
82
evals = [" pydantic-evals=={{ version }}" ]
83
83
# A2A
You can’t perform that action at this time.
0 commit comments