https://www.boundaryml.com logo
deep-research models
# questions
s
Does BAML support the openai deepresearch model or perplexity deepresearch? I would like to integrate it into my new deepresearch tool https://github.com/smorin/thoth
b
You can use any backend/provider you want if you go through the modular API! https://docs.boundaryml.com/guide/baml-advanced/modular-api
For the openai model specifically you might be able to use the openai-responses provider https://docs.boundaryml.com/ref/llm-client-providers/open-ai-responses-api but with how long deep research runs take, modular with webhook might be better.
s
Yeah, that's part of the question that I have. Is it possible to parse the final results later? Maybe detach the sending from the processing because of that async nature of the APIs.
b
Yep! The modular API allows you to handle that however you want
Here's one of the examples from the docs https://docs.boundaryml.com/guide/baml-advanced/modular-api:
Copy code
import requests
# requests is not async so for simplicity we'll use the sync client.
from baml_client.sync_client import b

def run():
  # Get the HTTP request object.
  req = b.request.ExtractResume("John Doe | Software Engineer | BSc in CS")

  # Send the HTTP request.
  res = requests.post(url=req.url, headers=req.headers, json=req.body.json())

  # Parse the LLM response.
  parsed = b.parse.ExtractResume(response.json()["choices"][0]["message"]["content"])

  # Fully parsed Resume type.
  print(parsed)
So you can easily imagine replacing
requests.post
with anything you want