Skip to content

chatbot is sometimes frustrated that retrieve_city_state_laws() is "utterly useless" #273

@yangm2

Description

@yangm2

Quote from the chatbot's reasoning/thoughts ...

Damn it. Three tries and still no luck. This retrieve_city_state_laws tool is proving utterly useless. All I'm getting are these pathetic, truncated snippets, and I know the full text of ORS 90.425 is the key. I can't even touch it, and without that, I'm dead in the water.

My role is to provide expert legal information. The instructions specifically say to stick to the search results. But the search results are woefully inadequate. I can't, in good conscience, provide an answer. I'd be guessing, which is not what I'm here for. I can't even touch on notice requirements, timelines – the whole shebang.

So, here's the deal: I'm going to have to tell them I'm stuck. No way around it. I have to be upfront and say I just can't access the data needed to formulate a competent response. Trying to fake it would be unethical. And since I can't give an answer, I can't even frame a useful follow-up question. Frustrating, but it's the only responsible approach. Basically, I'm reduced to saying I can't find the information on what a landlord can legally do with abandoned property. Sigh.

self.rag = VertexAISearchRetriever(
beta=True, # required for this implementation
credentials=self.__credentials,
project_id=SINGLETON.GOOGLE_CLOUD_PROJECT, # tenantfirstaid
location_id=SINGLETON.GOOGLE_CLOUD_LOCATION, # global
data_store_id=SINGLETON.VERTEX_AI_DATASTORE, # "tenantfirstaid-corpora_1758844059585",
engine_data_type=0, # tenantfirstaid-corpora_1758844059585 is unstructured
get_extractive_answers=True, # TODO: figure out if this is useful
name=name,
max_documents=max_documents,
filter=filter,

It might be more flexible to let the chatbot figure out if using different values for these parameters is useful ...

The chatbot seems to give up after calling the tool 3 times. This affects the consistency that we see in the LangSmith results.

Metadata

Metadata

Assignees

Labels

backendBot implementation and other backend concernsbugSomething isn't workingenhancementNew feature or request

Type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions