byron mackay
byron mackay
LLangfuse
Created by byron mackay on 4/22/2024 in #get-support
When I attempt to get a prompt from
FIXED: force reinstalled langfuse's package did the trick
6 replies
LLangfuse
Created by byron mackay on 4/22/2024 in #get-support
When I attempt to get a prompt from
No description
6 replies
LLangfuse
Created by byron mackay on 4/22/2024 in #get-support
When I attempt to get a prompt from
On top of that, I see that the Prompt_Chat and Prompt_Text objects do in fact have a type property
6 replies
LLangfuse
Created by byron mackay on 4/22/2024 in #get-support
When I attempt to get a prompt from
Oddly enough, even though the type in the json is "text", the code returns a Prompt_Chat object instead of a Prompt_Text object
6 replies
LLangfuse
Created by byron mackay on 4/22/2024 in #get-support
When I attempt to get a prompt from
JSON response
{
"id": "clvbdigib000r13c73mrbbc3e",
"createdAt": "2024-04-22T19:52:02.580Z",
"updatedAt": "2024-04-22T19:52:19.451Z",
"projectId": "cltyrwd9100012wl7n2r3mrop",
"createdBy": "cltyrsxly00002wl75il4gufi",
"prompt": "Determine how the company...",
"name": "PROMPT_NAME",
"version": 1,
"type": "text",
"isActive": true,
"config": {},
"tags": [
"trend"
]
}
{
"id": "clvbdigib000r13c73mrbbc3e",
"createdAt": "2024-04-22T19:52:02.580Z",
"updatedAt": "2024-04-22T19:52:19.451Z",
"projectId": "cltyrwd9100012wl7n2r3mrop",
"createdBy": "cltyrsxly00002wl75il4gufi",
"prompt": "Determine how the company...",
"name": "PROMPT_NAME",
"version": 1,
"type": "text",
"isActive": true,
"config": {},
"tags": [
"trend"
]
}
6 replies
LLangfuse
Created by byron mackay on 4/22/2024 in #get-support
When I attempt to get a prompt from
Environment: - langfuse==2.27.1 - language: python - docker file is up to date
6 replies
LLangfuse
Created by Bhasker on 4/18/2024 in #get-support
which version are you using? run_id not
It looks like we were having the same issue. The problem has been resolved since I updated to 2.27
3 replies
LLangfuse
Created by Bhasker on 4/18/2024 in #get-support
which version are you using? run_id not
I was on 2.26.3. I'm now updated to 2.27.0. Thanks!
3 replies
LLangfuse
Created by byron mackay on 4/15/2024 in #get-support
My local instance of langfuse is showing
Working now. Thanks, @Marc!
8 replies
LLangfuse
Created by byron mackay on 4/15/2024 in #get-support
My local instance of langfuse is showing
def langfuse_callback(tags):
langfuse = Langfuse()
trace = langfuse.trace(
tags=tags
)
return trace.get_langchain_handler()
def langfuse_callback(tags):
langfuse = Langfuse()
trace = langfuse.trace(
tags=tags
)
return trace.get_langchain_handler()
8 replies
LLangfuse
Created by byron mackay on 4/15/2024 in #get-support
My local instance of langfuse is showing
template = PromptTemplate(template="{query} Context: {results}", input_variables=["query", "results"])

chain = LLMChain(llm=llm, prompt=template)



print(chain.invoke({"query": "What are the largest cost drivers in 2023?", "results": results},
config={
"callbacks": [langfuse_callback(["rag"])]
}
)
)
template = PromptTemplate(template="{query} Context: {results}", input_variables=["query", "results"])

chain = LLMChain(llm=llm, prompt=template)



print(chain.invoke({"query": "What are the largest cost drivers in 2023?", "results": results},
config={
"callbacks": [langfuse_callback(["rag"])]
}
)
)
8 replies
LLangfuse
Created by byron mackay on 4/10/2024 in #get-support
I'm having issues with the `api/public/
Hi Marc, I was able to get it fixed. I needed to update the DB. Sorry for the confusion.
7 replies
LLangfuse
Created by byron mackay on 4/10/2024 in #get-support
I'm having issues with the `api/public/
I have the latest for both my python langfuse library and the langfuse docker image
7 replies
LLangfuse
Created by byron mackay on 4/10/2024 in #get-support
I'm having issues with the `api/public/
Relevant stack trace:
File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/langfuse/client.py", line 2368, in get_langchain_handler
self.link(span, run_name)
File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/langfuse/client.py", line 2339, in link
self.langfuse.client.dataset_run_items.create(
File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/langfuse/api/resources/dataset_run_items/client.py", line 88, in create
return pydantic_v1.parse_obj_as(DatasetRunItem, _response.json()) # type: ignore
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/pydantic/v1/tools.py", line 38, in parse_obj_as
return model_type(__root__=obj).__root__
^^^^^^^^^^^^^^^^^^^^^^^^
File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/pydantic/v1/main.py", line 341, in __init__
raise validation_error
pydantic.v1.error_wrappers.ValidationError: 1 validation error for ParsingModel[DatasetRunItem]
__root__ -> traceId
field required (type=value_error.missing)
File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/langfuse/client.py", line 2368, in get_langchain_handler
self.link(span, run_name)
File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/langfuse/client.py", line 2339, in link
self.langfuse.client.dataset_run_items.create(
File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/langfuse/api/resources/dataset_run_items/client.py", line 88, in create
return pydantic_v1.parse_obj_as(DatasetRunItem, _response.json()) # type: ignore
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/pydantic/v1/tools.py", line 38, in parse_obj_as
return model_type(__root__=obj).__root__
^^^^^^^^^^^^^^^^^^^^^^^^
File "/Library/Frameworks/Python.framework/Versions/3.12/lib/python3.12/site-packages/pydantic/v1/main.py", line 341, in __init__
raise validation_error
pydantic.v1.error_wrappers.ValidationError: 1 validation error for ParsingModel[DatasetRunItem]
__root__ -> traceId
field required (type=value_error.missing)
7 replies