Adding Foundry support for FastAPI web app with SQL backend

Hi there :slight_smile:

We’re a startup building an agent optimization platform. One of our clients is using Palantir Foundry to store their data and they have asked us to integrate our platform into Palantir Foundry. Essentially, our platform is a FastAPI server connected to a SQL DB where it reads/writes information (sometimes on the hot path). Our schema backend implements ~100 functions that, under the hood, call a bunch of SQL queries. We also have maximum inner product search over vectors (we use extensions like pgvector in Postgres).

For integration into Foundry, I was thinking about representing our DB as an Ontology. Couple of questions:

  • Does this make sense? Is the latency and parallelism going to be okay?
  • Is there a better way to do this than creating an ontology?
  • How would you handle maintainability? Our schema still changes, and I kind of want to avoid having to manually tweak the ontology every time we change it.
  • Is here someone who would like to help with that? Sort of like a consulting gig.