Update trace.py
Browse files
trace.py
CHANGED
|
@@ -2,7 +2,16 @@ import wandb
|
|
| 2 |
|
| 3 |
from wandb.sdk.data_types.trace_tree import Trace
|
| 4 |
|
| 5 |
-
def wandb_trace(rag_option,
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 6 |
wandb.init(project = "openai-llm-rag")
|
| 7 |
|
| 8 |
trace = Trace(
|
|
@@ -37,4 +46,5 @@ def wandb_trace(rag_option, prompt, completion, result, generation_info, llm_out
|
|
| 37 |
)
|
| 38 |
|
| 39 |
trace.log("evaluation")
|
|
|
|
| 40 |
wandb.finish()
|
|
|
|
| 2 |
|
| 3 |
from wandb.sdk.data_types.trace_tree import Trace
|
| 4 |
|
| 5 |
+
def wandb_trace(rag_option,
|
| 6 |
+
prompt,
|
| 7 |
+
completion,
|
| 8 |
+
result,
|
| 9 |
+
generation_info,
|
| 10 |
+
llm_output,
|
| 11 |
+
chain,
|
| 12 |
+
err_msg,
|
| 13 |
+
start_time_ms,
|
| 14 |
+
end_time_ms):
|
| 15 |
wandb.init(project = "openai-llm-rag")
|
| 16 |
|
| 17 |
trace = Trace(
|
|
|
|
| 46 |
)
|
| 47 |
|
| 48 |
trace.log("evaluation")
|
| 49 |
+
|
| 50 |
wandb.finish()
|