@@ -21,7 +21,7 @@ To get started with _semantic-router_ we install it like so:
...
@@ -21,7 +21,7 @@ To get started with _semantic-router_ we install it like so:
pip install -qU semantic-router
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_:
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 routes for now — one for talk on _politics_ and another for _chitchat_:
```python
```python
fromsemantic_router.schemaimportRoute
fromsemantic_router.schemaimportRoute
...
@@ -51,11 +51,11 @@ chitchat = Route(
...
@@ -51,11 +51,11 @@ chitchat = Route(
],
],
)
)
# we place both of our decisions together into single list
# we place both of our routes together into single list
decisions=[politics,chitchat]
routes=[politics,chitchat]
```
```
We have our decisions ready, now we initialize an embedding / encoder model. We currently support a `CohereEncoder` and `OpenAIEncoder` — more encoders will be added soon. To initialize them we do:
We have our routes ready, now we initialize an embedding / encoder model. We currently support a `CohereEncoder` and `OpenAIEncoder` — more encoders will be added soon. To initialize them we do: