Skip to content
Snippets Groups Projects
Commit 97a9620a authored by James Briggs's avatar James Briggs
Browse files

fix: formatting issues

parent d4d35909
No related branches found
No related tags found
No related merge requests found
...@@ -15,7 +15,7 @@ associated with that route. ...@@ -15,7 +15,7 @@ associated with that route.
For example we could provide a dynamic route with associated utterances: For example we could provide a dynamic route with associated utterances:
:: .. code:: python
"what is x to the power of y?" "what is x to the power of y?"
"what is 9 to the power of 4?" "what is 9 to the power of 4?"
...@@ -26,7 +26,7 @@ For example we could provide a dynamic route with associated utterances: ...@@ -26,7 +26,7 @@ For example we could provide a dynamic route with associated utterances:
and we could also provide the route with a schema outlining key features and we could also provide the route with a schema outlining key features
of the function: of the function:
:: .. code:: python
def power(base: float, exponent: float) -> float: def power(base: float, exponent: float) -> float:
"""Raise base to the power of exponent. """Raise base to the power of exponent.
...@@ -79,7 +79,6 @@ it correctly. ...@@ -79,7 +79,6 @@ it correctly.
.. parsed-literal:: .. parsed-literal::
'17:57' '17:57'
......
...@@ -147,7 +147,7 @@ hardware ...@@ -147,7 +147,7 @@ hardware
Initializing Dynamic Routes Initializing Dynamic Routes
=========================== ---------------------------
Similar to the ``02-dynamic-routes.ipynb`` notebook, we will be Similar to the ``02-dynamic-routes.ipynb`` notebook, we will be
initializing some dynamic routes that make use of LLMs for function initializing some dynamic routes that make use of LLMs for function
...@@ -249,7 +249,7 @@ a ``HuggingFaceEncoder`` with ``sentence-transformers/all-MiniLM-L6-v2`` ...@@ -249,7 +249,7 @@ a ``HuggingFaceEncoder`` with ``sentence-transformers/all-MiniLM-L6-v2``
encoder = HuggingFaceEncoder() encoder = HuggingFaceEncoder()
``llama.cpp`` LLM ``llama.cpp`` LLM
================= -----------------
From here, we can go ahead and instantiate our ``llama-cpp-python`` From here, we can go ahead and instantiate our ``llama-cpp-python``
``llama_cpp.Llama`` LLM, and then pass it to the ``llama_cpp.Llama`` LLM, and then pass it to the
......
...@@ -28,7 +28,7 @@ The saved files contain all the information needed to initialize new ...@@ -28,7 +28,7 @@ The saved files contain all the information needed to initialize new
route layers. If we are using a remote index, we can use the route layers. If we are using a remote index, we can use the
`sync features`_ to keep the route layer in sync with the index. `sync features`_ to keep the route layer in sync with the index.
.. _sync features: sync.rst .. _sync features: sync.html
Full Example Full Example
--------------- ---------------
...@@ -45,7 +45,7 @@ load a route layer from file. ...@@ -45,7 +45,7 @@ load a route layer from file.
We start by installing the library: We start by installing the library:
.. code:: ipython3 .. code:: none
!pip install -qU semantic-router !pip install -qU semantic-router
...@@ -54,7 +54,7 @@ Define Route ...@@ -54,7 +54,7 @@ Define Route
First let's create a list of routes: First let's create a list of routes:
.. code:: ipython3 .. code:: python
from semantic_router import Route from semantic_router import Route
......
...@@ -66,3 +66,5 @@ You can try this yourself by running the following: ...@@ -66,3 +66,5 @@ You can try this yourself by running the following:
) )
rl = RouteLayer(encoder=encoder, routes=routes, index=pc_index) rl = RouteLayer(encoder=encoder, routes=routes, index=pc_index)
When initializing the `PineconeIndex` object, we can specify the `sync` parameter.
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment