MCPcopy Create free account
hub / github.com/InfinitiBit/graphbit / with_tool_calls

Method with_tool_calls

python/src/llm/response.rs:426–431  ·  view source on GitHub ↗

Add tool calls (builder pattern)

(&mut self, tool_calls: Vec<PyLlmToolCall>)

Source from the content-addressed store, hash-verified

424
425 /// Add tool calls (builder pattern)
426 fn with_tool_calls(&mut self, tool_calls: Vec<PyLlmToolCall>) -> PyResult<()> {
427 let rust_tool_calls: Vec<CoreLlmToolCall> =
428 tool_calls.into_iter().map(|tc| tc.inner).collect();
429 self.inner = self.inner.clone().with_tool_calls(rust_tool_calls);
430 Ok(())
431 }
432
433 /// Set finish reason (builder pattern)
434 fn with_finish_reason(&mut self, finish_reason: &PyFinishReason) -> PyResult<()> {

Callers 2

Calls 1

cloneMethod · 0.80

Tested by

no test coverage detected