From 2980694cf7249cb4a1186d75ac4f2506ac99f604 Mon Sep 17 00:00:00 2001 From: James Briggs <35938317+jamescalam@users.noreply.github.com> Date: Sat, 30 Dec 2023 13:35:57 +0100 Subject: [PATCH] Update README.md --- README.md | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index 2db0e9b7..a4ecced9 100644 --- a/README.md +++ b/README.md @@ -24,7 +24,7 @@ pip install -qU semantic-router We begin by defining a set of `Decision` objects. These are the decision paths that the semantic router can decide to use, let's try two simple decisions for now — one for talk on _politics_ and another for _chitchat_: ```python -from semantic_router.schema import Route +from semantic_router import Route # we could use this as a guide for our chatbot to avoid political conversations politics = Route( @@ -81,7 +81,7 @@ dl = RouteLayer(encoder=encoder, decisions=decisions) We can now use our decision layer to make super fast decisions based on user queries. Let's try with two queries that should trigger our decisions: ```python -dl("don't you love politics?") +dl("don't you love politics?").name ``` ``` @@ -91,7 +91,7 @@ dl("don't you love politics?") Correct decision, let's try another: ```python -dl("how's the weather today?") +dl("how's the weather today?").name ``` ``` @@ -101,7 +101,7 @@ dl("how's the weather today?") We get both decisions correct! Now lets try sending an unrelated query: ```python -dl("I'm interested in learning about llama 2") +dl("I'm interested in learning about llama 2").name ``` ``` -- GitLab