File tree 2 files changed +5
-11
lines changed 2 files changed +5
-11
lines changed Original file line number Diff line number Diff line change 7
7
8
8
load_dotenv ()
9
9
10
- # Llama cloud
11
- llama_cloud_api_key = os .getenv ("LLAMA_CLOUD_API_KEY" )
12
- org_id = os .getenv ("ORGANIZATION_ID" )
13
10
# Llama cloud
14
11
llama_cloud_api_key = os .getenv ("LLAMA_CLOUD_API_KEY" )
15
12
org_id = os .getenv ("ORGANIZATION_ID" )
16
13
17
14
if not llama_cloud_api_key :
18
15
raise ValueError ("LLAMA_CLOUD_API_KEY environment variable is required" )
19
16
20
- org_id = os .getenv ("ORGANIZATION_ID" )
21
17
if not org_id :
22
18
raise ValueError ("ORGANIZATION_ID environment variable is required" )
23
19
@@ -38,8 +34,8 @@ def llama_client():
38
34
return client
39
35
40
36
def ollama_llm ():
41
- llm = Ollama (model = "llama3.1:latest" , request_timeout = 360.0
42
- )
37
+ llm = Ollama (model = "llama3.1:latest" ,
38
+ request_timeout = 360.0 )
43
39
return llm
44
40
45
41
@@ -53,7 +49,5 @@ def get_opik_tracker():
53
49
project_name = os .getenv ("OPIK_PROJECT_NAME" )
54
50
if not api_key :
55
51
raise ValueError (
56
- "OPIK API KEY not set visit https://www.comet.com/opik\
57
- to set"
58
- )
52
+ "OPIK API KEY not set visit https://www.comet.com/opik to set" )
59
53
return api_key , opik_workspace , project_name
Original file line number Diff line number Diff line change @@ -35,9 +35,9 @@ class LogEvent(Event):
35
35
delta : bool = False
36
36
37
37
38
- def parse_claim (data : str ) -> ClaimInfo :
38
+ def parse_claim (file_path : str ) -> ClaimInfo :
39
39
import json
40
- with open (data , "r" ) as f :
40
+ with open (file_path , "r" ) as f :
41
41
data = json .load (f )
42
42
return ClaimInfo .model_validate (data ) # replace "ClaimInfo".model_validate with actual ClaimInfo class method
43
43
You can’t perform that action at this time.
0 commit comments