diff --git a/README.md b/README.md index b260363a6..2e21a3432 100644 --- a/README.md +++ b/README.md @@ -149,7 +149,7 @@ The how-tos are quick lookups about how to do things. Compared to the tutorials, | [...define a task](./src/documentation/how_tos/how_to_define_a_task.ipynb) | How to come up with a new task and formulate it | | [...implement a task](./src/documentation/how_tos/how_to_implement_a_task.ipynb) | Implement a formulated task and make it run with the Intelligence Layer | | [...debug and log a task](./src/documentation/how_tos/how_to_log_and_debug_a_task.ipynb) | Tools for logging and debugging in tasks | -| [...run the trace viewer](./src/documentation/how_tos/how_to_run_the_trace_viewer.ipynb) | Downloading and running the trace viewer for debugging traces | +| [...use PhariaStudio with traces](./src/documentation/how_tos/how_to_use_pharia_studio_with_traces.ipynb) | Submitting Traces to PhariaStudio for debugging | | **Analysis Pipeline** | | | [...implement a simple evaluation and aggregation logic](./src/documentation/how_tos/how_to_implement_a_simple_evaluation_and_aggregation_logic.ipynb) | Basic examples of evaluation and aggregation logic | | [...create a dataset](./src/documentation/how_tos/how_to_create_a_dataset.ipynb) | Create a dataset used for running a task | diff --git a/src/documentation/how_tos/how_to_log_and_debug_a_task.ipynb b/src/documentation/how_tos/how_to_log_and_debug_a_task.ipynb index 9b62fccc3..f335fd726 100644 --- a/src/documentation/how_tos/how_to_log_and_debug_a_task.ipynb +++ b/src/documentation/how_tos/how_to_log_and_debug_a_task.ipynb @@ -37,10 +37,7 @@ " - To create custom logging messages in a trace use `task_span.log()`.\n", " - To map a complex execution flow of a task into a single trace, pass the `task_span` of the `do_run` to other execution methods (e.g. `Task.run()` or `model.complete()`). \n", " - If the execution method is not provided by the intelligence layer, the tracing of input and output has to happen manually. See the implementation of `Task.run()` for an example.\n", - " - Use the [trace viewer](./how_to_run_the_trace_viewer.ipynb) to view and inspect a trace\n", - " - Use and display an `InMemoryTracer` in a notebook to automatically send the trace data to the trace viewer.\n", - " - Note: This also works for traces of the `Runner` and the `Evaluator`.\n", - " - To create persistent traces, use the `FileTracer` instead. This creates files which can manually be uploaded in the trace viewer UI." + " - Use the [submit trace functionality of the `StudioClient`](./how_to_use_pharia_studio_with_traces.ipynb) to view and inspect a trace in PhariaStudio" ] }, { @@ -77,10 +74,6 @@ "\n", "tracer = InMemoryTracer()\n", "DummyTask().run(\"\", tracer)\n", - "# ! make sure to run the trace viewer docker container to get the improved display !\n", - "# display an InMemoryTracer in a notebook and send the data to the trace viewer\n", - "display(tracer)\n", - "\n", "pass" ] } diff --git a/src/documentation/how_tos/how_to_run_the_trace_viewer.ipynb b/src/documentation/how_tos/how_to_use_pharia_studio_with_traces.ipynb similarity index 89% rename from src/documentation/how_tos/how_to_run_the_trace_viewer.ipynb rename to src/documentation/how_tos/how_to_use_pharia_studio_with_traces.ipynb index 3c9a08f19..6516cde7b 100644 --- a/src/documentation/how_tos/how_to_run_the_trace_viewer.ipynb +++ b/src/documentation/how_tos/how_to_use_pharia_studio_with_traces.ipynb @@ -36,10 +36,8 @@ "source": [ "from uuid import uuid4\n", "\n", - "from intelligence_layer.connectors.studio.studio import StudioClient\n", - "from intelligence_layer.core.task import Task\n", - "from intelligence_layer.core.tracer.in_memory_tracer import InMemoryTracer\n", - "from intelligence_layer.core.tracer.tracer import TaskSpan\n", + "from intelligence_layer.connectors import StudioClient\n", + "from intelligence_layer.core import InMemoryTracer, Task, TaskSpan\n", "\n", "\n", "# Step 0\n", diff --git a/src/intelligence_layer/connectors/studio/studio.py b/src/intelligence_layer/connectors/studio/studio.py index 1b2a51309..9a256aa35 100644 --- a/src/intelligence_layer/connectors/studio/studio.py +++ b/src/intelligence_layer/connectors/studio/studio.py @@ -8,7 +8,7 @@ from pydantic import BaseModel from requests.exceptions import ConnectionError, MissingSchema -from intelligence_layer.core.tracer.tracer import ExportedSpan, ExportedSpanList, Tracer +from intelligence_layer.core import ExportedSpan, ExportedSpanList, Tracer class StudioProject(BaseModel):