51 matches across 1 files for func main lang:Python path:libs/partners/perplexity/langchain_perplexity/chat_models.py
snippet_mode: auto · sorted by relevance
libs/partners/perplexity/langchain_perplexity/chat_models.py PYTHON 51 matches · showing 5 view file →
30 ChatMessage,
31 ChatMessageChunk,
32 FunctionMessageChunk,
33 HumanMessage,
34 HumanMessageChunk,
· · ·
48from langchain_core.tools import BaseTool
49from langchain_core.utils import get_pydantic_field_names, secret_from_env
50from langchain_core.utils.function_calling import (
51 convert_to_json_schema,
52 convert_to_openai_tool,
· · ·
163
164def _is_builtin_tool(tool: dict) -> bool:
165 """Return True if `tool` is a Responses-API built-in (non-`function`) tool.
166
167 Perplexity's Agent API ships built-in tools (e.g. `web_search`,
· · ·
168 `code_interpreter`) that are identified by a `type` value other than
169 `"function"`. Chat Completions only accepts function tools, so any tool
170 failing this check forces the Responses route.
171 """
· · ·
172 return "type" in tool and tool["type"] != "function"
173
174
+ 46 more matches in this file
Search syntax
auth loginboth terms (AND is implicit)
auth OR logineither term
NOT path:vendorexclude matches
"exact phrase"quoted exact match
/func\s+Test/regex
handler~1fuzzy (Levenshtein 1)
file:*_test.gofilename glob
path:pkg/auth/**full path glob
lang:golanguage filter

Search any public repo from your terminal

This page calls POST /api/v1/code_search. Same tool, available over MCP for Claude/Cursor/Copilot.