Skip to content

(pkg-R) Encountering latency with querychat server when using complex database #208

@jperone

Description

@jperone

Hello, thank you for this package and the update, it's been integral to my work.

I've run into a loading issue with my app after converting to use version 0.2.0.9000. In the initial pkg version, I supplied the full system prompt, data description, and extra instructions so nothing was generated by the LLM, which produced a very quick app startup time. Now, I supply it the same way but I'm getting 50K+ms of load time on app startup. I profiled and it looks like the get_schema_impl() method is where the bottleneck is:

Image

My data source is a duckdb table with 1.5M rows with about 52 columns, of which I intend to supply the full schema in the prompt, as it won't change much in my case. It seems as though calling $server() also creates a call to my duckdb conn to imply the schema, which I don't need as I supply it to the LLM. Maybe I'm misinterpreting some of the profiling, but I was wondering if there is a way to circumvent the schema imply, if data_description is supplied? Thank you

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions