mirror of
https://github.com/qdrant/landing_page.git
synced 2026-10-04 10:28:29 +02:00
fix: fix python snippets formatting
This commit is contained in:
@@ -2,8 +2,8 @@
|
||||
from qdrant_client import QdrantClient, models
|
||||
|
||||
client = QdrantClient(
|
||||
url="https://xyz-example.qdrant.io:6333",
|
||||
api_key="<your-api-key>",
|
||||
url="https://xyz-example.qdrant.io:6333",
|
||||
api_key="<your-api-key>",
|
||||
cloud_inference=True
|
||||
)
|
||||
|
||||
@@ -17,8 +17,9 @@ client.upsert(
|
||||
image="https://qdrant.tech/example.png",
|
||||
model="jinaai/jina-clip-v2",
|
||||
options={
|
||||
"jina-api-key": "<your_jinaai_api_key>",
|
||||
"dimensions": 512},
|
||||
"jina-api-key": "<your_jinaai_api_key>",
|
||||
"dimensions": 512
|
||||
},
|
||||
),
|
||||
"text": models.Document(
|
||||
text="Mars, the red planet",
|
||||
@@ -32,4 +33,5 @@ client.upsert(
|
||||
)
|
||||
],
|
||||
)
|
||||
|
||||
```
|
||||
+6
-6
@@ -2,19 +2,19 @@
|
||||
from qdrant_client import QdrantClient, models
|
||||
|
||||
client = QdrantClient(
|
||||
url="https://xyz-example.qdrant.io:6333",
|
||||
api_key="<your-api-key>",
|
||||
url="https://xyz-example.qdrant.io:6333",
|
||||
api_key="<your-api-key>",
|
||||
cloud_inference=True
|
||||
)
|
||||
|
||||
client.query_points(
|
||||
collection_name="<your_collection_name>",
|
||||
query=models.Document(
|
||||
text="How to bake cookies?",
|
||||
model="openai/text-embedding-3-large",
|
||||
text="How to bake cookies?",
|
||||
model="openai/text-embedding-3-large",
|
||||
options={
|
||||
"openai-api-key": "<your_openai_api_key>",
|
||||
"dimensions": 512
|
||||
"openai-api-key": "<your_openai_api_key>",
|
||||
"dimensions": 512
|
||||
}
|
||||
)
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user